Bug 1469262 - pkg_resources.VersionConflict: (coverage 3.6b3 (/usr/lib64/python2.7/site-packages), Requirement.parse('coverage>=3.6'))
pkg_resources.VersionConflict: (coverage 3.6b3 (/usr/lib64/python2.7/site-pac...
Status: ASSIGNED
Product: Fedora EPEL
Classification: Fedora
Component: python-cov-core (Show other bugs)
epel7
All Linux
unspecified Severity medium
: ---
: ---
Assigned To: Bohuslav "Slavek" Kabrda
Fedora Extras Quality Assurance
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2017-07-10 14:51 EDT by Randy Barlow
Modified: 2017-08-17 00:44 EDT (History)
7 users (show)

See Also:
Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed:
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Randy Barlow 2017-07-10 14:51:07 EDT
Description of problem:
I am unable to test Bodhi's coverage on EPEL 7 with pytest-cov:

$ /usr/bin/py.test
Traceback (most recent call last):
  File "/usr/bin/py.test", line 9, in <module>
    load_entry_point('pytest==2.7.0', 'console_scripts', 'py.test-2.7')()
  File "/usr/lib/python2.7/site-packages/_pytest/config.py", line 32, in main
    config = _prepareconfig(args, plugins)
  File "/usr/lib/python2.7/site-packages/_pytest/config.py", line 85, in _prepareconfig
    pluginmanager=pluginmanager, args=args)
  File "/usr/lib/python2.7/site-packages/_pytest/core.py", line 521, in __call__
    return self._docall(self.methods, kwargs)
  File "/usr/lib/python2.7/site-packages/_pytest/core.py", line 528, in _docall
    firstresult=self.firstresult).execute()
  File "/usr/lib/python2.7/site-packages/_pytest/core.py", line 393, in execute
    return wrapped_call(method(*args), self.execute)
  File "/usr/lib/python2.7/site-packages/_pytest/core.py", line 109, in wrapped_call
    wrap_controller.send(call_outcome)
  File "/usr/lib/python2.7/site-packages/_pytest/helpconfig.py", line 28, in pytest_cmdline_parse
    config = outcome.get_result()
  File "/usr/lib/python2.7/site-packages/_pytest/core.py", line 138, in get_result
    py.builtin._reraise(*ex)
  File "/usr/lib/python2.7/site-packages/_pytest/core.py", line 123, in __init__
    self.result = func()
  File "/usr/lib/python2.7/site-packages/_pytest/core.py", line 394, in execute
    res = method(*args)
  File "/usr/lib/python2.7/site-packages/_pytest/config.py", line 636, in pytest_cmdline_parse
    self.parse(args)
  File "/usr/lib/python2.7/site-packages/_pytest/config.py", line 746, in parse
    self._preparse(args)
  File "/usr/lib/python2.7/site-packages/_pytest/config.py", line 713, in _preparse
    self.pluginmanager.consider_setuptools_entrypoints()
  File "/usr/lib/python2.7/site-packages/_pytest/core.py", line 278, in consider_setuptools_entrypoints
    plugin = ep.load()
  File "/usr/lib/python2.7/site-packages/pkg_resources.py", line 2259, in load
    if require: self.require(env, installer)
  File "/usr/lib/python2.7/site-packages/pkg_resources.py", line 2272, in require
    working_set.resolve(self.dist.requires(self.extras),env,installer)))
  File "/usr/lib/python2.7/site-packages/pkg_resources.py", line 630, in resolve
    raise VersionConflict(dist,req) # XXX put more info here
pkg_resources.VersionConflict: (coverage 3.6b3 (/usr/lib64/python2.7/site-packages), Requirement.parse('coverage>=3.6'))
Comment 1 Orion Poplawski 2017-07-14 11:14:53 EDT
This requirement actually comes from cov-core.
Comment 2 Charalampos Stratakis 2017-07-20 09:06:35 EDT
The version of python-coverage that exists in RHEL is coverage-3.6b3 and cov-core doesn't accept it. Will patch it to find the b3 version and see if it works.

Could you provide me a reproducer as well?
Comment 3 Orion Poplawski 2017-08-04 17:08:38 EDT
$ cat test_cov.py
pytest_plugins = 'cov'

$ py.test test_cov.py
Traceback (most recent call last):
  File "/usr/bin/py.test", line 9, in <module>
    load_entry_point('pytest==2.7.0', 'console_scripts', 'py.test-2.7')()
  File "/usr/lib/python2.7/site-packages/_pytest/config.py", line 32, in main
    config = _prepareconfig(args, plugins)
  File "/usr/lib/python2.7/site-packages/_pytest/config.py", line 85, in _prepareconfig
    pluginmanager=pluginmanager, args=args)
  File "/usr/lib/python2.7/site-packages/_pytest/core.py", line 521, in __call__
    return self._docall(self.methods, kwargs)
  File "/usr/lib/python2.7/site-packages/_pytest/core.py", line 528, in _docall
    firstresult=self.firstresult).execute()
  File "/usr/lib/python2.7/site-packages/_pytest/core.py", line 393, in execute
    return wrapped_call(method(*args), self.execute)
  File "/usr/lib/python2.7/site-packages/_pytest/core.py", line 109, in wrapped_call
    wrap_controller.send(call_outcome)
  File "/usr/lib/python2.7/site-packages/_pytest/helpconfig.py", line 28, in pytest_cmdline_parse
    config = outcome.get_result()
  File "/usr/lib/python2.7/site-packages/_pytest/core.py", line 138, in get_result
    py.builtin._reraise(*ex)
  File "/usr/lib/python2.7/site-packages/_pytest/core.py", line 123, in __init__
    self.result = func()
  File "/usr/lib/python2.7/site-packages/_pytest/core.py", line 394, in execute
    res = method(*args)
  File "/usr/lib/python2.7/site-packages/_pytest/config.py", line 636, in pytest_cmdline_parse
    self.parse(args)
  File "/usr/lib/python2.7/site-packages/_pytest/config.py", line 746, in parse
    self._preparse(args)
  File "/usr/lib/python2.7/site-packages/_pytest/config.py", line 713, in _preparse
    self.pluginmanager.consider_setuptools_entrypoints()
  File "/usr/lib/python2.7/site-packages/_pytest/core.py", line 278, in consider_setuptools_entrypoints
    plugin = ep.load()
  File "/usr/lib/python2.7/site-packages/pkg_resources.py", line 2259, in load
    if require: self.require(env, installer)
  File "/usr/lib/python2.7/site-packages/pkg_resources.py", line 2272, in require
    working_set.resolve(self.dist.requires(self.extras),env,installer)))
  File "/usr/lib/python2.7/site-packages/pkg_resources.py", line 630, in resolve
    raise VersionConflict(dist,req) # XXX put more info here
pkg_resources.VersionConflict: (coverage 3.6b3 (/usr/lib64/python2.7/site-packages), Requirement.parse('coverage>=3.6'))

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