
My team uses the optimized flag when building 'binaries' via py2exe before distributing. In the end it really is security through obscurity, but something is always better than nothing. On a different note, I don't think asserts belong in production. I fully concede that there is no real consensus either way on this belief so I think it's important to have the option so people can run in the mode which they prefer. -Mark On Tue, Feb 2, 2010 at 10:16 AM, Antoine Pitrou <solipsis@pitrou.net> wrote:
Larry Hastings <larry@...> writes:
I ask you: why gunk up the filesystem with two files when one would do? I propose we change the pyc file so it can contain multiple code objects.
I think we should dump the lie about "optimized" bytecode when the only optimization is that we strip some docstrings, disable asserts and set __debug__ to False.
There should be only one possible bytecode file (XXX.pyc), and we could provide a "strip" tool (and/or corresponding function in the compileall module) for people for whom minimizing bytecode file size is important.
Also, it would be interesting to know who bothers to use "python -O" (or "-OO"). I know I never use it.
Antoine.
_______________________________________________ Python-ideas mailing list Python-ideas@python.org http://mail.python.org/mailman/listinfo/python-ideas