Re: problem with log=warning

Steven Armstrong <[email protected]>
Newsgroups gmane.comp.web.pyblosxom.user
Message-ID <[email protected]>
Joseph Reagle wrote:
> When I set my log variable to 'warning', I get the following error from 
> Apache. Every other value works fine.
> 
> 
> 
> [Tue Feb 06 14:16:28 2007] [error] [client 74.65.195.139] Traceback (most 
> recent call last):
> [Tue Feb 06 14:16:28 2007] [error] [client 74.65.195.139]   File "blog", 
> line 86, in ?
> [Tue Feb 06 14:16:28 2007] [error] [client 74.65.195.139]     p.run()
> [Tue Feb 06 14:16:28 2007] [error] [client 74.65.195.139]   
> File "/home/reagle/data/2web/pyblosxom-1.3.2/Pyblosxom/pyblosxom.py", line 
> 163, in run
> [Tue Feb 06 14:16:28 2007] [error] [client 74.65.195.139]     
> donefunc=lambda x:x)
> [Tue Feb 06 14:16:28 2007] [error] [client 74.65.195.139]   
> File "/home/reagle/data/2web/pyblosxom-1.3.2/Pyblosxom/tools.py", line 551, 
> in run_callback
> [Tue Feb 06 14:16:28 2007] [error] [client 74.65.195.139]     output = 
> func(input)
> [Tue Feb 06 14:16:28 2007] [error] [client 74.65.195.139]   
> File "/home/reagle/data/2web/pyblosxom-1.3.2/contrib.1.3.0/plugins/comments/plugins/trackback.py", 
> line 78, in cb_handle
> [Tue Feb 06 14:16:28 2007] [error] [client 74.65.195.139]     logger = 
> tools.getLogger()
> [Tue Feb 06 14:16:28 2007] [error] [client 74.65.195.139]   
> File "/home/reagle/data/2web/pyblosxom-1.3.2/Pyblosxom/tools.py", line 796, 
> in getLogger
> [Tue Feb 06 14:16:28 2007] [error] [client 74.65.195.139]     int_level = 
> getattr(logging, log_level.upper())
> [Tue Feb 06 14:16:28 2007] [error] [client 74.65.195.139] 
> AttributeError: 'module' object has no attribute 'WARNING'
> [Tue Feb 06 14:16:28 2007] [error] [client 74.65.195.139] Premature end of 
> script headers: blog
>                            

Hi Joseph

That's weired. What version of Python are you using?
Can you check in a shell if the WARNING property is accessible there?

If your running Python >= 2.3:
python -c 'import logging; print logging.WARNING'

If your running Python < 2.3:
cd /home/reagle/data/2web/pyblosxom-1.3.2/Pyblosxom/
python -c 'import _logging as logging; print logging.WARNING'

hth
cheers
Steven

-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier.
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.