[Python-Dev] Handling of sys.args (Re: User's complaints)

Greg Ewing greg.ewing at canterbury.ac.nz
Fri Jul 14 06:55:34 CEST 2006


Ka-Ping Yee wrote:

> I think of 'sys' as the place for sensitive interpreter internals

Well, it seems to be rather a mixture at the moment.
I suppose you could regard sys.modules as fairly
sensitive, since messing with it can have big effects
on the behaviour of the whole program, and changing
sys.stdout or sys.stderr also has global effects.

But it's also how you do things like getting info
about the current exception, which doesn't seem
particularly sensitive to me.

Maybe sys needs to be split into two modules, with
the non-sensitive one pre-imported (so that the
importless interpreter you suggest wouldn't be
unnecessarily crippled).

--
Greg


More information about the Python-Dev mailing list