[Python-Dev] Pronouncement needed in issue9675
ncoghlan at gmail.com
Wed Sep 29 14:04:24 CEST 2010
On Wed, Sep 29, 2010 at 9:03 AM, Jesus Cea <jcea at jcea.es> wrote:
> About converting the deprecation warning to a py3k warning... Would a
> py3k warning be converted to an error when python is invoked as "-We"?.
> If that is the case, we are in the same situation.
To unpack Guido's response slightly, Py3k specific deprecation
warnings are only triggered if you pass the "-3" flag on the command
line. So "-We" won't cause them to throw an exception, but "-We -3"
(Python 2.6.5, started with "-We")
>>> sys.py3kwarning = True
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/usr/lib/python2.6/warnings.py", line 22, in warnpy3k
warn(message, category, stacklevel+1)
Nick Coghlan | ncoghlan at gmail.com | Brisbane, Australia
More information about the Python-Dev