Modify ↓
#8547 closed defect (fixed)
AttributeError: 'NoneType' object has no attribute 'split'
Reported by: | Owned by: | Christian Boos | |
---|---|---|---|
Priority: | normal | Milestone: | 0.11.6 |
Component: | ticket system | Version: | none |
Severity: | normal | Keywords: | NULL |
Cc: | Branch: | ||
Release Notes: | |||
API Changes: | |||
Internal Changes: |
Description (last modified by )
How to Reproduce
While doing a POST operation on /ticket/411
, Trac issued an internal error.
(please provide additional details here)
Request parameters:
{'__FORM_TOKEN': u'ebf9ea65f8fe75c21dc66626', 'action': u'reopen', 'action_change_owner_reassign_owner': u'anonymous', 'author': u'aahz@pythoncraft.com', 'cnum': u'7', 'comment': u"As a new Trac user, I also find this behavior suboptimal. It's been five years, please revisit this design flaw -- it makes it very difficult to update a ticket summary so that others don't need to scroll through the entire comment history.", 'field_component': u'ticket system', 'field_keywords': u'', 'field_milestone': u'0.8', 'field_priority': u'high', 'field_severity': u'normal', 'field_summary': u'Edit ticket description?', 'field_type': u'defect', 'field_version': u'0.7', 'id': u'411', 'preview': u'Preview', 'replyto': u'', 'ts': u'2006-06-21 08:26:44+00:00'}
System Information
Trac | 0.11.5stable-r8354
|
Python | 2.5.2 (r252:60911, Oct 5 2008, 19:29:17) [GCC 4.3.2]
|
setuptools | 0.6c9
|
psycopg2 | 2.0.8
|
Genshi | 0.6dev-r999
|
Pygments | 1.0
|
Subversion | 1.5.1 (r32289)
|
Python Traceback
Traceback (most recent call last): File "/usr/local/virtualenv/lib/python2.5/site-packages/Trac-0.11.5stable_r8354-py2.5.egg/trac/web/main.py", line 444, in _dispatch_request dispatcher.dispatch(req) File "/usr/local/virtualenv/lib/python2.5/site-packages/Trac-0.11.5stable_r8354-py2.5.egg/trac/web/main.py", line 205, in dispatch resp = chosen_handler.process_request(req) File "/usr/local/virtualenv/lib/python2.5/site-packages/Trac-0.11.5stable_r8354-py2.5.egg/trac/ticket/web_ui.py", line 182, in process_request return self._process_ticket_request(req) File "/usr/local/virtualenv/lib/python2.5/site-packages/Trac-0.11.5stable_r8354-py2.5.egg/trac/ticket/web_ui.py", line 531, in _process_ticket_request get_reporter_id(req, 'author'), field_changes) File "/usr/local/virtualenv/lib/python2.5/site-packages/Trac-0.11.5stable_r8354-py2.5.egg/trac/ticket/web_ui.py", line 1260, in _insert_ticket_data self._render_property_changes(req, ticket, field_changes) File "/usr/local/virtualenv/lib/python2.5/site-packages/Trac-0.11.5stable_r8354-py2.5.egg/trac/ticket/web_ui.py", line 1310, in _render_property_changes resource_new) File "/usr/local/virtualenv/lib/python2.5/site-packages/Trac-0.11.5stable_r8354-py2.5.egg/trac/ticket/web_ui.py", line 1344, in _render_property_diff old_list, new_list = old.split(), new.split() AttributeError: 'NoneType' object has no attribute 'split'
Attachments (0)
Change History (3)
comment:1 by , 15 years ago
Component: | general → ticket system |
---|---|
Description: | modified (diff) |
Milestone: | → 0.11.6 |
Owner: | set to |
comment:2 by , 15 years ago
Keywords: | NULL added |
---|---|
Resolution: | → fixed |
Status: | new → closed |
Above fix applied in [8451].
comment:3 by , 15 years ago
Has been outdated by the patch of #8326. However, this patch can be applied fine to 0.11.5 in contrary to the newer one.
Note:
See TracTickets
for help on using tickets.
Thanks for the report.
The keywords field for this ticket must have been NULL in the database, for some reason.
In this case we don't insert this field in the ticket
values
dict (L103-104), which implies that when setting the field later on, the_old
dict ends with aNone
value (L123-124) in trac/ticket/model.py.This was done in r7570 in order to fix #4061, so we can't fix the current issue by inserting
''
invalues
in this case.I guess we simply need to accept that
_old['keywords']
can eventually beNone
.trac/ticket/web_ui.py
old.split(), new.split()(
new
can't possibly be None here, but again, I thought the same aboutold
at first inspection ;-) )