Bug 1208811 - AttributeError: 'module' object has no attribute 'Bytes'
Summary: AttributeError: 'module' object has no attribute 'Bytes'
Keywords:
Status: CLOSED DUPLICATE of bug 1417701
Alias: None
Product: Fedora EPEL
Classification: Fedora
Component: python-ipaddr
Version: epel7
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Leon Keijser
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks: 1185471 1208782
TreeView+ depends on / blocked
 
Reported: 2015-04-03 09:20 UTC by George Notaras
Modified: 2017-01-31 19:09 UTC (History)
7 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2017-01-31 19:09:29 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Bugzilla 1185471 0 unspecified CLOSED /usr/lib/python2.7/site-packages/spf.py crashes on IPv6 addresses 2021-02-22 00:41:40 UTC
Red Hat Bugzilla 1206380 0 unspecified CLOSED Traceback when originating address is IPv6 2021-02-22 00:41:40 UTC

Internal Links: 1417701

Description George Notaras 2015-04-03 09:20:49 UTC
Description of problem:

Apr  3 07:17:57 examplesrv policyd-spf[11516]: Traceback (most recent call last):
Apr  3 07:17:57 examplesrv policyd-spf[11516]: File "/usr/libexec/postfix/policyd-spf", line 680, in <module>
Apr  3 07:17:57 examplesrv policyd-spf[11516]: instance_dict, configData, peruser)
Apr  3 07:17:57 examplesrv policyd-spf[11516]: File "/usr/libexec/postfix/policyd-spf", line 517, in _spfcheck
Apr  3 07:17:57 examplesrv policyd-spf[11516]: res = spf.check2(ip, sender, helo, querytime=configData.get('Lookup_Time'))
Apr  3 07:17:57 examplesrv policyd-spf[11516]: File "/usr/lib/python2.7/site-packages/spf.py", line 297, in check2
Apr  3 07:17:57 examplesrv policyd-spf[11516]: receiver=receiver,timeout=timeout,verbose=verbose,querytime=querytime).check()
Apr  3 07:17:57 examplesrv policyd-spf[11516]: File "/usr/lib/python2.7/site-packages/spf.py", line 547, in check
Apr  3 07:17:57 examplesrv policyd-spf[11516]: rc = self.check1(spf, self.d, 0)
Apr  3 07:17:57 examplesrv policyd-spf[11516]: File "/usr/lib/python2.7/site-packages/spf.py", line 586, in check1
Apr  3 07:17:57 examplesrv policyd-spf[11516]: return self.check0(spf, recursion)
Apr  3 07:17:57 examplesrv policyd-spf[11516]: File "/usr/lib/python2.7/site-packages/spf.py", line 900, in check0
Apr  3 07:17:57 examplesrv policyd-spf[11516]: if self.cidrmatch(self.dns_mx(arg), cidrlength):
Apr  3 07:17:57 examplesrv policyd-spf[11516]: File "/usr/lib/python2.7/site-packages/spf.py", line 1194, in dns_mx
Apr  3 07:17:57 examplesrv policyd-spf[11516]: return [a for mx in mxnames[:max] for a in self.dns_a(mx[1],self.A)]
Apr  3 07:17:57 examplesrv policyd-spf[11516]: File "/usr/lib/python2.7/site-packages/spf.py", line 1206, in dns_a
Apr  3 07:17:57 examplesrv policyd-spf[11516]: return [ipaddress.Bytes(ip) for ip in r]
Apr  3 07:17:57 examplesrv policyd-spf[11516]: AttributeError: 'module' object has no attribute 'Bytes'


Version-Release number of selected component (if applicable):

python-ipaddr-2.1.9-5.el7.noarch

Comment 1 George Notaras 2015-04-03 09:38:00 UTC
I rebuilt the current rawhide package (2.1.10-2) for CentOS 7 and I confirm it resolves the issue.

Please update the package.

Comment 2 Leon Keijser 2015-04-03 09:54:28 UTC
Hi, thanks for the report. I'll rebuild it asap.

Comment 3 Peter Bieringer 2015-05-03 16:02:07 UTC
can you please provide the link to the rebuild? Currently no updated el7 RPM is listed here:

http://koji.fedoraproject.org/koji/packageinfo?packageID=10310

also none of the maintainers have el7 permissions:
listed)https://admin.fedoraproject.org/pkgdb/package/python-ipaddr/

Comment 4 Frank Büttner 2016-10-25 13:29:11 UTC
Hello, how are the state of it?

Comment 5 Fabian Arrotin 2017-01-17 15:24:38 UTC
Just to confirm that we (CentOS.org) had the same issue when we enabled SPF checks with pypolicyd-spf (and deps)
So we rebuilt python-ipaddr 2.10 (for CentOS 6 and CentOS 7) here : https://cbs.centos.org/koji/packageinfo?packageID=5152

Hope this helps people in the same situation

Comment 6 Robert Scheck 2017-01-29 01:01:18 UTC
Why has this bug been filed against EPEL rather RHEL? If I'm not completely
mistaken, python-ipaddr is shipped by RHEL 7 (at least CentOS ships it, thus
RHEL too): https://git.centos.org/log/rpms!python-ipaddr.git/refs!heads!c7

Comment 7 Robert Scheck 2017-01-29 01:09:16 UTC
Cross-filed case 01781715 on the Red Hat customer portal.

Oh, and could somebody please reassign this bug against the correct product?

Comment 8 Fabian Arrotin 2017-01-29 08:13:16 UTC
@Robert Yeah, I initially thought that when the bug report was created (in the el7.0 days) python-ipaddr was probably not in rhel and so only in epel, but it seems it was already there (see http://vault.centos.org/7.0.1406/os/x86_64/Packages/python-ipaddr-2.1.9-5.el7.noarch.rpm)

So it should be moved indeed, so that RHEL maintainers can take action too.

PS : I built it on cbs.centos.org, but it's still in an internal 'centos infra' repo (as I needed it for our puppet deployments), and *not* in CentOS 7 base repo (we don't override base pkg)

Comment 9 Robert Scheck 2017-01-30 17:27:25 UTC
Not sure why GSS had to clone this bug into bug #1417701 for RHEL (rather
just to adjust the product of this bug properly), so: Could somebody close
this report as duplicate of bug #1417701, please? Thanks :)

Comment 10 George Notaras 2017-01-31 19:09:29 UTC

*** This bug has been marked as a duplicate of bug 1417701 ***


Note You need to log in before you can comment on or make changes to this bug.