#2036: TG gives 500 server error instead of 403 or 404
-------------------------------------------------------+--------------------
Reporter: chrisz | Owner: faide
Type: defect | Status: new
Priority: normal | Milestone: 1.1
Component: TurboGears | Version: 1.0.7
Severity: minor | Resolution:
Keywords: JSON, NoApplicableMethods, SecureResource |
-------------------------------------------------------+--------------------
Comment (by Chris Arndt):
Ok, I can now reproduce the 500 error too. Here's the exception traceback
for reference:
{{{
2009-09-19 18:21:29,014 cherrypy.msg INFO HTTP: Page handler: <bound
method Root.login of <test2036.controllers.Root object at 0x2294c10>>
Traceback (most recent call last):
File "/Users/chris/lib/tg11svnpy25/lib/python2.5/site-
packages/CherryPy-2.3.0-py2.5.egg/cherrypy/_cphttptools.py", line 121, in
_run
self.main()
File "/Users/chris/lib/tg11svnpy25/lib/python2.5/site-
packages/CherryPy-2.3.0-py2.5.egg/cherrypy/_cphttptools.py", line 264, in
main
body = page_handler(*virtual_path, **self.params)
File "<string>", line 3, in login
File
"/Users/chris/work/turbogears/svn/branches/1.1/turbogears/controllers.py",
line 356, in expose
*args, **kw)
File "<generated code>", line 0, in run_with_transaction
File "build/bdist.macosx-10.3-fat/egg/peak/rules/core.py", line 153, in
__call__
return self.body(*args, **kw)
File
"/Users/chris/work/turbogears/svn/branches/1.1/turbogears/database.py",
line 435, in sa_rwt
retval = func(*args, **kw)
File
"/Users/chris/work/turbogears/svn/branches/1.1/turbogears/controllers.py",
line 240, in _expose
@abstract()
File "<generated code>", line 0, in _expose
File "build/bdist.macosx-10.3-fat/egg/peak/rules/core.py", line 214, in
__call__
raise self.__class__(*self.args+(args,kw)) # XXX
NoApplicableMethods: ((<function login at 0x228caf0>, 'application/json',
False,
<test2036.controllers.Root object at 0x2294c10>), {'tg_format': u'json',
'forward_url': None})
Request Headers:
COOKIE: tg-visit=4d9464b318a5cb1389d99b71351a1976ca51cdea
Content-Length:
ACCEPT-CHARSET: ISO-8859-1,utf-8;q=0.7,*;q=0.7
USER-AGENT: Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10.4; de;
rv:1.9.1.3) Gecko/20090824 Firefox/3.5.3
CONNECTION: keep-alive
REFERER: http://localhost:8080/
X-REQUESTED-WITH: XMLHttpRequest
HOST: localhost:8080
ACCEPT: application/json
Remote-Addr: ::1
ACCEPT-LANGUAGE: de-de,de;q=0.8,en;q=0.5,en-us;q=0.3
Content-Type:
ACCEPT-ENCODING: gzip,deflate
KEEP-ALIVE: 300
::1 - - [19/Sep/2009:16:21:29 +0000] "GET /sub/time?tg_format=json
HTTP/1.1" 500 2238
"http://localhost:8080/" "Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10.4;
de;
rv:1.9.1.3) Gecko/20090824 Firefox/3.5.3"
}}}
--
Ticket URL: <http://trac.turbogears.org/ticket/2036#comment:7>
TurboGears <http://www.turbogears.org/>
TurboGears front-to-back web development
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google
Groups "TurboGears Tickets" group.
This group is read-only. No posting by normal members allowed.
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/turbogears-tickets?hl=en?hl=en
-~----------~----~----~----~------~----~------~--~---