[Python-bugs-list] [ python-Bugs-599869 ] NameError value is not the name error
noreply@sourceforge.net
noreply@sourceforge.net
Tue, 27 Aug 2002 08:05:44 -0700
Bugs item #599869, was opened at 2002-08-25 10:04
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=105470&aid=599869&group_id=5470
Category: Documentation
Group: Python 2.2
Status: Open
Resolution: None
Priority: 5
Submitted By: Pedro Rodriguez (pedro_rodriguez)
Assigned to: Raymond Hettinger (rhettinger)
Summary: NameError value is not the name error
Initial Comment:
NameError value was the faulty name in 1.5.2, but it
isn't in 2.2.
try:
a
except NameError, e:
print e.args
Reports in 1.5.2 :
('a',)
Reports in 2.2 :
("name 'a' is not defined",)
----------------------------------------------------------------------
>Comment By: Peter Schneider-Kamp (nowonder)
Date: 2002-08-27 15:05
Message:
Logged In: YES
user_id=14463
What do you mean? Pedro gave a link. Just search for
'NameError' on that page.
If you are referring to the cvs docs, the appropriate file is:
dist/src/Doc/lib/libexcs.tex, line 209f
Pedro is right in that current practice is incosistent with old
practice AND documentation.
----------------------------------------------------------------------
Comment By: Pedro Rodriguez (pedro_rodriguez)
Date: 2002-08-26 07:38
Message:
Logged In: YES
user_id=426450
http://www.python.org/doc/current/lib/module-exceptions.html
-
exception NameError
Raised when a local or global name is not found. This
applies only to unqualified names. The associated value is
the name that could not be found.
-
----------------------------------------------------------------------
Comment By: Raymond Hettinger (rhettinger)
Date: 2002-08-25 16:39
Message:
Logged In: YES
user_id=80475
Where does this apper in the docs?
----------------------------------------------------------------------
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=105470&aid=599869&group_id=5470