On Centos7 pylint fails to build

Bug #1350644 reported by Kris Lindgren
10
This bug affects 2 people
Affects Status Importance Assigned to Milestone
anvil
Fix Committed
Medium
Unassigned

Bug Description

This appears to be because the tests wont bitcompile:

+ /usr/lib/rpm/brp-python-bytecompile /usr/bin/python 1
Bytecompiling .py files below /root/openstack/deps/rpmbuild/pylint-0.25.2-0.el7.centos.src.rpm/BUILDROOT/pylint-0.25.2-0.el7.centos
.x86_64/usr/lib/python2.7/ using /usr/bin/python2.7
/usr/lib/python2.7/site-packages/pylint/test/input/func_assert_2uple.py:4: SyntaxWarning: assertion is always true, perhaps remove
parentheses?
/usr/lib/python2.7/site-packages/pylint/test/input/func_assert_2uple.py:5: SyntaxWarning: assertion is always true, perhaps remove
parentheses?
/usr/lib/python2.7/site-packages/pylint/test/input/func_assert_2uple.py:7: SyntaxWarning: assertion is always true, perhaps remove
parentheses?
/usr/lib/python2.7/site-packages/pylint/test/input/func_assert_2uple.py:8: SyntaxWarning: assertion is always true, perhaps remove
parentheses?
/usr/lib/python2.7/site-packages/pylint/test/input/func_assert_2uple.py:9: SyntaxWarning: assertion is always true, perhaps remove
parentheses?
/usr/lib/python2.7/site-packages/pylint/test/input/func_assert_2uple.py:11: SyntaxWarning: assertion is always true, perhaps remove
 parentheses?
Compiling /root/openstack/deps/rpmbuild/pylint-0.25.2-0.el7.centos.src.rpm/BUILDROOT/pylint-0.25.2-0.el7.centos.x86_64/usr/lib/pyth
on2.7/site-packages/pylint/test/input/func_3k_removed_stuff_py_30.py ...
  File "/usr/lib/python2.7/site-packages/pylint/test/input/func_3k_removed_stuff_py_30.py", line 4
SyntaxError: from __future__ imports must occur at the beginning of the file

Compiling /root/openstack/deps/rpmbuild/pylint-0.25.2-0.el7.centos.src.rpm/BUILDROOT/pylint-0.25.2-0.el7.centos.x86_64/usr/lib/pyth
on2.7/site-packages/pylint/test/input/func_continue_not_in_loop.py ...
  File "/usr/lib/python2.7/site-packages/pylint/test/input/func_continue_not_in_loop.py", line 8
SyntaxError: 'continue' not properly in loop

Compiling /root/openstack/deps/rpmbuild/pylint-0.25.2-0.el7.centos.src.rpm/BUILDROOT/pylint-0.25.2-0.el7.centos.x86_64/usr/lib/pyth
on2.7/site-packages/pylint/test/input/func_keyword_repeat.py ...
  File "/usr/lib/python2.7/site-packages/pylint/test/input/func_keyword_repeat.py", line 8
SyntaxError: keyword argument repeated

Compiling /root/openstack/deps/rpmbuild/pylint-0.25.2-0.el7.centos.src.rpm/BUILDROOT/pylint-0.25.2-0.el7.centos.x86_64/usr/lib/pyth
on2.7/site-packages/pylint/test/input/func_return_outside_func.py ...
  File "/usr/lib/python2.7/site-packages/pylint/test/input/func_return_outside_func.py", line 3
SyntaxError: 'return' outside function

Compiling /root/openstack/deps/rpmbuild/pylint-0.25.2-0.el7.centos.src.rpm/BUILDROOT/pylint-0.25.2-0.el7.centos.x86_64/usr/lib/pyth
on2.7/site-packages/pylint/test/input/func_return_yield_mix.py ...
SyntaxError: 'return' with argument inside generator (func_return_yield_mix.py, line 8)

Compiling /root/openstack/deps/rpmbuild/pylint-0.25.2-0.el7.centos.src.rpm/BUILDROOT/pylint-0.25.2-0.el7.centos.x86_64/usr/lib/pyth
on2.7/site-packages/pylint/test/input/func_syntax_error.py ...
  File "/usr/lib/python2.7/site-packages/pylint/test/input/func_syntax_error.py", line 1
    def toto
           ^
SyntaxError: invalid syntax

Compiling /root/openstack/deps/rpmbuild/pylint-0.25.2-0.el7.centos.src.rpm/BUILDROOT/pylint-0.25.2-0.el7.centos.x86_64/usr/lib/pyth
on2.7/site-packages/pylint/test/input/func_unknown_encoding.py ...
  File "/usr/lib/python2.7/site-packages/pylint/test/input/func_unknown_encoding.py", line 0
SyntaxError: unknown encoding: IBO-8859-1

Compiling /root/openstack/deps/rpmbuild/pylint-0.25.2-0.el7.centos.src.rpm/BUILDROOT/pylint-0.25.2-0.el7.centos.x86_64/usr/lib/pyth
on2.7/site-packages/pylint/test/input/func_w0705.py ...
  File "/usr/lib/python2.7/site-packages/pylint/test/input/func_w0705.py", line 28
SyntaxError: default 'except:' must be last

Compiling /root/openstack/deps/rpmbuild/pylint-0.25.2-0.el7.centos.src.rpm/BUILDROOT/pylint-0.25.2-0.el7.centos.x86_64/usr/lib/pyth
on2.7/site-packages/pylint/test/input/func_yield_outside_func.py ...
  File "/usr/lib/python2.7/site-packages/pylint/test/input/func_yield_outside_func.py", line 3
SyntaxError: 'yield' outside function

Compiling /root/openstack/deps/rpmbuild/pylint-0.25.2-0.el7.centos.src.rpm/BUILDROOT/pylint-0.25.2-0.el7.centos.x86_64/usr/lib/pyth
on2.7/site-packages/pylint/test/input/syntax_error.py ...
Sorry: IndentationError: expected an indented block (syntax_error.py, line 2)
error: Bad exit status from /var/tmp/rpm-tmp.T9uxtI (%install)

RPM build errors:
    Bad exit status from /var/tmp/rpm-tmp.T9uxtI (%install)
[root@localhost anvil]#

Revision history for this message
Stig Telfer (stigtelfer) wrote :

It appears that the python bytecompiling phase of RPM installation can now cause RPM installation to fail. The default invocation of helper script brp-python-bytecompile has changed.

If you define _python_bytecompile_errors_terminate_build to be 0 in your RPM macros, the RPM installation succeeds. Should Anvil define this macro value always when invoking rpmbuild, or specifically when packaging pylint?

Revision history for this message
Joshua Harlow (harlowja) wrote :

Looking @ http://www.rpmfind.net//linux/RPM/fedora/devel/rawhide/i386/p/pylint-1.2-7.fc21.noarch.html it seems to just remove the tests, so maybe we should do the same??

Joshua Harlow (harlowja)
Changed in anvil:
importance: Undecided → Medium
Joshua Harlow (harlowja)
Changed in anvil:
status: New → Fix Committed
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.