Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

suppress pyc generation

0 views
Skip to first unread message

Eddy Ilg

unread,
Dec 25, 2005, 8:01:35 AM12/25/05
to pytho...@python.org
Hi,

I would like to suppress .pyc generation or have the .pyc generation in a
speical seperate root (I found something about PYCROOT). Has this been
implemented yet? Is there an environment variable or a command line switch
that suppresses .pyc generation?

Eddy

Ivan Herman

unread,
Dec 25, 2005, 9:53:44 AM12/25/05
to Eddy Ilg, pytho...@python.org
There is a simple, though slightly ugly trick: if the directory where the python
module resides, is not writable to the python process, the python runtime will
silently ignore .pyc generation (as far as I know). It is not elegant, but it
works...

Ivan

Ivan Herman

unread,
Dec 25, 2005, 9:53:57 AM12/25/05
to Eddy Ilg, pytho...@python.org
There is a simple, though slightly ugly trick: if the directory where the python
module resides, is not writable to the python process, the python runtime will
silently ignore .pyc generation (as far as I know). It is not elegant, but it
works...

Ivan

-------- Original Message --------
From: "Eddy Ilg" <ed...@fericom.net>
To:
Subject: suppress pyc generation
Date: 25/12/2005 14:01

Ivan Herman

unread,
Dec 25, 2005, 9:53:57 AM12/25/05
to Eddy Ilg, pytho...@python.org
There is a simple, though slightly ugly trick: if the directory where the python
module resides, is not writable to the python process, the python runtime will
silently ignore .pyc generation (as far as I know). It is not elegant, but it
works...

Ivan

-------- Original Message --------
From: "Eddy Ilg" <ed...@fericom.net>
To:
Subject: suppress pyc generation
Date: 25/12/2005 14:01

sk...@pobox.com

unread,
Dec 25, 2005, 11:45:42 AM12/25/05
to Eddy Ilg, pytho...@python.org

Eddy> I would like to suppress .pyc generation or have the .pyc
Eddy> generation in a speical seperate root (I found something about
Eddy> PYCROOT). Has this been implemented yet? Is there an environment
Eddy> variable or a command line switch that suppresses .pyc generation?

Take a look at PEP 304 and see if that would meet your needs:

http://www.python.org/peps/pep-0304.html

If you have comments on it, best to submit a tracker item on Sourceforge in
addition to posting your ideas here to make sure they don't get lost.

Skip

0 new messages