[Python-Dev] disable writing .py[co]

Neal Norwitz neal@metaslash.com
Mon, 20 Jan 2003 17:57:33 -0500


On Mon, Jan 20, 2003 at 05:42:29PM -0500, Guido van Rossum wrote:
> > In http://python.org/sf/602345 (option for not writing .py[co] files)
> > Martin suggested that in addition to a flag (-R, as in read-only),
> > perhaps there should be an env't variable and/or a sys attribute
> > which controls whether .py[co] files are written or not.
> > 
> > Opinions?  
> > 
> > If you like the idea of an env't variable or sys attribute, do you
> > have suggestions for names?  PYTHONREADONLY and sys.readonly_import?
> 
> Traditionally, this has been the area of environment variables (tested
> at the time when main() parses its arguments) and command line
> options.  Do you really need to be able to control this dynamically
> during program execution?

I don't need the feature at all. :-)

It was not requested in the original bug report.  Paul Dubois,
who also wanted this feature, didn't indicate it was desirable.

So unless someone speaks up, it's YAGNI.

I've updated the man page, and will add an entry to NEWS.  Is there
any other doc that should be added?

Neal