[Python-checkins] r72013 - in python/branches/py3k: Doc/library/traceback.rst
georg.brandl
python-checkins at python.org
Mon Apr 27 18:22:44 CEST 2009
Author: georg.brandl
Date: Mon Apr 27 18:22:44 2009
New Revision: 72013
Log:
Merged revisions 72007 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk
........
r72007 | georg.brandl | 2009-04-27 17:09:25 +0200 (Mo, 27 Apr 2009) | 1 line
#5856: fix typo s in traceback example.
........
Modified:
python/branches/py3k/ (props changed)
python/branches/py3k/Doc/library/traceback.rst
Modified: python/branches/py3k/Doc/library/traceback.rst
==============================================================================
--- python/branches/py3k/Doc/library/traceback.rst (original)
+++ python/branches/py3k/Doc/library/traceback.rst Mon Apr 27 18:22:44 2009
@@ -269,10 +269,10 @@
This last example demonstrates the final few formatting functions::
>>> import traceback
- >>> format_list([('spam.py', 3, '<module>', 'spam.eggs()'),
- ... ('eggs.py', 42, 'eggs', 'return "bacon"')])
+ >>> traceback.format_list([('spam.py', 3, '<module>', 'spam.eggs()'),
+ ... ('eggs.py', 42, 'eggs', 'return "bacon"')])
[' File "spam.py", line 3, in <module>\n spam.eggs()\n',
' File "eggs.py", line 42, in eggs\n return "bacon"\n']
- >>> theError = IndexError('tuple indx out of range')
- >>> traceback.format_exception_only(type(theError), theError)
+ >>> an_error = IndexError('tuple index out of range')
+ >>> traceback.format_exception_only(type(an_error), an_error)
['IndexError: tuple index out of range\n']
More information about the Python-checkins
mailing list