Message73578
Any buggy behavior might be relied on by applications. Taken to the
extreme, you can never have a bug-fix release of Python.
__file__ from PYTHONSTARTUP breaks the warnings module. It would be
difficult for an application to rely on __main__.__file__ being set,
since $PYTHONSTARTUP is only read in interactive mode - when it's a
human using Python, not a program. Of course another process could run
Python interactively in a child process and then rely on __file__, sure.
But why is that valid? It's not like __file__ *means* something there
- it's just the value of PYTHONSTARTUP.
But I guess I don't really care anymore. I understand why warnings are
being reported incorrectly now, so I doubt this affects /me/ anymore.
It seems like it'd be better to reduce confusion for other people too,
but that's not up to me.
Thanks for pointing out where it was fixed in 2.6. |
|
Date |
User |
Action |
Args |
2008-09-22 13:57:17 | exarkun | set | recipients:
+ exarkun, amaury.forgeotdarc |
2008-09-22 13:57:17 | exarkun | set | messageid: <1222091837.07.0.663751311398.issue3933@psf.upfronthosting.co.za> |
2008-09-22 13:57:16 | exarkun | link | issue3933 messages |
2008-09-22 13:57:15 | exarkun | create | |
|