[Python-Dev] Use ptyhon -s as default shbang for system python executables/daemons

Barry Warsaw barry at python.org
Wed Mar 18 22:56:07 CET 2015


On Mar 18, 2015, at 02:44 PM, Toshio Kuratomi wrote:

>Interesting, I've cautiously in favor of -s in Fedora but the more I've
>thought about it the less I've liked -E.  It just seems like PYTHONPATH is
>analagous to LD_LIBRARY_PATH for C programs and PATH for shell scripting.
>We leave both of those for local admins and users to affect the behaviour of
>programs if they needed to.

It is, and it isn't.  It's different because you can always explicitly
override the shebang line if needed.  So if a local admin really needed to
override $PYTHONPATH (though I can't come up with a use case right now), they
could just:

$ python3 -s /usr/bin/foo

>Was there some discussion of -E specifically in Debian where it was
>consciously decided that PYTHONPATH was not analagous or that the benefit
>risk was different than for those other env vars?

I'd have to go digging around the archives.  It wasn't a recent discussion
IIRC.

Cheers,
-Barry
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 819 bytes
Desc: OpenPGP digital signature
URL: <http://mail.python.org/pipermail/python-dev/attachments/20150318/678ef8a2/attachment.sig>


More information about the Python-Dev mailing list