Opened 11 years ago
Closed 11 years ago
#11183 closed defect (wontfix)
Error on Ticket-Action
Reported by: | Owned by: | Chris Nelson | |
---|---|---|---|
Priority: | normal | Component: | TracJsGanttPlugin |
Severity: | normal | Keywords: | |
Cc: | Trac Release: | 0.12 |
Description
every action with tickets (create, change, etc.) result in the following error.
I fount, that
result {}
at the line
result['href'] = req.href.ticket(val)
Trac detected an internal error:
AttributeError: 'NoneType' object has no attribute 'href'
Most recent call last: File "c:/users/franball/appdata/local/temp/2/easy_install-lixnu4/Trac-0.12.1-py2.6-win32.egg.tmp/trac/web/main.py", line 511, in _dispatch_request dispatcher.dispatch(req) File "c:/users/franball/appdata/local/temp/2/easy_install-lixnu4/Trac-0.12.1-py2.6-win32.egg.tmp/trac/web/main.py", line 237, in dispatch resp = chosen_handler.process_request(req) File "c:/users/franball/appdata/local/temp/2/easy_install-lixnu4/Trac-0.12.1-py2.6-win32.egg.tmp/trac/ticket/web_ui.py", line 169, in process_request return self._process_ticket_request(req) File "c:/users/franball/appdata/local/temp/2/easy_install-lixnu4/Trac-0.12.1-py2.6-win32.egg.tmp/trac/ticket/web_ui.py", line 541, in _process_ticket_request self._do_save(req, ticket, action) File "c:/users/franball/appdata/local/temp/2/easy_install-lixnu4/Trac-0.12.1-py2.6-win32.egg.tmp/trac/ticket/web_ui.py", line 1238, in _do_save cnum=internal_cnum): File "c:/users/franball/appdata/local/temp/2/easy_install-lixnu4/Trac-0.12.1-py2.6-win32.egg.tmp/trac/ticket/model.py", line 360, in save_changes listener.ticket_changed(self, comment, author, old_values) File "build/bdist.win32/egg/tracjsgantt/tracpm.py", line 2950, in ticket_changed self.rescheduleTickets(ticket, old_values) File "build/bdist.win32/egg/tracjsgantt/tracpm.py", line 2753, in rescheduleTickets tickets = self.queryTickets(ids) File "build/bdist.win32/egg/tracjsgantt/tracpm.py", line 2549, in queryTickets return self.pm.query(options, set()) File "build/bdist.win32/egg/tracjsgantt/tracpm.py", line 1193, in query tickets = query.execute(req) File "c:/users/franball/appdata/local/temp/2/easy_install-lixnu4/Trac-0.12.1-py2.6-win32.egg.tmp/trac/ticket/query.py", line 330, in execute result['href'] = req.href.ticket(val)
I used
trac-jsgantt | 0.10-r12998 |
installed from svn today
Attachments (0)
Change History (8)
comment:1 follow-up: 2 Changed 11 years ago by
comment:2 Changed 11 years ago by
Replying to ChrisNelson:
Please try disabling the background ticket rescheduler and see if that helps. I'm working in that module and hope to fix this soon.
I try'd to modify a ticket and to create a new ticket. Both tests worked.
comment:3 Changed 11 years ago by
Can you post your trac.ini
sections for TracPM and Trac-jsGantt? I don't see this problem.
comment:4 Changed 11 years ago by
From following the traceback, we can see that TracPM.query
is called without a req
argument. Therefore the req
parameter in TracPM.query
will be None
, and query.execute
shouldn't be called without passing a Request
object: tracjsganttplugin/0.11/tracjsgantt/tracpm.py@13705:1197#L1161. At least, it should be called with req=None
prior to Trac 0.12.2: [trac 10378].
So unless a workaround it put in place, the minimum Trac version for this plugin will need to be 0.12.2.
comment:5 Changed 11 years ago by
I have the plugin working in 0.11.6 (with some local changes) and 1.0.1. I don't quite understand the comment about 0.12.2 being required.
comment:6 follow-up: 7 Changed 11 years ago by
I explained in comment:4, prior to [trac 10378] which was included in Trac 0.12.2, you have to pass a Request
object to Query.count
and Query.execute
. However, in the case leading to the error, TracPM.query
is called without a Request
object, which leads to Query.execute
being called without passing a Request
object (req = None
).
Perhaps your local changes included the patch in [trac 10378].
comment:7 Changed 11 years ago by
Replying to rjollos:
I explained in comment:4, prior to [trac 10378] which was included in Trac 0.12.2, you have to pass a
Request
object toQuery.count
andQuery.execute
. However, in the case leading to the error,TracPM.query
is called without aRequest
object, which leads toQuery.execute
being called without passing aRequest
object (req = None
).Perhaps your local changes included the patch in [trac 10378].
Yeah, that seems likely since I originated that patch. ;-)
comment:8 Changed 11 years ago by
Resolution: | → wontfix |
---|---|
Status: | new → closed |
I think that the background rescheduler requires [trac 10378]. Because it runs in background, it has no request so there is no way to make one up reasonable. So:
- Apply the patch, or
- Disable the background rescheduler
Sorry I can't do better.
Please try disabling the background ticket rescheduler and see if that helps. I'm working in that module and hope to fix this soon.