timmerk / ipaddr-py

Automatically exported from code.google.com/p/ipaddr-py
0 stars 0 forks source link

NameError when checking prefixlen syntax of IPv6Network #51

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. Create an IPv6Network object from any (invalid) IPv6 string containing 
more than one /.
>>> import ipaddr
>>> ipaddr.IPv6Network("::a:b/120/120")
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "ipaddr.py", line 1773, in __init__
    raise AddressValueError(ipaddr)
NameError: global name 'ipaddr' is not defined

What is the expected output? What do you see instead?
IPv6Network.__init__ correctly detects that this is invalid syntax and 
tries to raise an AddressValueError on the address, but provides an invalid 
argument.

What version of the product are you using? On what operating system?
SVN revision 129, Ubuntu Linux 9.10.

Please provide any additional information below.
Patch and test case are attached.

Original issue reported on code.google.com by hb...@ele.uri.edu on 18 Dec 2009 at 3:38

Attachments:

GoogleCodeExporter commented 9 years ago
fixed in r131.
thanks.

Original comment by pmo...@google.com on 2 Feb 2010 at 5:49