|
Home > Archive > Apache Mod-Python > November 2006 > Created: (MODPYTHON-201) ReportError in importer.py raises
You are viewing an archived Text-only version of the thread.
To view this thread in it's original format and/or if you want to reply to
this thread please [click here]
| Author |
Created: (MODPYTHON-201) ReportError in importer.py raises
|
|
| Jim Gallacher (JIRA) 2006-11-03, 7:13 pm |
| ReportError in importer.py raises an exception for mal-formed psp
-----------------------------------------------------------------
Key: MODPYTHON-201
URL: http://issues.apache.org/jira/browse/MODPYTHON-201
Project: mod_python
Issue Type: Bug
Components: importer
Affects Versions: 3.3
Environment: 3.3.0-dev-20061029
Reporter: Jim Gallacher
Priority: Blocker
Mal formed psp causes an exception in importer.py ReportError
The following psp contains a syntax error, and generates an exception as expected, causing importer.ReportError to be called.
test.psp
-------------
<%
req.write('x'
%>
There is bug in ReportError however that raises an exception, and a 500 Internal Server Error is sent to the client.
apache error_log
--------------------------
[Fri Nov 03 16:08:19 2006] [error] [client 192.168.1.2] req.write("""
[Fri Nov 03 16:08:19 2006] [error] [client 192.168.1.2] ^
[Fri Nov 03 16:08:19 2006] [error] [client 192.168.1.2] SyntaxError: invalid syntax
Traceback (most recent call last):
File "/usr/lib/python2.4/site-packages/mod_python/importer.py", line 1797, in ReportError
stime = time.asctime(time.localtime(modules.stime))
AttributeError: '_module_cache' object has no attribute 'stime'
[Fri Nov 03 16:08:19 2006] [error] [client 192.168.1.2] python_handler: Dispatch() returned non-integer.
I'm not sure if this is a simple bug in ReportError, or indicates a deeper problem with cache mechanism in the importer.
| |
| Jim Gallacher 2006-11-04, 7:12 am |
| Sometimes it's hard to keep up with you, Graham. ;)
Although I haven't been around much lately, I have been compiling and
testing the svn commits on a regular basis. As it happens, the machine I
used for this bug report was not one with the latest and greatest.
Jim
Graham Dumpleton wrote:
> You don't have latest source code checked out from subversion. I
> fixed that in a commit a few hours after I originally introduced it.
> Also, I subsequently changed the code again after that and 'stime'
> no longer exists, or at least it is called something different now.
>
> Graham
>
> On 04/11/2006, at 8:26 AM, Jim Gallacher (JIRA) wrote:
>
>
|
|
|
|
|