That still leaves the question of what to do with __file__ (for which
even the solution in the PEP isn't particularly clean). Perhaps the
thing to do there is to have __file__ always point to the source file
and introduce a __file_cached__ that points to the bytecompiled file on
disk (set to None if it doesn't exist, as may be the case for __main__
or due to writing of bytecode files being disabled).
And what if there isn't a source file, because I want to deploy the
byte-code only?
This is possible now, but would be impossible if there was this kind of
distinction.
That said, and understanding Martin von Löwis objections against ZIP files,
I'm +1 for something like module.some-kind-of-version.pyc instead of
subdirectories.
Henning
_______________________________________________
Python-Dev mailing list
Python-Dev@python.org
http://mail.python.org/mailman/listinfo/python-dev
Unsubscribe:
http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com