#280 Add a template for the blocker bug status email
Merged a year ago by kparal. Opened 2 years ago by adamwill.
fedora-qa/ adamwill/blockerbugs template-statusmail  into  develop

@@ -385,6 +385,22 @@ 

      return response

  

  

+ @main.route('/milestone/<int:num>/<release_name>/statusmail')

+ def display_release_statusmail(num, release_name):

+     release = Release.query.filter_by(number=num).first()

+     milestone = Milestone.query.filter_by(release=release, version=release_name).first()

+     if not milestone:

+         abort(404)

+     bugz = get_milestone_bugs(milestone)

+     accepted = bugz["Accepted Blockers"] + bugz["Accepted 0-day Blockers"] + bugz["Accepted Previous Release Blockers"]

+     proposed = bugz["Proposed Blockers"]

+ 

+     response = make_response(render_template(

+         'statusmail.txt', accepted=accepted, proposed=proposed, milestone=release_name, release_num=num))

+     response.mimetype = 'text/plain'

+     return response

+ 

+ 

  @main.route('/milestone/<int:num>/<milestone_name>/info')

  def display_milestone_info(num, milestone_name):

      release = Release.query.filter_by(number=num).first()

@@ -14,7 +14,8 @@ 

          <a role="button" href="./buglist" class="btn btn-light {{ subnavactive('buglist') }}">Bug List</a>

          <a role="button" href="./updates" class="btn btn-light {{ subnavactive('updates') }}">Updates</a>

          <a role="button" href="./irc" class="btn btn-light {{ subnavactive('irc') }}">IRC Format</a>

-         <a role="button" href="./requests" class="btn btn-light {{ subnavactive('irc') }}">Requests</a>

+         <a role="button" href="./requests" class="btn btn-light {{ subnavactive('requests') }}">Requests</a>

+         <a role="button" href="./statusmail" class="btn btn-light {{ subnavactive('statusmail') }}">Status Mail</a>

      </div>

  </div>

  {% endblock %}

@@ -0,0 +1,41 @@ 

+ From: 

+ To: devel@lists.fedoraproject.org, test@lists.fedoraproject.org

+ Subject: Fedora Linux {{ release_num }} {{ milestone.title() }} blocker status summary

+ 

+ Hi folks!

+ 

+ Action summary

+ ==============

+ 

+ Accepted blockers

+ -----------------

+ {% for bug in accepted %}

+ {{ loop.index }}. {{ bug.component }} - {{ bug.url.replace("show_bug.cgi?id=", "") }} - {{ bug.status }}: 

+ {% endfor %}

+ 

+ Proposed blockers

+ -----------------

+ {% for bug in proposed %}

+ {{ loop.index }}. {{ bug.component }} - {{ bug.url.replace("show_bug.cgi?id=", "") }} - {{ bug.status }}: 

+ {% endfor %}

+ 

+ Bug-by-bug detail

+ =================

+ 

+ Accepted blockers

+ -----------------

+ {% for bug in accepted %}

+ {{ loop.index }}. {{ bug.component }} - {{ bug.url.replace("show_bug.cgi?id=", "") }} - {{ bug.status }}

+ {{ bug.summary }}

+ 

+ 

+ {% endfor %}

+ 

+ Proposed blockers

+ -----------------

+ {% for bug in proposed %}

+ {{ loop.index }}. {{ bug.component }} - {{ bug.url.replace("show_bug.cgi?id=", "") }} - {{ bug.status }}

+ {{ bug.summary }}

+ 

+ 

+ {% endfor %}

I didn't get around to adding tests, but I used this to create this week's blocker status mail and it works, so, hey. I could get a bit fancy and add automatic texts for blockers with updates in testing, and auto-generate an intro with dates and stuff, but didn't get around to that yet either.

Thanks for the PR. Since you're currently using it in your deployment, I assume it's not necessary to merge it immediately. You can continue to fine-tune it, if needed, and I'll look at it once F39 is out :-)

Not immediately, no, but we're gonna want to merge it so the new operations architect can use it when they take this back over from me...

also, kinda a note to self, when we do merge this, we should update https://docs.fedoraproject.org/en-US/program_management/pgm_guide/sop/blocker-email/ to recommend using it.

Commit ad51cce fixes this pull-request

Pull-Request has been merged by kparal

a year ago

@frantisekz Can you please deploy to stg, and if nothing obviously breaks, to production, so that we can test this new feature? Thanks!

@adamwill It's now deployed. If you notice some problem, shout :)