Skip to content
This repository has been archived by the owner on May 25, 2024. It is now read-only.

Fix for https connection by httplib2 (TypeError: __init__() got an un… #1

Open
wants to merge 4 commits into
base: master
Choose a base branch
from

Conversation

kamilhlawiczka
Copy link

Fix for https connection by httplib2

Error message: TypeError: __init__() got an unexpected keyword argument 'context'

traceback:

Traceback (most recent call last):
  File "<string>", line 1, in <module>
  File "/home/kml/venv/httplib2/lib/python3.6/site-packages/httplib2/__init__.py", line 1396, in request
    self.disable_ssl_certificate_validation)
  File "/home/kml/venv/httplib2/lib/python3.6/site-packages/httplib2/__init__.py", line 979, in __init__
    timeout=timeout, context=context)
  File "/home/kml/venv/httplib2/lib/python3.6/site-packages/geventhttpclient/httplib.py", line 118, in __init__
    HTTPConnection.__init__(self, host, port, **kw)
  File "/home/kml/venv/httplib2/lib/python3.6/site-packages/geventhttpclient/httplib.py", line 95, in __init__
    HTTPLibConnection.__init__(self, *args, **kw)
TypeError: __init__() got an unexpected keyword argument 'context'

reposteps:

pip install geventhttpclient-wheels
pip install httplib2
python -c 'import geventhttpclient.httplib;geventhttpclient.httplib.patch();import httplib2;h=httplib2.Http();h.request("https://github.com", "GET")'

src from reposteps:

import geventhttpclient.httplib
geventhttpclient.httplib.patch()
import httplib2

h=httplib2.Http()
h.request("https://github.com", "GET")'

env:
Python 3.6.5
geventhttpclient-wheels 1.3.1.dev1
httplib2 0.11.3

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
1 participant