Error with co_filename when loading modules from zip file

Bob Rossi bob at
Tue Mar 6 14:41:32 CET 2012

On Tue, Mar 06, 2012 at 02:38:50AM -0800, Vinay Sajip wrote:
> On Mar 6, 2:40 am, Bob Rossi <b... at> wrote:
> > Darn it, this was reported in 2007
> >
> > and it was mentioned the logging package was effected.
> >
> > Yikes.
> >
> I will think about this, but don't expect any quick resolution :-( I
> think the right fix would be not in the logging package, but in the
> module loading machinery (as mentioned on that issue).
> I wouldn't worry about the performance aspect - once the logging
> package is loaded, there's no performance impact. That's a tiny one-
> off hit which you will probably not notice at all.


Do you know where the bytecode gets stored when you load a py
file from a zip?

My program can potentially run for hours, from an embedded context,
and could call into the logger and other py files over and over.

Are the bytecode files stored in RAM one time, or recomputed each
time they are needed?


More information about the Python-list mailing list