logging module - restricted mode error

Vinay Sajip vinay_sajip at yahoo.co.uk
Sat Oct 20 15:18:34 EDT 2007


On 16 Oct, 04:14, Paul Rudin <paul.nos... at rudin.co.uk> wrote:
> I'm occasionally seeing tracebacks like this:
>
> Traceback (most recent call last):
>   File "logging/__init__.py", line 744, in emit
>   File "logging/__init__.py", line 630, in format
>   File "logging/__init__.py", line 421, in format
> RuntimeError: instance.__dict__ not accessible in restricted mode
>
> I'm not sure what it means. Googling leads me to
> <http://docs.python.org/lib/restricted.html> but that says that those
> modules were disabled in 2.3 and I'm running 2.5.1. In any case I'm
> not using them (although it could be that one of the 3rd party modules
> I'm using does something.)
>
> Could someone please explain what this error means?

Can you say a little bit more about the execution environment? For
example, are you running under mod_python? If so, which version?

When googling, did you search for the exact text of the error message?
For example, did you see the following post?

http://mail-archives.apache.org/mod_mbox/httpd-python-dev/200404.mbox/%3C408661A5.3010001@sjsoft.com%3E

Vinay Sajip




More information about the Python-list mailing list