[Bug 1421375] Re: AttributeError when attempting to access _sys.maxint
Chris J Arges
1421375 at bugs.launchpad.net
Thu Feb 12 20:13:46 UTC 2015
sponsored for trusty
--
You received this bug notification because you are a member of Ubuntu
Sponsors Team, which is subscribed to the bug report.
https://bugs.launchpad.net/bugs/1421375
Title:
AttributeError when attempting to access _sys.maxint
Status in python-netaddr package in Ubuntu:
Fix Released
Status in python-netaddr source package in Trusty:
New
Bug description:
[Impact]
Anyone on Trusty wishing to utilize IPSets for gathering ranges of IPs.
[Test Case]
Code to reproduce:
from netaddr import IPSet
def get_ip_set(cidr):
""" Returns a list of ip's in cidr for use in juju's no-proxy setting
"""
ips = list(IPSet([cidr]))
return ",".join(str(x) for x in ips)
get_ip_set('10.0.4.0/24')
[Regression Potentional]
None
[Other Info]
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/usr/share/openstack/cloudinstall/netutils.py", line 78, in get_ip_set
ips = list(IPSet([cidr]))
File "/usr/lib/python3/dist-packages/netaddr/ip/sets.py", line 518, in __len__
if size > _sys.maxint:
AttributeError: 'module' object has no attribute 'maxint'
To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/python-netaddr/+bug/1421375/+subscriptions
More information about the Ubuntu-sponsors
mailing list