Modify ↓
Opened 14 years ago
Closed 13 years ago
#9008 closed defect (fixed)
indexerror when referencing a new ticket
| Reported by: | Kenny Bohle | Owned by: | ejucovy |
|---|---|---|---|
| Priority: | normal | Component: | TracBacksPlugin |
| Severity: | normal | Keywords: | indexerror |
| Cc: | Trac Release: | 0.11 |
Description
The plugin will create an internal error when a new ticket without a changelog is referenced. See the screenshots below for more information.
Attachments (2)
Change History (9)
Changed 14 years ago by
| Attachment: | issue1.png added |
|---|
Changed 14 years ago by
| Attachment: | issue2.png added |
|---|
comment:1 Changed 14 years ago by
comment:2 Changed 14 years ago by
| Status: | new → assigned |
|---|
I'll try to take a look this weekend. Thanks for reporting.
comment:4 Changed 14 years ago by
| Resolution: | → fixed |
|---|---|
| Status: | assigned → closed |
comment:5 Changed 13 years ago by
| Resolution: | fixed |
|---|---|
| Status: | closed → reopened |
This is still failing, but with a different error now: AttributeError: 'int' object has no attribute 'rsplit'
In the event that the changelog is empty, cnum_thischange needs to be set to the string "1", not the integer 1.
comment:6 Changed 13 years ago by
| Owner: | changed from Ryan J Ollos to ejucovy |
|---|---|
| Status: | reopened → new |
comment:7 Changed 13 years ago by
| Resolution: | → fixed |
|---|---|
| Status: | new → closed |
Note: See
TracTickets for help on using
tickets.



Got the same issue:
Traceback (most recent call last): File "/usr/local/lib/python2.7/dist-packages/Trac-0.12.2-py2.7.egg/trac/web/main.py", line 511, in _dispatch_request dispatcher.dispatch(req) File "/usr/local/lib/python2.7/dist-packages/Trac-0.12.2-py2.7.egg/trac/web/main.py", line 237, in dispatch resp = chosen_handler.process_request(req) File "/usr/local/lib/python2.7/dist-packages/Trac-0.12.2-py2.7.egg/trac/ticket/web_ui.py", line 170, in process_request return self._process_newticket_request(req) File "/usr/local/lib/python2.7/dist-packages/Trac-0.12.2-py2.7.egg/trac/ticket/web_ui.py", line 398, in _process_newticket_request self._do_create(req, ticket) # (redirected if successful) File "/usr/local/lib/python2.7/dist-packages/Trac-0.12.2-py2.7.egg/trac/ticket/web_ui.py", line 1193, in _do_create ticket.insert() File "/usr/local/lib/python2.7/dist-packages/Trac-0.12.2-py2.7.egg/trac/ticket/model.py", line 246, in insert listener.ticket_created(self) File "/usr/local/lib/python2.7/dist-packages/Tracbacks-0.1-py2.7.egg/tracbacks/tracbacks.py", line 66, in ticket_created ticket.values.get('reporter'), None) File "/usr/local/lib/python2.7/dist-packages/Tracbacks-0.1-py2.7.egg/tracbacks/tracbacks.py", line 100, in ticket_changed cnum_lastcomment = int(cnum_lastchange[-1]) ValueError: invalid literal for int() with base 10: 'assigned'and
Traceback (most recent call last): File "/usr/local/lib/python2.7/dist-packages/Trac-0.12.2-py2.7.egg/trac/web/main.py", line 511, in _dispatch_request dispatcher.dispatch(req) File "/usr/local/lib/python2.7/dist-packages/Trac-0.12.2-py2.7.egg/trac/web/main.py", line 237, in dispatch resp = chosen_handler.process_request(req) File "/usr/local/lib/python2.7/dist-packages/Trac-0.12.2-py2.7.egg/trac/ticket/web_ui.py", line 169, in process_request return self._process_ticket_request(req) File "/usr/local/lib/python2.7/dist-packages/Trac-0.12.2-py2.7.egg/trac/ticket/web_ui.py", line 541, in _process_ticket_request self._do_save(req, ticket, action) File "/usr/local/lib/python2.7/dist-packages/Trac-0.12.2-py2.7.egg/trac/ticket/web_ui.py", line 1238, in _do_save cnum=internal_cnum): File "/usr/local/lib/python2.7/dist-packages/Trac-0.12.2-py2.7.egg/trac/ticket/model.py", line 360, in save_changes listener.ticket_changed(self, comment, author, old_values) File "/usr/local/lib/python2.7/dist-packages/Tracbacks-0.1-py2.7.egg/tracbacks/tracbacks.py", line 98, in ticket_changed lastchange = change_log[-1] IndexError: list index out of range