What steps will reproduce the problem?
1. Add non-numberic characters to the "bugs" field.
2. Attempt to view the issue page will give a page with an error starting
with this:
ValueError at /r/7/
invalid literal for int() with base 10: 'bug'
The problem is in reviews/models.py, line 286:
def get_bug_list(self):
"""
Returns a sorted list of bugs associated with this review request.
"""
bugs = re.split(r"[, ]+", self.bugs_closed)
286: bugs.sort(cmp=lambda x,y: int(x) - int(y))
return bugs
Some possible fixes:
1. cmp function in sort is changed to be more general
2. add try/except around bugs.sort. bug lists with non-numeric characters
are unsorted.
3. Extract just the numeric parts of each bug id before sorting.