#219: depcheck: NameError: global name 'rpmfluff' is not defined
---------------------+------------------------------------------------------
Reporter: kparal | Owner: wwoods
Type: defect | Status: closed
Priority: major | Milestone: Package Update Acceptance Test Plan - depcheck
Component: tests | Version: 1.0
Resolution: fixed | Keywords:
---------------------+------------------------------------------------------
Changes (by wwoods):
* status: new => closed
* resolution: => fixed
Old description:
{{{
# ~autotest/client/site_tests/depcheck/depcheck --selftest
/usr/lib/python2.6/site-packages/rpmfluff.py:58: DeprecationWarning: The
popen2 module is deprecated. Use the subprocess module.
import popen2
EEEEEEEE
======================================================================
ERROR: test_createrepo (depcheck.DepcheckPrereqTestCase)
----------------------------------------------------------------------
Traceback (most recent call last):
File "/usr/share/autotest/client/site_tests/depcheck/depcheck.py", line
277, in test_createrepo
rpmlist = simple_rpmlist()
File "/usr/share/autotest/client/site_tests/depcheck/depcheck.py", line
249, in simple_rpmlist
m = rpmfluff.SimpleRpmBuild('mint', '1.0', '1')
NameError: global name 'rpmfluff' is not defined
======================================================================
ERROR: test_rpmfluff (depcheck.DepcheckPrereqTestCase)
----------------------------------------------------------------------
Traceback (most recent call last):
File "/usr/share/autotest/client/site_tests/depcheck/depcheck.py", line
260, in test_rpmfluff
p = rpmfluff.SimpleRpmBuild(n, v, r)
NameError: global name 'rpmfluff' is not defined
======================================================================
ERROR: test_simple_yum_setup (depcheck.DepcheckPrereqTestCase)
----------------------------------------------------------------------
Traceback (most recent call last):
File "/usr/share/autotest/client/site_tests/depcheck/depcheck.py", line
290, in test_simple_yum_setup
arch = rpmfluff.expectedArch
NameError: global name 'rpmfluff' is not defined
======================================================================
ERROR: Test a changed Provides:
----------------------------------------------------------------------
Traceback (most recent call last):
File "/usr/share/autotest/client/site_tests/depcheck/depcheck.py", line
317, in setUp
self.arch = rpmfluff.expectedArch
NameError: global name 'rpmfluff' is not defined
======================================================================
ERROR: Make sure we accept a consistent repo, and no updates at all
----------------------------------------------------------------------
Traceback (most recent call last):
File "/usr/share/autotest/client/site_tests/depcheck/depcheck.py", line
317, in setUp
self.arch = rpmfluff.expectedArch
NameError: global name 'rpmfluff' is not defined
======================================================================
ERROR: Make sure depcheck accepts a good update as expected
----------------------------------------------------------------------
Traceback (most recent call last):
File "/usr/share/autotest/client/site_tests/depcheck/depcheck.py", line
317, in setUp
self.arch = rpmfluff.expectedArch
NameError: global name 'rpmfluff' is not defined
======================================================================
ERROR: make sure depcheck catches updates with missing requires
----------------------------------------------------------------------
Traceback (most recent call last):
File "/usr/share/autotest/client/site_tests/depcheck/depcheck.py", line
317, in setUp
self.arch = rpmfluff.expectedArch
NameError: global name 'rpmfluff' is not defined
======================================================================
ERROR: Test with one good and one bad update
----------------------------------------------------------------------
Traceback (most recent call last):
File "/usr/share/autotest/client/site_tests/depcheck/depcheck.py", line
317, in setUp
self.arch = rpmfluff.expectedArch
NameError: global name 'rpmfluff' is not defined
----------------------------------------------------------------------
Ran 8 tests in 0.002s
FAILED (errors=8)
}}}
New description:
{{{
# ~autotest/client/site_tests/depcheck/depcheck --selftest
/usr/lib/python2.6/site-packages/rpmfluff.py:58: DeprecationWarning: The
popen2 module is deprecated. Use the subprocess module.
import popen2
EEEEEEEE
======================================================================
ERROR: test_createrepo (depcheck.DepcheckPrereqTestCase)
----------------------------------------------------------------------
Traceback (most recent call last):
File "/usr/share/autotest/client/site_tests/depcheck/depcheck.py", line
277, in test_createrepo
rpmlist = simple_rpmlist()
File "/usr/share/autotest/client/site_tests/depcheck/depcheck.py", line
249, in simple_rpmlist
m = rpmfluff.SimpleRpmBuild('mint', '1.0', '1')
NameError: global name 'rpmfluff' is not defined
======================================================================
ERROR: test_rpmfluff (depcheck.DepcheckPrereqTestCase)
----------------------------------------------------------------------
Traceback (most recent call last):
File "/usr/share/autotest/client/site_tests/depcheck/depcheck.py", line
260, in test_rpmfluff
p = rpmfluff.SimpleRpmBuild(n, v, r)
NameError: global name 'rpmfluff' is not defined
======================================================================
ERROR: test_simple_yum_setup (depcheck.DepcheckPrereqTestCase)
----------------------------------------------------------------------
Traceback (most recent call last):
File "/usr/share/autotest/client/site_tests/depcheck/depcheck.py", line
290, in test_simple_yum_setup
arch = rpmfluff.expectedArch
NameError: global name 'rpmfluff' is not defined
======================================================================
ERROR: Test a changed Provides:
----------------------------------------------------------------------
Traceback (most recent call last):
File "/usr/share/autotest/client/site_tests/depcheck/depcheck.py", line
317, in setUp
self.arch = rpmfluff.expectedArch
NameError: global name 'rpmfluff' is not defined
======================================================================
ERROR: Make sure we accept a consistent repo, and no updates at all
----------------------------------------------------------------------
Traceback (most recent call last):
File "/usr/share/autotest/client/site_tests/depcheck/depcheck.py", line
317, in setUp
self.arch = rpmfluff.expectedArch
NameError: global name 'rpmfluff' is not defined
======================================================================
ERROR: Make sure depcheck accepts a good update as expected
----------------------------------------------------------------------
Traceback (most recent call last):
File "/usr/share/autotest/client/site_tests/depcheck/depcheck.py", line
317, in setUp
self.arch = rpmfluff.expectedArch
NameError: global name 'rpmfluff' is not defined
======================================================================
ERROR: make sure depcheck catches updates with missing requires
----------------------------------------------------------------------
Traceback (most recent call last):
File "/usr/share/autotest/client/site_tests/depcheck/depcheck.py", line
317, in setUp
self.arch = rpmfluff.expectedArch
NameError: global name 'rpmfluff' is not defined
======================================================================
ERROR: Test with one good and one bad update
----------------------------------------------------------------------
Traceback (most recent call last):
File "/usr/share/autotest/client/site_tests/depcheck/depcheck.py", line
317, in setUp
self.arch = rpmfluff.expectedArch
NameError: global name 'rpmfluff' is not defined
----------------------------------------------------------------------
Ran 8 tests in 0.002s
FAILED (errors=8)
}}}
Comment:
Yup, that's what's happening.
I've patched depcheck.py to import rpmfluff unconditionally. This is the
simplest solution but it does make depcheck grow a dependency on rpmfluff.
But it can just install that during the setup() function.
--
Ticket URL: <
https://fedorahosted.org/autoqa/ticket/219#comment:2>
AutoQA <
http://autoqa.fedorahosted.org>
Automated QA project