Merge lp:~julian-edwards/launchpad/oops-dspr-page-bug-592417 into lp:launchpad

Proposed by Julian Edwards on 2010-07-06
Status: Merged
Merged at revision: 11095
Proposed branch: lp:~julian-edwards/launchpad/oops-dspr-page-bug-592417
Merge into: lp:launchpad
Diff against target: 0 lines
To merge this branch: bzr merge lp:~julian-edwards/launchpad/oops-dspr-page-bug-592417
Reviewer Review Type Date Requested Status
Gary Poster (community) cp Approve on 2010-07-08
Michael Nelson (community) ui 2010-07-06 Approve on 2010-07-06
Graham Binns (community) code 2010-07-06 Approve on 2010-07-06
Review via email: mp+29273@code.launchpad.net

Commit Message

Prevent the distroseriessourcepackagerelease page from OOPSing when trying to render information about deleted package files.

Description of the Change

= Summary =
Fix https://bugs.edge.launchpad.net/soyuz/+bug/592417

The page is blowing up when trying to render file details for deleted files.

== Proposed fix ==
The template should render an unlinked filename with no details if the file
was deleted.

== Pre-implementation notes ==
Basically the same implementation as
https://code.edge.launchpad.net/~michael.nelson/launchpad/580181-only-one-ds-
cache/+merge/26329
as discussed with noodles.

== Implementation details ==
Simple fix to the template to detect if the file was deleted or not, and
renders:

filename (deleted)

instead of the linked files with size/md5 etc.

== Tests ==
bin/test -cvv test_distrosourcepackagerelease

== Demo and Q/A ==
Already on dogfood and working fine. See:
https://dogfood.launchpad.net/ubuntu/+source/uex/1.0.0.9-1/+index

To post a comment you must log in.
Graham Binns (gmb) :
review: Approve (code)
Michael Nelson (michael.nelson) wrote :

Thanks Julian. A small UI improvement that I'll leave up to you:

AFAICS, the other page that was fixed didn't include the size and checksum columns, so when I look at the example page, it almost seems as if the deleted file isn't part of the table.

A really easy fix is to change the class for that table from "summary" (which does nothing afaics) to "listing" - and see what you think (in case you haven't seen it, you can do it directly in the Chromium inspector to try it out)

Another option would be to add "N/A" or whatever we use as the standard for not applicable for the size/md5 for deleted files, but I don't think this is necessary when the "listing" class is used.

review: Approve (ui)
Julian Edwards (julian-edwards) wrote :

As discussed on IRC, I've changed the table class to "narrow listing" and it
looks much better.

Thanks guys.

Gary Poster (gary) :
review: Approve (cp)

Preview Diff

Empty