This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author ggenellina
Recipients ggenellina
Date 2011-06-07.08:48:20
SpamBayes Score 2.824468e-08
Marked as misclassified No
Message-id <1307436501.83.0.59684150491.issue12276@psf.upfronthosting.co.za>
In-reply-to
Content
Python 3.x doesn't honor sys.tracebacklimit=0

According to 
http://docs.python.org/py3k/library/sys.html#sys.tracebacklimit
when set to 0, it should not print any stack trace, but it does.

Python 3.2 (r32:88445, Feb 20 2011, 21:29:02) [MSC v.1500 32 bit (Intel)] on win
32
Type "help", "copyright", "credits" or "license" for more information.
p3> import sys
p3> sys.tracebacklimit = 0
p3>
p3> def f(x):
...   return f(x-1) if x else 0/0
...
p3> f(5)
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "<stdin>", line 2, in f
  File "<stdin>", line 2, in f
  File "<stdin>", line 2, in f
  File "<stdin>", line 2, in f
  File "<stdin>", line 2, in f
  File "<stdin>", line 2, in f
ZeroDivisionError: division by zero
p3>
History
Date User Action Args
2011-06-07 08:48:21ggenellinasetrecipients: + ggenellina
2011-06-07 08:48:21ggenellinasetmessageid: <1307436501.83.0.59684150491.issue12276@psf.upfronthosting.co.za>
2011-06-07 08:48:21ggenellinalinkissue12276 messages
2011-06-07 08:48:21ggenellinacreate