Bug 1393979 - copr-cli: ImportError: cannot import name InvalidHeader
Summary: copr-cli: ImportError: cannot import name InvalidHeader
Keywords:
Status: CLOSED UPSTREAM
Alias: None
Product: Fedora
Classification: Fedora
Component: copr-cli
Version: rawhide
Hardware: x86_64
OS: Linux
unspecified
urgent
Target Milestone: ---
Assignee: Miroslav Suchý
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2016-11-10 18:22 UTC by Sorin Sbarnea
Modified: 2016-11-10 18:36 UTC (History)
4 users (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2016-11-10 18:36:40 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)
pip freeze report (2.91 KB, text/plain)
2016-11-10 18:25 UTC, Sorin Sbarnea
no flags Details

Description Sorin Sbarnea 2016-11-10 18:22:31 UTC
Description of problem:
After installing copr-cli using pip I tried to run it and I got:

$ copr-cli
Traceback (most recent call last):
  File "/bin/copr-cli", line 7, in <module>
    from copr_cli.main import main
  File "/usr/lib/python2.7/site-packages/copr_cli/main.py", line 31, in <module>
    from copr import CoprClient
  File "/usr/lib/python2.7/site-packages/copr/__init__.py", line 1, in <module>
    from .client import CoprClient
  File "/usr/lib/python2.7/site-packages/copr/client/__init__.py", line 7, in <module>
    from .client import CoprClient
  File "/usr/lib/python2.7/site-packages/copr/client/client.py", line 14, in <module>
    import requests
  File "/usr/lib/python2.7/site-packages/requests/__init__.py", line 64, in <module>
    from . import utils
  File "/usr/lib/python2.7/site-packages/requests/utils.py", line 29, in <module>
    from .exceptions import InvalidURL, InvalidHeader, FileModeWarning
ImportError: cannot import name InvalidHeader

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

Comment 1 Sorin Sbarnea 2016-11-10 18:25:22 UTC
Created attachment 1219473 [details]
pip freeze report

Comment 2 Sorin Sbarnea 2016-11-10 18:36:40 UTC
Not sure what caused this but doing this fixed it:

pip install --upgrade --force-reinstall requestsexceptions requests requests-toolbelt

I do mention that pip freeze reports the same packages as installed as before running the command, but this time it works.

This does not seem like a bug in copr-cli so raising it there

https://github.com/kennethreitz/requests/issues/3670


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