[#45] replace http.py with the Requests library
- Note the following exception replacements: mwclient.errors.HTTPError -> requests.exceptions.ConnectionError mwclient.errors.HTTPStatusError -> requests.exceptions.HTTPError mwclient.errors.HTTPRedirectError -> requests.exceptions.TooManyRedirects - Removed the `compability.old_upload` method, which was used for MediaWiki < 1.16. - Requests automatically decompresses gzip-encoded responses, and does its best to decode response content to unicode when possible. - [#53] Using the Responses library to mock http requests in tests
Showing
- .travis.yml 1 addition, 1 deletion.travis.yml
- examples/upload.py 22 additions, 20 deletionsexamples/upload.py
- mwclient/client.py 39 additions, 50 deletionsmwclient/client.py
- mwclient/compatibility.py 1 addition, 47 deletionsmwclient/compatibility.py
- mwclient/errors.py 0 additions, 12 deletionsmwclient/errors.py
- mwclient/ex.py 2 additions, 2 deletionsmwclient/ex.py
- mwclient/http.py 0 additions, 270 deletionsmwclient/http.py
- mwclient/upload.py 0 additions, 135 deletionsmwclient/upload.py
- requirements-dev.txt 2 additions, 1 deletionrequirements-dev.txt
- requirements.txt 2 additions, 1 deletionrequirements.txt
- setup.py 2 additions, 2 deletionssetup.py
- tests/client_test.py 112 additions, 5 deletionstests/client_test.py
Loading
Please register or sign in to comment