id summary reporter owner description type status priority component severity resolution keywords cc release 7307 Comment diffs do not work in Trac 0.12 with MasterTicketsPlugin enabled ed.porter@… Noah Kantrowitz "Trac 0.12 allows ticket comments to be edited, and comments that have been edited gain a ""diff"" button. Clicking here should show the comment's change history, but with MasterTicketsPlugin enabled it causes an error: {{{ Oops… Trac detected an internal error: KeyError: 'fields' Python Traceback Most recent call last: * File ""build/bdist.linux-x86_64/egg/trac/web/main.py"", line 513, in _dispatch_request Local variables: Name Value dispatcher e env env_error None req resp [] * File ""build/bdist.linux-x86_64/egg/trac/web/main.py"", line 245, in dispatch Local variables: Name Value chosen_handler chrome e err (, req resp ('diff_view.html', {'longcol': '', 'new_version': 1, 'cnum': 3, ... self * File ""build/bdist.linux-x86_64/egg/trac/web/main.py"", line 359, in _post_process_request Local variables: Name Value args ('diff_view.html', {'longcol': '', 'new_version': 1, 'cnum': 3, ... extra_arg_count 3 f nbargs 3 req resp ('diff_view.html', {'longcol': '', 'new_version': 1, 'cnum': 3, ... self * File ""build/bdist.linux-i686/egg/mastertickets/web_ui.py"", line 64, in post_process_request Code fragment: Line 59 # Add link to depgraph if needed 60 if links: 61 add_ctxtnav(req, 'Depgraph', req.href.depgraph(tkt.id)) 62 63 for change in data.get('changes', []): 64 for field, field_data in change['fields'].iteritems(): 65 if field in self.fields: 66 if field_data['new'].strip(): 67 new = set([int(n) for n in field_data['new'].split(',')]) 68 else: 69 new = set() Local variables: Name Value change {'diffs': [[{'base': {'lines': [, req self template 'diff_view.html' tkt File ""build/bdist.linux-x86_64/egg/trac/web/main.py"", line 513, in _dispatch_requestFile ""build/bdist.linux-x86_64/egg/trac/web/main.py"", line 245, in dispatchFile ""build/bdist.linux-x86_64/egg/trac/web/main.py"", line 359, in _post_process_requestFile ""build/bdist.linux-i686/egg/mastertickets/web_ui.py"", line 64, in post_process_request for field, field_data in change['fields'].iteritems(): System Information: User Agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.2.3) Gecko/20100404 Fedora/3.6.3-0.el5.mh Firefox/3.6.3 }}} The comment diff is displayed as expected if MasterTicketsPlugin is disabled." defect closed normal MasterTicketsPlugin normal duplicate 0.12