Comments (3)
This is happening because you're using Python 2.6. wsgi-intercept 1.0.0 dropped support for python 2.6. It's only tested on 2.7 and 3.3 and beyond. If you need to continue using 2.6 for some reason then you'll need to pin to version 0.10.3.
In the tests below foo.py
is your example test put into a file with a couple of asserts at the end. In the 2.7 example the lack of output or error means everything worked.
shine:/tmp $ foobar/bin/python2.6 /tmp/foo.py
Traceback (most recent call last):
File "/tmp/foo.py", line 12, in <module>
resp, content = http.request(url)
File "/private/tmp/foobar/lib/python2.6/site-packages/httplib2/__init__.py", line 1491, in request
proxy_info=proxy_info)
File "/private/tmp/foobar/lib/python2.6/site-packages/wsgi_intercept/httplib2_intercept.py", line 24, in __init__
timeout=timeout, source_address=source_address)
TypeError: __init__() got an unexpected keyword argument 'source_address'
shine:/tmp $ python2.7 /tmp/foo.py
If there's some pressing reason why 2.6 support is still important to maintain, please let me know in a respose to this comment. If not, please get off python 2.6.6; there have been important security fixes (see 2.6.9) and 2.6 is no longer a supported version of Python.
from wsgi-intercept.
Thank you for your answer and you recommendations @cdent!
For now i can't move to Python 2.7, so i'll stay on version 0.10.3.
I was wrong because in the documentation (http://wsgi-intercept.readthedocs.org/en/latest/), on the history section still mentions Python 2.6
from wsgi-intercept.
Oh, sorry about, thanks for letting me know. It turns out that the docs build jobs at readthedocs were not working properly. The source had been updated but not the published docs. I'm fixing the docs jobs now.
from wsgi-intercept.
Related Issues (20)
- Including LICENSE file in the code repository and Adding it in the Manifest file HOT 4
- Please allow to disable internet tests HOT 3
- wsgi_intercept.make_environ turns headers into unicode HOT 3
- When using the url arg to an Interceptor, if there is no port in the url an error happens
- wsgi-intercept should build in some character encoding checks
- Write ignores response body when first item in iterable is an empty string HOT 1
- urllib3 intercept cause TypeError with https URL HOT 8
- Logs / errors are lost due to `wsgi.errors` not extracted HOT 4
- Interceptor.uninstall_interceptor turns off intercept for all intercepts using the same module
- Pypi sdist tarball doesn't have README.rst HOT 3
- Missing 2 required positional arguments: 'environ' and 'start_response' with Django 2.2 HOT 4
- With httplib2 0.14.0 many tests fail HOT 9
- HTTPS connections with Requests library don't support verify=False to outside domains HOT 7
- Support aiohttp HOT 2
- Simple example fails with Python 2 HOT 5
- PEP517 HOT 4
- Incompatibility with pytest 7.2.0 HOT 2
- support urllib3 > 2
- drop support for python 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from wsgi-intercept.