Bug 1249651 - docker-py gets broken by old python-requests version
docker-py gets broken by old python-requests version
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: docker (Show other bugs)
Unspecified Unspecified
unspecified Severity unspecified
: rc
: ---
Assigned To: Lokesh Mandvekar
: Extras
Depends On: 1245521 1245523
Blocks: 1246120
  Show dependency treegraph
Reported: 2015-08-03 09:40 EDT by Bohuslav "Slavek" Kabrda
Modified: 2016-01-07 16:44 EST (History)
10 users (show)

See Also:
Fixed In Version: docker-1.7.1-109.el7_1
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: 1245521
Last Closed: 2016-01-07 16:44:12 EST
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

  None (edit)
Description Bohuslav "Slavek" Kabrda 2015-08-03 09:40:21 EDT
+++ This bug was initially created as a clone of Bug #1245521 +++

When I try to use a Python application that depends on python-docker-py (or python3-docker-py) and uses setuptools entry point for its binary, I get this error (using atomic-reactor [1]):

Traceback (most recent call last):
  File "/usr/bin/atomic-reactor2", line 5, in <module>
    from pkg_resources import load_entry_point
  File "/usr/lib/python2.7/site-packages/pkg_resources/__init__.py", line 3084, in <module>
  File "/usr/lib/python2.7/site-packages/pkg_resources/__init__.py", line 3070, in _call_aside
    f(*args, **kwargs)
  File "/usr/lib/python2.7/site-packages/pkg_resources/__init__.py", line 3097, in _initialize_master_working_set
    working_set = WorkingSet._build_master()
  File "/usr/lib/python2.7/site-packages/pkg_resources/__init__.py", line 653, in _build_master
    return cls._build_from_requirements(__requires__)
  File "/usr/lib/python2.7/site-packages/pkg_resources/__init__.py", line 666, in _build_from_requirements
    dists = ws.resolve(reqs, Environment())
  File "/usr/lib/python2.7/site-packages/pkg_resources/__init__.py", line 839, in resolve
    raise DistributionNotFound(req, requirers)
pkg_resources.DistributionNotFound: The 'websocket-client>=0.32.0' distribution was not found and is required by docker-py

So the problem is that Fedora's python-websocket-client is too old. I'll open another bug for python-websocket-client to update, but I think there's also a problem in python-docker-py that should be solved.
Either python-docker-py should use proper python-websocket-client version in specfile, like "Requires: python-websocket-client >= 0.32.0" or "/usr/lib/python2.7/site-packages/docker_py-1.3.0-py2.7.egg-info/requires.txt" should be patched to not require that specific version (assuming the package can work with older versions).

[1] https://github.com/projectatomic/atomic-reactor

--- Additional comment from Tomas Tomecek on 2015-07-28 00:46:05 EDT ---



does f22 also require a fix?

--- Additional comment from Bohuslav "Slavek" Kabrda on 2015-07-28 05:25:05 EDT ---

F22 is fine, no fix needed there. Thanks!

--- Additional comment from Tomas Tomecek on 2015-07-28 05:42:06 EDT ---

Closing then. Feel free to reopen in case more issues.

Note: the original Fedora bug was for incompatible python-websocket-client version, this one is for incompatible python-requests version. I provided the RHEL 7 backtrace and explanation at bug 1192534 comment 13.

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