Person.__repr__ causes an oops masking the real error because displayname is unicode
Bug #575976 reported by
Diogo Matsubara
This bug affects 2 people
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Launchpad itself |
Fix Released
|
Low
|
Curtis Hovey |
Bug Description
As seen on OOPS-1582EB1587 a UnicodeEncodeError was raised while GET'ing the +reviewaccount page for a person and the person display name contains non-ascii characters.
Related branches
lp:~sinzui/launchpad/oopsless-repr
- Eleanor Berger (community): Approve (code)
-
Diff: 169 lines (+68/-10)6 files modifiedlib/canonical/launchpad/database/account.py (+2/-1)
lib/canonical/launchpad/tests/test_account.py (+17/-0)
lib/lp/registry/model/distribution.py (+4/-3)
lib/lp/registry/model/person.py (+2/-2)
lib/lp/registry/tests/test_distribution.py (+28/-4)
lib/lp/registry/tests/test_person.py (+15/-0)
Changed in launchpad-registry: | |
milestone: | series-future → 10.05 |
assignee: | nobody → Curtis Hovey (sinzui) |
status: | Triaged → In Progress |
Changed in launchpad-registry: | |
status: | In Progress → Fix Committed |
tags: |
added: qa-ok removed: qa-needstesting |
Changed in launchpad-registry: | |
status: | Fix Committed → Fix Released |
To post a comment you must log in.
The oops was created *after* the canonical_ urldata_ iterator raised its own error because henninge hacked the URL to non-existant person. The error message wanted to tell henninge to be a good boy, but the NoCanonicalUrl uses the __repr__ of the object, which for many launchpad objects, will contain unicode.