url
stringlengths
50
53
repository_url
stringclasses
1 value
labels_url
stringlengths
64
67
comments_url
stringlengths
59
62
events_url
stringlengths
57
60
html_url
stringlengths
38
43
id
int64
597k
2.65B
node_id
stringlengths
18
32
number
int64
1
6.83k
title
stringlengths
1
296
user
dict
labels
listlengths
0
5
state
stringclasses
2 values
locked
bool
2 classes
assignee
dict
assignees
listlengths
0
4
milestone
dict
comments
int64
0
211
created_at
stringlengths
20
20
updated_at
stringlengths
20
20
closed_at
stringlengths
20
20
author_association
stringclasses
3 values
active_lock_reason
stringclasses
4 values
body
stringlengths
0
65.6k
closed_by
dict
reactions
dict
timeline_url
stringlengths
59
62
performed_via_github_app
null
state_reason
stringclasses
3 values
draft
bool
2 classes
pull_request
dict
is_pull_request
bool
2 classes
issue_comments
listlengths
0
30
https://api.github.com/repos/psf/requests/issues/3031
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/3031/labels{/name}
https://api.github.com/repos/psf/requests/issues/3031/comments
https://api.github.com/repos/psf/requests/issues/3031/events
https://github.com/psf/requests/issues/3031
138,483,327
MDU6SXNzdWUxMzg0ODMzMjc=
3,031
[WinError 10048] Only one usage of each socket address ...
{ "avatar_url": "https://avatars.githubusercontent.com/u/16397493?v=4", "events_url": "https://api.github.com/users/iliakarmanov/events{/privacy}", "followers_url": "https://api.github.com/users/iliakarmanov/followers", "following_url": "https://api.github.com/users/iliakarmanov/following{/other_user}", "gists_url": "https://api.github.com/users/iliakarmanov/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/iliakarmanov", "id": 16397493, "login": "iliakarmanov", "node_id": "MDQ6VXNlcjE2Mzk3NDkz", "organizations_url": "https://api.github.com/users/iliakarmanov/orgs", "received_events_url": "https://api.github.com/users/iliakarmanov/received_events", "repos_url": "https://api.github.com/users/iliakarmanov/repos", "site_admin": false, "starred_url": "https://api.github.com/users/iliakarmanov/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/iliakarmanov/subscriptions", "type": "User", "url": "https://api.github.com/users/iliakarmanov", "user_view_type": "public" }
[ { "color": "e11d21", "default": false, "description": null, "id": 136589914, "name": "Needs Info", "node_id": "MDU6TGFiZWwxMzY1ODk5MTQ=", "url": "https://api.github.com/repos/psf/requests/labels/Needs%20Info" }, { "color": "777777", "default": false, "description": null, ...
closed
true
null
[]
null
8
2016-03-04T14:02:15Z
2021-09-08T14:00:29Z
2016-04-16T04:05:20Z
NONE
resolved
I notice that despite using requests.Session() - I still seem to be creating new connections/sockets which eventually exhaust (TIME_WAIT) and I get the following error: > [WinError 10048] Only one usage of each socket address (protocol/network address/port) is normally permitted',)) ``` s = requests.Session() data = zip(url_routes, cycle(s)) calc_routes = pool.map(processRequest, data) ``` I posted a bit more [here](http://stackoverflow.com/questions/35793908/python-multiprocessing-associate-a-process-with-a-session), however not sure how to address this
{ "avatar_url": "https://avatars.githubusercontent.com/u/240830?v=4", "events_url": "https://api.github.com/users/sigmavirus24/events{/privacy}", "followers_url": "https://api.github.com/users/sigmavirus24/followers", "following_url": "https://api.github.com/users/sigmavirus24/following{/other_user}", "gists_url": "https://api.github.com/users/sigmavirus24/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/sigmavirus24", "id": 240830, "login": "sigmavirus24", "node_id": "MDQ6VXNlcjI0MDgzMA==", "organizations_url": "https://api.github.com/users/sigmavirus24/orgs", "received_events_url": "https://api.github.com/users/sigmavirus24/received_events", "repos_url": "https://api.github.com/users/sigmavirus24/repos", "site_admin": false, "starred_url": "https://api.github.com/users/sigmavirus24/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sigmavirus24/subscriptions", "type": "User", "url": "https://api.github.com/users/sigmavirus24", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/3031/reactions" }
https://api.github.com/repos/psf/requests/issues/3031/timeline
null
completed
null
null
false
[ "What does `processRequest` do?\n", "FWIW, I should mention that it's _extremely_ unwise to use a Session from multiple processes at the same time: it's not clear to me at all how well connection pooling will behave in that situation, and any number of things could start misbehaving. It's vastly preferable to hav...
https://api.github.com/repos/psf/requests/issues/3030
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/3030/labels{/name}
https://api.github.com/repos/psf/requests/issues/3030/comments
https://api.github.com/repos/psf/requests/issues/3030/events
https://github.com/psf/requests/issues/3030
138,403,878
MDU6SXNzdWUxMzg0MDM4Nzg=
3,030
Strange behaviour in class dict
{ "avatar_url": "https://avatars.githubusercontent.com/u/7345039?v=4", "events_url": "https://api.github.com/users/coveritytest/events{/privacy}", "followers_url": "https://api.github.com/users/coveritytest/followers", "following_url": "https://api.github.com/users/coveritytest/following{/other_user}", "gists_url": "https://api.github.com/users/coveritytest/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/coveritytest", "id": 7345039, "login": "coveritytest", "node_id": "MDQ6VXNlcjczNDUwMzk=", "organizations_url": "https://api.github.com/users/coveritytest/orgs", "received_events_url": "https://api.github.com/users/coveritytest/received_events", "repos_url": "https://api.github.com/users/coveritytest/repos", "site_admin": false, "starred_url": "https://api.github.com/users/coveritytest/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/coveritytest/subscriptions", "type": "User", "url": "https://api.github.com/users/coveritytest", "user_view_type": "public" }
[]
closed
true
null
[]
null
1
2016-03-04T07:34:22Z
2016-03-04T15:02:07Z
2016-03-04T08:13:41Z
NONE
null
Apparently the class does not like hyphens or percent sign. cookies = dict(hottest-count='working') SyntaxError: keyword can't be an expression Same problem with cookies like %FOO%='bar'.
{ "avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4", "events_url": "https://api.github.com/users/Lukasa/events{/privacy}", "followers_url": "https://api.github.com/users/Lukasa/followers", "following_url": "https://api.github.com/users/Lukasa/following{/other_user}", "gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/Lukasa", "id": 1382556, "login": "Lukasa", "node_id": "MDQ6VXNlcjEzODI1NTY=", "organizations_url": "https://api.github.com/users/Lukasa/orgs", "received_events_url": "https://api.github.com/users/Lukasa/received_events", "repos_url": "https://api.github.com/users/Lukasa/repos", "site_admin": false, "starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions", "type": "User", "url": "https://api.github.com/users/Lukasa", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/3030/reactions" }
https://api.github.com/repos/psf/requests/issues/3030/timeline
null
completed
null
null
false
[ "@coveritytest That has nothing to do with requests, and everything to do with Python: as the error reports to you, your _syntax_ is wrong.\n\nTry: `cookies = {\"hottest-count\": \"working\"}`.\n" ]
https://api.github.com/repos/psf/requests/issues/3029
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/3029/labels{/name}
https://api.github.com/repos/psf/requests/issues/3029/comments
https://api.github.com/repos/psf/requests/issues/3029/events
https://github.com/psf/requests/pull/3029
138,314,104
MDExOlB1bGxSZXF1ZXN0NjE2MzU0MDE=
3,029
[MULTIPART-FILE] Content type should always be set
{ "avatar_url": "https://avatars.githubusercontent.com/u/1840162?v=4", "events_url": "https://api.github.com/users/vaibhavkaul/events{/privacy}", "followers_url": "https://api.github.com/users/vaibhavkaul/followers", "following_url": "https://api.github.com/users/vaibhavkaul/following{/other_user}", "gists_url": "https://api.github.com/users/vaibhavkaul/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/vaibhavkaul", "id": 1840162, "login": "vaibhavkaul", "node_id": "MDQ6VXNlcjE4NDAxNjI=", "organizations_url": "https://api.github.com/users/vaibhavkaul/orgs", "received_events_url": "https://api.github.com/users/vaibhavkaul/received_events", "repos_url": "https://api.github.com/users/vaibhavkaul/repos", "site_admin": false, "starred_url": "https://api.github.com/users/vaibhavkaul/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/vaibhavkaul/subscriptions", "type": "User", "url": "https://api.github.com/users/vaibhavkaul", "user_view_type": "public" }
[ { "color": "eb6420", "default": false, "description": null, "id": 44501256, "name": "Breaking API Change", "node_id": "MDU6TGFiZWw0NDUwMTI1Ng==", "url": "https://api.github.com/repos/psf/requests/labels/Breaking%20API%20Change" }, { "color": "e11d21", "default": false, "d...
closed
true
null
[]
null
15
2016-03-03T22:20:14Z
2021-09-08T04:01:15Z
2016-03-04T19:57:56Z
NONE
resolved
# Context In here: https://github.com/kennethreitz/requests/blob/v2.7.0/requests/models.py#L464-L466 The content type is only set if the there isn't one already set. I feel this shouldn't be the case. As we can see here: https://github.com/kennethreitz/requests/blob/master/requests/packages/urllib3/filepost.py#L92 The content type string has a boundary generated by this method. This is specific to the body being encoded. Without this boundary and content type, the data being posted is no longer considered `Multipart Form Data`, which is the whole point of specifying `files=` in the post method. Even raising an exception would be better than silently skipping setting the content type.
{ "avatar_url": "https://avatars.githubusercontent.com/u/1840162?v=4", "events_url": "https://api.github.com/users/vaibhavkaul/events{/privacy}", "followers_url": "https://api.github.com/users/vaibhavkaul/followers", "following_url": "https://api.github.com/users/vaibhavkaul/following{/other_user}", "gists_url": "https://api.github.com/users/vaibhavkaul/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/vaibhavkaul", "id": 1840162, "login": "vaibhavkaul", "node_id": "MDQ6VXNlcjE4NDAxNjI=", "organizations_url": "https://api.github.com/users/vaibhavkaul/orgs", "received_events_url": "https://api.github.com/users/vaibhavkaul/received_events", "repos_url": "https://api.github.com/users/vaibhavkaul/repos", "site_admin": false, "starred_url": "https://api.github.com/users/vaibhavkaul/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/vaibhavkaul/subscriptions", "type": "User", "url": "https://api.github.com/users/vaibhavkaul", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/3029/reactions" }
https://api.github.com/repos/psf/requests/issues/3029/timeline
null
null
false
{ "diff_url": "https://github.com/psf/requests/pull/3029.diff", "html_url": "https://github.com/psf/requests/pull/3029", "merged_at": null, "patch_url": "https://github.com/psf/requests/pull/3029.patch", "url": "https://api.github.com/repos/psf/requests/pulls/3029" }
true
[ "Hi @vaibhavkaul,\n\nThanks for sending a pull request. I'm afraid we likely won't be accepting it. Here's why:\n- This is drastically backwards incompatible behaviour. \n- It takes a great deal of freedom away from the user which we have intentionally placed into their hands.\n- This code does not just change this...
https://api.github.com/repos/psf/requests/issues/3028
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/3028/labels{/name}
https://api.github.com/repos/psf/requests/issues/3028/comments
https://api.github.com/repos/psf/requests/issues/3028/events
https://github.com/psf/requests/issues/3028
138,167,856
MDU6SXNzdWUxMzgxNjc4NTY=
3,028
"in" operation on resp.cookies should not raise CookieConflictError
{ "avatar_url": "https://avatars.githubusercontent.com/u/687131?v=4", "events_url": "https://api.github.com/users/trilogysci/events{/privacy}", "followers_url": "https://api.github.com/users/trilogysci/followers", "following_url": "https://api.github.com/users/trilogysci/following{/other_user}", "gists_url": "https://api.github.com/users/trilogysci/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/trilogysci", "id": 687131, "login": "trilogysci", "node_id": "MDQ6VXNlcjY4NzEzMQ==", "organizations_url": "https://api.github.com/users/trilogysci/orgs", "received_events_url": "https://api.github.com/users/trilogysci/received_events", "repos_url": "https://api.github.com/users/trilogysci/repos", "site_admin": false, "starred_url": "https://api.github.com/users/trilogysci/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/trilogysci/subscriptions", "type": "User", "url": "https://api.github.com/users/trilogysci", "user_view_type": "public" }
[ { "color": "e10c02", "default": false, "description": null, "id": 117744, "name": "Bug", "node_id": "MDU6TGFiZWwxMTc3NDQ=", "url": "https://api.github.com/repos/psf/requests/labels/Bug" }, { "color": "0b02e1", "default": false, "description": null, "id": 191274, "...
closed
true
null
[]
null
3
2016-03-03T12:37:56Z
2021-09-08T18:00:55Z
2016-04-16T04:05:38Z
NONE
resolved
Hosts which have the same cookie define for multiple domains should not raise "CookieConflictError: There are multiple cookies with name," when performing "in" It should short cut and return True immediately when found.
{ "avatar_url": "https://avatars.githubusercontent.com/u/240830?v=4", "events_url": "https://api.github.com/users/sigmavirus24/events{/privacy}", "followers_url": "https://api.github.com/users/sigmavirus24/followers", "following_url": "https://api.github.com/users/sigmavirus24/following{/other_user}", "gists_url": "https://api.github.com/users/sigmavirus24/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/sigmavirus24", "id": 240830, "login": "sigmavirus24", "node_id": "MDQ6VXNlcjI0MDgzMA==", "organizations_url": "https://api.github.com/users/sigmavirus24/orgs", "received_events_url": "https://api.github.com/users/sigmavirus24/received_events", "repos_url": "https://api.github.com/users/sigmavirus24/repos", "site_admin": false, "starred_url": "https://api.github.com/users/sigmavirus24/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sigmavirus24/subscriptions", "type": "User", "url": "https://api.github.com/users/sigmavirus24", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/3028/reactions" }
https://api.github.com/repos/psf/requests/issues/3028/timeline
null
completed
null
null
false
[ "So the problem here is that the default implementation of `collections.Mapping.__contains__` calls in to `__getitem__`, which for the `RequestsCookieJar` requires that there be no duplicate. In this instance, we probably get the most bang for our buck by just overriding `__contains__` to call the parent implementa...
https://api.github.com/repos/psf/requests/issues/3027
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/3027/labels{/name}
https://api.github.com/repos/psf/requests/issues/3027/comments
https://api.github.com/repos/psf/requests/issues/3027/events
https://github.com/psf/requests/issues/3027
137,907,812
MDU6SXNzdWUxMzc5MDc4MTI=
3,027
requests can't make a request to the server it's running on
{ "avatar_url": "https://avatars.githubusercontent.com/u/3768695?v=4", "events_url": "https://api.github.com/users/isc-rsingh/events{/privacy}", "followers_url": "https://api.github.com/users/isc-rsingh/followers", "following_url": "https://api.github.com/users/isc-rsingh/following{/other_user}", "gists_url": "https://api.github.com/users/isc-rsingh/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/isc-rsingh", "id": 3768695, "login": "isc-rsingh", "node_id": "MDQ6VXNlcjM3Njg2OTU=", "organizations_url": "https://api.github.com/users/isc-rsingh/orgs", "received_events_url": "https://api.github.com/users/isc-rsingh/received_events", "repos_url": "https://api.github.com/users/isc-rsingh/repos", "site_admin": false, "starred_url": "https://api.github.com/users/isc-rsingh/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/isc-rsingh/subscriptions", "type": "User", "url": "https://api.github.com/users/isc-rsingh", "user_view_type": "public" }
[]
closed
true
null
[]
null
6
2016-03-02T15:38:20Z
2016-03-04T15:02:26Z
2016-03-02T15:39:59Z
NONE
null
Here's a test case that never returns a response. Shouldn't this work? ``` python import requests from flask import Flask app = Flask(__name__) @app.route('/') def Welcome(): return "Testing requests module's ability to call the service in which it's running" @app.route('/test') def TestRequest(): resp = requests.get('http://0.0.0.0:5004') print('Response from TestRequest: '+resp.text) if __name__ == "__main__": app.run(host='0.0.0.0', port=5004, debug=True) ```
{ "avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4", "events_url": "https://api.github.com/users/Lukasa/events{/privacy}", "followers_url": "https://api.github.com/users/Lukasa/followers", "following_url": "https://api.github.com/users/Lukasa/following{/other_user}", "gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/Lukasa", "id": 1382556, "login": "Lukasa", "node_id": "MDQ6VXNlcjEzODI1NTY=", "organizations_url": "https://api.github.com/users/Lukasa/orgs", "received_events_url": "https://api.github.com/users/Lukasa/received_events", "repos_url": "https://api.github.com/users/Lukasa/repos", "site_admin": false, "starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions", "type": "User", "url": "https://api.github.com/users/Lukasa", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/3027/reactions" }
https://api.github.com/repos/psf/requests/issues/3027/timeline
null
completed
null
null
false
[ "Flask's debug server cannot handle multiple requests at once. Run Flask behind a proper WSGI server and you'll be fine. =)\n", "Thanks for the tip @Lukasa. I'm a newbie when it comes to Python web serving. Been struggling getting Apache WSGI module + Flask on OS X el capitan all day. First it was SIP (system int...
https://api.github.com/repos/psf/requests/issues/3026
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/3026/labels{/name}
https://api.github.com/repos/psf/requests/issues/3026/comments
https://api.github.com/repos/psf/requests/issues/3026/events
https://github.com/psf/requests/issues/3026
137,789,383
MDU6SXNzdWUxMzc3ODkzODM=
3,026
option to enable TCP level keepalive
{ "avatar_url": "https://avatars.githubusercontent.com/u/61531?v=4", "events_url": "https://api.github.com/users/woosley/events{/privacy}", "followers_url": "https://api.github.com/users/woosley/followers", "following_url": "https://api.github.com/users/woosley/following{/other_user}", "gists_url": "https://api.github.com/users/woosley/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/woosley", "id": 61531, "login": "woosley", "node_id": "MDQ6VXNlcjYxNTMx", "organizations_url": "https://api.github.com/users/woosley/orgs", "received_events_url": "https://api.github.com/users/woosley/received_events", "repos_url": "https://api.github.com/users/woosley/repos", "site_admin": false, "starred_url": "https://api.github.com/users/woosley/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/woosley/subscriptions", "type": "User", "url": "https://api.github.com/users/woosley", "user_view_type": "public" }
[]
closed
true
null
[]
null
3
2016-03-02T06:46:46Z
2021-09-08T19:00:32Z
2016-03-02T07:14:21Z
NONE
resolved
When there is firewall between client and server, http session will be killed even with keepalive enabled because no TCP level keepalive probe is sent. according to [here](http://tldp.org/HOWTO/TCP-Keepalive-HOWTO/usingkeepalive.html) > Remember that keepalive support, even if configured in the kernel, is not the default behavior in Linux. Programs must request keepalive control for their sockets using the setsockopt interface. There are relatively few programs implementing keepalive that said, is it possible to enable this behavior as an option in the library?
{ "avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4", "events_url": "https://api.github.com/users/Lukasa/events{/privacy}", "followers_url": "https://api.github.com/users/Lukasa/followers", "following_url": "https://api.github.com/users/Lukasa/following{/other_user}", "gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/Lukasa", "id": 1382556, "login": "Lukasa", "node_id": "MDQ6VXNlcjEzODI1NTY=", "organizations_url": "https://api.github.com/users/Lukasa/orgs", "received_events_url": "https://api.github.com/users/Lukasa/received_events", "repos_url": "https://api.github.com/users/Lukasa/repos", "site_admin": false, "starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions", "type": "User", "url": "https://api.github.com/users/Lukasa", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/3026/reactions" }
https://api.github.com/repos/psf/requests/issues/3026/timeline
null
completed
null
null
false
[ "It is already possible: the requests tool belt provides a [Socket Options transport adapter](http://toolbelt.readthedocs.org/en/latest/adapters.html#socketoptionsadapter) that allows you to turn on TCP_KEEPALIVE.\n", "There's also a separate keep alive adapter which subclasses the socket options adapter. That wi...
https://api.github.com/repos/psf/requests/issues/3025
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/3025/labels{/name}
https://api.github.com/repos/psf/requests/issues/3025/comments
https://api.github.com/repos/psf/requests/issues/3025/events
https://github.com/psf/requests/issues/3025
136,877,478
MDU6SXNzdWUxMzY4Nzc0Nzg=
3,025
Proxies not working
{ "avatar_url": "https://avatars.githubusercontent.com/u/15353112?v=4", "events_url": "https://api.github.com/users/Tosible/events{/privacy}", "followers_url": "https://api.github.com/users/Tosible/followers", "following_url": "https://api.github.com/users/Tosible/following{/other_user}", "gists_url": "https://api.github.com/users/Tosible/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/Tosible", "id": 15353112, "login": "Tosible", "node_id": "MDQ6VXNlcjE1MzUzMTEy", "organizations_url": "https://api.github.com/users/Tosible/orgs", "received_events_url": "https://api.github.com/users/Tosible/received_events", "repos_url": "https://api.github.com/users/Tosible/repos", "site_admin": false, "starred_url": "https://api.github.com/users/Tosible/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Tosible/subscriptions", "type": "User", "url": "https://api.github.com/users/Tosible", "user_view_type": "public" }
[]
closed
true
null
[]
null
7
2016-02-27T04:28:31Z
2021-09-08T19:00:30Z
2016-02-27T05:36:42Z
NONE
resolved
My script shows that proxies aren't working. Am I doing something wrong? Here's the code if you need: [Script.zip](https://github.com/kennethreitz/requests/files/149201/Script.zip)
{ "avatar_url": "https://avatars.githubusercontent.com/u/240830?v=4", "events_url": "https://api.github.com/users/sigmavirus24/events{/privacy}", "followers_url": "https://api.github.com/users/sigmavirus24/followers", "following_url": "https://api.github.com/users/sigmavirus24/following{/other_user}", "gists_url": "https://api.github.com/users/sigmavirus24/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/sigmavirus24", "id": 240830, "login": "sigmavirus24", "node_id": "MDQ6VXNlcjI0MDgzMA==", "organizations_url": "https://api.github.com/users/sigmavirus24/orgs", "received_events_url": "https://api.github.com/users/sigmavirus24/received_events", "repos_url": "https://api.github.com/users/sigmavirus24/repos", "site_admin": false, "starred_url": "https://api.github.com/users/sigmavirus24/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sigmavirus24/subscriptions", "type": "User", "url": "https://api.github.com/users/sigmavirus24", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/3025/reactions" }
https://api.github.com/repos/psf/requests/issues/3025/timeline
null
completed
null
null
false
[ "Code here:\n\n``` python\n# Important stuff here\nfrom json import load\nimport requests\nfrom random import choice, randint, shuffle\nfrom urllib2 import urlopen\n\nurl = 'http://epiccodes.com' \n\n# Random proxies from - http://proxygaz.com\nproxies = {'https': 'https:131.96.228.236:9064',\n 'https': '...
https://api.github.com/repos/psf/requests/issues/3024
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/3024/labels{/name}
https://api.github.com/repos/psf/requests/issues/3024/comments
https://api.github.com/repos/psf/requests/issues/3024/events
https://github.com/psf/requests/pull/3024
134,818,979
MDExOlB1bGxSZXF1ZXN0NTk5MjU1MzE=
3,024
Added unit tests for utils module
{ "avatar_url": "https://avatars.githubusercontent.com/u/1236561?v=4", "events_url": "https://api.github.com/users/Stranger6667/events{/privacy}", "followers_url": "https://api.github.com/users/Stranger6667/followers", "following_url": "https://api.github.com/users/Stranger6667/following{/other_user}", "gists_url": "https://api.github.com/users/Stranger6667/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/Stranger6667", "id": 1236561, "login": "Stranger6667", "node_id": "MDQ6VXNlcjEyMzY1NjE=", "organizations_url": "https://api.github.com/users/Stranger6667/orgs", "received_events_url": "https://api.github.com/users/Stranger6667/received_events", "repos_url": "https://api.github.com/users/Stranger6667/repos", "site_admin": false, "starred_url": "https://api.github.com/users/Stranger6667/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Stranger6667/subscriptions", "type": "User", "url": "https://api.github.com/users/Stranger6667", "user_view_type": "public" }
[]
closed
true
null
[]
null
2
2016-02-19T09:44:23Z
2021-09-08T04:01:10Z
2016-04-06T19:05:13Z
CONTRIBUTOR
resolved
More unit tests for `utils` module. Also there is small cleanup for this module - removed unused imports & variable. Lines coverage increased from 46% to 75%, but I'd like to ask about some functions, which are not used in `requests` at all (e.g `dict_to_sequence`, `from_key_val_list`, etc). Is there some plan for them? I wanted to write unit tests for it, but I'm not sure, may be they are staged to be deleted and it is not reasonable to cover them with unit tests. BR
{ "avatar_url": "https://avatars.githubusercontent.com/u/119893?v=4", "events_url": "https://api.github.com/users/kennethreitz/events{/privacy}", "followers_url": "https://api.github.com/users/kennethreitz/followers", "following_url": "https://api.github.com/users/kennethreitz/following{/other_user}", "gists_url": "https://api.github.com/users/kennethreitz/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/kennethreitz", "id": 119893, "login": "kennethreitz", "node_id": "MDQ6VXNlcjExOTg5Mw==", "organizations_url": "https://api.github.com/users/kennethreitz/orgs", "received_events_url": "https://api.github.com/users/kennethreitz/received_events", "repos_url": "https://api.github.com/users/kennethreitz/repos", "site_admin": false, "starred_url": "https://api.github.com/users/kennethreitz/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/kennethreitz/subscriptions", "type": "User", "url": "https://api.github.com/users/kennethreitz", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/3024/reactions" }
https://api.github.com/repos/psf/requests/issues/3024/timeline
null
null
false
{ "diff_url": "https://github.com/psf/requests/pull/3024.diff", "html_url": "https://github.com/psf/requests/pull/3024", "merged_at": "2016-04-06T19:05:13Z", "patch_url": "https://github.com/psf/requests/pull/3024.patch", "url": "https://api.github.com/repos/psf/requests/pulls/3024" }
true
[ "Some of the utils module functions are left in place to avoid breaking users that may be using them directly, even though they're not used in requests any more. There's certainly no plan to remove them prior to 3.0.0.\n", "I'm down for removing ones that _don't belong there_ for 3.0. \n" ]
https://api.github.com/repos/psf/requests/issues/3023
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/3023/labels{/name}
https://api.github.com/repos/psf/requests/issues/3023/comments
https://api.github.com/repos/psf/requests/issues/3023/events
https://github.com/psf/requests/pull/3023
134,643,102
MDExOlB1bGxSZXF1ZXN0NTk4MzM5NTc=
3,023
Add exceptions into __init__.py
{ "avatar_url": "https://avatars.githubusercontent.com/u/244969?v=4", "events_url": "https://api.github.com/users/jtpereyda/events{/privacy}", "followers_url": "https://api.github.com/users/jtpereyda/followers", "following_url": "https://api.github.com/users/jtpereyda/following{/other_user}", "gists_url": "https://api.github.com/users/jtpereyda/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jtpereyda", "id": 244969, "login": "jtpereyda", "node_id": "MDQ6VXNlcjI0NDk2OQ==", "organizations_url": "https://api.github.com/users/jtpereyda/orgs", "received_events_url": "https://api.github.com/users/jtpereyda/received_events", "repos_url": "https://api.github.com/users/jtpereyda/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jtpereyda/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jtpereyda/subscriptions", "type": "User", "url": "https://api.github.com/users/jtpereyda", "user_view_type": "public" }
[]
closed
true
null
[]
null
9
2016-02-18T17:28:38Z
2021-09-08T04:01:16Z
2016-02-19T01:49:15Z
NONE
resolved
Addresses Issue #3022. Also added the JetBrains IDE settings folder, `.idea/`, to `.gitignore`.
{ "avatar_url": "https://avatars.githubusercontent.com/u/119893?v=4", "events_url": "https://api.github.com/users/kennethreitz/events{/privacy}", "followers_url": "https://api.github.com/users/kennethreitz/followers", "following_url": "https://api.github.com/users/kennethreitz/following{/other_user}", "gists_url": "https://api.github.com/users/kennethreitz/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/kennethreitz", "id": 119893, "login": "kennethreitz", "node_id": "MDQ6VXNlcjExOTg5Mw==", "organizations_url": "https://api.github.com/users/kennethreitz/orgs", "received_events_url": "https://api.github.com/users/kennethreitz/received_events", "repos_url": "https://api.github.com/users/kennethreitz/repos", "site_admin": false, "starred_url": "https://api.github.com/users/kennethreitz/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/kennethreitz/subscriptions", "type": "User", "url": "https://api.github.com/users/kennethreitz", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/3023/reactions" }
https://api.github.com/repos/psf/requests/issues/3023/timeline
null
null
false
{ "diff_url": "https://github.com/psf/requests/pull/3023.diff", "html_url": "https://github.com/psf/requests/pull/3023", "merged_at": null, "patch_url": "https://github.com/psf/requests/pull/3023.patch", "url": "https://api.github.com/repos/psf/requests/pulls/3023" }
true
[ "I'm going to leave this up to @kennethreitz. As you stated in #3022, this is totally unnecessary, but neither is it a maintenance burden, so I have no objection to it. Thanks for your contribution! :cake:\n", "We already have all the exceptions available in the public API:\n\n``` python\nfrom .exceptions import ...
https://api.github.com/repos/psf/requests/issues/3022
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/3022/labels{/name}
https://api.github.com/repos/psf/requests/issues/3022/comments
https://api.github.com/repos/psf/requests/issues/3022/events
https://github.com/psf/requests/issues/3022
134,639,217
MDU6SXNzdWUxMzQ2MzkyMTc=
3,022
exceptions missing from __init__.py
{ "avatar_url": "https://avatars.githubusercontent.com/u/244969?v=4", "events_url": "https://api.github.com/users/jtpereyda/events{/privacy}", "followers_url": "https://api.github.com/users/jtpereyda/followers", "following_url": "https://api.github.com/users/jtpereyda/following{/other_user}", "gists_url": "https://api.github.com/users/jtpereyda/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jtpereyda", "id": 244969, "login": "jtpereyda", "node_id": "MDQ6VXNlcjI0NDk2OQ==", "organizations_url": "https://api.github.com/users/jtpereyda/orgs", "received_events_url": "https://api.github.com/users/jtpereyda/received_events", "repos_url": "https://api.github.com/users/jtpereyda/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jtpereyda/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jtpereyda/subscriptions", "type": "User", "url": "https://api.github.com/users/jtpereyda", "user_view_type": "public" }
[]
closed
true
null
[]
null
5
2016-02-18T17:12:37Z
2021-09-08T18:00:55Z
2016-04-16T04:05:57Z
NONE
resolved
It is traditional to include the public API in `__init__.py`. Consider this test code: ``` python import requests import requests.exceptions a = requests.exceptions.ConnectTimeout ``` This will run properly, but PyCharm raises a warning, saying, "Cannot find reference 'exceptions' in `__init__.py`". This could be fixed by changing an `__init__.py` line from: ``` from . import utils ``` to ``` from . import requests, utils ``` While this is technically a [bug ](https://youtrack.jetbrains.com/issue/PY-18550) in PyCharm, requests' **init**.py already imports utils, apparently for this very purpose. So it would be consistent to import exceptions as well.
{ "avatar_url": "https://avatars.githubusercontent.com/u/240830?v=4", "events_url": "https://api.github.com/users/sigmavirus24/events{/privacy}", "followers_url": "https://api.github.com/users/sigmavirus24/followers", "following_url": "https://api.github.com/users/sigmavirus24/following{/other_user}", "gists_url": "https://api.github.com/users/sigmavirus24/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/sigmavirus24", "id": 240830, "login": "sigmavirus24", "node_id": "MDQ6VXNlcjI0MDgzMA==", "organizations_url": "https://api.github.com/users/sigmavirus24/orgs", "received_events_url": "https://api.github.com/users/sigmavirus24/received_events", "repos_url": "https://api.github.com/users/sigmavirus24/repos", "site_admin": false, "starred_url": "https://api.github.com/users/sigmavirus24/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sigmavirus24/subscriptions", "type": "User", "url": "https://api.github.com/users/sigmavirus24", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/3022/reactions" }
https://api.github.com/repos/psf/requests/issues/3022/timeline
null
completed
null
null
false
[ "This isn't _technically_ a bug in PyCharm. It is a bug that they should be fixing. If we did something like this for each editor that does nonsensical things like this, I'm not sure we'd have a very coherent project.\n", "@kennethreitz Resolved this by changing the docs (see PR #3023).\n\nLooks like http://docs....
https://api.github.com/repos/psf/requests/issues/3021
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/3021/labels{/name}
https://api.github.com/repos/psf/requests/issues/3021/comments
https://api.github.com/repos/psf/requests/issues/3021/events
https://github.com/psf/requests/pull/3021
134,496,478
MDExOlB1bGxSZXF1ZXN0NTk3NTc5MDE=
3,021
Fix #3017: Whitespace characters surrounding a URL should be ignored
{ "avatar_url": "https://avatars.githubusercontent.com/u/120788?v=4", "events_url": "https://api.github.com/users/geckon/events{/privacy}", "followers_url": "https://api.github.com/users/geckon/followers", "following_url": "https://api.github.com/users/geckon/following{/other_user}", "gists_url": "https://api.github.com/users/geckon/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/geckon", "id": 120788, "login": "geckon", "node_id": "MDQ6VXNlcjEyMDc4OA==", "organizations_url": "https://api.github.com/users/geckon/orgs", "received_events_url": "https://api.github.com/users/geckon/received_events", "repos_url": "https://api.github.com/users/geckon/repos", "site_admin": false, "starred_url": "https://api.github.com/users/geckon/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/geckon/subscriptions", "type": "User", "url": "https://api.github.com/users/geckon", "user_view_type": "public" }
[]
closed
true
null
[]
null
3
2016-02-18T06:51:32Z
2021-09-08T05:00:55Z
2016-02-18T07:01:41Z
NONE
resolved
My attempt to fix [the issue I reported](https://github.com/kennethreitz/requests/issues/3017). Feel free to comment my changes, especially if you don't agree with them.
{ "avatar_url": "https://avatars.githubusercontent.com/u/119893?v=4", "events_url": "https://api.github.com/users/kennethreitz/events{/privacy}", "followers_url": "https://api.github.com/users/kennethreitz/followers", "following_url": "https://api.github.com/users/kennethreitz/following{/other_user}", "gists_url": "https://api.github.com/users/kennethreitz/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/kennethreitz", "id": 119893, "login": "kennethreitz", "node_id": "MDQ6VXNlcjExOTg5Mw==", "organizations_url": "https://api.github.com/users/kennethreitz/orgs", "received_events_url": "https://api.github.com/users/kennethreitz/received_events", "repos_url": "https://api.github.com/users/kennethreitz/repos", "site_admin": false, "starred_url": "https://api.github.com/users/kennethreitz/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/kennethreitz/subscriptions", "type": "User", "url": "https://api.github.com/users/kennethreitz", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/3021/reactions" }
https://api.github.com/repos/psf/requests/issues/3021/timeline
null
null
false
{ "diff_url": "https://github.com/psf/requests/pull/3021.diff", "html_url": "https://github.com/psf/requests/pull/3021", "merged_at": "2016-02-18T07:01:41Z", "patch_url": "https://github.com/psf/requests/pull/3021.patch", "url": "https://api.github.com/repos/psf/requests/pulls/3021" }
true
[ "@geckon thank you!\n\nFor the record, this is a potentially breaking change for _someone_, hence why it has to wait for inclusion in the 3.x series. \n", ":sparkles: :cake: :sparkles:\n", "Thanks for this @geckon \n" ]
https://api.github.com/repos/psf/requests/issues/3020
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/3020/labels{/name}
https://api.github.com/repos/psf/requests/issues/3020/comments
https://api.github.com/repos/psf/requests/issues/3020/events
https://github.com/psf/requests/pull/3020
134,435,798
MDExOlB1bGxSZXF1ZXN0NTk3Mjg2ODY=
3,020
Fix #3017: Whitepace characters surrounding a URL should be ignored
{ "avatar_url": "https://avatars.githubusercontent.com/u/120788?v=4", "events_url": "https://api.github.com/users/geckon/events{/privacy}", "followers_url": "https://api.github.com/users/geckon/followers", "following_url": "https://api.github.com/users/geckon/following{/other_user}", "gists_url": "https://api.github.com/users/geckon/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/geckon", "id": 120788, "login": "geckon", "node_id": "MDQ6VXNlcjEyMDc4OA==", "organizations_url": "https://api.github.com/users/geckon/orgs", "received_events_url": "https://api.github.com/users/geckon/received_events", "repos_url": "https://api.github.com/users/geckon/repos", "site_admin": false, "starred_url": "https://api.github.com/users/geckon/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/geckon/subscriptions", "type": "User", "url": "https://api.github.com/users/geckon", "user_view_type": "public" }
[]
closed
true
null
[]
null
2
2016-02-17T23:45:37Z
2021-09-08T05:00:56Z
2016-02-18T06:54:01Z
NONE
resolved
My attempt to fix [the issue I reported](https://github.com/kennethreitz/requests/issues/3017). Feel free to comment my changes, especially if you don't agree with them.
{ "avatar_url": "https://avatars.githubusercontent.com/u/120788?v=4", "events_url": "https://api.github.com/users/geckon/events{/privacy}", "followers_url": "https://api.github.com/users/geckon/followers", "following_url": "https://api.github.com/users/geckon/following{/other_user}", "gists_url": "https://api.github.com/users/geckon/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/geckon", "id": 120788, "login": "geckon", "node_id": "MDQ6VXNlcjEyMDc4OA==", "organizations_url": "https://api.github.com/users/geckon/orgs", "received_events_url": "https://api.github.com/users/geckon/received_events", "repos_url": "https://api.github.com/users/geckon/repos", "site_admin": false, "starred_url": "https://api.github.com/users/geckon/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/geckon/subscriptions", "type": "User", "url": "https://api.github.com/users/geckon", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/3020/reactions" }
https://api.github.com/repos/psf/requests/issues/3020/timeline
null
null
false
{ "diff_url": "https://github.com/psf/requests/pull/3020.diff", "html_url": "https://github.com/psf/requests/pull/3020", "merged_at": null, "patch_url": "https://github.com/psf/requests/pull/3020.patch", "url": "https://api.github.com/repos/psf/requests/pulls/3020" }
true
[ "@geckon please rebase this against that branch instead. If you need help, let me know and I can give you some instructions that should work in this case. Thanks for handling this! :cake: \n", "Hopefully I did it right the third time: https://github.com/kennethreitz/requests/pull/3021\nI believe this PR can be cl...
https://api.github.com/repos/psf/requests/issues/3019
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/3019/labels{/name}
https://api.github.com/repos/psf/requests/issues/3019/comments
https://api.github.com/repos/psf/requests/issues/3019/events
https://github.com/psf/requests/pull/3019
134,430,169
MDExOlB1bGxSZXF1ZXN0NTk3MjUzOTc=
3,019
Fix #3017: Whitepace characters surrounding a URL should be ignored
{ "avatar_url": "https://avatars.githubusercontent.com/u/120788?v=4", "events_url": "https://api.github.com/users/geckon/events{/privacy}", "followers_url": "https://api.github.com/users/geckon/followers", "following_url": "https://api.github.com/users/geckon/following{/other_user}", "gists_url": "https://api.github.com/users/geckon/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/geckon", "id": 120788, "login": "geckon", "node_id": "MDQ6VXNlcjEyMDc4OA==", "organizations_url": "https://api.github.com/users/geckon/orgs", "received_events_url": "https://api.github.com/users/geckon/received_events", "repos_url": "https://api.github.com/users/geckon/repos", "site_admin": false, "starred_url": "https://api.github.com/users/geckon/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/geckon/subscriptions", "type": "User", "url": "https://api.github.com/users/geckon", "user_view_type": "public" }
[]
closed
true
null
[]
null
4
2016-02-17T23:14:54Z
2021-09-08T05:00:56Z
2016-02-18T06:54:36Z
NONE
resolved
My attempt to fix [the issue I reported](https://github.com/kennethreitz/requests/issues/3017). Feel free to comment my changes, especially if you don't agree with them.
{ "avatar_url": "https://avatars.githubusercontent.com/u/120788?v=4", "events_url": "https://api.github.com/users/geckon/events{/privacy}", "followers_url": "https://api.github.com/users/geckon/followers", "following_url": "https://api.github.com/users/geckon/following{/other_user}", "gists_url": "https://api.github.com/users/geckon/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/geckon", "id": 120788, "login": "geckon", "node_id": "MDQ6VXNlcjEyMDc4OA==", "organizations_url": "https://api.github.com/users/geckon/orgs", "received_events_url": "https://api.github.com/users/geckon/received_events", "repos_url": "https://api.github.com/users/geckon/repos", "site_admin": false, "starred_url": "https://api.github.com/users/geckon/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/geckon/subscriptions", "type": "User", "url": "https://api.github.com/users/geckon", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/3019/reactions" }
https://api.github.com/repos/psf/requests/issues/3019/timeline
null
null
false
{ "diff_url": "https://github.com/psf/requests/pull/3019.diff", "html_url": "https://github.com/psf/requests/pull/3019", "merged_at": null, "patch_url": "https://github.com/psf/requests/pull/3019.patch", "url": "https://api.github.com/repos/psf/requests/pulls/3019" }
true
[ "Looks perfect to me!\n", "@geckon although, we're going to be merging this into the `proposed/3.0.0` branch. would you like to make your PR against that branch instead?\n", "No problem: https://github.com/kennethreitz/requests/pull/3020\nIs that alright?\n", "Hopefully I did it right the third time: https://...
https://api.github.com/repos/psf/requests/issues/3018
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/3018/labels{/name}
https://api.github.com/repos/psf/requests/issues/3018/comments
https://api.github.com/repos/psf/requests/issues/3018/events
https://github.com/psf/requests/issues/3018
134,293,897
MDU6SXNzdWUxMzQyOTM4OTc=
3,018
ConnectionError: ('Connection aborted.', error(13, 'Permission denied'))
{ "avatar_url": "https://avatars.githubusercontent.com/u/16576155?v=4", "events_url": "https://api.github.com/users/OneSecure/events{/privacy}", "followers_url": "https://api.github.com/users/OneSecure/followers", "following_url": "https://api.github.com/users/OneSecure/following{/other_user}", "gists_url": "https://api.github.com/users/OneSecure/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/OneSecure", "id": 16576155, "login": "OneSecure", "node_id": "MDQ6VXNlcjE2NTc2MTU1", "organizations_url": "https://api.github.com/users/OneSecure/orgs", "received_events_url": "https://api.github.com/users/OneSecure/received_events", "repos_url": "https://api.github.com/users/OneSecure/repos", "site_admin": false, "starred_url": "https://api.github.com/users/OneSecure/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/OneSecure/subscriptions", "type": "User", "url": "https://api.github.com/users/OneSecure", "user_view_type": "public" }
[ { "color": "fbca04", "default": false, "description": null, "id": 615414998, "name": "GAE Support", "node_id": "MDU6TGFiZWw2MTU0MTQ5OTg=", "url": "https://api.github.com/repos/psf/requests/labels/GAE%20Support" } ]
closed
true
null
[]
null
5
2016-02-17T14:27:05Z
2021-09-08T01:21:17Z
2016-02-17T14:43:43Z
NONE
resolved
On GAE, it went wrong. WARNING 2016-02-17 14:06:22,023 urlfetch_stub.py:540] Stripped prohibited headers from URLFetch request: ['Host'] INFO 2016-02-17 14:06:22,773 connectionpool.py:758] Starting new HTTPS connection (1): api.weibo.com ERROR 2016-02-17 14:06:23,531 webapp2.py:1528] ('Connection aborted.', error(13, 'Permission denied')) Traceback (most recent call last): File "/Users/go_appengine/lib/webapp2-2.3/webapp2.py", line 1511, in **call** rv = self.handle_exception(request, response, e) File "/Users/go_appengine/lib/webapp2-2.3/webapp2.py", line 1505, in **call** rv = self.router.dispatch(request, response) File "/Users/go_appengine/lib/webapp2-2.3/webapp2.py", line 1253, in default_dispatcher return route.handler_adapter(request, response) File "/Users/go_appengine/lib/webapp2-2.3/webapp2.py", line 1077, in **call** return handler.dispatch() File "/Users/go_appengine/lib/webapp2-2.3/webapp2.py", line 547, in dispatch return self.handle_exception(e, self.app.debug) File "/Users/go_appengine/lib/webapp2-2.3/webapp2.py", line 545, in dispatch return method(_args, *_kwargs) File "/Users/Desktop/main.py", line 27, in get postBingImageToWeibo(prefix, userUrl) File "/Users/Desktop/bingimage.py", line 60, in postBingImageToWeibo client.post('statuses/upload', status=info, pic=picFile) File "/Users/Desktop/weibo_tiny.py", line 130, in post files=files).text) File "/Users/Desktop/requests/sessions.py", line 511, in post return self.request('POST', url, data=data, json=json, *_kwargs) File "/Users/Desktop/requests/sessions.py", line 468, in request resp = self.send(prep, *_send_kwargs) File "/Users/Desktop/requests/sessions.py", line 576, in send r = adapter.send(request, **kwargs) File "/Users/Desktop/requests/adapters.py", line 426, in send raise ConnectionError(err, request=request) ConnectionError: ('Connection aborted.', error(13, 'Permission denied')) INFO 2016-02-17 14:06:23,598 module.py:787] default: "GET /retrievedata HTTP/1.1" 500 114
{ "avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4", "events_url": "https://api.github.com/users/Lukasa/events{/privacy}", "followers_url": "https://api.github.com/users/Lukasa/followers", "following_url": "https://api.github.com/users/Lukasa/following{/other_user}", "gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/Lukasa", "id": 1382556, "login": "Lukasa", "node_id": "MDQ6VXNlcjEzODI1NTY=", "organizations_url": "https://api.github.com/users/Lukasa/orgs", "received_events_url": "https://api.github.com/users/Lukasa/received_events", "repos_url": "https://api.github.com/users/Lukasa/repos", "site_admin": false, "starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions", "type": "User", "url": "https://api.github.com/users/Lukasa", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/3018/reactions" }
https://api.github.com/repos/psf/requests/issues/3018/timeline
null
completed
null
null
false
[ "When I using version 2.3.0, This issue is disappear.\n\nhttps://github.com/kennethreitz/requests/tree/6366d3dd190a9e58ca582955cddf7e2ac5f32dcc\n\nLike the following link\nhttp://stackoverflow.com/questions/27974128/how-do-i-resolve-django-allauth-connection-aborted-error13-permission-d\n", "I'm afraid that Reque...
https://api.github.com/repos/psf/requests/issues/3017
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/3017/labels{/name}
https://api.github.com/repos/psf/requests/issues/3017/comments
https://api.github.com/repos/psf/requests/issues/3017/events
https://github.com/psf/requests/issues/3017
133,979,726
MDU6SXNzdWUxMzM5Nzk3MjY=
3,017
Whitepace characters surrounding a URL should be ignored
{ "avatar_url": "https://avatars.githubusercontent.com/u/120788?v=4", "events_url": "https://api.github.com/users/geckon/events{/privacy}", "followers_url": "https://api.github.com/users/geckon/followers", "following_url": "https://api.github.com/users/geckon/following{/other_user}", "gists_url": "https://api.github.com/users/geckon/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/geckon", "id": 120788, "login": "geckon", "node_id": "MDQ6VXNlcjEyMDc4OA==", "organizations_url": "https://api.github.com/users/geckon/orgs", "received_events_url": "https://api.github.com/users/geckon/received_events", "repos_url": "https://api.github.com/users/geckon/repos", "site_admin": false, "starred_url": "https://api.github.com/users/geckon/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/geckon/subscriptions", "type": "User", "url": "https://api.github.com/users/geckon", "user_view_type": "public" }
[]
closed
true
null
[]
{ "closed_at": null, "closed_issues": 29, "created_at": "2013-11-17T11:29:34Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4", "events_url": "https://api.github.com/users/Lukasa/events{/privacy}", "followers_url": "https://api.github.com/users/Lukasa/followers", "following_url": "https://api.github.com/users/Lukasa/following{/other_user}", "gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/Lukasa", "id": 1382556, "login": "Lukasa", "node_id": "MDQ6VXNlcjEzODI1NTY=", "organizations_url": "https://api.github.com/users/Lukasa/orgs", "received_events_url": "https://api.github.com/users/Lukasa/received_events", "repos_url": "https://api.github.com/users/Lukasa/repos", "site_admin": false, "starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions", "type": "User", "url": "https://api.github.com/users/Lukasa", "user_view_type": "public" }, "description": null, "due_on": null, "html_url": "https://github.com/psf/requests/milestone/20", "id": 487518, "labels_url": "https://api.github.com/repos/psf/requests/milestones/20/labels", "node_id": "MDk6TWlsZXN0b25lNDg3NTE4", "number": 20, "open_issues": 12, "state": "open", "title": "3.0.0", "updated_at": "2024-05-19T18:43:00Z", "url": "https://api.github.com/repos/psf/requests/milestones/20" }
16
2016-02-16T13:17:02Z
2021-09-08T19:00:32Z
2016-02-18T22:34:54Z
NONE
resolved
It might be beneficial to unite the behavior with other tools (including browsers) and start ignoring whitespaces surrounding a URL. See the examples: ``` $ curl -s "https://github.com/ " -o /dev/null -w "%{http_code}"; echo 200 $ python -c 'import urllib2; print(urllib2.urlopen("https://github.com/ ").getcode())' 200 $ python -c 'import requests; print(requests.get("https://github.com/ ").status_code)' 404 ``` Also, W3C [defines](https://www.w3.org/TR/2012/WD-html5-20121025/links.html#attr-hyperlink-href) the `a` tag's `href` attribute as... > The href attribute on a and area elements must have a value that is a valid URL potentially surrounded by spaces. Where _URL potentially surrounded by spaces_ is [defined](https://www.w3.org/TR/2012/WD-html5-20121025/urls.html#valid-url-potentially-surrounded-by-spaces) as... > A string is a valid non-empty URL potentially surrounded by spaces if, after stripping leading and trailing whitespace from it, it is a valid non-empty URL. I know this is not a killer argument for the requests library but it would be beneficial if it behaved the same way as the other approaches. It would also make HTML processing with requests (and e.g. beautifulsoup4) easier.
{ "avatar_url": "https://avatars.githubusercontent.com/u/240830?v=4", "events_url": "https://api.github.com/users/sigmavirus24/events{/privacy}", "followers_url": "https://api.github.com/users/sigmavirus24/followers", "following_url": "https://api.github.com/users/sigmavirus24/following{/other_user}", "gists_url": "https://api.github.com/users/sigmavirus24/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/sigmavirus24", "id": 240830, "login": "sigmavirus24", "node_id": "MDQ6VXNlcjI0MDgzMA==", "organizations_url": "https://api.github.com/users/sigmavirus24/orgs", "received_events_url": "https://api.github.com/users/sigmavirus24/received_events", "repos_url": "https://api.github.com/users/sigmavirus24/repos", "site_admin": false, "starred_url": "https://api.github.com/users/sigmavirus24/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sigmavirus24/subscriptions", "type": "User", "url": "https://api.github.com/users/sigmavirus24", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/3017/reactions" }
https://api.github.com/repos/psf/requests/issues/3017/timeline
null
completed
null
null
false
[ "I have no objection to calling `strip` on a URL that's passed into requests.\n", "Do we currently `%20` these?\n", "Yes.\n", "> I have no objection to calling strip on a URL that's passed into requests.\n\nDo you mean the requests should do it or the caller?\n\nI may be very well mistaken but it might be eno...
https://api.github.com/repos/psf/requests/issues/3016
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/3016/labels{/name}
https://api.github.com/repos/psf/requests/issues/3016/comments
https://api.github.com/repos/psf/requests/issues/3016/events
https://github.com/psf/requests/issues/3016
133,752,844
MDU6SXNzdWUxMzM3NTI4NDQ=
3,016
"Request.hooks" and "Session.hooks" merged inappropriately.
{ "avatar_url": "https://avatars.githubusercontent.com/u/8749411?v=4", "events_url": "https://api.github.com/users/elonzh/events{/privacy}", "followers_url": "https://api.github.com/users/elonzh/followers", "following_url": "https://api.github.com/users/elonzh/following{/other_user}", "gists_url": "https://api.github.com/users/elonzh/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/elonzh", "id": 8749411, "login": "elonzh", "node_id": "MDQ6VXNlcjg3NDk0MTE=", "organizations_url": "https://api.github.com/users/elonzh/orgs", "received_events_url": "https://api.github.com/users/elonzh/received_events", "repos_url": "https://api.github.com/users/elonzh/repos", "site_admin": false, "starred_url": "https://api.github.com/users/elonzh/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/elonzh/subscriptions", "type": "User", "url": "https://api.github.com/users/elonzh", "user_view_type": "public" }
[]
closed
true
null
[]
null
4
2016-02-15T16:12:19Z
2021-09-08T19:00:32Z
2016-02-16T09:07:55Z
NONE
resolved
Both `Session` and `Request` have attribute `hooks`. The hook function list execute sequentially. In this situation, `Session.hooks` executed for every request and `Request.hooks` executed for a specifical request. But in fact, `Session.hooks` were replaced with `Request.hooks` when code ran into `merge_setting`: ``` Python merged_setting = dict_class(to_key_val_list(session_setting)) merged_setting.update(to_key_val_list(request_setting)) ```
{ "avatar_url": "https://avatars.githubusercontent.com/u/119893?v=4", "events_url": "https://api.github.com/users/kennethreitz/events{/privacy}", "followers_url": "https://api.github.com/users/kennethreitz/followers", "following_url": "https://api.github.com/users/kennethreitz/following{/other_user}", "gists_url": "https://api.github.com/users/kennethreitz/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/kennethreitz", "id": 119893, "login": "kennethreitz", "node_id": "MDQ6VXNlcjExOTg5Mw==", "organizations_url": "https://api.github.com/users/kennethreitz/orgs", "received_events_url": "https://api.github.com/users/kennethreitz/received_events", "repos_url": "https://api.github.com/users/kennethreitz/repos", "site_admin": false, "starred_url": "https://api.github.com/users/kennethreitz/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/kennethreitz/subscriptions", "type": "User", "url": "https://api.github.com/users/kennethreitz", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/3016/reactions" }
https://api.github.com/repos/psf/requests/issues/3016/timeline
null
completed
null
null
false
[ "@evilerliang Do the requests docs guarantee that `Session.hooks` will not be replaced by `Request.hooks`? In general, things declared for specific requests _override_ the things declared on the `Session`, rather than _supplementing_ them.\n", "I reviewed the doc, thk.\n\n> Any dictionaries that you pass to a req...
https://api.github.com/repos/psf/requests/issues/3015
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/3015/labels{/name}
https://api.github.com/repos/psf/requests/issues/3015/comments
https://api.github.com/repos/psf/requests/issues/3015/events
https://github.com/psf/requests/issues/3015
133,623,869
MDU6SXNzdWUxMzM2MjM4Njk=
3,015
Ability to set timeout after response
{ "avatar_url": "https://avatars.githubusercontent.com/u/9677399?v=4", "events_url": "https://api.github.com/users/ofek/events{/privacy}", "followers_url": "https://api.github.com/users/ofek/followers", "following_url": "https://api.github.com/users/ofek/following{/other_user}", "gists_url": "https://api.github.com/users/ofek/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/ofek", "id": 9677399, "login": "ofek", "node_id": "MDQ6VXNlcjk2NzczOTk=", "organizations_url": "https://api.github.com/users/ofek/orgs", "received_events_url": "https://api.github.com/users/ofek/received_events", "repos_url": "https://api.github.com/users/ofek/repos", "site_admin": false, "starred_url": "https://api.github.com/users/ofek/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/ofek/subscriptions", "type": "User", "url": "https://api.github.com/users/ofek", "user_view_type": "public" }
[]
closed
true
null
[]
null
12
2016-02-15T05:04:00Z
2021-09-08T19:00:33Z
2016-02-15T23:21:51Z
CONTRIBUTOR
resolved
For devs who use this great library, it would be very beneficial to be able to set the timeout AFTER initial connection. There are a few scenarios where this is useful but one of the main patterns/use cases is this: ``` import requests import socket # May or may not subclass threading.Thread class Getter(object): def __init__(self): self.request = requests.get(url, stream=True) def run(self): with open(path, 'r+b') as file: bytes_consumed = 0 while True: try: chunk = self.request.raw.read(size) if not chunk: break chunk_length = len(chunk) file.write(chunk) bytes_consumed += chunk_length except socket.timeout: # handle incomplete download by using range header next time, etc. ``` Handling incomplete downloads due to connection loss is common and especially important when downloading large or many files (or both). As you can see, this can be achieved in a fairly straightforward way. The issue is there is really no good way to write tests for this. Each method would involve OS specific code which would also be a no-go for CI services. What would be an option is the ability to set the timeout after establishing a connection. This way in a test you could do "r.timeout = (None, 0.00001)" and during reading it would simulate a timeout. To my knowledge this is no way currently to inject a new Timeout class retroactively. Is this correct?
{ "avatar_url": "https://avatars.githubusercontent.com/u/9677399?v=4", "events_url": "https://api.github.com/users/ofek/events{/privacy}", "followers_url": "https://api.github.com/users/ofek/followers", "following_url": "https://api.github.com/users/ofek/following{/other_user}", "gists_url": "https://api.github.com/users/ofek/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/ofek", "id": 9677399, "login": "ofek", "node_id": "MDQ6VXNlcjk2NzczOTk=", "organizations_url": "https://api.github.com/users/ofek/orgs", "received_events_url": "https://api.github.com/users/ofek/received_events", "repos_url": "https://api.github.com/users/ofek/repos", "site_admin": false, "starred_url": "https://api.github.com/users/ofek/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/ofek/subscriptions", "type": "User", "url": "https://api.github.com/users/ofek", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/3015/reactions" }
https://api.github.com/repos/psf/requests/issues/3015/timeline
null
completed
null
null
false
[ "Out of interest, why do you need to set the timeout retroactively? You could just set the timeout in the constructor, could you not?\n", "To test connection loss handling as explained above. Is there already some way to do this? I was looking through the code but couldn't quite wrap my head around how one might ...
https://api.github.com/repos/psf/requests/issues/3014
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/3014/labels{/name}
https://api.github.com/repos/psf/requests/issues/3014/comments
https://api.github.com/repos/psf/requests/issues/3014/events
https://github.com/psf/requests/pull/3014
133,576,032
MDExOlB1bGxSZXF1ZXN0NTkzMDQ4NjA=
3,014
PreparedRequest.dump()
{ "avatar_url": "https://avatars.githubusercontent.com/u/119893?v=4", "events_url": "https://api.github.com/users/kennethreitz/events{/privacy}", "followers_url": "https://api.github.com/users/kennethreitz/followers", "following_url": "https://api.github.com/users/kennethreitz/following{/other_user}", "gists_url": "https://api.github.com/users/kennethreitz/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/kennethreitz", "id": 119893, "login": "kennethreitz", "node_id": "MDQ6VXNlcjExOTg5Mw==", "organizations_url": "https://api.github.com/users/kennethreitz/orgs", "received_events_url": "https://api.github.com/users/kennethreitz/received_events", "repos_url": "https://api.github.com/users/kennethreitz/repos", "site_admin": false, "starred_url": "https://api.github.com/users/kennethreitz/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/kennethreitz/subscriptions", "type": "User", "url": "https://api.github.com/users/kennethreitz", "user_view_type": "public" }
[]
closed
true
null
[]
null
63
2016-02-14T20:26:41Z
2021-09-06T00:06:51Z
2016-04-06T19:08:02Z
CONTRIBUTOR
resolved
``` >>> r = requests.get('http://httpbin.org/ip') >>> print r.request.dump() REQUESTS/2.9.1 GET http://httpbin.org/ip Connection: keep-alive Accept-Encoding: gzip, deflate Accept: */* User-Agent: python-requests/2.9.1 ```
{ "avatar_url": "https://avatars.githubusercontent.com/u/119893?v=4", "events_url": "https://api.github.com/users/kennethreitz/events{/privacy}", "followers_url": "https://api.github.com/users/kennethreitz/followers", "following_url": "https://api.github.com/users/kennethreitz/following{/other_user}", "gists_url": "https://api.github.com/users/kennethreitz/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/kennethreitz", "id": 119893, "login": "kennethreitz", "node_id": "MDQ6VXNlcjExOTg5Mw==", "organizations_url": "https://api.github.com/users/kennethreitz/orgs", "received_events_url": "https://api.github.com/users/kennethreitz/received_events", "repos_url": "https://api.github.com/users/kennethreitz/repos", "site_admin": false, "starred_url": "https://api.github.com/users/kennethreitz/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/kennethreitz/subscriptions", "type": "User", "url": "https://api.github.com/users/kennethreitz", "user_view_type": "public" }
{ "+1": 1, "-1": 1, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 2, "url": "https://api.github.com/repos/psf/requests/issues/3014/reactions" }
https://api.github.com/repos/psf/requests/issues/3014/timeline
null
null
false
{ "diff_url": "https://github.com/psf/requests/pull/3014.diff", "html_url": "https://github.com/psf/requests/pull/3014", "merged_at": null, "patch_url": "https://github.com/psf/requests/pull/3014.patch", "url": "https://api.github.com/repos/psf/requests/pulls/3014" }
true
[ "I think `render` is a good name if it was reporting `HTTP/1.1` in the strings. Another name may be more appropriate now. \n", "I find it entertaining how this showcases just how much we completely disregard header order. \n", "Thinking of removing Response's render. \n", "Maybe `dump()`?\n", "@Lukasa hmmm,...
https://api.github.com/repos/psf/requests/issues/3013
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/3013/labels{/name}
https://api.github.com/repos/psf/requests/issues/3013/comments
https://api.github.com/repos/psf/requests/issues/3013/events
https://github.com/psf/requests/issues/3013
133,534,638
MDU6SXNzdWUxMzM1MzQ2Mzg=
3,013
Easy printing of Requests and Responses, two new utils?
{ "avatar_url": "https://avatars.githubusercontent.com/u/224130?v=4", "events_url": "https://api.github.com/users/EmilStenstrom/events{/privacy}", "followers_url": "https://api.github.com/users/EmilStenstrom/followers", "following_url": "https://api.github.com/users/EmilStenstrom/following{/other_user}", "gists_url": "https://api.github.com/users/EmilStenstrom/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/EmilStenstrom", "id": 224130, "login": "EmilStenstrom", "node_id": "MDQ6VXNlcjIyNDEzMA==", "organizations_url": "https://api.github.com/users/EmilStenstrom/orgs", "received_events_url": "https://api.github.com/users/EmilStenstrom/received_events", "repos_url": "https://api.github.com/users/EmilStenstrom/repos", "site_admin": false, "starred_url": "https://api.github.com/users/EmilStenstrom/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/EmilStenstrom/subscriptions", "type": "User", "url": "https://api.github.com/users/EmilStenstrom", "user_view_type": "public" }
[ { "color": "02e10c", "default": false, "description": null, "id": 76800, "name": "Feature Request", "node_id": "MDU6TGFiZWw3NjgwMA==", "url": "https://api.github.com/repos/psf/requests/labels/Feature%20Request" } ]
closed
true
null
[]
null
12
2016-02-14T12:25:29Z
2021-09-08T18:00:54Z
2016-04-16T04:06:18Z
NONE
resolved
Several times now I've stumbled over cases where I would like to print the request and response objects as strings to the console. Simply to see when headers and content are sent. Seems more people than I have had this problem: http://stackoverflow.com/questions/20658572/python-requests-print-entire-http-request-raw My suggestion: add two util methods that print requests and responses according to the HTTP spec. They are fully optional to use, and would not break backwards compatibility: To be clear, I'm suggesting something link this be added to requests.utils: ``` python def print_request(req): print('HTTP/1.1 {method} {url}\n{headers}\n\n{body}'.format( method=req.method, url=req.url, headers='\n'.join('{}: {}'.format(k, v) for k, v in req.headers.items()), body=req.body, )) def print_response(res): print('HTTP/1.1 {status_code}\n{headers}\n\n{body}'.format( status_code=res.status_code, headers='\n'.join('{}: {}'.format(k, v) for k, v in res.headers.items()), body=res.content, )) ``` Is this a good idea?
{ "avatar_url": "https://avatars.githubusercontent.com/u/240830?v=4", "events_url": "https://api.github.com/users/sigmavirus24/events{/privacy}", "followers_url": "https://api.github.com/users/sigmavirus24/followers", "following_url": "https://api.github.com/users/sigmavirus24/following{/other_user}", "gists_url": "https://api.github.com/users/sigmavirus24/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/sigmavirus24", "id": 240830, "login": "sigmavirus24", "node_id": "MDQ6VXNlcjI0MDgzMA==", "organizations_url": "https://api.github.com/users/sigmavirus24/orgs", "received_events_url": "https://api.github.com/users/sigmavirus24/received_events", "repos_url": "https://api.github.com/users/sigmavirus24/repos", "site_admin": false, "starred_url": "https://api.github.com/users/sigmavirus24/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sigmavirus24/subscriptions", "type": "User", "url": "https://api.github.com/users/sigmavirus24", "user_view_type": "public" }
{ "+1": 9, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 9, "url": "https://api.github.com/repos/psf/requests/issues/3013/reactions" }
https://api.github.com/repos/psf/requests/issues/3013/timeline
null
completed
null
null
false
[ "@EmilStenstrom Generally this is a good idea, but we tend to oppose having 'utility' functions be merged into requests itself: we want to restrict the scope of the main library so that it remains really good at doing its specific roles.\n\nFor that reason, you should check out the [requests toolbelt](https://toolb...
https://api.github.com/repos/psf/requests/issues/3012
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/3012/labels{/name}
https://api.github.com/repos/psf/requests/issues/3012/comments
https://api.github.com/repos/psf/requests/issues/3012/events
https://github.com/psf/requests/issues/3012
133,487,050
MDU6SXNzdWUxMzM0ODcwNTA=
3,012
Memory usage
{ "avatar_url": "https://avatars.githubusercontent.com/u/7945525?v=4", "events_url": "https://api.github.com/users/Leo675/events{/privacy}", "followers_url": "https://api.github.com/users/Leo675/followers", "following_url": "https://api.github.com/users/Leo675/following{/other_user}", "gists_url": "https://api.github.com/users/Leo675/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/Leo675", "id": 7945525, "login": "Leo675", "node_id": "MDQ6VXNlcjc5NDU1MjU=", "organizations_url": "https://api.github.com/users/Leo675/orgs", "received_events_url": "https://api.github.com/users/Leo675/received_events", "repos_url": "https://api.github.com/users/Leo675/repos", "site_admin": false, "starred_url": "https://api.github.com/users/Leo675/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Leo675/subscriptions", "type": "User", "url": "https://api.github.com/users/Leo675", "user_view_type": "public" }
[]
closed
true
null
[]
null
10
2016-02-14T00:25:05Z
2021-09-08T19:00:33Z
2016-02-14T01:22:20Z
NONE
resolved
Memory usage seems to be abnormally high for requests when using python 2.7. Request version being tested is 2.9.1 installed by pip. "pip show requests" output will be at the end. I'm unsure if this is an "issue", but it seems to be using 25MB just by importing requests. Testing was done using memory_profiler. I've included simple test code and some output. https://pypi.python.org/pypi/memory_profiler There's also a noticeable wait time when importing with python 2.7. ``` from memory_profiler import profile @profile def request_test(): import requests @profile def urllib3_test(): import urllib3 request_test() urllib3_test() ``` ``` $ python test.py Filename: test.py Line # Mem usage Increment Line Contents ================================================ 3 12.2 MiB 0.0 MiB @profile 4 def request_test(): 5 37.8 MiB 25.6 MiB import requests Filename: test.py Line # Mem usage Increment Line Contents ================================================ 8 37.8 MiB 0.0 MiB @profile 9 def urllib3_test(): 10 38.2 MiB 0.3 MiB import urllib3 ``` ``` $ python3 test.py Filename: test.py Line # Mem usage Increment Line Contents ================================================ 3 12.4 MiB 0.0 MiB @profile 4 def request_test(): 5 19.4 MiB 7.0 MiB import requests Filename: test.py Line # Mem usage Increment Line Contents ================================================ 8 19.5 MiB 0.0 MiB @profile 9 def urllib3_test(): 10 20.0 MiB 0.4 MiB import urllib3 ``` ``` $ pip2.7 show requests --- Metadata-Version: 2.0 Name: requests Version: 2.9.1 Summary: Python HTTP for Humans. Home-page: http://python-requests.org Author: Kenneth Reitz Author-email: me@kennethreitz.com License: Apache 2.0 Location: /usr/local/lib/python2.7/dist-packages ``` ``` $ pip3.4 show requests --- Metadata-Version: 2.0 Name: requests Version: 2.9.1 Summary: Python HTTP for Humans. Home-page: http://python-requests.org Author: Kenneth Reitz Author-email: me@kennethreitz.com License: Apache 2.0 Location: /usr/local/lib/python3.4/dist-packages ```
{ "avatar_url": "https://avatars.githubusercontent.com/u/7945525?v=4", "events_url": "https://api.github.com/users/Leo675/events{/privacy}", "followers_url": "https://api.github.com/users/Leo675/followers", "following_url": "https://api.github.com/users/Leo675/following{/other_user}", "gists_url": "https://api.github.com/users/Leo675/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/Leo675", "id": 7945525, "login": "Leo675", "node_id": "MDQ6VXNlcjc5NDU1MjU=", "organizations_url": "https://api.github.com/users/Leo675/orgs", "received_events_url": "https://api.github.com/users/Leo675/received_events", "repos_url": "https://api.github.com/users/Leo675/repos", "site_admin": false, "starred_url": "https://api.github.com/users/Leo675/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Leo675/subscriptions", "type": "User", "url": "https://api.github.com/users/Leo675", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/3012/reactions" }
https://api.github.com/repos/psf/requests/issues/3012/timeline
null
completed
null
null
false
[ "update:\n\nAfter upgrading all OTHER python packages, the memory usage with python 2.7 dropped down to 7.8 MiB\n\nSeems to be an issue with another library that is imported into requests and not actually caused by requests itself.\n", "@IDSninja do you have a list of the packages you upgraded? Requests doesn't i...
https://api.github.com/repos/psf/requests/issues/3011
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/3011/labels{/name}
https://api.github.com/repos/psf/requests/issues/3011/comments
https://api.github.com/repos/psf/requests/issues/3011/events
https://github.com/psf/requests/issues/3011
133,412,794
MDU6SXNzdWUxMzM0MTI3OTQ=
3,011
Requests SSL Handshake Failure
{ "avatar_url": "https://avatars.githubusercontent.com/u/9329553?v=4", "events_url": "https://api.github.com/users/wraithseeker/events{/privacy}", "followers_url": "https://api.github.com/users/wraithseeker/followers", "following_url": "https://api.github.com/users/wraithseeker/following{/other_user}", "gists_url": "https://api.github.com/users/wraithseeker/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/wraithseeker", "id": 9329553, "login": "wraithseeker", "node_id": "MDQ6VXNlcjkzMjk1NTM=", "organizations_url": "https://api.github.com/users/wraithseeker/orgs", "received_events_url": "https://api.github.com/users/wraithseeker/received_events", "repos_url": "https://api.github.com/users/wraithseeker/repos", "site_admin": false, "starred_url": "https://api.github.com/users/wraithseeker/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/wraithseeker/subscriptions", "type": "User", "url": "https://api.github.com/users/wraithseeker", "user_view_type": "public" }
[]
closed
true
null
[]
null
5
2016-02-13T08:00:39Z
2021-09-08T19:00:33Z
2016-02-13T09:04:42Z
NONE
resolved
I'm getting requests.exceptions.SSLError: [SSL: SSLV3_ALERT_HANDSHAKE_FAILURE] sslv3 alert handshake failure (_ssl.c:645) using the Requests library to fetch a webpage with Python3. Most other https website work but there are only a couple of websites that causes me to encounter this error. Pip3 list ``` cffi (1.5.0) cryptography (1.2.2) idna (2.0) ndg-httpsclient (0.4.0) pip (8.0.2) pyasn1 (0.1.9) pycparser (2.14) pyOpenSSL (0.15.1) pyperclip (1.5.26) requests (2.9.1) setuptools (18.2) six (1.10.0) ``` ``` import requests res = requests.get('https://visualnoveler.com/') ``` ``` Traceback (most recent call last): File "/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/requests/packages/urllib3/connectionpool.py", line 559, in urlopen body=body, headers=headers) File "/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/requests/packages/urllib3/connectionpool.py", line 345, in _make_request self._validate_conn(conn) File "/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/requests/packages/urllib3/connectionpool.py", line 784, in _validate_conn conn.connect() File "/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/requests/packages/urllib3/connection.py", line 252, in connect ssl_version=resolved_ssl_version) File "/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/requests/packages/urllib3/util/ssl_.py", line 305, in ssl_wrap_socket return context.wrap_socket(sock, server_hostname=server_hostname) File "/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/ssl.py", line 376, in wrap_socket _context=self) File "/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/ssl.py", line 747, in __init__ self.do_handshake() File "/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/ssl.py", line 983, in do_handshake self._sslobj.do_handshake() File "/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/ssl.py", line 628, in do_handshake self._sslobj.do_handshake() ssl.SSLError: [SSL: SSLV3_ALERT_HANDSHAKE_FAILURE] sslv3 alert handshake failure (_ssl.c:645) During handling of the above exception, another exception occurred: Traceback (most recent call last): File "/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/requests/adapters.py", line 376, in send timeout=timeout File "/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/requests/packages/urllib3/connectionpool.py", line 588, in urlopen raise SSLError(e) requests.packages.urllib3.exceptions.SSLError: [SSL: SSLV3_ALERT_HANDSHAKE_FAILURE] sslv3 alert handshake failure (_ssl.c:645) During handling of the above exception, another exception occurred: Traceback (most recent call last): File "/Users/wraithseeker/Desktop/Untitled.py", line 3, in <module> res = requests.get('https://visualnoveler.com/') File "/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/requests/api.py", line 67, in get return request('get', url, params=params, **kwargs) File "/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/requests/api.py", line 53, in request return session.request(method=method, url=url, **kwargs) File "/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/requests/sessions.py", line 468, in request resp = self.send(prep, **send_kwargs) File "/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/requests/sessions.py", line 576, in send r = adapter.send(request, **kwargs) File "/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/requests/adapters.py", line 447, in send raise SSLError(e, request=request) requests.exceptions.SSLError: [SSL: SSLV3_ALERT_HANDSHAKE_FAILURE] sslv3 alert handshake failure (_ssl.c:645) [Finished in 0.5s with exit code 1] ```
{ "avatar_url": "https://avatars.githubusercontent.com/u/9329553?v=4", "events_url": "https://api.github.com/users/wraithseeker/events{/privacy}", "followers_url": "https://api.github.com/users/wraithseeker/followers", "following_url": "https://api.github.com/users/wraithseeker/following{/other_user}", "gists_url": "https://api.github.com/users/wraithseeker/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/wraithseeker", "id": 9329553, "login": "wraithseeker", "node_id": "MDQ6VXNlcjkzMjk1NTM=", "organizations_url": "https://api.github.com/users/wraithseeker/orgs", "received_events_url": "https://api.github.com/users/wraithseeker/received_events", "repos_url": "https://api.github.com/users/wraithseeker/repos", "site_admin": false, "starred_url": "https://api.github.com/users/wraithseeker/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/wraithseeker/subscriptions", "type": "User", "url": "https://api.github.com/users/wraithseeker", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/3011/reactions" }
https://api.github.com/repos/psf/requests/issues/3011/timeline
null
completed
null
null
false
[ "This works on my machine (just adding additional information). I do not, however, have pyOpenSSL installed. \n", "PyOpenSSL is not currently used on Python 3.\n\nWhat version of OpenSSL are you using? `python -c 'import ssl; print ssl.OPENSSL_VERSION'`\n", "`OpenSSL 0.9.8zg 14 July 2015`\n\nI tried uninstallin...
https://api.github.com/repos/psf/requests/issues/3010
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/3010/labels{/name}
https://api.github.com/repos/psf/requests/issues/3010/comments
https://api.github.com/repos/psf/requests/issues/3010/events
https://github.com/psf/requests/issues/3010
133,394,357
MDU6SXNzdWUxMzMzOTQzNTc=
3,010
get_redirect_location return error hostname
{ "avatar_url": "https://avatars.githubusercontent.com/u/1644359?v=4", "events_url": "https://api.github.com/users/jsfs2019/events{/privacy}", "followers_url": "https://api.github.com/users/jsfs2019/followers", "following_url": "https://api.github.com/users/jsfs2019/following{/other_user}", "gists_url": "https://api.github.com/users/jsfs2019/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jsfs2019", "id": 1644359, "login": "jsfs2019", "node_id": "MDQ6VXNlcjE2NDQzNTk=", "organizations_url": "https://api.github.com/users/jsfs2019/orgs", "received_events_url": "https://api.github.com/users/jsfs2019/received_events", "repos_url": "https://api.github.com/users/jsfs2019/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jsfs2019/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jsfs2019/subscriptions", "type": "User", "url": "https://api.github.com/users/jsfs2019", "user_view_type": "public" }
[]
closed
true
null
[]
null
4
2016-02-13T03:39:26Z
2021-09-08T19:00:34Z
2016-02-13T03:56:03Z
NONE
resolved
when I visited site http://bitsnoop.com/chano-dominguez-hecho-a-mano-200-q18406062.html like this: ``` In [3]: r = get('http://bitsnoop.com/chano-dominguez-hecho-a-mano-200-q18406062.html', allow_redirects=False) In [4]: r.status_code Out[4]: 302 In [5]: r.raw.get_redirect_location() Out[5]: 'http://127.0.0.1/' ``` I got the error redirect address. So I test the website with curl: ``` $ curl -v http://bitsnoop.com/chano-dominguez-hecho-a-mano-200-q18406062.html * Hostname was NOT found in DNS cache * Trying 31.7.59.14... * Trying 2a02:29b8:1925::2... * Immediate connect fail for 2a02:29b8:1925::2: Network is unreachable * Connected to bitsnoop.com (31.7.59.14) port 80 (#0) > GET /chano-dominguez-hecho-a-mano-200-q18406062.html HTTP/1.1 > User-Agent: curl/7.35.0 > Host: bitsnoop.com > Accept: */* > < HTTP/1.1 301 Moved Permanently < Content-Type: text/html; charset=utf-8 < Keep-Alive: timeout=300 < Location: http://bitsnoop.com/chano-dominguez-hecho-a-mano-2002-q18406062.html < Transfer-Encoding: chunked < Date: Sat, 13 Feb 2016 01:29:09 GMT < Connection: keep-alive * Server Hampsterbox/2.0 is not blacklisted < Server: Hampsterbox/2.0 < * Connection #0 to host bitsnoop.com left intact ``` Obviously the right redirect address is http://bitsnoop.com/chano-dominguez-hecho-a-mano-2002-q18406062.html. It's really confusing;)
{ "avatar_url": "https://avatars.githubusercontent.com/u/119893?v=4", "events_url": "https://api.github.com/users/kennethreitz/events{/privacy}", "followers_url": "https://api.github.com/users/kennethreitz/followers", "following_url": "https://api.github.com/users/kennethreitz/following{/other_user}", "gists_url": "https://api.github.com/users/kennethreitz/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/kennethreitz", "id": 119893, "login": "kennethreitz", "node_id": "MDQ6VXNlcjExOTg5Mw==", "organizations_url": "https://api.github.com/users/kennethreitz/orgs", "received_events_url": "https://api.github.com/users/kennethreitz/received_events", "repos_url": "https://api.github.com/users/kennethreitz/repos", "site_admin": false, "starred_url": "https://api.github.com/users/kennethreitz/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/kennethreitz/subscriptions", "type": "User", "url": "https://api.github.com/users/kennethreitz", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/3010/reactions" }
https://api.github.com/repos/psf/requests/issues/3010/timeline
null
completed
null
null
false
[ "`r.raw.get_redirect_location()` is not actually part of the Requests API, and is not a supported way to procure that information.\n\nThe proper way (as it stands) is to simply look at the value of the `Location` header:\n\n``` python\n>>> r.headers['Location']\n'http://127.0.0.1/'\n```\n", "@jaron92: It looks li...
https://api.github.com/repos/psf/requests/issues/3009
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/3009/labels{/name}
https://api.github.com/repos/psf/requests/issues/3009/comments
https://api.github.com/repos/psf/requests/issues/3009/events
https://github.com/psf/requests/issues/3009
133,365,559
MDU6SXNzdWUxMzMzNjU1NTk=
3,009
Inspecting 'response.ok' with non-ascii HTTP status "reason" content causes UnicodeDecodeError
{ "avatar_url": "https://avatars.githubusercontent.com/u/420896?v=4", "events_url": "https://api.github.com/users/rene-armida/events{/privacy}", "followers_url": "https://api.github.com/users/rene-armida/followers", "following_url": "https://api.github.com/users/rene-armida/following{/other_user}", "gists_url": "https://api.github.com/users/rene-armida/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/rene-armida", "id": 420896, "login": "rene-armida", "node_id": "MDQ6VXNlcjQyMDg5Ng==", "organizations_url": "https://api.github.com/users/rene-armida/orgs", "received_events_url": "https://api.github.com/users/rene-armida/received_events", "repos_url": "https://api.github.com/users/rene-armida/repos", "site_admin": false, "starred_url": "https://api.github.com/users/rene-armida/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/rene-armida/subscriptions", "type": "User", "url": "https://api.github.com/users/rene-armida", "user_view_type": "public" }
[ { "color": "e10c02", "default": false, "description": null, "id": 117744, "name": "Bug", "node_id": "MDU6TGFiZWwxMTc3NDQ=", "url": "https://api.github.com/repos/psf/requests/labels/Bug" } ]
closed
true
null
[]
null
12
2016-02-12T23:09:13Z
2021-09-08T16:00:39Z
2016-08-05T00:10:35Z
NONE
resolved
Duplicate bug disclaimer: this is related to other Unicode + header issues, however, those all focus on errors raised while generating an outbound request. This applies only to inbound requests. (See also: #1082, #400, and to a lesser extent, #390, #409, #421, and #424; if this is already covered by another bug, sorry for bugging you guys. Thanks!) When inspecting responses with Unicode-encoded non-latin content trailing the HTTP status header in the response, requests raises UnicodeDecodeError. ``` (requests) marmida@loquat:~$ python Python 2.7.10 (default, Oct 14 2015, 16:09:02) [GCC 5.2.1 20151010] on linux2 Type "help", "copyright", "credits" or "license" for more information. >>> import requests >>> resp = requests.get('http://jp.apps.gree.net/ja/1604') >>> resp.ok Traceback (most recent call last): File "<stdin>", line 1, in <module> File "/home/marmida/venvs/requests/local/lib/python2.7/site-packages/requests/models.py", line 623, in ok self.raise_for_status() File "/home/marmida/venvs/requests/local/lib/python2.7/site-packages/requests/models.py", line 837, in raise_for_status http_error_msg = '%s Server Error: %s for url: %s' % (self.status_code, self.reason, self.url) UnicodeDecodeError: 'ascii' codec can't decode byte 0xe3 in position 23: ordinal not in range(128) ``` The content causing the problem, fetched via curl: ``` $ curl -v 'http://jp.apps.gree.net/ja/1604' * Connected to jp.apps.gree.net (116.93.155.51) port 80 (#0) > GET /ja/1604 HTTP/1.1 > Host: jp.apps.gree.net > User-Agent: curl/7.43.0 > Accept: */* > < HTTP/1.1 503 AKB48ステージファイター < Server: nginx ``` In the stack trace above, formatting `http_error_msg` as a `string` won't work, because `self.reason` contains non-ascii `unicode`. Requests version: 2.9.1 Run from a fresh virtualenv with only `requests` installed.
{ "avatar_url": "https://avatars.githubusercontent.com/u/240830?v=4", "events_url": "https://api.github.com/users/sigmavirus24/events{/privacy}", "followers_url": "https://api.github.com/users/sigmavirus24/followers", "following_url": "https://api.github.com/users/sigmavirus24/following{/other_user}", "gists_url": "https://api.github.com/users/sigmavirus24/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/sigmavirus24", "id": 240830, "login": "sigmavirus24", "node_id": "MDQ6VXNlcjI0MDgzMA==", "organizations_url": "https://api.github.com/users/sigmavirus24/orgs", "received_events_url": "https://api.github.com/users/sigmavirus24/received_events", "repos_url": "https://api.github.com/users/sigmavirus24/repos", "site_admin": false, "starred_url": "https://api.github.com/users/sigmavirus24/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sigmavirus24/subscriptions", "type": "User", "url": "https://api.github.com/users/sigmavirus24", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/3009/reactions" }
https://api.github.com/repos/psf/requests/issues/3009/timeline
null
completed
null
null
false
[ "I think the best way for this to be solved is for us to switch the format specifier for the reason phrase from `%s` to `%r`. Given that RFC 7230 tells us that a client should basically ignore the reason phrase anyway, we should avoid trying to interpret it. \n", ":+1: \n", "Extra datapoint, I've been bitten by...
https://api.github.com/repos/psf/requests/issues/3008
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/3008/labels{/name}
https://api.github.com/repos/psf/requests/issues/3008/comments
https://api.github.com/repos/psf/requests/issues/3008/events
https://github.com/psf/requests/issues/3008
133,362,834
MDU6SXNzdWUxMzMzNjI4MzQ=
3,008
invalid git history
{ "avatar_url": "https://avatars.githubusercontent.com/u/1505226?v=4", "events_url": "https://api.github.com/users/thestinger/events{/privacy}", "followers_url": "https://api.github.com/users/thestinger/followers", "following_url": "https://api.github.com/users/thestinger/following{/other_user}", "gists_url": "https://api.github.com/users/thestinger/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/thestinger", "id": 1505226, "login": "thestinger", "node_id": "MDQ6VXNlcjE1MDUyMjY=", "organizations_url": "https://api.github.com/users/thestinger/orgs", "received_events_url": "https://api.github.com/users/thestinger/received_events", "repos_url": "https://api.github.com/users/thestinger/repos", "site_admin": false, "starred_url": "https://api.github.com/users/thestinger/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/thestinger/subscriptions", "type": "User", "url": "https://api.github.com/users/thestinger", "user_view_type": "public" }
[]
closed
true
null
[]
null
12
2016-02-12T22:51:09Z
2016-03-09T21:27:22Z
2016-02-13T00:11:32Z
NONE
null
The Git history for this repository is invalid. You'll run into this if you enable verification of the history in your configuration (which should really be the default): ``` [transfer] fsckobjects = true [fetch] fsckobjects = true [receive] fsckobjects = true ``` ``` % git clone https://github.com/kennethreitz/requests.git Cloning into 'requests'... remote: Counting objects: 16580, done. error: object 5e6ecdad9f69b1ff789a17733b8edc6fd7091bd8: badTimezone: invalid author/committer line - bad time zone fatal: Error in object ``` If you look at the commit with verification disabled, you can see the problem: ``` commit 5e6ecdad9f69b1ff789a17733b8edc6fd7091bd8 Author: Shrikant Sharat Kandula <shrikantsharat.k@gmail.com> Date: Thu Sep 8 02:38:50 2011 +51800 Typo in documentation The kwarg is named `headers`, not `header`. Also, its a dict, not a set. ``` I don't have a suggestion on how to approach this. It's quite unfortunate. The history would probably have to be rewritten, and that would be awful. I do think it's worth noting though... verification by default may become the default on various distributions or even upstream.
{ "avatar_url": "https://avatars.githubusercontent.com/u/119893?v=4", "events_url": "https://api.github.com/users/kennethreitz/events{/privacy}", "followers_url": "https://api.github.com/users/kennethreitz/followers", "following_url": "https://api.github.com/users/kennethreitz/following{/other_user}", "gists_url": "https://api.github.com/users/kennethreitz/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/kennethreitz", "id": 119893, "login": "kennethreitz", "node_id": "MDQ6VXNlcjExOTg5Mw==", "organizations_url": "https://api.github.com/users/kennethreitz/orgs", "received_events_url": "https://api.github.com/users/kennethreitz/received_events", "repos_url": "https://api.github.com/users/kennethreitz/repos", "site_admin": false, "starred_url": "https://api.github.com/users/kennethreitz/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/kennethreitz/subscriptions", "type": "User", "url": "https://api.github.com/users/kennethreitz", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/3008/reactions" }
https://api.github.com/repos/psf/requests/issues/3008/timeline
null
completed
null
null
false
[ "> verification by default may become the default on various distributions\n\nI'd assume there are many more large/popular repositories that contain at least broken timestamps. IMO it'd be impudent if a distro patches git in a way that would break cloning repos like this. Given requests' history with downstream pat...
https://api.github.com/repos/psf/requests/issues/3007
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/3007/labels{/name}
https://api.github.com/repos/psf/requests/issues/3007/comments
https://api.github.com/repos/psf/requests/issues/3007/events
https://github.com/psf/requests/issues/3007
133,202,073
MDU6SXNzdWUxMzMyMDIwNzM=
3,007
Add ability to pass CA certificates by fileobj
{ "avatar_url": "https://avatars.githubusercontent.com/u/88809?v=4", "events_url": "https://api.github.com/users/Kentzo/events{/privacy}", "followers_url": "https://api.github.com/users/Kentzo/followers", "following_url": "https://api.github.com/users/Kentzo/following{/other_user}", "gists_url": "https://api.github.com/users/Kentzo/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/Kentzo", "id": 88809, "login": "Kentzo", "node_id": "MDQ6VXNlcjg4ODA5", "organizations_url": "https://api.github.com/users/Kentzo/orgs", "received_events_url": "https://api.github.com/users/Kentzo/received_events", "repos_url": "https://api.github.com/users/Kentzo/repos", "site_admin": false, "starred_url": "https://api.github.com/users/Kentzo/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Kentzo/subscriptions", "type": "User", "url": "https://api.github.com/users/Kentzo", "user_view_type": "public" }
[]
closed
true
null
[]
null
8
2016-02-12T10:16:35Z
2021-09-08T13:05:30Z
2016-02-12T13:27:52Z
NONE
resolved
Sometimes requests has no ability to open file with CA because is no such file, e.g. when CA is embedded in the app. requests should allow to specify fileobj (which can be a file or io wrapper on top of string and bytes) for that.
{ "avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4", "events_url": "https://api.github.com/users/Lukasa/events{/privacy}", "followers_url": "https://api.github.com/users/Lukasa/followers", "following_url": "https://api.github.com/users/Lukasa/following{/other_user}", "gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/Lukasa", "id": 1382556, "login": "Lukasa", "node_id": "MDQ6VXNlcjEzODI1NTY=", "organizations_url": "https://api.github.com/users/Lukasa/orgs", "received_events_url": "https://api.github.com/users/Lukasa/received_events", "repos_url": "https://api.github.com/users/Lukasa/repos", "site_admin": false, "starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions", "type": "User", "url": "https://api.github.com/users/Lukasa", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/3007/reactions" }
https://api.github.com/repos/psf/requests/issues/3007/timeline
null
completed
null
null
false
[ "Unfortunately that's extremely difficult for requests to do. \n\nThe 'path to a file' approach is actually the API used by OpenSSL. It's also possible to pass an in-memory serialized representation (as read from a file object), but that API is not exposed by the standard library so we can't rely on that being pres...
https://api.github.com/repos/psf/requests/issues/3006
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/3006/labels{/name}
https://api.github.com/repos/psf/requests/issues/3006/comments
https://api.github.com/repos/psf/requests/issues/3006/events
https://github.com/psf/requests/issues/3006
133,149,897
MDU6SXNzdWUxMzMxNDk4OTc=
3,006
requests.exceptions.SSLError: EOF occurred in violation of protocol (_ssl.c:645)
{ "avatar_url": "https://avatars.githubusercontent.com/u/2891235?v=4", "events_url": "https://api.github.com/users/caizixian/events{/privacy}", "followers_url": "https://api.github.com/users/caizixian/followers", "following_url": "https://api.github.com/users/caizixian/following{/other_user}", "gists_url": "https://api.github.com/users/caizixian/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/caizixian", "id": 2891235, "login": "caizixian", "node_id": "MDQ6VXNlcjI4OTEyMzU=", "organizations_url": "https://api.github.com/users/caizixian/orgs", "received_events_url": "https://api.github.com/users/caizixian/received_events", "repos_url": "https://api.github.com/users/caizixian/repos", "site_admin": false, "starred_url": "https://api.github.com/users/caizixian/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/caizixian/subscriptions", "type": "User", "url": "https://api.github.com/users/caizixian", "user_view_type": "public" }
[]
closed
true
null
[]
null
77
2016-02-12T03:30:56Z
2021-09-04T00:06:18Z
2016-08-05T07:52:35Z
NONE
resolved
Here is the first issue. https://github.com/kennethreitz/requests/issues/2906 Python 3.5.1 (https://www.python.org/downloads/) Virtualenv 14.0.5 Mac OS X 10.11.3 First, I created a virtualenv and `pip install requests[security]` Then I got ``` >>> from cryptography.hazmat.backends.openssl.backend import backend >>> print(backend.openssl_version_text()) OpenSSL 1.0.2f 28 Jan 2016 ``` which was what I expected. Everything worked great for about an hour. Then, some of my own scripts crashed which was normal. After that, when I try to run my script again, I got following exceptions ``` ssl.SSLEOFError: EOF occurred in violation of protocol (_ssl.c:645) requests.packages.urllib3.exceptions.SSLError: EOF occurred in violation of protocol (_ssl.c:645) requests.exceptions.SSLError: EOF occurred in violation of protocol (_ssl.c:645) ``` So I opened another Python console and ``` >>> requests.get("https://www.google.com") <Response [200]> >>> requests.get("https://www.telegram.org") Traceback (most recent call last): File "VirtualenvPath/lib/python3.5/site-packages/requests/packages/urllib3/connectionpool.py", line 559, in urlopen body=body, headers=headers) File "VirtualenvPath/lib/python3.5/site-packages/requests/packages/urllib3/connectionpool.py", line 345, in _make_request self._validate_conn(conn) File "VirtualenvPath/lib/python3.5/site-packages/requests/packages/urllib3/connectionpool.py", line 784, in _validate_conn conn.connect() File "VirtualenvPath/lib/python3.5/site-packages/requests/packages/urllib3/connection.py", line 252, in connect ssl_version=resolved_ssl_version) File "VirtualenvPath/lib/python3.5/site-packages/requests/packages/urllib3/util/ssl_.py", line 305, in ssl_wrap_socket return context.wrap_socket(sock, server_hostname=server_hostname) File "/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/ssl.py", line 376, in wrap_socket _context=self) File "/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/ssl.py", line 747, in __init__ self.do_handshake() File "/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/ssl.py", line 983, in do_handshake self._sslobj.do_handshake() File "/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/ssl.py", line 628, in do_handshake self._sslobj.do_handshake() ssl.SSLEOFError: EOF occurred in violation of protocol (_ssl.c:645) During handling of the above exception, another exception occurred: Traceback (most recent call last): File "VirtualenvPath/lib/python3.5/site-packages/requests/adapters.py", line 376, in send timeout=timeout File "VirtualenvPath/lib/python3.5/site-packages/requests/packages/urllib3/connectionpool.py", line 588, in urlopen raise SSLError(e) requests.packages.urllib3.exceptions.SSLError: EOF occurred in violation of protocol (_ssl.c:645) During handling of the above exception, another exception occurred: Traceback (most recent call last): File "<stdin>", line 1, in <module> File "VirtualenvPath/lib/python3.5/site-packages/requests/api.py", line 67, in get return request('get', url, params=params, **kwargs) File "VirtualenvPath/lib/python3.5/site-packages/requests/api.py", line 53, in request return session.request(method=method, url=url, **kwargs) File "VirtualenvPath/lib/python3.5/site-packages/requests/sessions.py", line 468, in request resp = self.send(prep, **send_kwargs) File "VirtualenvPath/lib/python3.5/site-packages/requests/sessions.py", line 576, in send r = adapter.send(request, **kwargs) File "VirtualenvPath/lib/python3.5/site-packages/requests/adapters.py", line 447, in send raise SSLError(e, request=request) requests.exceptions.SSLError: EOF occurred in violation of protocol (_ssl.c:645) >>> ``` So I rebooted, uninstalled all these libs and pip install them again. Everything worked again. But after 1 hour or so, same exception again.
{ "avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4", "events_url": "https://api.github.com/users/Lukasa/events{/privacy}", "followers_url": "https://api.github.com/users/Lukasa/followers", "following_url": "https://api.github.com/users/Lukasa/following{/other_user}", "gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/Lukasa", "id": 1382556, "login": "Lukasa", "node_id": "MDQ6VXNlcjEzODI1NTY=", "organizations_url": "https://api.github.com/users/Lukasa/orgs", "received_events_url": "https://api.github.com/users/Lukasa/received_events", "repos_url": "https://api.github.com/users/Lukasa/repos", "site_admin": false, "starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions", "type": "User", "url": "https://api.github.com/users/Lukasa", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/3006/reactions" }
https://api.github.com/repos/psf/requests/issues/3006/timeline
null
completed
null
null
false
[ "> Then, some of my own scripts crashed which was normal.\n\nWhat does a crash like that look like?\n\n> After that, when I try to run my script again, I got following exceptions\n\nAre you completely unable to run them at all after that?\n", "@sigmavirus24 It's just some bug in my own code without anything to do...
https://api.github.com/repos/psf/requests/issues/3005
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/3005/labels{/name}
https://api.github.com/repos/psf/requests/issues/3005/comments
https://api.github.com/repos/psf/requests/issues/3005/events
https://github.com/psf/requests/pull/3005
133,051,769
MDExOlB1bGxSZXF1ZXN0NTkwNzMzMzk=
3,005
Use time.monotonic() for tracking elapsed time where available
{ "avatar_url": "https://avatars.githubusercontent.com/u/109152?v=4", "events_url": "https://api.github.com/users/scop/events{/privacy}", "followers_url": "https://api.github.com/users/scop/followers", "following_url": "https://api.github.com/users/scop/following{/other_user}", "gists_url": "https://api.github.com/users/scop/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/scop", "id": 109152, "login": "scop", "node_id": "MDQ6VXNlcjEwOTE1Mg==", "organizations_url": "https://api.github.com/users/scop/orgs", "received_events_url": "https://api.github.com/users/scop/received_events", "repos_url": "https://api.github.com/users/scop/repos", "site_admin": false, "starred_url": "https://api.github.com/users/scop/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/scop/subscriptions", "type": "User", "url": "https://api.github.com/users/scop", "user_view_type": "public" }
[ { "color": "e11d21", "default": false, "description": null, "id": 44501305, "name": "Not Ready To Merge", "node_id": "MDU6TGFiZWw0NDUwMTMwNQ==", "url": "https://api.github.com/repos/psf/requests/labels/Not%20Ready%20To%20Merge" }, { "color": "e11d21", "default": false, "d...
closed
true
null
[]
null
5
2016-02-11T18:30:48Z
2021-09-08T04:01:11Z
2016-04-06T18:56:17Z
CONTRIBUTOR
resolved
{ "avatar_url": "https://avatars.githubusercontent.com/u/119893?v=4", "events_url": "https://api.github.com/users/kennethreitz/events{/privacy}", "followers_url": "https://api.github.com/users/kennethreitz/followers", "following_url": "https://api.github.com/users/kennethreitz/following{/other_user}", "gists_url": "https://api.github.com/users/kennethreitz/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/kennethreitz", "id": 119893, "login": "kennethreitz", "node_id": "MDQ6VXNlcjExOTg5Mw==", "organizations_url": "https://api.github.com/users/kennethreitz/orgs", "received_events_url": "https://api.github.com/users/kennethreitz/received_events", "repos_url": "https://api.github.com/users/kennethreitz/repos", "site_admin": false, "starred_url": "https://api.github.com/users/kennethreitz/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/kennethreitz/subscriptions", "type": "User", "url": "https://api.github.com/users/kennethreitz", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/3005/reactions" }
https://api.github.com/repos/psf/requests/issues/3005/timeline
null
null
false
{ "diff_url": "https://github.com/psf/requests/pull/3005.diff", "html_url": "https://github.com/psf/requests/pull/3005", "merged_at": null, "patch_url": "https://github.com/psf/requests/pull/3005.patch", "url": "https://api.github.com/repos/psf/requests/pulls/3005" }
true
[ "Hey @scop I was wondering if you could provide detail about why this is desirable and why we should change the existing behaviour as well as a description of when/where monotonic will be available and where/when it won't.\n", "Most of the requested details should be answered by the `time.monotonic` docs: https:/...
https://api.github.com/repos/psf/requests/issues/3004
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/3004/labels{/name}
https://api.github.com/repos/psf/requests/issues/3004/comments
https://api.github.com/repos/psf/requests/issues/3004/events
https://github.com/psf/requests/issues/3004
132,781,456
MDU6SXNzdWUxMzI3ODE0NTY=
3,004
Durable way to obtain SSLError errno
{ "avatar_url": "https://avatars.githubusercontent.com/u/1385596?v=4", "events_url": "https://api.github.com/users/AlanCoding/events{/privacy}", "followers_url": "https://api.github.com/users/AlanCoding/followers", "following_url": "https://api.github.com/users/AlanCoding/following{/other_user}", "gists_url": "https://api.github.com/users/AlanCoding/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/AlanCoding", "id": 1385596, "login": "AlanCoding", "node_id": "MDQ6VXNlcjEzODU1OTY=", "organizations_url": "https://api.github.com/users/AlanCoding/orgs", "received_events_url": "https://api.github.com/users/AlanCoding/received_events", "repos_url": "https://api.github.com/users/AlanCoding/repos", "site_admin": false, "starred_url": "https://api.github.com/users/AlanCoding/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/AlanCoding/subscriptions", "type": "User", "url": "https://api.github.com/users/AlanCoding", "user_view_type": "public" }
[]
closed
false
null
[]
{ "closed_at": null, "closed_issues": 29, "created_at": "2024-05-19T18:29:04Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/18519037?v=4", "events_url": "https://api.github.com/users/sethmlarson/events{/privacy}", "followers_url": "https://api.github.com/users/sethmlarson/followers", "following_url": "https://api.github.com/users/sethmlarson/following{/other_user}", "gists_url": "https://api.github.com/users/sethmlarson/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/sethmlarson", "id": 18519037, "login": "sethmlarson", "node_id": "MDQ6VXNlcjE4NTE5MDM3", "organizations_url": "https://api.github.com/users/sethmlarson/orgs", "received_events_url": "https://api.github.com/users/sethmlarson/received_events", "repos_url": "https://api.github.com/users/sethmlarson/repos", "site_admin": false, "starred_url": "https://api.github.com/users/sethmlarson/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sethmlarson/subscriptions", "type": "User", "url": "https://api.github.com/users/sethmlarson", "user_view_type": "public" }, "description": "", "due_on": null, "html_url": "https://github.com/psf/requests/milestone/34", "id": 11073254, "labels_url": "https://api.github.com/repos/psf/requests/milestones/34/labels", "node_id": "MI_kwDOABTKOs4AqPbm", "number": 34, "open_issues": 0, "state": "open", "title": "Bankruptcy", "updated_at": "2024-05-20T14:37:16Z", "url": "https://api.github.com/repos/psf/requests/milestones/34" }
6
2016-02-10T18:33:23Z
2024-05-20T14:35:28Z
2024-05-20T14:35:28Z
NONE
null
## Issue I want to get the errno property of an SSLError object the right way. ## Description I have a Session object, for which I call the request method made inside of a try-catch block. I would like to distinguish between different situations, all of which will have the same traceback, and all of which produce an SSLError. Here is the specific code I'm working with, starting with the except block with SSLError: https://github.com/ansible/tower-cli/blob/master/lib/tower_cli/api.py#L103 Different situations will return (at least) two different types of SSLErrors: 1. requests.exceptions.SSLError: EOF occurred in violation of protocol (_ssl.c:590) 2. requests.exceptions.SSLError: [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed (_ssl.c:590) ## Work-around Attempts Here is an example of someone else who tried to distinguish between these scenarios: https://github.com/kisom/woofs/blob/ca589bf57390069f61981fdae1b216d8c657f75c/woofs.py#L237 ``` python if 'EOF occurred in violation of protocol' in str(e): continue ``` (note: My exception is named `ex`, but it is named `e` in the above code) I'm not a fan of this code. If I do pdb.set_trace() and inspect the error in my case, I find that `ex.errno` is `None`. ### EOF error ``` python (Pdb) print ex.args[0].args[0].args (1, u'[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed (_ssl.c:590)') ``` ### CA error ``` python (Pdb) print ex.args[0].args[0].args (8, u'EOF occurred in violation of protocol (_ssl.c:590)') ``` You can see that the first error has an error number 1, and the second error has an error number 8. This is what I want. So I could obtain the SSLError number from `ex.args[0].args[0].args[0]`, and branch different cases based on that. But if the requests library changes in the future, another layer of try-except might be added, so realistically I would need to write a loop that recursively reads `args` as long as it's a tuple, until I get to an integer. Is this the best available method to get the error number? It seems strange that `ex.message` will automatically look into the args chain and obtain the error message string, but `ex.errno` will not do the same for the error number. I'm using requests 2.9.1.
{ "avatar_url": "https://avatars.githubusercontent.com/u/18519037?v=4", "events_url": "https://api.github.com/users/sethmlarson/events{/privacy}", "followers_url": "https://api.github.com/users/sethmlarson/followers", "following_url": "https://api.github.com/users/sethmlarson/following{/other_user}", "gists_url": "https://api.github.com/users/sethmlarson/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/sethmlarson", "id": 18519037, "login": "sethmlarson", "node_id": "MDQ6VXNlcjE4NTE5MDM3", "organizations_url": "https://api.github.com/users/sethmlarson/orgs", "received_events_url": "https://api.github.com/users/sethmlarson/received_events", "repos_url": "https://api.github.com/users/sethmlarson/repos", "site_admin": false, "starred_url": "https://api.github.com/users/sethmlarson/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sethmlarson/subscriptions", "type": "User", "url": "https://api.github.com/users/sethmlarson", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/3004/reactions" }
https://api.github.com/repos/psf/requests/issues/3004/timeline
null
completed
null
null
false
[ "This would be helpful as i get `SSLError: (\"bad handshake: SysCallError(-1, 'Unexpected EOF')\",)` when i run my scripts and i am not sure what error is causing this issue exactly. The traceback does lead to the Requests `adapter.py` library.\n", "@girishsortur This would not help you at all. You can already se...
https://api.github.com/repos/psf/requests/issues/3003
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/3003/labels{/name}
https://api.github.com/repos/psf/requests/issues/3003/comments
https://api.github.com/repos/psf/requests/issues/3003/events
https://github.com/psf/requests/pull/3003
132,563,476
MDExOlB1bGxSZXF1ZXN0NTg4MjM1NTY=
3,003
Added pprint() function to Response and PreparedRequest objects for human-reading goodness
{ "avatar_url": "https://avatars.githubusercontent.com/u/5515484?v=4", "events_url": "https://api.github.com/users/mtj42/events{/privacy}", "followers_url": "https://api.github.com/users/mtj42/followers", "following_url": "https://api.github.com/users/mtj42/following{/other_user}", "gists_url": "https://api.github.com/users/mtj42/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/mtj42", "id": 5515484, "login": "mtj42", "node_id": "MDQ6VXNlcjU1MTU0ODQ=", "organizations_url": "https://api.github.com/users/mtj42/orgs", "received_events_url": "https://api.github.com/users/mtj42/received_events", "repos_url": "https://api.github.com/users/mtj42/repos", "site_admin": false, "starred_url": "https://api.github.com/users/mtj42/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/mtj42/subscriptions", "type": "User", "url": "https://api.github.com/users/mtj42", "user_view_type": "public" }
[]
closed
true
null
[]
null
6
2016-02-09T23:05:14Z
2021-09-08T05:00:57Z
2016-02-10T20:26:21Z
NONE
resolved
This feature is aimed at making debugging/following HTTP traffic easier on a developer. Many times in the past, I would send Requests' traffic through Burp proxy in order to have a visual representation of my HTTP traffic. With this pull request, a developer can simply call pprint() on their HTTP requests to see a Burp-like view of the traffic. Example usage: ``` import requests r = requests.get("http://www.praetorian.com") r.request.pprint() r.pprint(body=False) ```
{ "avatar_url": "https://avatars.githubusercontent.com/u/5515484?v=4", "events_url": "https://api.github.com/users/mtj42/events{/privacy}", "followers_url": "https://api.github.com/users/mtj42/followers", "following_url": "https://api.github.com/users/mtj42/following{/other_user}", "gists_url": "https://api.github.com/users/mtj42/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/mtj42", "id": 5515484, "login": "mtj42", "node_id": "MDQ6VXNlcjU1MTU0ODQ=", "organizations_url": "https://api.github.com/users/mtj42/orgs", "received_events_url": "https://api.github.com/users/mtj42/received_events", "repos_url": "https://api.github.com/users/mtj42/repos", "site_admin": false, "starred_url": "https://api.github.com/users/mtj42/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/mtj42/subscriptions", "type": "User", "url": "https://api.github.com/users/mtj42", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/3003/reactions" }
https://api.github.com/repos/psf/requests/issues/3003/timeline
null
null
false
{ "diff_url": "https://github.com/psf/requests/pull/3003.diff", "html_url": "https://github.com/psf/requests/pull/3003", "merged_at": null, "patch_url": "https://github.com/psf/requests/pull/3003.patch", "url": "https://api.github.com/repos/psf/requests/pulls/3003" }
true
[ "This already exists (to a degree) in the requests-toolbelt: https://toolbelt.readthedocs.org/en/latest/dumputils.html\n", "My major problem with the dump utility is that it is not as granular as pprint(), which gives a developer the ability to dump a single request or a response without the body attached (good f...
https://api.github.com/repos/psf/requests/issues/3002
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/3002/labels{/name}
https://api.github.com/repos/psf/requests/issues/3002/comments
https://api.github.com/repos/psf/requests/issues/3002/events
https://github.com/psf/requests/issues/3002
132,525,007
MDU6SXNzdWUxMzI1MjUwMDc=
3,002
Request via IPv6 ip result in a broken Host header
{ "avatar_url": "https://avatars.githubusercontent.com/u/569440?v=4", "events_url": "https://api.github.com/users/pneumaticdeath/events{/privacy}", "followers_url": "https://api.github.com/users/pneumaticdeath/followers", "following_url": "https://api.github.com/users/pneumaticdeath/following{/other_user}", "gists_url": "https://api.github.com/users/pneumaticdeath/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/pneumaticdeath", "id": 569440, "login": "pneumaticdeath", "node_id": "MDQ6VXNlcjU2OTQ0MA==", "organizations_url": "https://api.github.com/users/pneumaticdeath/orgs", "received_events_url": "https://api.github.com/users/pneumaticdeath/received_events", "repos_url": "https://api.github.com/users/pneumaticdeath/repos", "site_admin": false, "starred_url": "https://api.github.com/users/pneumaticdeath/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/pneumaticdeath/subscriptions", "type": "User", "url": "https://api.github.com/users/pneumaticdeath", "user_view_type": "public" }
[]
closed
true
null
[]
null
27
2016-02-09T20:30:32Z
2021-09-08T16:00:35Z
2016-08-05T07:51:40Z
NONE
resolved
This is a regression from 2.7.0 and 2.9.1. When using a URL with an IPv6 ip in the host part of the url: http://[2620:10d:c021:11::75]/foo, in 2.7.0 the Host header looks correct as so: Host: [2620:10d:c021:11::75] But when using 2.9.1, it gets munged: Host: [[2620:10d:c021:11::75]] This causes Django to barf.
{ "avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4", "events_url": "https://api.github.com/users/Lukasa/events{/privacy}", "followers_url": "https://api.github.com/users/Lukasa/followers", "following_url": "https://api.github.com/users/Lukasa/following{/other_user}", "gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/Lukasa", "id": 1382556, "login": "Lukasa", "node_id": "MDQ6VXNlcjEzODI1NTY=", "organizations_url": "https://api.github.com/users/Lukasa/orgs", "received_events_url": "https://api.github.com/users/Lukasa/received_events", "repos_url": "https://api.github.com/users/Lukasa/repos", "site_admin": false, "starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions", "type": "User", "url": "https://api.github.com/users/Lukasa", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/3002/reactions" }
https://api.github.com/repos/psf/requests/issues/3002/timeline
null
completed
null
null
false
[ "Just to clarify, where did you install requests from?\n", "So this was probably introduced by shazow/urllib3#708. Looks like we'll have to revert that @shazow.\n\n@pneumaticdeath Why Python version are you using?\n", "I got it from https://pypi.python.org/packages/source/r/requests/requests-2.9.1.tar.gz#md5=0b...
https://api.github.com/repos/psf/requests/issues/3001
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/3001/labels{/name}
https://api.github.com/repos/psf/requests/issues/3001/comments
https://api.github.com/repos/psf/requests/issues/3001/events
https://github.com/psf/requests/issues/3001
132,501,201
MDU6SXNzdWUxMzI1MDEyMDE=
3,001
Multipart mixed responses generate warnings
{ "avatar_url": "https://avatars.githubusercontent.com/u/36793?v=4", "events_url": "https://api.github.com/users/ndw/events{/privacy}", "followers_url": "https://api.github.com/users/ndw/followers", "following_url": "https://api.github.com/users/ndw/following{/other_user}", "gists_url": "https://api.github.com/users/ndw/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/ndw", "id": 36793, "login": "ndw", "node_id": "MDQ6VXNlcjM2Nzkz", "organizations_url": "https://api.github.com/users/ndw/orgs", "received_events_url": "https://api.github.com/users/ndw/received_events", "repos_url": "https://api.github.com/users/ndw/repos", "site_admin": false, "starred_url": "https://api.github.com/users/ndw/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/ndw/subscriptions", "type": "User", "url": "https://api.github.com/users/ndw", "user_view_type": "public" }
[]
closed
true
null
[]
null
1
2016-02-09T18:57:40Z
2021-09-08T19:00:35Z
2016-02-09T19:17:12Z
NONE
resolved
If you read a multipart/mixed response, the connectionpool issues a couple of warnings about defects in the message. I'm not sure what the expected, correct behavior is, but these warnings seem spurious. Stick this perl script somewhere: ``` #!/usr/bin/perl print "Server: Some Server Name\r\n"; print "Content-Type: multipart/mixed; boundary=36eeb8c4e26d842a\r\n"; print "Content-Length: 178\r\n"; print "\r\n\r\n"; print "--36eeb8c4e26d842a\r\n"; print "Content-Type: text/plain\r\n"; print "\r\n"; print "7\r\n"; print "--36eeb8c4e26d842a\r\n"; print "Content-Type: text/plain\r\n"; print "\r\n"; print "9\r\n"; print "--36eeb8c4e26d842a\r\n"; print "Content-Type: text/plain\r\n"; print "\r\n"; print "11\r\n"; print "--36eeb8c4e26d842a--\r\n"; ``` Read it with requests (naturally, you'll have to change the URI to wherever you put the script): ``` import requests, logging logging.basicConfig(level=logging.WARNING) logging.getLogger("requests").setLevel(logging.DEBUG) headers = {'accept': "multipart/mixed"} r = requests.get("http://localhost:8124/cgi-bin/mpm.pl", headers=headers) print(r) ``` The following errors are displayed: ``` DEBUG:requests.packages.urllib3.connectionpool:"GET http://localhost:8124/cgi-bin/mpm.pl HTTP/1.1" 200 178 WARNING:requests.packages.urllib3.connectionpool:Failed to parse headers (url=http://localhost:8888/http://localhost:8124/cgi-bin/mpm.pl): [StartBoundaryNotFoundDefect(), MultipartInvariantViolationDefect()], unparsed data: '' Traceback (most recent call last): File "/home/ndw/.virtualenvs/pyapi/lib/python3.4/site-packages/requests-2.8.0-py3.4.egg/requests/packages/urllib3/connectionpool.py", line 390, in _make_request assert_header_parsing(httplib_response.msg) File "/home/ndw/.virtualenvs/pyapi/lib/python3.4/site-packages/requests-2.8.0-py3.4.egg/requests/packages/urllib3/util/response.py", line 58, in assert_header_parsing raise HeaderParsingError(defects=defects, unparsed_data=unparsed_data) requests.packages.urllib3.exceptions.HeaderParsingError: [StartBoundaryNotFoundDefect(), MultipartInvariantViolationDefect()], unparsed data: '' ``` It took me quite a while to work out that they were spurious (because in real life, the server side that is generating the multipart/mixed is more complicated!)
{ "avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4", "events_url": "https://api.github.com/users/Lukasa/events{/privacy}", "followers_url": "https://api.github.com/users/Lukasa/followers", "following_url": "https://api.github.com/users/Lukasa/following{/other_user}", "gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/Lukasa", "id": 1382556, "login": "Lukasa", "node_id": "MDQ6VXNlcjEzODI1NTY=", "organizations_url": "https://api.github.com/users/Lukasa/orgs", "received_events_url": "https://api.github.com/users/Lukasa/received_events", "repos_url": "https://api.github.com/users/Lukasa/repos", "site_admin": false, "starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions", "type": "User", "url": "https://api.github.com/users/Lukasa", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/3001/reactions" }
https://api.github.com/repos/psf/requests/issues/3001/timeline
null
completed
null
null
false
[ "Ah, can you raise this issue on the urllib3 repo! We'd love to merge a fix at the project! It's [here](https://github.com/shazow/urllib3).\n" ]
https://api.github.com/repos/psf/requests/issues/3000
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/3000/labels{/name}
https://api.github.com/repos/psf/requests/issues/3000/comments
https://api.github.com/repos/psf/requests/issues/3000/events
https://github.com/psf/requests/issues/3000
132,283,591
MDU6SXNzdWUxMzIyODM1OTE=
3,000
Problem with Content-Lenght is missing
{ "avatar_url": "https://avatars.githubusercontent.com/u/17131854?v=4", "events_url": "https://api.github.com/users/victor1969/events{/privacy}", "followers_url": "https://api.github.com/users/victor1969/followers", "following_url": "https://api.github.com/users/victor1969/following{/other_user}", "gists_url": "https://api.github.com/users/victor1969/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/victor1969", "id": 17131854, "login": "victor1969", "node_id": "MDQ6VXNlcjE3MTMxODU0", "organizations_url": "https://api.github.com/users/victor1969/orgs", "received_events_url": "https://api.github.com/users/victor1969/received_events", "repos_url": "https://api.github.com/users/victor1969/repos", "site_admin": false, "starred_url": "https://api.github.com/users/victor1969/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/victor1969/subscriptions", "type": "User", "url": "https://api.github.com/users/victor1969", "user_view_type": "public" }
[]
closed
true
null
[]
null
6
2016-02-08T23:11:45Z
2021-09-08T19:00:35Z
2016-02-08T23:37:19Z
NONE
resolved
I'm playing clonk rage but i can't play online because this happend Content-Lenght is missing pls help me PS: i don't speak english so well
{ "avatar_url": "https://avatars.githubusercontent.com/u/119893?v=4", "events_url": "https://api.github.com/users/kennethreitz/events{/privacy}", "followers_url": "https://api.github.com/users/kennethreitz/followers", "following_url": "https://api.github.com/users/kennethreitz/following{/other_user}", "gists_url": "https://api.github.com/users/kennethreitz/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/kennethreitz", "id": 119893, "login": "kennethreitz", "node_id": "MDQ6VXNlcjExOTg5Mw==", "organizations_url": "https://api.github.com/users/kennethreitz/orgs", "received_events_url": "https://api.github.com/users/kennethreitz/received_events", "repos_url": "https://api.github.com/users/kennethreitz/repos", "site_admin": false, "starred_url": "https://api.github.com/users/kennethreitz/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/kennethreitz/subscriptions", "type": "User", "url": "https://api.github.com/users/kennethreitz", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/3000/reactions" }
https://api.github.com/repos/psf/requests/issues/3000/timeline
null
completed
null
null
false
[ "@victor1969 can you please share the code you are using so we can understand what you're asking?\n", "where i get the code?\n", "@victor1969 is this an error you saw while playing a game? Why did you decide to post about it here?\n", "i'm just trying to play online Clonk rage but says on the server list\nInt...
https://api.github.com/repos/psf/requests/issues/2999
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/2999/labels{/name}
https://api.github.com/repos/psf/requests/issues/2999/comments
https://api.github.com/repos/psf/requests/issues/2999/events
https://github.com/psf/requests/issues/2999
131,995,844
MDU6SXNzdWUxMzE5OTU4NDQ=
2,999
URL-encoded boolean parameter passed as ?foo=True instead of ?foo=1
{ "avatar_url": "https://avatars.githubusercontent.com/u/6293202?v=4", "events_url": "https://api.github.com/users/FlyingLotus1983/events{/privacy}", "followers_url": "https://api.github.com/users/FlyingLotus1983/followers", "following_url": "https://api.github.com/users/FlyingLotus1983/following{/other_user}", "gists_url": "https://api.github.com/users/FlyingLotus1983/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/FlyingLotus1983", "id": 6293202, "login": "FlyingLotus1983", "node_id": "MDQ6VXNlcjYyOTMyMDI=", "organizations_url": "https://api.github.com/users/FlyingLotus1983/orgs", "received_events_url": "https://api.github.com/users/FlyingLotus1983/received_events", "repos_url": "https://api.github.com/users/FlyingLotus1983/repos", "site_admin": false, "starred_url": "https://api.github.com/users/FlyingLotus1983/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/FlyingLotus1983/subscriptions", "type": "User", "url": "https://api.github.com/users/FlyingLotus1983", "user_view_type": "public" }
[]
closed
true
null
[]
null
2
2016-02-07T18:34:30Z
2021-09-08T19:00:35Z
2016-02-07T19:48:24Z
NONE
resolved
When encoding a boolean into a URL encoded parameter: ``` payload = {'foo': True} resp = requests.post(path, params=payload) ``` Requests currently generates: `?foo=True` .. I would expect the boolean to be encoded as a 1 or 0, e.g. `?foo=1` , as some clients may not understand `True` as a boolean. I did some google searching, and I am not even sure if there are rules for how a boolean should be encoded, I didn't find any specific guidelines, just that a lot of URL encoding libraries seem to always encode booleans as 1's and 0's. Apologies if this is known and/or expected behavior. I'm not a web guru by any means, but at the least, Requests does seem to be handling it differently than other libraries I've used in the past.
{ "avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4", "events_url": "https://api.github.com/users/Lukasa/events{/privacy}", "followers_url": "https://api.github.com/users/Lukasa/followers", "following_url": "https://api.github.com/users/Lukasa/following{/other_user}", "gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/Lukasa", "id": 1382556, "login": "Lukasa", "node_id": "MDQ6VXNlcjEzODI1NTY=", "organizations_url": "https://api.github.com/users/Lukasa/orgs", "received_events_url": "https://api.github.com/users/Lukasa/received_events", "repos_url": "https://api.github.com/users/Lukasa/repos", "site_admin": false, "starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions", "type": "User", "url": "https://api.github.com/users/Lukasa", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/2999/reactions" }
https://api.github.com/repos/psf/requests/issues/2999/timeline
null
completed
null
null
false
[ "There are no rules for how to encode Boolean types, because urlencoding is performed on strings, not on typed objects. For that reason, Reuests coerces all objects passed to the urlencoding logic to strings (except for `None`, which it handles specially).\n\nThis is not considered a bug by the requests team: while...
https://api.github.com/repos/psf/requests/issues/2998
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/2998/labels{/name}
https://api.github.com/repos/psf/requests/issues/2998/comments
https://api.github.com/repos/psf/requests/issues/2998/events
https://github.com/psf/requests/issues/2998
131,786,503
MDU6SXNzdWUxMzE3ODY1MDM=
2,998
Requests default to environment CA even when there's a session-set CA
{ "avatar_url": "https://avatars.githubusercontent.com/u/1117819?v=4", "events_url": "https://api.github.com/users/jcmcken/events{/privacy}", "followers_url": "https://api.github.com/users/jcmcken/followers", "following_url": "https://api.github.com/users/jcmcken/following{/other_user}", "gists_url": "https://api.github.com/users/jcmcken/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jcmcken", "id": 1117819, "login": "jcmcken", "node_id": "MDQ6VXNlcjExMTc4MTk=", "organizations_url": "https://api.github.com/users/jcmcken/orgs", "received_events_url": "https://api.github.com/users/jcmcken/received_events", "repos_url": "https://api.github.com/users/jcmcken/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jcmcken/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jcmcken/subscriptions", "type": "User", "url": "https://api.github.com/users/jcmcken", "user_view_type": "public" }
[ { "color": "e10c02", "default": false, "description": null, "id": 117744, "name": "Bug", "node_id": "MDU6TGFiZWwxMTc3NDQ=", "url": "https://api.github.com/repos/psf/requests/labels/Bug" } ]
closed
true
null
[]
null
4
2016-02-05T23:16:51Z
2021-09-08T19:00:34Z
2016-02-10T08:46:49Z
NONE
resolved
If I set a CA via an environment variable, such as: ``` console $ export REQUESTS_CA_BUNDLE=/etc/pki/tls/certs/ca-bundle.crt ``` (Where the CA bundle actually does exist) And then I prepare a session like this: ``` python import requests session = requests.Session() session.verify = '/path/to/custom/ca.pem' ``` (Again, assume this 2nd CA path exists) Executing a `session.get` against an HTTPS endpoint signed by the 2nd CA but not the first will result in an SSL verification error. This is because the request is defaulting to using the environment CA rather than the session CA. This sort of contradicts my expectations, where the session is much closer to the request in the stack than the process's environment. The source of this issue is the merging happening here: https://github.com/kennethreitz/requests/blob/3a77b59df222920391359f052cab9319dda31ac7/requests/sessions.py#L625 ...where the conditional validates whether the verification is set at the request level (either `True` or `None`) before choosing to set the env CA, but doesn't look at the session (`self.verify`) (which likely has, and in my case does have, a more accurate CA setting).
{ "avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4", "events_url": "https://api.github.com/users/Lukasa/events{/privacy}", "followers_url": "https://api.github.com/users/Lukasa/followers", "following_url": "https://api.github.com/users/Lukasa/following{/other_user}", "gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/Lukasa", "id": 1382556, "login": "Lukasa", "node_id": "MDQ6VXNlcjEzODI1NTY=", "organizations_url": "https://api.github.com/users/Lukasa/orgs", "received_events_url": "https://api.github.com/users/Lukasa/received_events", "repos_url": "https://api.github.com/users/Lukasa/repos", "site_admin": false, "starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions", "type": "User", "url": "https://api.github.com/users/Lukasa", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/2998/reactions" }
https://api.github.com/repos/psf/requests/issues/2998/timeline
null
completed
null
null
false
[ "I believe this is related to https://github.com/kennethreitz/requests/issues/2018 which is scheduled for 3.0.0\n", "As an aside, you can disable using the environment by setting `trust_env=False`.\n", "Closing to centralise on #2018.\n", "@sigmavirus24 That's the workaround I intend to use, although it's a l...
https://api.github.com/repos/psf/requests/issues/2997
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/2997/labels{/name}
https://api.github.com/repos/psf/requests/issues/2997/comments
https://api.github.com/repos/psf/requests/issues/2997/events
https://github.com/psf/requests/issues/2997
131,736,140
MDU6SXNzdWUxMzE3MzYxNDA=
2,997
allow_redirects=True for one get affects the next one
{ "avatar_url": "https://avatars.githubusercontent.com/u/39889?v=4", "events_url": "https://api.github.com/users/yarikoptic/events{/privacy}", "followers_url": "https://api.github.com/users/yarikoptic/followers", "following_url": "https://api.github.com/users/yarikoptic/following{/other_user}", "gists_url": "https://api.github.com/users/yarikoptic/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/yarikoptic", "id": 39889, "login": "yarikoptic", "node_id": "MDQ6VXNlcjM5ODg5", "organizations_url": "https://api.github.com/users/yarikoptic/orgs", "received_events_url": "https://api.github.com/users/yarikoptic/received_events", "repos_url": "https://api.github.com/users/yarikoptic/repos", "site_admin": false, "starred_url": "https://api.github.com/users/yarikoptic/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/yarikoptic/subscriptions", "type": "User", "url": "https://api.github.com/users/yarikoptic", "user_view_type": "public" }
[ { "color": "e10c02", "default": false, "description": null, "id": 117744, "name": "Bug", "node_id": "MDU6TGFiZWwxMTc3NDQ=", "url": "https://api.github.com/repos/psf/requests/labels/Bug" } ]
closed
true
null
[]
null
7
2016-02-05T19:41:55Z
2021-09-08T19:00:36Z
2016-02-05T22:53:55Z
NONE
resolved
Here is an example with 3 similar `get` calls with all allow_redirects=False: ``` $> PYTHONPATH=$PWD python -c "import requests; url = 'http://127.0.0.1:45508/ds666'; sess = requests.Session(); print sess.get(url, allow_redirects=False); print sess.get(url, allow_redirects=False); print sess.get(url, allow_redirects=False)" <Response [301]> <Response [301]> <Response [301]> ``` all of them logically 301. If 2nd one says to allow redirects, then 3rd would also succeed even if I disallow redirects for that invocation ``` $> PYTHONPATH=$PWD python -c "import requests; url = 'http://127.0.0.1:45508/ds666'; sess = requests.Session(); print sess.get(url, allow_redirects=False); print sess.get(url, allow_redirects=True); print sess.get(url, allow_redirects=False)" <Response [301]> <Response [200]> <Response [200]> ``` Demonstrated on ``` v2.9.1-63-g6143b7e ```
{ "avatar_url": "https://avatars.githubusercontent.com/u/119893?v=4", "events_url": "https://api.github.com/users/kennethreitz/events{/privacy}", "followers_url": "https://api.github.com/users/kennethreitz/followers", "following_url": "https://api.github.com/users/kennethreitz/following{/other_user}", "gists_url": "https://api.github.com/users/kennethreitz/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/kennethreitz", "id": 119893, "login": "kennethreitz", "node_id": "MDQ6VXNlcjExOTg5Mw==", "organizations_url": "https://api.github.com/users/kennethreitz/orgs", "received_events_url": "https://api.github.com/users/kennethreitz/received_events", "repos_url": "https://api.github.com/users/kennethreitz/repos", "site_admin": false, "starred_url": "https://api.github.com/users/kennethreitz/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/kennethreitz/subscriptions", "type": "User", "url": "https://api.github.com/users/kennethreitz", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/2997/reactions" }
https://api.github.com/repos/psf/requests/issues/2997/timeline
null
completed
null
null
false
[ "Good spot! I suspect this might be the result of the 301 cache misbehaving somewhat. @sigmavirus24, does that sound right to you?\n", "Yikes, this is a nasty bug.\n", "I actually can't reproduce this, using the code available in our `master` branch.\n", "copy paste after me! ;)\n\n```\nhopa:/tmp\n$> git clon...
https://api.github.com/repos/psf/requests/issues/2996
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/2996/labels{/name}
https://api.github.com/repos/psf/requests/issues/2996/comments
https://api.github.com/repos/psf/requests/issues/2996/events
https://github.com/psf/requests/pull/2996
131,638,696
MDExOlB1bGxSZXF1ZXN0NTg0MjU5MzA=
2,996
Added tests module
{ "avatar_url": "https://avatars.githubusercontent.com/u/1236561?v=4", "events_url": "https://api.github.com/users/Stranger6667/events{/privacy}", "followers_url": "https://api.github.com/users/Stranger6667/followers", "following_url": "https://api.github.com/users/Stranger6667/following{/other_user}", "gists_url": "https://api.github.com/users/Stranger6667/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/Stranger6667", "id": 1236561, "login": "Stranger6667", "node_id": "MDQ6VXNlcjEyMzY1NjE=", "organizations_url": "https://api.github.com/users/Stranger6667/orgs", "received_events_url": "https://api.github.com/users/Stranger6667/received_events", "repos_url": "https://api.github.com/users/Stranger6667/repos", "site_admin": false, "starred_url": "https://api.github.com/users/Stranger6667/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Stranger6667/subscriptions", "type": "User", "url": "https://api.github.com/users/Stranger6667", "user_view_type": "public" }
[]
closed
true
null
[]
null
4
2016-02-05T13:01:41Z
2021-09-08T05:00:57Z
2016-02-05T20:54:25Z
CONTRIBUTOR
resolved
Hello, I want to propose some tests changes again :) What is done: 1. All tests are moved to`tests` module. 2. All tests related to `requests.utils` are separated in `tests.test_utils` module. 3. Fixtures `httpbin` and `httpbin_secure` were slightly refactored and moved to `tests.conftest` module. 4. `ThreadPool` was removed, because it was not used. 5. All compatibility code was moved to `tests.compat`. 6. More parametrization was added. I want to ask you if I'm going in the right way or not. Also I noticed, that `requests.utils` has ~45% coverage by unit tests, so, would you mind if I'll add more unit tests i this PR? If everything is ok
{ "avatar_url": "https://avatars.githubusercontent.com/u/119893?v=4", "events_url": "https://api.github.com/users/kennethreitz/events{/privacy}", "followers_url": "https://api.github.com/users/kennethreitz/followers", "following_url": "https://api.github.com/users/kennethreitz/following{/other_user}", "gists_url": "https://api.github.com/users/kennethreitz/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/kennethreitz", "id": 119893, "login": "kennethreitz", "node_id": "MDQ6VXNlcjExOTg5Mw==", "organizations_url": "https://api.github.com/users/kennethreitz/orgs", "received_events_url": "https://api.github.com/users/kennethreitz/received_events", "repos_url": "https://api.github.com/users/kennethreitz/repos", "site_admin": false, "starred_url": "https://api.github.com/users/kennethreitz/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/kennethreitz/subscriptions", "type": "User", "url": "https://api.github.com/users/kennethreitz", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/2996/reactions" }
https://api.github.com/repos/psf/requests/issues/2996/timeline
null
null
false
{ "diff_url": "https://github.com/psf/requests/pull/2996.diff", "html_url": "https://github.com/psf/requests/pull/2996", "merged_at": "2016-02-05T20:54:25Z", "patch_url": "https://github.com/psf/requests/pull/2996.patch", "url": "https://api.github.com/repos/psf/requests/pulls/2996" }
true
[ "Pinging @kennethreitz again for review on test code.\n\nThanks for this @Stranger6667!\n", "@Stranger6667 more tests for `utils` are more than welcome!\n", ":sparkles: :cake: :sparkles:\n", "Thank you, @Lukasa @kennethreitz ! :)\n" ]
https://api.github.com/repos/psf/requests/issues/2995
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/2995/labels{/name}
https://api.github.com/repos/psf/requests/issues/2995/comments
https://api.github.com/repos/psf/requests/issues/2995/events
https://github.com/psf/requests/issues/2995
131,486,326
MDU6SXNzdWUxMzE0ODYzMjY=
2,995
SSL Get Server Certificate Error
{ "avatar_url": "https://avatars.githubusercontent.com/u/10137?v=4", "events_url": "https://api.github.com/users/ghost/events{/privacy}", "followers_url": "https://api.github.com/users/ghost/followers", "following_url": "https://api.github.com/users/ghost/following{/other_user}", "gists_url": "https://api.github.com/users/ghost/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/ghost", "id": 10137, "login": "ghost", "node_id": "MDQ6VXNlcjEwMTM3", "organizations_url": "https://api.github.com/users/ghost/orgs", "received_events_url": "https://api.github.com/users/ghost/received_events", "repos_url": "https://api.github.com/users/ghost/repos", "site_admin": false, "starred_url": "https://api.github.com/users/ghost/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/ghost/subscriptions", "type": "User", "url": "https://api.github.com/users/ghost", "user_view_type": "public" }
[]
closed
true
null
[]
null
1
2016-02-04T22:02:03Z
2021-09-08T19:00:36Z
2016-02-04T22:05:37Z
NONE
resolved
I'm getting certificate verify failed errors for a few websites including Google. I've just tried with a new Digital Ocean droplet and still having the same issues so it's not just my server. I did the following, create a new Ubuntu 14.04 droplet on Digital Ocean. Installed python-pip (python and OpenSSL were already installed). Upgraded requests to the latest version (pip install requests --upgrade) and installed security (pip install requests[security]). Just to confirm, the droplet originally came with requests version 2.2.1, hence the reason for upgrading to 2.9.1. I also installed the pip modules: certifi and urllib3. Before upgrading requests and installing the other modules, I ran `import requests` and `requests.get("https://www.google.co.uk")`. This worked fine and returned 200. After upgrading and installing the other packages, I got the following: `Traceback (most recent call last): File "<stdin>", line 1, in <module> File "/usr/local/lib/python2.7/dist-packages/requests/api.py", line 67, in get return request('get', url, params=params, **kwargs) File "/usr/local/lib/python2.7/dist-packages/requests/api.py", line 53, in request return session.request(method=method, url=url, **kwargs) File "/usr/local/lib/python2.7/dist-packages/requests/sessions.py", line 468, in request resp = self.send(prep, **send_kwargs) File "/usr/local/lib/python2.7/dist-packages/requests/sessions.py", line 576, in send r = adapter.send(request, **kwargs) File "/usr/local/lib/python2.7/dist-packages/requests/adapters.py", line 447, in send raise SSLError(e, request=request) requests.exceptions.SSLError: [Errno 1] _ssl.c:510: error:14090086:SSL routines:SSL3_GET_SERVER_CERTIFICATE:certificate verify failed ` I tried it on https://github.com and it worked perfectly. I tried it on https://google.com and https://themoviedb.org and both has certificate verify failed errors even though they both have valid certificates.
{ "avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4", "events_url": "https://api.github.com/users/Lukasa/events{/privacy}", "followers_url": "https://api.github.com/users/Lukasa/followers", "following_url": "https://api.github.com/users/Lukasa/following{/other_user}", "gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/Lukasa", "id": 1382556, "login": "Lukasa", "node_id": "MDQ6VXNlcjEzODI1NTY=", "organizations_url": "https://api.github.com/users/Lukasa/orgs", "received_events_url": "https://api.github.com/users/Lukasa/received_events", "repos_url": "https://api.github.com/users/Lukasa/repos", "site_admin": false, "starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions", "type": "User", "url": "https://api.github.com/users/Lukasa", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/2995/reactions" }
https://api.github.com/repos/psf/requests/issues/2995/timeline
null
completed
null
null
false
[ "You'll need to read certifi/python-certifi#26.\n" ]
https://api.github.com/repos/psf/requests/issues/2994
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/2994/labels{/name}
https://api.github.com/repos/psf/requests/issues/2994/comments
https://api.github.com/repos/psf/requests/issues/2994/events
https://github.com/psf/requests/pull/2994
131,140,637
MDExOlB1bGxSZXF1ZXN0NTgxOTQ1MzE=
2,994
Fixed test execution.
{ "avatar_url": "https://avatars.githubusercontent.com/u/1236561?v=4", "events_url": "https://api.github.com/users/Stranger6667/events{/privacy}", "followers_url": "https://api.github.com/users/Stranger6667/followers", "following_url": "https://api.github.com/users/Stranger6667/following{/other_user}", "gists_url": "https://api.github.com/users/Stranger6667/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/Stranger6667", "id": 1236561, "login": "Stranger6667", "node_id": "MDQ6VXNlcjEyMzY1NjE=", "organizations_url": "https://api.github.com/users/Stranger6667/orgs", "received_events_url": "https://api.github.com/users/Stranger6667/received_events", "repos_url": "https://api.github.com/users/Stranger6667/repos", "site_admin": false, "starred_url": "https://api.github.com/users/Stranger6667/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Stranger6667/subscriptions", "type": "User", "url": "https://api.github.com/users/Stranger6667", "user_view_type": "public" }
[]
closed
true
null
[]
null
1
2016-02-03T20:20:08Z
2021-09-08T05:00:58Z
2016-02-03T20:53:08Z
CONTRIBUTOR
resolved
Now hook executes as expected.
{ "avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4", "events_url": "https://api.github.com/users/Lukasa/events{/privacy}", "followers_url": "https://api.github.com/users/Lukasa/followers", "following_url": "https://api.github.com/users/Lukasa/following{/other_user}", "gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/Lukasa", "id": 1382556, "login": "Lukasa", "node_id": "MDQ6VXNlcjEzODI1NTY=", "organizations_url": "https://api.github.com/users/Lukasa/orgs", "received_events_url": "https://api.github.com/users/Lukasa/received_events", "repos_url": "https://api.github.com/users/Lukasa/repos", "site_admin": false, "starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions", "type": "User", "url": "https://api.github.com/users/Lukasa", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/2994/reactions" }
https://api.github.com/repos/psf/requests/issues/2994/timeline
null
null
false
{ "diff_url": "https://github.com/psf/requests/pull/2994.diff", "html_url": "https://github.com/psf/requests/pull/2994", "merged_at": "2016-02-03T20:53:08Z", "patch_url": "https://github.com/psf/requests/pull/2994.patch", "url": "https://api.github.com/repos/psf/requests/pulls/2994" }
true
[ "This looks good to me, thanks!\n" ]
https://api.github.com/repos/psf/requests/issues/2993
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/2993/labels{/name}
https://api.github.com/repos/psf/requests/issues/2993/comments
https://api.github.com/repos/psf/requests/issues/2993/events
https://github.com/psf/requests/pull/2993
131,107,460
MDExOlB1bGxSZXF1ZXN0NTgxNzY5NzI=
2,993
Changes to support sending a complete response object when 407 errors…
{ "avatar_url": "https://avatars.githubusercontent.com/u/17050642?v=4", "events_url": "https://api.github.com/users/angelcaido19/events{/privacy}", "followers_url": "https://api.github.com/users/angelcaido19/followers", "following_url": "https://api.github.com/users/angelcaido19/following{/other_user}", "gists_url": "https://api.github.com/users/angelcaido19/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/angelcaido19", "id": 17050642, "login": "angelcaido19", "node_id": "MDQ6VXNlcjE3MDUwNjQy", "organizations_url": "https://api.github.com/users/angelcaido19/orgs", "received_events_url": "https://api.github.com/users/angelcaido19/received_events", "repos_url": "https://api.github.com/users/angelcaido19/repos", "site_admin": false, "starred_url": "https://api.github.com/users/angelcaido19/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/angelcaido19/subscriptions", "type": "User", "url": "https://api.github.com/users/angelcaido19", "user_view_type": "public" }
[]
closed
true
null
[]
null
3
2016-02-03T18:08:43Z
2021-09-08T05:00:58Z
2016-02-03T18:10:24Z
NONE
resolved
… is found while doing the CONNECT to proxy. Added a way to stablish a connection using connect over an already connected socket Trying to connect to a "https" web page using a proxy uses a "HTTP CONNECT" verb to tell the proxy that we want to connect to a https destination. With "basic authentication" the "CONNECT" is sent with the appropriate headers so the proxy can authenticate the request and do the request to the https web server. (That headers are setup by the requests library) With "NTLM" we use a plugin (requests-ntlm) that is set as a hook and it is called on every request response. For example: with HTTP, the requests library sends a "GET" to a web page, as a response we get a HTTP-407 that is handled by the plugin hook to do the NTLM negotiation and authentication In a HTTPS scenario, the first connection to the proxy is being done with the "CONNECT". At that time, requests does not set any authentication header (because it is handled by a plugin) and we get an 407 authentication Error. This Patch tries to avoid raising an exception on "Proxy Authentication" errors and it sends back a complete http response so it can be handled by the requests-ntlm plugin and reuse an already connected and authenticated socket to do the connection
{ "avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4", "events_url": "https://api.github.com/users/Lukasa/events{/privacy}", "followers_url": "https://api.github.com/users/Lukasa/followers", "following_url": "https://api.github.com/users/Lukasa/following{/other_user}", "gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/Lukasa", "id": 1382556, "login": "Lukasa", "node_id": "MDQ6VXNlcjEzODI1NTY=", "organizations_url": "https://api.github.com/users/Lukasa/orgs", "received_events_url": "https://api.github.com/users/Lukasa/received_events", "repos_url": "https://api.github.com/users/Lukasa/repos", "site_admin": false, "starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions", "type": "User", "url": "https://api.github.com/users/Lukasa", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/2993/reactions" }
https://api.github.com/repos/psf/requests/issues/2993/timeline
null
null
false
{ "diff_url": "https://github.com/psf/requests/pull/2993.diff", "html_url": "https://github.com/psf/requests/pull/2993", "merged_at": null, "patch_url": "https://github.com/psf/requests/pull/2993.patch", "url": "https://api.github.com/repos/psf/requests/pulls/2993" }
true
[ "@angelcaido19 Sorry, but this includes changes in urllib3. You'll need to propose this patch over there first, I'm afraid. =(\n", "@Lukasa Hey thanks. Help me with this: Is this \"https://github.com/shazow/urllib3\" the oficial urllib3 repo?\nThanks again!!\n", "Ah, sorry I didn't link it: yeah it is!\n" ]
https://api.github.com/repos/psf/requests/issues/2992
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/2992/labels{/name}
https://api.github.com/repos/psf/requests/issues/2992/comments
https://api.github.com/repos/psf/requests/issues/2992/events
https://github.com/psf/requests/pull/2992
131,049,763
MDExOlB1bGxSZXF1ZXN0NTgxNDg0Mjc=
2,992
Use TTLCache to cache proxy_bypass.
{ "avatar_url": "https://avatars.githubusercontent.com/u/2840571?v=4", "events_url": "https://api.github.com/users/lazywei/events{/privacy}", "followers_url": "https://api.github.com/users/lazywei/followers", "following_url": "https://api.github.com/users/lazywei/following{/other_user}", "gists_url": "https://api.github.com/users/lazywei/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/lazywei", "id": 2840571, "login": "lazywei", "node_id": "MDQ6VXNlcjI4NDA1NzE=", "organizations_url": "https://api.github.com/users/lazywei/orgs", "received_events_url": "https://api.github.com/users/lazywei/received_events", "repos_url": "https://api.github.com/users/lazywei/repos", "site_admin": false, "starred_url": "https://api.github.com/users/lazywei/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/lazywei/subscriptions", "type": "User", "url": "https://api.github.com/users/lazywei", "user_view_type": "public" }
[]
closed
true
null
[]
null
18
2016-02-03T14:59:15Z
2021-09-07T00:06:36Z
2017-02-10T17:19:47Z
NONE
resolved
As mentioned in https://github.com/kennethreitz/requests/issues/2988, we might leverage the LRU cache to speed up the `proxy_bypass`, which might cause unexpected delay.
{ "avatar_url": "https://avatars.githubusercontent.com/u/119893?v=4", "events_url": "https://api.github.com/users/kennethreitz/events{/privacy}", "followers_url": "https://api.github.com/users/kennethreitz/followers", "following_url": "https://api.github.com/users/kennethreitz/following{/other_user}", "gists_url": "https://api.github.com/users/kennethreitz/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/kennethreitz", "id": 119893, "login": "kennethreitz", "node_id": "MDQ6VXNlcjExOTg5Mw==", "organizations_url": "https://api.github.com/users/kennethreitz/orgs", "received_events_url": "https://api.github.com/users/kennethreitz/received_events", "repos_url": "https://api.github.com/users/kennethreitz/repos", "site_admin": false, "starred_url": "https://api.github.com/users/kennethreitz/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/kennethreitz/subscriptions", "type": "User", "url": "https://api.github.com/users/kennethreitz", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/2992/reactions" }
https://api.github.com/repos/psf/requests/issues/2992/timeline
null
null
false
{ "diff_url": "https://github.com/psf/requests/pull/2992.diff", "html_url": "https://github.com/psf/requests/pull/2992", "merged_at": null, "patch_url": "https://github.com/psf/requests/pull/2992.patch", "url": "https://api.github.com/repos/psf/requests/pulls/2992" }
true
[ "The bigger problem here is that `functools.lru_cache` is not available in Python 2. It should be fairly trivial to lift the code into a backport module and vendor it though.\n", "For general code review I'm not best placed to do it because I suggested the approach to begin with, so let's tag in @sigmavirus24 and...
https://api.github.com/repos/psf/requests/issues/2991
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/2991/labels{/name}
https://api.github.com/repos/psf/requests/issues/2991/comments
https://api.github.com/repos/psf/requests/issues/2991/events
https://github.com/psf/requests/pull/2991
130,677,837
MDExOlB1bGxSZXF1ZXN0NTc5ODM3MTk=
2,991
[WIP] Test suite refactoring
{ "avatar_url": "https://avatars.githubusercontent.com/u/1236561?v=4", "events_url": "https://api.github.com/users/Stranger6667/events{/privacy}", "followers_url": "https://api.github.com/users/Stranger6667/followers", "following_url": "https://api.github.com/users/Stranger6667/following{/other_user}", "gists_url": "https://api.github.com/users/Stranger6667/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/Stranger6667", "id": 1236561, "login": "Stranger6667", "node_id": "MDQ6VXNlcjEyMzY1NjE=", "organizations_url": "https://api.github.com/users/Stranger6667/orgs", "received_events_url": "https://api.github.com/users/Stranger6667/received_events", "repos_url": "https://api.github.com/users/Stranger6667/repos", "site_admin": false, "starred_url": "https://api.github.com/users/Stranger6667/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Stranger6667/subscriptions", "type": "User", "url": "https://api.github.com/users/Stranger6667", "user_view_type": "public" }
[]
closed
true
null
[]
null
5
2016-02-02T13:04:14Z
2021-09-08T05:00:58Z
2016-02-03T08:26:27Z
CONTRIBUTOR
resolved
Hello, I'd like to propose some refactorings for current test suite. First of all it is more about testing convenience, to make development process easier. Current changes: - Changed test running to setup.py. It allows to use some tuning on dependencies during test runs - Updated classifiers list. All tests run fine on Python 2.6 and PyPy. And almost all on Jython. I think it will not be a problem to deal with 2 failing tests, but will see. - Added config file for coverage. But I'm not sure about omitting "_/packages/_". - Added tox.ini to run tests against different Python versions locally. - Removed `unittest` from tests. It is not required for `py.test`. Also I've removed `_multiprocess_can_split_` because it is only related to `nose`. - Added some of py.test parametrization. - Replaced `assert False` with `pytest.fail`. - Fixed typo and added some minor improvements. Some thoughts and questions: - Coverage report shows, that code [here](https://github.com/kennethreitz/requests/compare/master...Stranger6667:tests-refactoring?expand=1#diff-56c2d754173a4a158ce8f445834c8fe8R616) is not executed. So, is there problem in hooks execution? - Split test module to some logically separated files. Current file is kind of huge. May be it will be better to have test suite in multiply files? - Python 3.2. Basically all tests pass on Python 3.2 / PyPy3 (based on Python 3.2). But `httpbin` dependency is not compatible with this Python version. But `requests` seems to be compatible. Any plans to keep compatibility with Python 3.2? May be rewrite some tests for Python 3.2 or something? - Jython. Most things are OK on Jython. Only 2 tests are failing - `TestRequests.test_pyopenssl_redirect` and `TestMorselToCookieExpires.test_expires_valid_str`. I don't know detail yet, but I hope, that it won't be a problem to fix it. Is it reasonable to run test suite against Jython? - Travis CI. I saw some CI-related lines in `Makefile`, but I don't see any info about in docs. Can you help me here? Also I can add some Travis CI config to run all configurations on it (including Jython) - Public coverage report. May I add some `codecov/coveralls` integration? Will it be helpful? It is not a complete lists and I'll be glad to hear what do you think about it. Also I'll be happy to write more tests here :) Thanks!
{ "avatar_url": "https://avatars.githubusercontent.com/u/119893?v=4", "events_url": "https://api.github.com/users/kennethreitz/events{/privacy}", "followers_url": "https://api.github.com/users/kennethreitz/followers", "following_url": "https://api.github.com/users/kennethreitz/following{/other_user}", "gists_url": "https://api.github.com/users/kennethreitz/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/kennethreitz", "id": 119893, "login": "kennethreitz", "node_id": "MDQ6VXNlcjExOTg5Mw==", "organizations_url": "https://api.github.com/users/kennethreitz/orgs", "received_events_url": "https://api.github.com/users/kennethreitz/received_events", "repos_url": "https://api.github.com/users/kennethreitz/repos", "site_admin": false, "starred_url": "https://api.github.com/users/kennethreitz/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/kennethreitz/subscriptions", "type": "User", "url": "https://api.github.com/users/kennethreitz", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/2991/reactions" }
https://api.github.com/repos/psf/requests/issues/2991/timeline
null
null
false
{ "diff_url": "https://github.com/psf/requests/pull/2991.diff", "html_url": "https://github.com/psf/requests/pull/2991", "merged_at": "2016-02-03T08:26:27Z", "patch_url": "https://github.com/psf/requests/pull/2991.patch", "url": "https://api.github.com/repos/psf/requests/pulls/2991" }
true
[ "Thanks for this! I'll handle answering some questions, but I know that @kennethreitz has got opinions about some of the changes you're making here so I'll let him weigh in to do the actual review work.\n\nTo your first question, I suspect that test is just poorly written.\n\nTo Python 3.2 support, requests explici...
https://api.github.com/repos/psf/requests/issues/2990
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/2990/labels{/name}
https://api.github.com/repos/psf/requests/issues/2990/comments
https://api.github.com/repos/psf/requests/issues/2990/events
https://github.com/psf/requests/issues/2990
130,479,500
MDU6SXNzdWUxMzA0Nzk1MDA=
2,990
Consider simplifying Session.resolve_redirects
{ "avatar_url": "https://avatars.githubusercontent.com/u/119893?v=4", "events_url": "https://api.github.com/users/kennethreitz/events{/privacy}", "followers_url": "https://api.github.com/users/kennethreitz/followers", "following_url": "https://api.github.com/users/kennethreitz/following{/other_user}", "gists_url": "https://api.github.com/users/kennethreitz/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/kennethreitz", "id": 119893, "login": "kennethreitz", "node_id": "MDQ6VXNlcjExOTg5Mw==", "organizations_url": "https://api.github.com/users/kennethreitz/orgs", "received_events_url": "https://api.github.com/users/kennethreitz/received_events", "repos_url": "https://api.github.com/users/kennethreitz/repos", "site_admin": false, "starred_url": "https://api.github.com/users/kennethreitz/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/kennethreitz/subscriptions", "type": "User", "url": "https://api.github.com/users/kennethreitz", "user_view_type": "public" }
[ { "color": "eb6420", "default": false, "description": null, "id": 44501256, "name": "Breaking API Change", "node_id": "MDU6TGFiZWw0NDUwMTI1Ng==", "url": "https://api.github.com/repos/psf/requests/labels/Breaking%20API%20Change" } ]
closed
true
null
[]
{ "closed_at": null, "closed_issues": 29, "created_at": "2013-11-17T11:29:34Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4", "events_url": "https://api.github.com/users/Lukasa/events{/privacy}", "followers_url": "https://api.github.com/users/Lukasa/followers", "following_url": "https://api.github.com/users/Lukasa/following{/other_user}", "gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/Lukasa", "id": 1382556, "login": "Lukasa", "node_id": "MDQ6VXNlcjEzODI1NTY=", "organizations_url": "https://api.github.com/users/Lukasa/orgs", "received_events_url": "https://api.github.com/users/Lukasa/received_events", "repos_url": "https://api.github.com/users/Lukasa/repos", "site_admin": false, "starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions", "type": "User", "url": "https://api.github.com/users/Lukasa", "user_view_type": "public" }, "description": null, "due_on": null, "html_url": "https://github.com/psf/requests/milestone/20", "id": 487518, "labels_url": "https://api.github.com/repos/psf/requests/milestones/20/labels", "node_id": "MDk6TWlsZXN0b25lNDg3NTE4", "number": 20, "open_issues": 12, "state": "open", "title": "3.0.0", "updated_at": "2024-05-19T18:43:00Z", "url": "https://api.github.com/repos/psf/requests/milestones/20" }
3
2016-02-01T20:52:02Z
2021-09-08T19:00:36Z
2016-02-02T06:44:36Z
CONTRIBUTOR
resolved
Currently, the `Session.resolve_redirects` method requires a `Response` to be passed in, as well as a `Request` (the response's originating request). When using this method directly, this is a bit confusing, especially considering that the desired/required `Request` is an attribute of the obviously required `Response`. There must have been some reason behind why I made this design decision, but I'm not seeing it currently.
{ "avatar_url": "https://avatars.githubusercontent.com/u/119893?v=4", "events_url": "https://api.github.com/users/kennethreitz/events{/privacy}", "followers_url": "https://api.github.com/users/kennethreitz/followers", "following_url": "https://api.github.com/users/kennethreitz/following{/other_user}", "gists_url": "https://api.github.com/users/kennethreitz/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/kennethreitz", "id": 119893, "login": "kennethreitz", "node_id": "MDQ6VXNlcjExOTg5Mw==", "organizations_url": "https://api.github.com/users/kennethreitz/orgs", "received_events_url": "https://api.github.com/users/kennethreitz/received_events", "repos_url": "https://api.github.com/users/kennethreitz/repos", "site_admin": false, "starred_url": "https://api.github.com/users/kennethreitz/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/kennethreitz/subscriptions", "type": "User", "url": "https://api.github.com/users/kennethreitz", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/2990/reactions" }
https://api.github.com/repos/psf/requests/issues/2990/timeline
null
completed
null
null
false
[ "Adding this to 3.0.0 because it would be a fairly significant breaking change. I was also never quite certain why that was required, but I'm not certain it is actively harmful either :/\n", "Yeah, this would be a 3.0.0 change. \n\n@sigmavirus24 I was just trying to use it directly while debugging an infinitely r...
https://api.github.com/repos/psf/requests/issues/2989
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/2989/labels{/name}
https://api.github.com/repos/psf/requests/issues/2989/comments
https://api.github.com/repos/psf/requests/issues/2989/events
https://github.com/psf/requests/issues/2989
130,462,974
MDU6SXNzdWUxMzA0NjI5NzQ=
2,989
Any idea if it would be possible to use something like oscrypto instead of the bundled SSL lib for HTTPS?
{ "avatar_url": "https://avatars.githubusercontent.com/u/10779010?v=4", "events_url": "https://api.github.com/users/danechitoaie/events{/privacy}", "followers_url": "https://api.github.com/users/danechitoaie/followers", "following_url": "https://api.github.com/users/danechitoaie/following{/other_user}", "gists_url": "https://api.github.com/users/danechitoaie/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/danechitoaie", "id": 10779010, "login": "danechitoaie", "node_id": "MDQ6VXNlcjEwNzc5MDEw", "organizations_url": "https://api.github.com/users/danechitoaie/orgs", "received_events_url": "https://api.github.com/users/danechitoaie/received_events", "repos_url": "https://api.github.com/users/danechitoaie/repos", "site_admin": false, "starred_url": "https://api.github.com/users/danechitoaie/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/danechitoaie/subscriptions", "type": "User", "url": "https://api.github.com/users/danechitoaie", "user_view_type": "public" }
[]
closed
true
null
[]
null
4
2016-02-01T19:46:29Z
2021-09-08T19:00:34Z
2016-02-10T08:47:09Z
NONE
resolved
Any idea if it would be possible to use something like [oscrypto](https://github.com/wbond/oscrypto) instead of the bundled SSL lib for HTTPS? I need to use this in a Sublime Text 3 plugin where the bundled version of SSL is pretty old and I can't connect to some hosts supporting only TLS1.2. Using the above should fix this issue. Any idea how this can be used for SSL?
{ "avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4", "events_url": "https://api.github.com/users/Lukasa/events{/privacy}", "followers_url": "https://api.github.com/users/Lukasa/followers", "following_url": "https://api.github.com/users/Lukasa/following{/other_user}", "gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/Lukasa", "id": 1382556, "login": "Lukasa", "node_id": "MDQ6VXNlcjEzODI1NTY=", "organizations_url": "https://api.github.com/users/Lukasa/orgs", "received_events_url": "https://api.github.com/users/Lukasa/received_events", "repos_url": "https://api.github.com/users/Lukasa/repos", "site_admin": false, "starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions", "type": "User", "url": "https://api.github.com/users/Lukasa", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/2989/reactions" }
https://api.github.com/repos/psf/requests/issues/2989/timeline
null
completed
null
null
false
[ "@danechitoaie Let's split this into two questions.\n\nFirst, the problem with OpenSSL. If you can use a third-party library, you should be able to install `PyOpenSSL`, `ndg-httpsclient`, and `pyasn1`. If the `cryptography` library that backs PyOpenSSL is linked against a newer version of OpenSSL than the bundled o...
https://api.github.com/repos/psf/requests/issues/2988
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/2988/labels{/name}
https://api.github.com/repos/psf/requests/issues/2988/comments
https://api.github.com/repos/psf/requests/issues/2988/events
https://github.com/psf/requests/issues/2988
130,289,799
MDU6SXNzdWUxMzAyODk3OTk=
2,988
Proxy bypass detection could add delay of ~4.5 seconds to each request
{ "avatar_url": "https://avatars.githubusercontent.com/u/238652?v=4", "events_url": "https://api.github.com/users/schlamar/events{/privacy}", "followers_url": "https://api.github.com/users/schlamar/followers", "following_url": "https://api.github.com/users/schlamar/following{/other_user}", "gists_url": "https://api.github.com/users/schlamar/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/schlamar", "id": 238652, "login": "schlamar", "node_id": "MDQ6VXNlcjIzODY1Mg==", "organizations_url": "https://api.github.com/users/schlamar/orgs", "received_events_url": "https://api.github.com/users/schlamar/received_events", "repos_url": "https://api.github.com/users/schlamar/repos", "site_admin": false, "starred_url": "https://api.github.com/users/schlamar/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/schlamar/subscriptions", "type": "User", "url": "https://api.github.com/users/schlamar", "user_view_type": "public" }
[ { "color": "02e10c", "default": false, "description": null, "id": 76800, "name": "Feature Request", "node_id": "MDU6TGFiZWw3NjgwMA==", "url": "https://api.github.com/repos/psf/requests/labels/Feature%20Request" }, { "color": "0b02e1", "default": false, "description": null...
closed
true
null
[]
null
27
2016-02-01T08:16:17Z
2021-09-08T11:00:35Z
2017-03-04T14:53:00Z
CONTRIBUTOR
resolved
Requests uses `urlib.proxy_bypass` to check if the proxy should be bypassed. This uses `socket.gethostbyaddr` to check if the provided IP matches a hostname entered in the proxy bypass list. In some cases, `gethostbyaddr` takes up to 4.5 seconds on Windows (e.g. when the IP is found but the primary DNS doesn't recognize it). Currently, the proxy bypass detection is done for _every_ request, making it pretty unusable when the conditions are met where `gethostbyaddr` is this slow. A reasonable solution might be caching the results from `urlib.proxy_bypass`.
{ "avatar_url": "https://avatars.githubusercontent.com/u/240830?v=4", "events_url": "https://api.github.com/users/sigmavirus24/events{/privacy}", "followers_url": "https://api.github.com/users/sigmavirus24/followers", "following_url": "https://api.github.com/users/sigmavirus24/following{/other_user}", "gists_url": "https://api.github.com/users/sigmavirus24/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/sigmavirus24", "id": 240830, "login": "sigmavirus24", "node_id": "MDQ6VXNlcjI0MDgzMA==", "organizations_url": "https://api.github.com/users/sigmavirus24/orgs", "received_events_url": "https://api.github.com/users/sigmavirus24/received_events", "repos_url": "https://api.github.com/users/sigmavirus24/repos", "site_admin": false, "starred_url": "https://api.github.com/users/sigmavirus24/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sigmavirus24/subscriptions", "type": "User", "url": "https://api.github.com/users/sigmavirus24", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/2988/reactions" }
https://api.github.com/repos/psf/requests/issues/2988/timeline
null
completed
null
null
false
[ "Yeah, 4.5 seconds is probably too long.\n\nThe concern with caching the result is that the resolver doesn't give enough information for us to invalidate that cache appropriately, but we will from time to time want to invalidate it (so that long running processes don't end up so broken that they need a restart).\n\...
https://api.github.com/repos/psf/requests/issues/2987
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/2987/labels{/name}
https://api.github.com/repos/psf/requests/issues/2987/comments
https://api.github.com/repos/psf/requests/issues/2987/events
https://github.com/psf/requests/issues/2987
130,101,833
MDU6SXNzdWUxMzAxMDE4MzM=
2,987
Enhanced form-data serialization
{ "avatar_url": "https://avatars.githubusercontent.com/u/119893?v=4", "events_url": "https://api.github.com/users/kennethreitz/events{/privacy}", "followers_url": "https://api.github.com/users/kennethreitz/followers", "following_url": "https://api.github.com/users/kennethreitz/following{/other_user}", "gists_url": "https://api.github.com/users/kennethreitz/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/kennethreitz", "id": 119893, "login": "kennethreitz", "node_id": "MDQ6VXNlcjExOTg5Mw==", "organizations_url": "https://api.github.com/users/kennethreitz/orgs", "received_events_url": "https://api.github.com/users/kennethreitz/received_events", "repos_url": "https://api.github.com/users/kennethreitz/repos", "site_admin": false, "starred_url": "https://api.github.com/users/kennethreitz/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/kennethreitz/subscriptions", "type": "User", "url": "https://api.github.com/users/kennethreitz", "user_view_type": "public" }
[]
closed
false
{ "avatar_url": "https://avatars.githubusercontent.com/u/240830?v=4", "events_url": "https://api.github.com/users/sigmavirus24/events{/privacy}", "followers_url": "https://api.github.com/users/sigmavirus24/followers", "following_url": "https://api.github.com/users/sigmavirus24/following{/other_user}", "gists_url": "https://api.github.com/users/sigmavirus24/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/sigmavirus24", "id": 240830, "login": "sigmavirus24", "node_id": "MDQ6VXNlcjI0MDgzMA==", "organizations_url": "https://api.github.com/users/sigmavirus24/orgs", "received_events_url": "https://api.github.com/users/sigmavirus24/received_events", "repos_url": "https://api.github.com/users/sigmavirus24/repos", "site_admin": false, "starred_url": "https://api.github.com/users/sigmavirus24/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sigmavirus24/subscriptions", "type": "User", "url": "https://api.github.com/users/sigmavirus24", "user_view_type": "public" }
[ { "avatar_url": "https://avatars.githubusercontent.com/u/240830?v=4", "events_url": "https://api.github.com/users/sigmavirus24/events{/privacy}", "followers_url": "https://api.github.com/users/sigmavirus24/followers", "following_url": "https://api.github.com/users/sigmavirus24/following{/other_user}...
{ "closed_at": null, "closed_issues": 29, "created_at": "2024-05-19T18:29:04Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/18519037?v=4", "events_url": "https://api.github.com/users/sethmlarson/events{/privacy}", "followers_url": "https://api.github.com/users/sethmlarson/followers", "following_url": "https://api.github.com/users/sethmlarson/following{/other_user}", "gists_url": "https://api.github.com/users/sethmlarson/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/sethmlarson", "id": 18519037, "login": "sethmlarson", "node_id": "MDQ6VXNlcjE4NTE5MDM3", "organizations_url": "https://api.github.com/users/sethmlarson/orgs", "received_events_url": "https://api.github.com/users/sethmlarson/received_events", "repos_url": "https://api.github.com/users/sethmlarson/repos", "site_admin": false, "starred_url": "https://api.github.com/users/sethmlarson/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sethmlarson/subscriptions", "type": "User", "url": "https://api.github.com/users/sethmlarson", "user_view_type": "public" }, "description": "", "due_on": null, "html_url": "https://github.com/psf/requests/milestone/34", "id": 11073254, "labels_url": "https://api.github.com/repos/psf/requests/milestones/34/labels", "node_id": "MI_kwDOABTKOs4AqPbm", "number": 34, "open_issues": 0, "state": "open", "title": "Bankruptcy", "updated_at": "2024-05-20T14:37:16Z", "url": "https://api.github.com/repos/psf/requests/milestones/34" }
8
2016-01-31T08:41:47Z
2024-05-20T14:36:28Z
2024-05-20T14:36:27Z
CONTRIBUTOR
null
Would be great to include the functionality of `requests_toolbelt.utils.formdata.urlencode` in Requests. http://toolbelt.readthedocs.org/en/latest/formdata.html Thoughts? /cc @Lukasa @sigmavirus24
{ "avatar_url": "https://avatars.githubusercontent.com/u/18519037?v=4", "events_url": "https://api.github.com/users/sethmlarson/events{/privacy}", "followers_url": "https://api.github.com/users/sethmlarson/followers", "following_url": "https://api.github.com/users/sethmlarson/following{/other_user}", "gists_url": "https://api.github.com/users/sethmlarson/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/sethmlarson", "id": 18519037, "login": "sethmlarson", "node_id": "MDQ6VXNlcjE4NTE5MDM3", "organizations_url": "https://api.github.com/users/sethmlarson/orgs", "received_events_url": "https://api.github.com/users/sethmlarson/received_events", "repos_url": "https://api.github.com/users/sethmlarson/repos", "site_admin": false, "starred_url": "https://api.github.com/users/sethmlarson/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sethmlarson/subscriptions", "type": "User", "url": "https://api.github.com/users/sethmlarson", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/2987/reactions" }
https://api.github.com/repos/psf/requests/issues/2987/timeline
null
completed
null
null
false
[ "No objection from me, but the tool belt is @sigmavirus24's baby so he may have a stronger position,\n", "To be clear, I mean making that the default behavior. \n", "I think I'm the only contributing author of that code and both requests and the toolbelt are Apache-2.0.\n\nIf we want to move that into requests ...
https://api.github.com/repos/psf/requests/issues/2986
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/2986/labels{/name}
https://api.github.com/repos/psf/requests/issues/2986/comments
https://api.github.com/repos/psf/requests/issues/2986/events
https://github.com/psf/requests/pull/2986
130,024,126
MDExOlB1bGxSZXF1ZXN0NTc3NDczMDM=
2,986
Fix syntax error
{ "avatar_url": "https://avatars.githubusercontent.com/u/837573?v=4", "events_url": "https://api.github.com/users/untitaker/events{/privacy}", "followers_url": "https://api.github.com/users/untitaker/followers", "following_url": "https://api.github.com/users/untitaker/following{/other_user}", "gists_url": "https://api.github.com/users/untitaker/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/untitaker", "id": 837573, "login": "untitaker", "node_id": "MDQ6VXNlcjgzNzU3Mw==", "organizations_url": "https://api.github.com/users/untitaker/orgs", "received_events_url": "https://api.github.com/users/untitaker/received_events", "repos_url": "https://api.github.com/users/untitaker/repos", "site_admin": false, "starred_url": "https://api.github.com/users/untitaker/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/untitaker/subscriptions", "type": "User", "url": "https://api.github.com/users/untitaker", "user_view_type": "public" }
[]
closed
true
null
[]
null
2
2016-01-30T18:56:10Z
2021-09-08T05:00:59Z
2016-01-30T19:14:20Z
CONTRIBUTOR
resolved
null
{ "avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4", "events_url": "https://api.github.com/users/Lukasa/events{/privacy}", "followers_url": "https://api.github.com/users/Lukasa/followers", "following_url": "https://api.github.com/users/Lukasa/following{/other_user}", "gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/Lukasa", "id": 1382556, "login": "Lukasa", "node_id": "MDQ6VXNlcjEzODI1NTY=", "organizations_url": "https://api.github.com/users/Lukasa/orgs", "received_events_url": "https://api.github.com/users/Lukasa/received_events", "repos_url": "https://api.github.com/users/Lukasa/repos", "site_admin": false, "starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions", "type": "User", "url": "https://api.github.com/users/Lukasa", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/2986/reactions" }
https://api.github.com/repos/psf/requests/issues/2986/timeline
null
null
false
{ "diff_url": "https://github.com/psf/requests/pull/2986.diff", "html_url": "https://github.com/psf/requests/pull/2986", "merged_at": "2016-01-30T19:14:20Z", "patch_url": "https://github.com/psf/requests/pull/2986.patch", "url": "https://api.github.com/repos/psf/requests/pulls/2986" }
true
[ "Thanks @untitaker!\n", "oops\n" ]
https://api.github.com/repos/psf/requests/issues/2985
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/2985/labels{/name}
https://api.github.com/repos/psf/requests/issues/2985/comments
https://api.github.com/repos/psf/requests/issues/2985/events
https://github.com/psf/requests/pull/2985
129,987,754
MDExOlB1bGxSZXF1ZXN0NTc3NDAwNjg=
2,985
Fixed markup for/rendering of list in section "Custom Headers".
{ "avatar_url": "https://avatars.githubusercontent.com/u/95277?v=4", "events_url": "https://api.github.com/users/homeworkprod/events{/privacy}", "followers_url": "https://api.github.com/users/homeworkprod/followers", "following_url": "https://api.github.com/users/homeworkprod/following{/other_user}", "gists_url": "https://api.github.com/users/homeworkprod/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/homeworkprod", "id": 95277, "login": "homeworkprod", "node_id": "MDQ6VXNlcjk1Mjc3", "organizations_url": "https://api.github.com/users/homeworkprod/orgs", "received_events_url": "https://api.github.com/users/homeworkprod/received_events", "repos_url": "https://api.github.com/users/homeworkprod/repos", "site_admin": false, "starred_url": "https://api.github.com/users/homeworkprod/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/homeworkprod/subscriptions", "type": "User", "url": "https://api.github.com/users/homeworkprod", "user_view_type": "public" }
[]
closed
true
null
[]
null
2
2016-01-30T13:45:23Z
2021-09-08T05:01:01Z
2016-01-30T14:00:14Z
CONTRIBUTOR
resolved
{ "avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4", "events_url": "https://api.github.com/users/Lukasa/events{/privacy}", "followers_url": "https://api.github.com/users/Lukasa/followers", "following_url": "https://api.github.com/users/Lukasa/following{/other_user}", "gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/Lukasa", "id": 1382556, "login": "Lukasa", "node_id": "MDQ6VXNlcjEzODI1NTY=", "organizations_url": "https://api.github.com/users/Lukasa/orgs", "received_events_url": "https://api.github.com/users/Lukasa/received_events", "repos_url": "https://api.github.com/users/Lukasa/repos", "site_admin": false, "starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions", "type": "User", "url": "https://api.github.com/users/Lukasa", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/2985/reactions" }
https://api.github.com/repos/psf/requests/issues/2985/timeline
null
null
false
{ "diff_url": "https://github.com/psf/requests/pull/2985.diff", "html_url": "https://github.com/psf/requests/pull/2985", "merged_at": "2016-01-30T14:00:14Z", "patch_url": "https://github.com/psf/requests/pull/2985.patch", "url": "https://api.github.com/repos/psf/requests/pulls/2985" }
true
[ "Thanks! :sparkles: :cake: :sparkles:\n", "You're welcome. Glad I could help :)\n" ]
https://api.github.com/repos/psf/requests/issues/2984
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/2984/labels{/name}
https://api.github.com/repos/psf/requests/issues/2984/comments
https://api.github.com/repos/psf/requests/issues/2984/events
https://github.com/psf/requests/pull/2984
129,912,566
MDExOlB1bGxSZXF1ZXN0NTc3MTg0MjE=
2,984
Remove int type on HTTPAdapter's max_retries argument doc
{ "avatar_url": "https://avatars.githubusercontent.com/u/46059?v=4", "events_url": "https://api.github.com/users/carsonyl/events{/privacy}", "followers_url": "https://api.github.com/users/carsonyl/followers", "following_url": "https://api.github.com/users/carsonyl/following{/other_user}", "gists_url": "https://api.github.com/users/carsonyl/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/carsonyl", "id": 46059, "login": "carsonyl", "node_id": "MDQ6VXNlcjQ2MDU5", "organizations_url": "https://api.github.com/users/carsonyl/orgs", "received_events_url": "https://api.github.com/users/carsonyl/received_events", "repos_url": "https://api.github.com/users/carsonyl/repos", "site_admin": false, "starred_url": "https://api.github.com/users/carsonyl/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/carsonyl/subscriptions", "type": "User", "url": "https://api.github.com/users/carsonyl", "user_view_type": "public" }
[]
closed
true
null
[]
null
1
2016-01-29T23:41:23Z
2021-09-08T05:00:59Z
2016-01-30T02:59:04Z
CONTRIBUTOR
resolved
The argument description says `max_retries` can be an int, or a `urllib3.util.Retry` object. However, the type declared in the doc restricts it to int only. Passing a Retry object causes a warning in PyCharm code inspection. The behaviour described for `max_retries` is accurate: HTTPAdapter passes `max_retries` to `Retry.from_int()`, which just returns the input if `max_retries` is a Retry object.
{ "avatar_url": "https://avatars.githubusercontent.com/u/119893?v=4", "events_url": "https://api.github.com/users/kennethreitz/events{/privacy}", "followers_url": "https://api.github.com/users/kennethreitz/followers", "following_url": "https://api.github.com/users/kennethreitz/following{/other_user}", "gists_url": "https://api.github.com/users/kennethreitz/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/kennethreitz", "id": 119893, "login": "kennethreitz", "node_id": "MDQ6VXNlcjExOTg5Mw==", "organizations_url": "https://api.github.com/users/kennethreitz/orgs", "received_events_url": "https://api.github.com/users/kennethreitz/received_events", "repos_url": "https://api.github.com/users/kennethreitz/repos", "site_admin": false, "starred_url": "https://api.github.com/users/kennethreitz/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/kennethreitz/subscriptions", "type": "User", "url": "https://api.github.com/users/kennethreitz", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/2984/reactions" }
https://api.github.com/repos/psf/requests/issues/2984/timeline
null
null
false
{ "diff_url": "https://github.com/psf/requests/pull/2984.diff", "html_url": "https://github.com/psf/requests/pull/2984", "merged_at": "2016-01-30T02:59:04Z", "patch_url": "https://github.com/psf/requests/pull/2984.patch", "url": "https://api.github.com/repos/psf/requests/pulls/2984" }
true
[ "Thanks!\n" ]
https://api.github.com/repos/psf/requests/issues/2983
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/2983/labels{/name}
https://api.github.com/repos/psf/requests/issues/2983/comments
https://api.github.com/repos/psf/requests/issues/2983/events
https://github.com/psf/requests/issues/2983
129,640,029
MDU6SXNzdWUxMjk2NDAwMjk=
2,983
First line of uploading files disappears.
{ "avatar_url": "https://avatars.githubusercontent.com/u/11981676?v=4", "events_url": "https://api.github.com/users/amdei/events{/privacy}", "followers_url": "https://api.github.com/users/amdei/followers", "following_url": "https://api.github.com/users/amdei/following{/other_user}", "gists_url": "https://api.github.com/users/amdei/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/amdei", "id": 11981676, "login": "amdei", "node_id": "MDQ6VXNlcjExOTgxNjc2", "organizations_url": "https://api.github.com/users/amdei/orgs", "received_events_url": "https://api.github.com/users/amdei/received_events", "repos_url": "https://api.github.com/users/amdei/repos", "site_admin": false, "starred_url": "https://api.github.com/users/amdei/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/amdei/subscriptions", "type": "User", "url": "https://api.github.com/users/amdei", "user_view_type": "public" }
[]
closed
true
null
[]
null
3
2016-01-29T01:56:38Z
2021-09-08T19:00:37Z
2016-01-29T17:24:35Z
NONE
resolved
requests 2.9.1 Executing of this code (from samples in documentation): `import requests url = 'http://192.168.88.164:8000/' files = {'file': ('conf.txt', 'some, data,to send\r\nnanother,row,to,send\r\nyet another,row,to,send\r\n')} r = requests.post(url, files=files) print r.text` Results in correctly uploaded file, but without first line. I.e. part 'some, data,to send\r\n' is missed. Same with actoual file upload: `import requests url = 'http://192.168.88.164:8000/' files = {'file': ('conf.txt', open('conf.txt', 'rb'))} r = requests.post(url, files=files) print r.text` First line disappears from uploaded content. The same file uploaded to the same server with curl: `curl -v -X POST -F file=@conf.txt http://192.168.88.164:8000` do not such an issue. Issue seems to be in incorrect encoding - extra \r\n where missed somewhere.
{ "avatar_url": "https://avatars.githubusercontent.com/u/240830?v=4", "events_url": "https://api.github.com/users/sigmavirus24/events{/privacy}", "followers_url": "https://api.github.com/users/sigmavirus24/followers", "following_url": "https://api.github.com/users/sigmavirus24/following{/other_user}", "gists_url": "https://api.github.com/users/sigmavirus24/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/sigmavirus24", "id": 240830, "login": "sigmavirus24", "node_id": "MDQ6VXNlcjI0MDgzMA==", "organizations_url": "https://api.github.com/users/sigmavirus24/orgs", "received_events_url": "https://api.github.com/users/sigmavirus24/received_events", "repos_url": "https://api.github.com/users/sigmavirus24/repos", "site_admin": false, "starred_url": "https://api.github.com/users/sigmavirus24/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sigmavirus24/subscriptions", "type": "User", "url": "https://api.github.com/users/sigmavirus24", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/2983/reactions" }
https://api.github.com/repos/psf/requests/issues/2983/timeline
null
completed
null
null
false
[ "Sorry, but I can't reproduce this using a publicly available website. If I run this code:\n\n``` python\nimport requests\nurl = 'http://http2bin.org/post'\nfiles = {'file': ('conf.txt', 'some, data,to send\\r\\nnanother,row,to,send\\r\\nyet another,row,to,send\\r\\n')}\nr = requests.post(url, files=files)\nprint r...
https://api.github.com/repos/psf/requests/issues/2982
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/2982/labels{/name}
https://api.github.com/repos/psf/requests/issues/2982/comments
https://api.github.com/repos/psf/requests/issues/2982/events
https://github.com/psf/requests/issues/2982
129,265,819
MDU6SXNzdWUxMjkyNjU4MTk=
2,982
Error 404 for url, that contains relative path parts
{ "avatar_url": "https://avatars.githubusercontent.com/u/3865300?v=4", "events_url": "https://api.github.com/users/Lol4t0/events{/privacy}", "followers_url": "https://api.github.com/users/Lol4t0/followers", "following_url": "https://api.github.com/users/Lol4t0/following{/other_user}", "gists_url": "https://api.github.com/users/Lol4t0/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/Lol4t0", "id": 3865300, "login": "Lol4t0", "node_id": "MDQ6VXNlcjM4NjUzMDA=", "organizations_url": "https://api.github.com/users/Lol4t0/orgs", "received_events_url": "https://api.github.com/users/Lol4t0/received_events", "repos_url": "https://api.github.com/users/Lol4t0/repos", "site_admin": false, "starred_url": "https://api.github.com/users/Lol4t0/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Lol4t0/subscriptions", "type": "User", "url": "https://api.github.com/users/Lol4t0", "user_view_type": "public" }
[ { "color": "eb6420", "default": false, "description": null, "id": 44501256, "name": "Breaking API Change", "node_id": "MDU6TGFiZWw0NDUwMTI1Ng==", "url": "https://api.github.com/repos/psf/requests/labels/Breaking%20API%20Change" } ]
closed
false
null
[]
{ "closed_at": null, "closed_issues": 29, "created_at": "2024-05-19T18:29:04Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/18519037?v=4", "events_url": "https://api.github.com/users/sethmlarson/events{/privacy}", "followers_url": "https://api.github.com/users/sethmlarson/followers", "following_url": "https://api.github.com/users/sethmlarson/following{/other_user}", "gists_url": "https://api.github.com/users/sethmlarson/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/sethmlarson", "id": 18519037, "login": "sethmlarson", "node_id": "MDQ6VXNlcjE4NTE5MDM3", "organizations_url": "https://api.github.com/users/sethmlarson/orgs", "received_events_url": "https://api.github.com/users/sethmlarson/received_events", "repos_url": "https://api.github.com/users/sethmlarson/repos", "site_admin": false, "starred_url": "https://api.github.com/users/sethmlarson/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sethmlarson/subscriptions", "type": "User", "url": "https://api.github.com/users/sethmlarson", "user_view_type": "public" }, "description": "", "due_on": null, "html_url": "https://github.com/psf/requests/milestone/34", "id": 11073254, "labels_url": "https://api.github.com/repos/psf/requests/milestones/34/labels", "node_id": "MI_kwDOABTKOs4AqPbm", "number": 34, "open_issues": 0, "state": "open", "title": "Bankruptcy", "updated_at": "2024-05-20T14:37:16Z", "url": "https://api.github.com/repos/psf/requests/milestones/34" }
39
2016-01-27T20:55:05Z
2024-05-20T14:34:59Z
2024-05-20T14:34:59Z
NONE
null
Browser & other tools seem to ignore trailing dot in the URL. Unfortunately `requests` does not. Compare ``` $ curl -s https://github.com/. -o /dev/null -w "%{http_code}"; echo 200 ``` With ``` $ python -c 'import requests; print(requests.get("https://github.com/.").status_code)' 404 ```
{ "avatar_url": "https://avatars.githubusercontent.com/u/18519037?v=4", "events_url": "https://api.github.com/users/sethmlarson/events{/privacy}", "followers_url": "https://api.github.com/users/sethmlarson/followers", "following_url": "https://api.github.com/users/sethmlarson/following{/other_user}", "gists_url": "https://api.github.com/users/sethmlarson/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/sethmlarson", "id": 18519037, "login": "sethmlarson", "node_id": "MDQ6VXNlcjE4NTE5MDM3", "organizations_url": "https://api.github.com/users/sethmlarson/orgs", "received_events_url": "https://api.github.com/users/sethmlarson/received_events", "repos_url": "https://api.github.com/users/sethmlarson/repos", "site_admin": false, "starred_url": "https://api.github.com/users/sethmlarson/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sethmlarson/subscriptions", "type": "User", "url": "https://api.github.com/users/sethmlarson", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/2982/reactions" }
https://api.github.com/repos/psf/requests/issues/2982/timeline
null
completed
null
null
false
[ "requests/api.py - request()\n\n```\nwith sessions.Session() as session:\n return session.request(method=method, url=url.rstrip(\".\"), **kwargs)\n```\n\nNot sure if this matches any style guides, but should help solve this issue\n", "@TetraEtc that's overly general. While curl and browsers detect the `.` as t...
https://api.github.com/repos/psf/requests/issues/2981
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/2981/labels{/name}
https://api.github.com/repos/psf/requests/issues/2981/comments
https://api.github.com/repos/psf/requests/issues/2981/events
https://github.com/psf/requests/pull/2981
129,122,256
MDExOlB1bGxSZXF1ZXN0NTczNDk4NzA=
2,981
Warn about encrypted keys in the docs.
{ "avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4", "events_url": "https://api.github.com/users/Lukasa/events{/privacy}", "followers_url": "https://api.github.com/users/Lukasa/followers", "following_url": "https://api.github.com/users/Lukasa/following{/other_user}", "gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/Lukasa", "id": 1382556, "login": "Lukasa", "node_id": "MDQ6VXNlcjEzODI1NTY=", "organizations_url": "https://api.github.com/users/Lukasa/orgs", "received_events_url": "https://api.github.com/users/Lukasa/received_events", "repos_url": "https://api.github.com/users/Lukasa/repos", "site_admin": false, "starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions", "type": "User", "url": "https://api.github.com/users/Lukasa", "user_view_type": "public" }
[]
closed
true
null
[]
null
1
2016-01-27T11:57:13Z
2021-09-08T05:01:03Z
2016-01-27T16:19:27Z
MEMBER
resolved
We don't support them!
{ "avatar_url": "https://avatars.githubusercontent.com/u/240830?v=4", "events_url": "https://api.github.com/users/sigmavirus24/events{/privacy}", "followers_url": "https://api.github.com/users/sigmavirus24/followers", "following_url": "https://api.github.com/users/sigmavirus24/following{/other_user}", "gists_url": "https://api.github.com/users/sigmavirus24/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/sigmavirus24", "id": 240830, "login": "sigmavirus24", "node_id": "MDQ6VXNlcjI0MDgzMA==", "organizations_url": "https://api.github.com/users/sigmavirus24/orgs", "received_events_url": "https://api.github.com/users/sigmavirus24/received_events", "repos_url": "https://api.github.com/users/sigmavirus24/repos", "site_admin": false, "starred_url": "https://api.github.com/users/sigmavirus24/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sigmavirus24/subscriptions", "type": "User", "url": "https://api.github.com/users/sigmavirus24", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/2981/reactions" }
https://api.github.com/repos/psf/requests/issues/2981/timeline
null
null
false
{ "diff_url": "https://github.com/psf/requests/pull/2981.diff", "html_url": "https://github.com/psf/requests/pull/2981", "merged_at": "2016-01-27T16:19:27Z", "patch_url": "https://github.com/psf/requests/pull/2981.patch", "url": "https://api.github.com/repos/psf/requests/pulls/2981" }
true
[ "See also #2312.\n" ]
https://api.github.com/repos/psf/requests/issues/2980
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/2980/labels{/name}
https://api.github.com/repos/psf/requests/issues/2980/comments
https://api.github.com/repos/psf/requests/issues/2980/events
https://github.com/psf/requests/issues/2980
128,481,273
MDU6SXNzdWUxMjg0ODEyNzM=
2,980
request question
{ "avatar_url": "https://avatars.githubusercontent.com/u/3785409?v=4", "events_url": "https://api.github.com/users/rfyiamcool/events{/privacy}", "followers_url": "https://api.github.com/users/rfyiamcool/followers", "following_url": "https://api.github.com/users/rfyiamcool/following{/other_user}", "gists_url": "https://api.github.com/users/rfyiamcool/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/rfyiamcool", "id": 3785409, "login": "rfyiamcool", "node_id": "MDQ6VXNlcjM3ODU0MDk=", "organizations_url": "https://api.github.com/users/rfyiamcool/orgs", "received_events_url": "https://api.github.com/users/rfyiamcool/received_events", "repos_url": "https://api.github.com/users/rfyiamcool/repos", "site_admin": false, "starred_url": "https://api.github.com/users/rfyiamcool/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/rfyiamcool/subscriptions", "type": "User", "url": "https://api.github.com/users/rfyiamcool", "user_view_type": "public" }
[]
closed
true
null
[]
null
1
2016-01-25T07:46:14Z
2021-09-08T19:00:38Z
2016-01-25T08:06:50Z
NONE
resolved
requests.get('xxx', params={"id":111}) requests.get('xxx', params=json.dumps{"id":111}) These two are the same ?
{ "avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4", "events_url": "https://api.github.com/users/Lukasa/events{/privacy}", "followers_url": "https://api.github.com/users/Lukasa/followers", "following_url": "https://api.github.com/users/Lukasa/following{/other_user}", "gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/Lukasa", "id": 1382556, "login": "Lukasa", "node_id": "MDQ6VXNlcjEzODI1NTY=", "organizations_url": "https://api.github.com/users/Lukasa/orgs", "received_events_url": "https://api.github.com/users/Lukasa/received_events", "repos_url": "https://api.github.com/users/Lukasa/repos", "site_admin": false, "starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions", "type": "User", "url": "https://api.github.com/users/Lukasa", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/2980/reactions" }
https://api.github.com/repos/psf/requests/issues/2980/timeline
null
completed
null
null
false
[ "@rfyiamcool No. The first case does this: `xxx?id=111`. The second case does this: `xxx?%7B%22id%22:%20111%7D`.\n\nIn future, please ask questions on Stack Overflow: the GitHub issues page is strictly for bugs.\n" ]
https://api.github.com/repos/psf/requests/issues/2979
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/2979/labels{/name}
https://api.github.com/repos/psf/requests/issues/2979/comments
https://api.github.com/repos/psf/requests/issues/2979/events
https://github.com/psf/requests/issues/2979
128,423,683
MDU6SXNzdWUxMjg0MjM2ODM=
2,979
JSON content type for PUT method
{ "avatar_url": "https://avatars.githubusercontent.com/u/1684705?v=4", "events_url": "https://api.github.com/users/Neraste/events{/privacy}", "followers_url": "https://api.github.com/users/Neraste/followers", "following_url": "https://api.github.com/users/Neraste/following{/other_user}", "gists_url": "https://api.github.com/users/Neraste/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/Neraste", "id": 1684705, "login": "Neraste", "node_id": "MDQ6VXNlcjE2ODQ3MDU=", "organizations_url": "https://api.github.com/users/Neraste/orgs", "received_events_url": "https://api.github.com/users/Neraste/received_events", "repos_url": "https://api.github.com/users/Neraste/repos", "site_admin": false, "starred_url": "https://api.github.com/users/Neraste/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Neraste/subscriptions", "type": "User", "url": "https://api.github.com/users/Neraste", "user_view_type": "public" }
[]
closed
true
null
[]
null
1
2016-01-24T20:39:05Z
2021-09-08T19:00:38Z
2016-01-24T20:53:58Z
NONE
resolved
According to the [doc](http://docs.python-requests.org/en/latest/api/), you can specify to send a request with JSON content type for POST method. But there is nothing like this for PUT or PATCH methods. Is there a reason? Can this be implemented?
{ "avatar_url": "https://avatars.githubusercontent.com/u/240830?v=4", "events_url": "https://api.github.com/users/sigmavirus24/events{/privacy}", "followers_url": "https://api.github.com/users/sigmavirus24/followers", "following_url": "https://api.github.com/users/sigmavirus24/following{/other_user}", "gists_url": "https://api.github.com/users/sigmavirus24/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/sigmavirus24", "id": 240830, "login": "sigmavirus24", "node_id": "MDQ6VXNlcjI0MDgzMA==", "organizations_url": "https://api.github.com/users/sigmavirus24/orgs", "received_events_url": "https://api.github.com/users/sigmavirus24/received_events", "repos_url": "https://api.github.com/users/sigmavirus24/repos", "site_admin": false, "starred_url": "https://api.github.com/users/sigmavirus24/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sigmavirus24/subscriptions", "type": "User", "url": "https://api.github.com/users/sigmavirus24", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/2979/reactions" }
https://api.github.com/repos/psf/requests/issues/2979/timeline
null
completed
null
null
false
[ "If you look at the documentation for [`requests.put`](http://docs.python-requests.org/en/latest/api/#requests.put) and [`requests.patch`](http://docs.python-requests.org/en/latest/api/#requests.patch) they take `**kwargs` that are passed to [`requests.request`](http://docs.python-requests.org/en/latest/api/#reques...
https://api.github.com/repos/psf/requests/issues/2978
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/2978/labels{/name}
https://api.github.com/repos/psf/requests/issues/2978/comments
https://api.github.com/repos/psf/requests/issues/2978/events
https://github.com/psf/requests/issues/2978
128,419,712
MDU6SXNzdWUxMjg0MTk3MTI=
2,978
Inconsistent behaviour with https between urllib3 and requestsion.
{ "avatar_url": "https://avatars.githubusercontent.com/u/410950?v=4", "events_url": "https://api.github.com/users/jorourke/events{/privacy}", "followers_url": "https://api.github.com/users/jorourke/followers", "following_url": "https://api.github.com/users/jorourke/following{/other_user}", "gists_url": "https://api.github.com/users/jorourke/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jorourke", "id": 410950, "login": "jorourke", "node_id": "MDQ6VXNlcjQxMDk1MA==", "organizations_url": "https://api.github.com/users/jorourke/orgs", "received_events_url": "https://api.github.com/users/jorourke/received_events", "repos_url": "https://api.github.com/users/jorourke/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jorourke/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jorourke/subscriptions", "type": "User", "url": "https://api.github.com/users/jorourke", "user_view_type": "public" }
[]
closed
true
null
[]
null
9
2016-01-24T19:41:01Z
2021-09-08T16:00:35Z
2016-08-05T07:49:52Z
NONE
resolved
In trying to make a https connection as so: ``` shell (trustmile-api-p2710)jBeast:trustmile james$ python -c "import requests; r = requests.get('https://devapi.trustmile.com/static/index.html', verify=True)" Traceback (most recent call last): File "<string>", line 1, in <module> File "/Users/james/.virtualenvs/trustmile-api-p2710/lib/python2.7/site-packages/requests/api.py", line 67, in get return request('get', url, params=params, **kwargs) File "/Users/james/.virtualenvs/trustmile-api-p2710/lib/python2.7/site-packages/requests/api.py", line 53, in request return session.request(method=method, url=url, **kwargs) File "/Users/james/.virtualenvs/trustmile-api-p2710/lib/python2.7/site-packages/requests/sessions.py", line 468, in request resp = self.send(prep, **send_kwargs) File "/Users/james/.virtualenvs/trustmile-api-p2710/lib/python2.7/site-packages/requests/sessions.py", line 576, in send r = adapter.send(request, **kwargs) File "/Users/james/.virtualenvs/trustmile-api-p2710/lib/python2.7/site-packages/requests/adapters.py", line 447, in send raise SSLError(e, request=request) requests.exceptions.SSLError: ("bad handshake: Error([('SSL routines', 'ssl3_get_server_certificate', 'certificate verify failed')],)",) ``` I have latest necessary packages installed: ``` shell (trustmile-api-p2710)jBeast:trustmile james$ pip freeze | egrep '(requests|urllib3|certifi)' certifi==2015.11.20.1 requests==2.9.1 urllib3==1.14 ``` However, urllib works in the same environment: ``` python import urllib3 import certifi http = urllib3.PoolManager( cert_reqs='CERT_REQUIRED', # Force certificate check. ca_certs=certifi.where(), # Path to the Certifi bundle. ) # You're ready to make verified HTTPS requests. try: r = http.request('GET', 'https://devapi.trustmile.com/static/index.html') print r.status except urllib3.exceptions.SSLError as e: print e ``` Output is status 200. Am I missing something? I tried to set the relevant environment variables. The cert is a legit one and it's root cert is in the cacerts.pem in certifi package. Thanks again for an awesome package I use all the time Kenneth et al!
{ "avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4", "events_url": "https://api.github.com/users/Lukasa/events{/privacy}", "followers_url": "https://api.github.com/users/Lukasa/followers", "following_url": "https://api.github.com/users/Lukasa/following{/other_user}", "gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/Lukasa", "id": 1382556, "login": "Lukasa", "node_id": "MDQ6VXNlcjEzODI1NTY=", "organizations_url": "https://api.github.com/users/Lukasa/orgs", "received_events_url": "https://api.github.com/users/Lukasa/received_events", "repos_url": "https://api.github.com/users/Lukasa/repos", "site_admin": false, "starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions", "type": "User", "url": "https://api.github.com/users/Lukasa", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/2978/reactions" }
https://api.github.com/repos/psf/requests/issues/2978/timeline
null
completed
null
null
false
[ "Out of interest, what version of OpenSSL are you using? Run `python -c 'import ssl; print ssl.OPENSSL_VERSION'`\n", "OpenSSL 0.9.8zg 14 July 2015\n", "Interesting. Does this problem occur if you don't pass `verify=True`?\n", "Yep, same issue\n", "Hmm. What other packages do you have installed?\n", "Ah, t...
https://api.github.com/repos/psf/requests/issues/2977
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/2977/labels{/name}
https://api.github.com/repos/psf/requests/issues/2977/comments
https://api.github.com/repos/psf/requests/issues/2977/events
https://github.com/psf/requests/issues/2977
128,412,088
MDU6SXNzdWUxMjg0MTIwODg=
2,977
JSON-ROA data ignored
{ "avatar_url": "https://avatars.githubusercontent.com/u/113206?v=4", "events_url": "https://api.github.com/users/birk/events{/privacy}", "followers_url": "https://api.github.com/users/birk/followers", "following_url": "https://api.github.com/users/birk/following{/other_user}", "gists_url": "https://api.github.com/users/birk/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/birk", "id": 113206, "login": "birk", "node_id": "MDQ6VXNlcjExMzIwNg==", "organizations_url": "https://api.github.com/users/birk/orgs", "received_events_url": "https://api.github.com/users/birk/received_events", "repos_url": "https://api.github.com/users/birk/repos", "site_admin": false, "starred_url": "https://api.github.com/users/birk/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/birk/subscriptions", "type": "User", "url": "https://api.github.com/users/birk", "user_view_type": "public" }
[]
closed
true
null
[]
null
4
2016-01-24T17:29:44Z
2021-09-08T19:00:39Z
2016-01-24T17:50:40Z
NONE
resolved
Hi, I'm trying to read JSON-ROA responses from an API that look like this: ``` json { "_json-roa": { "filled_with": "lots of data" }, "created_at": "2015-11-05T10:33:37.249Z", "creator_id": "a41b963a-e50e-40ad-9c37-dc5dfcc9a1de", "id": "c97e9d4c-aaff-415a-a996-4a7e79ce0c81", } ``` A call to `r.json()` recognizes `created_at`, `creator_id`, and `id` correctly but ignores `_json-roa`. `r.text` shows likewise only the last three nodes. If I open and read the same JSON not as a server response but as a static file, parsing it is not problem. Any ideas? Best, birk
{ "avatar_url": "https://avatars.githubusercontent.com/u/113206?v=4", "events_url": "https://api.github.com/users/birk/events{/privacy}", "followers_url": "https://api.github.com/users/birk/followers", "following_url": "https://api.github.com/users/birk/following{/other_user}", "gists_url": "https://api.github.com/users/birk/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/birk", "id": 113206, "login": "birk", "node_id": "MDQ6VXNlcjExMzIwNg==", "organizations_url": "https://api.github.com/users/birk/orgs", "received_events_url": "https://api.github.com/users/birk/received_events", "repos_url": "https://api.github.com/users/birk/repos", "site_admin": false, "starred_url": "https://api.github.com/users/birk/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/birk/subscriptions", "type": "User", "url": "https://api.github.com/users/birk", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/2977/reactions" }
https://api.github.com/repos/psf/requests/issues/2977/timeline
null
completed
null
null
false
[ "If `r.text` only shows the last three nodes, that means that only the last three nodes are present. This means that for some reason the server is choosing not to send you that data.\n\nYou'll need to consult with your API documentation or server operator to determine why that data is absent.\n", "Thanks for the ...
https://api.github.com/repos/psf/requests/issues/2976
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/2976/labels{/name}
https://api.github.com/repos/psf/requests/issues/2976/comments
https://api.github.com/repos/psf/requests/issues/2976/events
https://github.com/psf/requests/pull/2976
128,077,424
MDExOlB1bGxSZXF1ZXN0NTY4NDM3OTU=
2,976
Fix api doc of debug logging for Python 3
{ "avatar_url": "https://avatars.githubusercontent.com/u/71619?v=4", "events_url": "https://api.github.com/users/shoma/events{/privacy}", "followers_url": "https://api.github.com/users/shoma/followers", "following_url": "https://api.github.com/users/shoma/following{/other_user}", "gists_url": "https://api.github.com/users/shoma/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/shoma", "id": 71619, "login": "shoma", "node_id": "MDQ6VXNlcjcxNjE5", "organizations_url": "https://api.github.com/users/shoma/orgs", "received_events_url": "https://api.github.com/users/shoma/received_events", "repos_url": "https://api.github.com/users/shoma/repos", "site_admin": false, "starred_url": "https://api.github.com/users/shoma/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/shoma/subscriptions", "type": "User", "url": "https://api.github.com/users/shoma", "user_view_type": "public" }
[]
closed
true
null
[]
null
3
2016-01-22T03:48:40Z
2021-09-08T05:01:03Z
2016-01-22T07:12:01Z
CONTRIBUTOR
resolved
`httplib` was renamed in Python 3.
{ "avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4", "events_url": "https://api.github.com/users/Lukasa/events{/privacy}", "followers_url": "https://api.github.com/users/Lukasa/followers", "following_url": "https://api.github.com/users/Lukasa/following{/other_user}", "gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/Lukasa", "id": 1382556, "login": "Lukasa", "node_id": "MDQ6VXNlcjEzODI1NTY=", "organizations_url": "https://api.github.com/users/Lukasa/orgs", "received_events_url": "https://api.github.com/users/Lukasa/received_events", "repos_url": "https://api.github.com/users/Lukasa/repos", "site_admin": false, "starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions", "type": "User", "url": "https://api.github.com/users/Lukasa", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/2976/reactions" }
https://api.github.com/repos/psf/requests/issues/2976/timeline
null
null
false
{ "diff_url": "https://github.com/psf/requests/pull/2976.diff", "html_url": "https://github.com/psf/requests/pull/2976", "merged_at": "2016-01-22T07:12:01Z", "patch_url": "https://github.com/psf/requests/pull/2976.patch", "url": "https://api.github.com/repos/psf/requests/pulls/2976" }
true
[ "This then breaks for users on Python 2. Can you simply add comments explaining how to do this on Python 3 instead of removing the recipe for people using Python 2?\n", "@sigmavirus24 \n\nOk, I'll update.\n", "Thanks! :sparkles: :cake: :sparkles:\n" ]
https://api.github.com/repos/psf/requests/issues/2975
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/2975/labels{/name}
https://api.github.com/repos/psf/requests/issues/2975/comments
https://api.github.com/repos/psf/requests/issues/2975/events
https://github.com/psf/requests/issues/2975
127,923,191
MDU6SXNzdWUxMjc5MjMxOTE=
2,975
Why retry doesn't work on sesson.post method
{ "avatar_url": "https://avatars.githubusercontent.com/u/1451096?v=4", "events_url": "https://api.github.com/users/demonguy/events{/privacy}", "followers_url": "https://api.github.com/users/demonguy/followers", "following_url": "https://api.github.com/users/demonguy/following{/other_user}", "gists_url": "https://api.github.com/users/demonguy/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/demonguy", "id": 1451096, "login": "demonguy", "node_id": "MDQ6VXNlcjE0NTEwOTY=", "organizations_url": "https://api.github.com/users/demonguy/orgs", "received_events_url": "https://api.github.com/users/demonguy/received_events", "repos_url": "https://api.github.com/users/demonguy/repos", "site_admin": false, "starred_url": "https://api.github.com/users/demonguy/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/demonguy/subscriptions", "type": "User", "url": "https://api.github.com/users/demonguy", "user_view_type": "public" }
[]
closed
true
null
[]
null
7
2016-01-21T13:23:15Z
2021-09-08T19:00:39Z
2016-01-21T13:29:33Z
NONE
resolved
I've pasted requests.packages.urllib3.util.Retry object to max_retries argument of HTTPAdapter But i found, it only works on session.get. How could i make it work on session.post ?
{ "avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4", "events_url": "https://api.github.com/users/Lukasa/events{/privacy}", "followers_url": "https://api.github.com/users/Lukasa/followers", "following_url": "https://api.github.com/users/Lukasa/following{/other_user}", "gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/Lukasa", "id": 1382556, "login": "Lukasa", "node_id": "MDQ6VXNlcjEzODI1NTY=", "organizations_url": "https://api.github.com/users/Lukasa/orgs", "received_events_url": "https://api.github.com/users/Lukasa/received_events", "repos_url": "https://api.github.com/users/Lukasa/repos", "site_admin": false, "starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions", "type": "User", "url": "https://api.github.com/users/Lukasa", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/2975/reactions" }
https://api.github.com/repos/psf/requests/issues/2975/timeline
null
completed
null
null
false
[ "When you say it doesn't work on post, what does that mean? What are you expecting to see and what actually happens?\n", "it means. when i use session.post to access url = 'https://httpbin.org/status/500', it doesn't retry and just return an 500 error, not maxretry error.\n", "@demonguy That's not how retries w...
https://api.github.com/repos/psf/requests/issues/2974
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/2974/labels{/name}
https://api.github.com/repos/psf/requests/issues/2974/comments
https://api.github.com/repos/psf/requests/issues/2974/events
https://github.com/psf/requests/issues/2974
127,714,446
MDU6SXNzdWUxMjc3MTQ0NDY=
2,974
Response encoding defaulting to ISO-8859-1
{ "avatar_url": "https://avatars.githubusercontent.com/u/208952?v=4", "events_url": "https://api.github.com/users/eskerda/events{/privacy}", "followers_url": "https://api.github.com/users/eskerda/followers", "following_url": "https://api.github.com/users/eskerda/following{/other_user}", "gists_url": "https://api.github.com/users/eskerda/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/eskerda", "id": 208952, "login": "eskerda", "node_id": "MDQ6VXNlcjIwODk1Mg==", "organizations_url": "https://api.github.com/users/eskerda/orgs", "received_events_url": "https://api.github.com/users/eskerda/received_events", "repos_url": "https://api.github.com/users/eskerda/repos", "site_admin": false, "starred_url": "https://api.github.com/users/eskerda/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/eskerda/subscriptions", "type": "User", "url": "https://api.github.com/users/eskerda", "user_view_type": "public" }
[]
closed
true
null
[]
null
1
2016-01-20T15:59:55Z
2021-09-08T19:00:39Z
2016-01-20T16:04:35Z
NONE
resolved
Hello, For the last month I've been getting reported issues on badly encoded data (ie: https://github.com/eskerda/pybikes/issues/109) I've searched through the issues and also tried to pinpoint it to a particular change, but only one if found is from 2014. Has something changed recently? Can be reproduced as: ``` python import requests import re rgx = r'setEstacao\((.+)\)' resp = requests.get('http://www.ciclosampa.com.br/estacoes.php') print "Uses default encoding %r" % resp.encoding print re.findall(rgx, resp.text)[0] print "" resp.encoding = 'UTF-8' print "Uses set encoding %r" % resp.encoding print re.findall(rgx, resp.text)[0] ``` ``` Uses default encoding 'ISO-8859-1' -23.572208,-46.644283,"1","Estação Hcor","Rua Desembargador Eliseu Guilherme 14","5","11" Uses set encoding 'UTF-8' -23.572208,-46.644283,"1","Estação Hcor","Rua Desembargador Eliseu Guilherme 14","5","11" ``` Sorry if this has already been reported or resolved. Looked for issues but most changes on this are too old to be relevant.
{ "avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4", "events_url": "https://api.github.com/users/Lukasa/events{/privacy}", "followers_url": "https://api.github.com/users/Lukasa/followers", "following_url": "https://api.github.com/users/Lukasa/following{/other_user}", "gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/Lukasa", "id": 1382556, "login": "Lukasa", "node_id": "MDQ6VXNlcjEzODI1NTY=", "organizations_url": "https://api.github.com/users/Lukasa/orgs", "received_events_url": "https://api.github.com/users/Lukasa/received_events", "repos_url": "https://api.github.com/users/Lukasa/repos", "site_admin": false, "starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions", "type": "User", "url": "https://api.github.com/users/Lukasa", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/2974/reactions" }
https://api.github.com/repos/psf/requests/issues/2974/timeline
null
completed
null
null
false
[ "This has not changed: requests has behaved like this for an extremely long time. See #2086 for a discussion about it.\n\nIf this used to work but has now stopped working, it's likely that the server used to send a `charset` field in the Content-Type header but no longer does.\n\nIf you know you're going to be hand...
https://api.github.com/repos/psf/requests/issues/2973
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/2973/labels{/name}
https://api.github.com/repos/psf/requests/issues/2973/comments
https://api.github.com/repos/psf/requests/issues/2973/events
https://github.com/psf/requests/pull/2973
127,687,147
MDExOlB1bGxSZXF1ZXN0NTY2MTAwNTQ=
2,973
Stop falling back to distutils in setup.py
{ "avatar_url": "https://avatars.githubusercontent.com/u/240830?v=4", "events_url": "https://api.github.com/users/sigmavirus24/events{/privacy}", "followers_url": "https://api.github.com/users/sigmavirus24/followers", "following_url": "https://api.github.com/users/sigmavirus24/following{/other_user}", "gists_url": "https://api.github.com/users/sigmavirus24/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/sigmavirus24", "id": 240830, "login": "sigmavirus24", "node_id": "MDQ6VXNlcjI0MDgzMA==", "organizations_url": "https://api.github.com/users/sigmavirus24/orgs", "received_events_url": "https://api.github.com/users/sigmavirus24/received_events", "repos_url": "https://api.github.com/users/sigmavirus24/repos", "site_admin": false, "starred_url": "https://api.github.com/users/sigmavirus24/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sigmavirus24/subscriptions", "type": "User", "url": "https://api.github.com/users/sigmavirus24", "user_view_type": "public" }
[]
closed
true
{ "avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4", "events_url": "https://api.github.com/users/Lukasa/events{/privacy}", "followers_url": "https://api.github.com/users/Lukasa/followers", "following_url": "https://api.github.com/users/Lukasa/following{/other_user}", "gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/Lukasa", "id": 1382556, "login": "Lukasa", "node_id": "MDQ6VXNlcjEzODI1NTY=", "organizations_url": "https://api.github.com/users/Lukasa/orgs", "received_events_url": "https://api.github.com/users/Lukasa/received_events", "repos_url": "https://api.github.com/users/Lukasa/repos", "site_admin": false, "starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions", "type": "User", "url": "https://api.github.com/users/Lukasa", "user_view_type": "public" }
[ { "avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4", "events_url": "https://api.github.com/users/Lukasa/events{/privacy}", "followers_url": "https://api.github.com/users/Lukasa/followers", "following_url": "https://api.github.com/users/Lukasa/following{/other_user}", "gists_url...
null
2
2016-01-20T13:53:40Z
2021-09-08T05:01:04Z
2016-01-20T13:54:58Z
CONTRIBUTOR
resolved
distutils has been deprecated for years now and pip is refusing to install projects using it. As such, _some_ users are reporting problems installing requests. Let's avoid this entirely by not falling back to distutils at all.
{ "avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4", "events_url": "https://api.github.com/users/Lukasa/events{/privacy}", "followers_url": "https://api.github.com/users/Lukasa/followers", "following_url": "https://api.github.com/users/Lukasa/following{/other_user}", "gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/Lukasa", "id": 1382556, "login": "Lukasa", "node_id": "MDQ6VXNlcjEzODI1NTY=", "organizations_url": "https://api.github.com/users/Lukasa/orgs", "received_events_url": "https://api.github.com/users/Lukasa/received_events", "repos_url": "https://api.github.com/users/Lukasa/repos", "site_admin": false, "starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions", "type": "User", "url": "https://api.github.com/users/Lukasa", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/2973/reactions" }
https://api.github.com/repos/psf/requests/issues/2973/timeline
null
null
false
{ "diff_url": "https://github.com/psf/requests/pull/2973.diff", "html_url": "https://github.com/psf/requests/pull/2973", "merged_at": "2016-01-20T13:54:58Z", "patch_url": "https://github.com/psf/requests/pull/2973.patch", "url": "https://api.github.com/repos/psf/requests/pulls/2973" }
true
[ "/cc @dstufft (re: https://github.com/pypa/pip/issues/3384#issuecomment-173202320) although I'm starting to suspect that that is a version of requests packaged by the distro that is causing wichert's problems.\n", "Still, we just don't need this fallback now.\n" ]
https://api.github.com/repos/psf/requests/issues/2972
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/2972/labels{/name}
https://api.github.com/repos/psf/requests/issues/2972/comments
https://api.github.com/repos/psf/requests/issues/2972/events
https://github.com/psf/requests/pull/2972
127,576,727
MDExOlB1bGxSZXF1ZXN0NTY1NDk3Mjk=
2,972
Return request & response with TooManyRedirects
{ "avatar_url": "https://avatars.githubusercontent.com/u/500774?v=4", "events_url": "https://api.github.com/users/munro/events{/privacy}", "followers_url": "https://api.github.com/users/munro/followers", "following_url": "https://api.github.com/users/munro/following{/other_user}", "gists_url": "https://api.github.com/users/munro/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/munro", "id": 500774, "login": "munro", "node_id": "MDQ6VXNlcjUwMDc3NA==", "organizations_url": "https://api.github.com/users/munro/orgs", "received_events_url": "https://api.github.com/users/munro/received_events", "repos_url": "https://api.github.com/users/munro/repos", "site_admin": false, "starred_url": "https://api.github.com/users/munro/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/munro/subscriptions", "type": "User", "url": "https://api.github.com/users/munro", "user_view_type": "public" }
[]
closed
true
null
[]
null
6
2016-01-20T00:53:26Z
2021-09-08T05:01:03Z
2016-01-21T23:01:58Z
CONTRIBUTOR
resolved
I'm using requests to fetch data from websites that I don't maintain, and sometimes websites have broken cyclic redirects, but still return useful responses. So I would like to grab the last cut off response, similar to the browser. The problem is that `TooManyRedirects` doesn't throw the ending response state for me to inspect, so this PR adds that.
{ "avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4", "events_url": "https://api.github.com/users/Lukasa/events{/privacy}", "followers_url": "https://api.github.com/users/Lukasa/followers", "following_url": "https://api.github.com/users/Lukasa/following{/other_user}", "gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/Lukasa", "id": 1382556, "login": "Lukasa", "node_id": "MDQ6VXNlcjEzODI1NTY=", "organizations_url": "https://api.github.com/users/Lukasa/orgs", "received_events_url": "https://api.github.com/users/Lukasa/received_events", "repos_url": "https://api.github.com/users/Lukasa/repos", "site_admin": false, "starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions", "type": "User", "url": "https://api.github.com/users/Lukasa", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/2972/reactions" }
https://api.github.com/repos/psf/requests/issues/2972/timeline
null
null
false
{ "diff_url": "https://github.com/psf/requests/pull/2972.diff", "html_url": "https://github.com/psf/requests/pull/2972", "merged_at": "2016-01-21T23:01:58Z", "patch_url": "https://github.com/psf/requests/pull/2972.patch", "url": "https://api.github.com/repos/psf/requests/pulls/2972" }
true
[ "@Lukasa I'm +0.5 on this. The reason I'm not a full +1 is that we might start leaking sockets this way.\n", "@sigmavirus24 We shouldn't leak sockets here: the redirect logic consumes all the data from the connection, which should return it back to the connection pool, and that happens before we raise `TooManyRed...
https://api.github.com/repos/psf/requests/issues/2971
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/2971/labels{/name}
https://api.github.com/repos/psf/requests/issues/2971/comments
https://api.github.com/repos/psf/requests/issues/2971/events
https://github.com/psf/requests/issues/2971
127,079,968
MDU6SXNzdWUxMjcwNzk5Njg=
2,971
SSL error: bad handshake
{ "avatar_url": "https://avatars.githubusercontent.com/u/7250762?v=4", "events_url": "https://api.github.com/users/Mohammed-Aadil/events{/privacy}", "followers_url": "https://api.github.com/users/Mohammed-Aadil/followers", "following_url": "https://api.github.com/users/Mohammed-Aadil/following{/other_user}", "gists_url": "https://api.github.com/users/Mohammed-Aadil/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/Mohammed-Aadil", "id": 7250762, "login": "Mohammed-Aadil", "node_id": "MDQ6VXNlcjcyNTA3NjI=", "organizations_url": "https://api.github.com/users/Mohammed-Aadil/orgs", "received_events_url": "https://api.github.com/users/Mohammed-Aadil/received_events", "repos_url": "https://api.github.com/users/Mohammed-Aadil/repos", "site_admin": false, "starred_url": "https://api.github.com/users/Mohammed-Aadil/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Mohammed-Aadil/subscriptions", "type": "User", "url": "https://api.github.com/users/Mohammed-Aadil", "user_view_type": "public" }
[]
closed
true
null
[]
null
2
2016-01-17T07:30:44Z
2021-09-08T19:00:40Z
2016-01-19T19:32:41Z
NONE
resolved
Traceback (most recent call last): File "<stdin>", line 1, in <module> File "/home/dev-django1/.virtualenvs/logic_srv/local/lib/python2.7/site-packages/requests/api.py", line 68, in get return request('get', url, *_kwargs) File "/home/dev-django1/.virtualenvs/logic_srv/local/lib/python2.7/site-packages/requests/api.py", line 50, in request response = session.request(method=method, url=url, *_kwargs) File "/home/dev-django1/.virtualenvs/logic_srv/local/lib/python2.7/site-packages/requests/sessions.py", line 464, in request resp = self.send(prep, *_send_kwargs) File "/home/dev-django1/.virtualenvs/logic_srv/local/lib/python2.7/site-packages/requests/sessions.py", line 576, in send r = adapter.send(request, *_kwargs) File "/home/dev-django1/.virtualenvs/logic_srv/local/lib/python2.7/site-packages/requests/adapters.py", line 431, in send raise SSLError(e, request=request) requests.exceptions.SSLError: [Errno bad handshake] [('SSL routines', 'SSL3_GET_SERVER_CERTIFICATE', 'certificate verify failed')] I do not know why it is coming in requests 2.6.0 while it is not coming in requests==2.2.1. This problem start arising yesterday when I hit it to google api on link https://www.googleapis.com/oauth2/v1/tokeninfo. I can't use verify=False as many stackoverflow thread is advising. And I'm pretty sure I have used ssl certificate properly in my web site too.
{ "avatar_url": "https://avatars.githubusercontent.com/u/240830?v=4", "events_url": "https://api.github.com/users/sigmavirus24/events{/privacy}", "followers_url": "https://api.github.com/users/sigmavirus24/followers", "following_url": "https://api.github.com/users/sigmavirus24/following{/other_user}", "gists_url": "https://api.github.com/users/sigmavirus24/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/sigmavirus24", "id": 240830, "login": "sigmavirus24", "node_id": "MDQ6VXNlcjI0MDgzMA==", "organizations_url": "https://api.github.com/users/sigmavirus24/orgs", "received_events_url": "https://api.github.com/users/sigmavirus24/received_events", "repos_url": "https://api.github.com/users/sigmavirus24/repos", "site_admin": false, "starred_url": "https://api.github.com/users/sigmavirus24/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sigmavirus24/subscriptions", "type": "User", "url": "https://api.github.com/users/sigmavirus24", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/2971/reactions" }
https://api.github.com/repos/psf/requests/issues/2971/timeline
null
completed
null
null
false
[ "What OS are you using?\n", "Yeah im using linux. Btw I fixed the error by removing and installing virtualenv package, not sure why this happened but i got it running. Thank you for your reply :)\n" ]
https://api.github.com/repos/psf/requests/issues/2970
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/2970/labels{/name}
https://api.github.com/repos/psf/requests/issues/2970/comments
https://api.github.com/repos/psf/requests/issues/2970/events
https://github.com/psf/requests/pull/2970
126,712,324
MDExOlB1bGxSZXF1ZXN0NTYwNzExODk=
2,970
Rebase to 2.9.1 changes
{ "avatar_url": "https://avatars.githubusercontent.com/u/2167844?v=4", "events_url": "https://api.github.com/users/hwms/events{/privacy}", "followers_url": "https://api.github.com/users/hwms/followers", "following_url": "https://api.github.com/users/hwms/following{/other_user}", "gists_url": "https://api.github.com/users/hwms/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/hwms", "id": 2167844, "login": "hwms", "node_id": "MDQ6VXNlcjIxNjc4NDQ=", "organizations_url": "https://api.github.com/users/hwms/orgs", "received_events_url": "https://api.github.com/users/hwms/received_events", "repos_url": "https://api.github.com/users/hwms/repos", "site_admin": false, "starred_url": "https://api.github.com/users/hwms/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/hwms/subscriptions", "type": "User", "url": "https://api.github.com/users/hwms", "user_view_type": "public" }
[]
closed
true
null
[]
null
1
2016-01-14T18:02:38Z
2021-09-08T04:01:02Z
2016-01-21T19:58:26Z
NONE
resolved
I just rebased the proposed 3.0.0 to current master near 2.9.1 to further help with socks support there also :)
{ "avatar_url": "https://avatars.githubusercontent.com/u/2167844?v=4", "events_url": "https://api.github.com/users/hwms/events{/privacy}", "followers_url": "https://api.github.com/users/hwms/followers", "following_url": "https://api.github.com/users/hwms/following{/other_user}", "gists_url": "https://api.github.com/users/hwms/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/hwms", "id": 2167844, "login": "hwms", "node_id": "MDQ6VXNlcjIxNjc4NDQ=", "organizations_url": "https://api.github.com/users/hwms/orgs", "received_events_url": "https://api.github.com/users/hwms/received_events", "repos_url": "https://api.github.com/users/hwms/repos", "site_admin": false, "starred_url": "https://api.github.com/users/hwms/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/hwms/subscriptions", "type": "User", "url": "https://api.github.com/users/hwms", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/2970/reactions" }
https://api.github.com/repos/psf/requests/issues/2970/timeline
null
null
false
{ "diff_url": "https://github.com/psf/requests/pull/2970.diff", "html_url": "https://github.com/psf/requests/pull/2970", "merged_at": null, "patch_url": "https://github.com/psf/requests/pull/2970.patch", "url": "https://api.github.com/repos/psf/requests/pulls/2970" }
true
[ "As long as it pushes the 3.0 to current upgrades (and works of course) i am happy with it :)\n" ]
https://api.github.com/repos/psf/requests/issues/2969
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/2969/labels{/name}
https://api.github.com/repos/psf/requests/issues/2969/comments
https://api.github.com/repos/psf/requests/issues/2969/events
https://github.com/psf/requests/issues/2969
126,671,871
MDU6SXNzdWUxMjY2NzE4NzE=
2,969
Cut a release to match urllib3-1.14?
{ "avatar_url": "https://avatars.githubusercontent.com/u/331338?v=4", "events_url": "https://api.github.com/users/ralphbean/events{/privacy}", "followers_url": "https://api.github.com/users/ralphbean/followers", "following_url": "https://api.github.com/users/ralphbean/following{/other_user}", "gists_url": "https://api.github.com/users/ralphbean/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/ralphbean", "id": 331338, "login": "ralphbean", "node_id": "MDQ6VXNlcjMzMTMzOA==", "organizations_url": "https://api.github.com/users/ralphbean/orgs", "received_events_url": "https://api.github.com/users/ralphbean/received_events", "repos_url": "https://api.github.com/users/ralphbean/repos", "site_admin": false, "starred_url": "https://api.github.com/users/ralphbean/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/ralphbean/subscriptions", "type": "User", "url": "https://api.github.com/users/ralphbean", "user_view_type": "public" }
[]
closed
true
null
[]
null
12
2016-01-14T15:03:07Z
2021-09-08T16:00:36Z
2016-08-05T07:49:39Z
CONTRIBUTOR
resolved
Hi, we noticed that urllib3-1.14 was released right at the end of 2015. Are there plans to release a new version of requests bundling that? Downstream in Fedora we had a bug filed requesting urllib3-1.14, but with the way things stand now, we can't update to that until we have a matching requests release. https://bugzilla.redhat.com/show_bug.cgi?id=1295402
{ "avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4", "events_url": "https://api.github.com/users/Lukasa/events{/privacy}", "followers_url": "https://api.github.com/users/Lukasa/followers", "following_url": "https://api.github.com/users/Lukasa/following{/other_user}", "gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/Lukasa", "id": 1382556, "login": "Lukasa", "node_id": "MDQ6VXNlcjEzODI1NTY=", "organizations_url": "https://api.github.com/users/Lukasa/orgs", "received_events_url": "https://api.github.com/users/Lukasa/received_events", "repos_url": "https://api.github.com/users/Lukasa/repos", "site_admin": false, "starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions", "type": "User", "url": "https://api.github.com/users/Lukasa", "user_view_type": "public" }
{ "+1": 2, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 2, "url": "https://api.github.com/repos/psf/requests/issues/2969/reactions" }
https://api.github.com/repos/psf/requests/issues/2969/timeline
null
completed
null
null
false
[ "@ralphbean At some point, sure. We weren't generally planning on racing to new urllib3 versions, especially as really the only change in that urllib3 release is the SOCKS proxy support.\n\nIs there a particular rush to get urllib3 1.14 into Fedora?\n", "I think Nir Magnezi in that ticket was having issues settin...
https://api.github.com/repos/psf/requests/issues/2968
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/2968/labels{/name}
https://api.github.com/repos/psf/requests/issues/2968/comments
https://api.github.com/repos/psf/requests/issues/2968/events
https://github.com/psf/requests/issues/2968
126,354,819
MDU6SXNzdWUxMjYzNTQ4MTk=
2,968
how can i use keystore file in request?
{ "avatar_url": "https://avatars.githubusercontent.com/u/935632?v=4", "events_url": "https://api.github.com/users/vinsia/events{/privacy}", "followers_url": "https://api.github.com/users/vinsia/followers", "following_url": "https://api.github.com/users/vinsia/following{/other_user}", "gists_url": "https://api.github.com/users/vinsia/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/vinsia", "id": 935632, "login": "vinsia", "node_id": "MDQ6VXNlcjkzNTYzMg==", "organizations_url": "https://api.github.com/users/vinsia/orgs", "received_events_url": "https://api.github.com/users/vinsia/received_events", "repos_url": "https://api.github.com/users/vinsia/repos", "site_admin": false, "starred_url": "https://api.github.com/users/vinsia/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/vinsia/subscriptions", "type": "User", "url": "https://api.github.com/users/vinsia", "user_view_type": "public" }
[]
closed
true
null
[]
null
1
2016-01-13T06:48:21Z
2021-09-08T20:00:47Z
2016-01-13T08:16:17Z
NONE
resolved
i got a keystore file, it contains much x.509 certificates. how to import them, while request something?
{ "avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4", "events_url": "https://api.github.com/users/Lukasa/events{/privacy}", "followers_url": "https://api.github.com/users/Lukasa/followers", "following_url": "https://api.github.com/users/Lukasa/following{/other_user}", "gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/Lukasa", "id": 1382556, "login": "Lukasa", "node_id": "MDQ6VXNlcjEzODI1NTY=", "organizations_url": "https://api.github.com/users/Lukasa/orgs", "received_events_url": "https://api.github.com/users/Lukasa/received_events", "repos_url": "https://api.github.com/users/Lukasa/repos", "site_admin": false, "starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions", "type": "User", "url": "https://api.github.com/users/Lukasa", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/2968/reactions" }
https://api.github.com/repos/psf/requests/issues/2968/timeline
null
completed
null
null
false
[ "@vinsia At this time requests can only pass X509 certificates to OpenSSL from the filesystem: either a file of PEM-encoded certificates or a directory of them. If you serialize your keystore file out to PEM-encoding, you should be able to use the `verify` argument to use them.\n" ]
https://api.github.com/repos/psf/requests/issues/2967
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/2967/labels{/name}
https://api.github.com/repos/psf/requests/issues/2967/comments
https://api.github.com/repos/psf/requests/issues/2967/events
https://github.com/psf/requests/issues/2967
126,214,154
MDU6SXNzdWUxMjYyMTQxNTQ=
2,967
SSL-Client-Certificate and Subject Alternative Names
{ "avatar_url": "https://avatars.githubusercontent.com/u/3438840?v=4", "events_url": "https://api.github.com/users/felskrone/events{/privacy}", "followers_url": "https://api.github.com/users/felskrone/followers", "following_url": "https://api.github.com/users/felskrone/following{/other_user}", "gists_url": "https://api.github.com/users/felskrone/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/felskrone", "id": 3438840, "login": "felskrone", "node_id": "MDQ6VXNlcjM0Mzg4NDA=", "organizations_url": "https://api.github.com/users/felskrone/orgs", "received_events_url": "https://api.github.com/users/felskrone/received_events", "repos_url": "https://api.github.com/users/felskrone/repos", "site_admin": false, "starred_url": "https://api.github.com/users/felskrone/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/felskrone/subscriptions", "type": "User", "url": "https://api.github.com/users/felskrone", "user_view_type": "public" }
[]
closed
true
null
[]
null
4
2016-01-12T16:14:02Z
2021-09-08T20:00:47Z
2016-01-12T18:08:10Z
NONE
resolved
I have a (Puppet-)generated SSL-certificate with a CN and several SANs. A stripped output of openssl-output looks like this: ``` bash # openssl x509 -in cert.crt -text Certificate: ... Signature Algorithm: sha256WithRSAEncryption Issuer: CN=Puppet CA: puppet.domain.com ... X509v3 extensions: ... X509v3 Subject Alternative Name: DNS:srv01.domain.com, DNS:srv02.domain.com, DNS:srv03.domain.com ... ``` Now when i use this certificate with requests, it always picks the CN to do the actual request. Meaning my remote always receives "puppet.domain.com" to verify the client-certificate against. Since the remote IS puppet.domain.com, and the client is srv01.domain.com, the verification always fails. Is there any way, to have requests use any of the SANs to do its request? Or is it my remote the actually only uses the CN to do verification?
{ "avatar_url": "https://avatars.githubusercontent.com/u/3438840?v=4", "events_url": "https://api.github.com/users/felskrone/events{/privacy}", "followers_url": "https://api.github.com/users/felskrone/followers", "following_url": "https://api.github.com/users/felskrone/following{/other_user}", "gists_url": "https://api.github.com/users/felskrone/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/felskrone", "id": 3438840, "login": "felskrone", "node_id": "MDQ6VXNlcjM0Mzg4NDA=", "organizations_url": "https://api.github.com/users/felskrone/orgs", "received_events_url": "https://api.github.com/users/felskrone/received_events", "repos_url": "https://api.github.com/users/felskrone/repos", "site_admin": false, "starred_url": "https://api.github.com/users/felskrone/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/felskrone/subscriptions", "type": "User", "url": "https://api.github.com/users/felskrone", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/2967/reactions" }
https://api.github.com/repos/psf/requests/issues/2967/timeline
null
completed
null
null
false
[ "Sorry...I'm confused. When you say \"to do the actual request\", what do you mean?\n", "I meant when i do request.post(url, cert()..) that requests always picks the CN.\n\nBut i think thats not the problem here. Im quite certain that the remote (apache) or maybe even the application (foreman) has to look at the ...
https://api.github.com/repos/psf/requests/issues/2966
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/2966/labels{/name}
https://api.github.com/repos/psf/requests/issues/2966/comments
https://api.github.com/repos/psf/requests/issues/2966/events
https://github.com/psf/requests/issues/2966
125,993,142
MDU6SXNzdWUxMjU5OTMxNDI=
2,966
Consider using system trust stores by default in 3.0.0.
{ "avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4", "events_url": "https://api.github.com/users/Lukasa/events{/privacy}", "followers_url": "https://api.github.com/users/Lukasa/followers", "following_url": "https://api.github.com/users/Lukasa/following{/other_user}", "gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/Lukasa", "id": 1382556, "login": "Lukasa", "node_id": "MDQ6VXNlcjEzODI1NTY=", "organizations_url": "https://api.github.com/users/Lukasa/orgs", "received_events_url": "https://api.github.com/users/Lukasa/received_events", "repos_url": "https://api.github.com/users/Lukasa/repos", "site_admin": false, "starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions", "type": "User", "url": "https://api.github.com/users/Lukasa", "user_view_type": "public" }
[ { "color": "fef2c0", "default": false, "description": null, "id": 60669570, "name": "Please Review", "node_id": "MDU6TGFiZWw2MDY2OTU3MA==", "url": "https://api.github.com/repos/psf/requests/labels/Please%20Review" }, { "color": "777777", "default": false, "description": n...
closed
false
null
[]
{ "closed_at": null, "closed_issues": 29, "created_at": "2013-11-17T11:29:34Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4", "events_url": "https://api.github.com/users/Lukasa/events{/privacy}", "followers_url": "https://api.github.com/users/Lukasa/followers", "following_url": "https://api.github.com/users/Lukasa/following{/other_user}", "gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/Lukasa", "id": 1382556, "login": "Lukasa", "node_id": "MDQ6VXNlcjEzODI1NTY=", "organizations_url": "https://api.github.com/users/Lukasa/orgs", "received_events_url": "https://api.github.com/users/Lukasa/received_events", "repos_url": "https://api.github.com/users/Lukasa/repos", "site_admin": false, "starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions", "type": "User", "url": "https://api.github.com/users/Lukasa", "user_view_type": "public" }, "description": null, "due_on": null, "html_url": "https://github.com/psf/requests/milestone/20", "id": 487518, "labels_url": "https://api.github.com/repos/psf/requests/milestones/20/labels", "node_id": "MDk6TWlsZXN0b25lNDg3NTE4", "number": 20, "open_issues": 12, "state": "open", "title": "3.0.0", "updated_at": "2024-05-19T18:43:00Z", "url": "https://api.github.com/repos/psf/requests/milestones/20" }
211
2016-01-11T17:15:47Z
2024-05-19T18:35:48Z
2024-05-19T18:35:47Z
MEMBER
null
It's been raised repeatedly, mostly by people using Linux systems, that it's annoying that requests doesn't use the system trust store and instead uses the one that certifi ships. This is an understandable position. I have some personal attachment to the certifi approach, but the other side of that argument definitely has a reasonable position too. For this reason, I'd like us to look into whether we should use the system trust store by default, and make certifi's bundle a fallback option. I have some caveats here: 1. If we move to the system trust store, we must do so on _all_ platforms: Linux must not be its own special snowflake. 2. We must have broad-based support for Linux and Windows. 3. We must be able to fall back to certifi cleanly. Right now it seems like the best route to achieving this would be to use [certitude](https://github.com/python-hyper/certitude). This currently has support for dynamically generating the cert bundle OpenSSL needs directly from the system keychain on OS X. If we added Linux and Windows support to that library, we may have the opportunity to switch to using certitude. Given @kennethreitz's bundling policy, we probably cannot unconditionally switch to certitude, because certitude depends on cryptography (at least on OS X). However, certitude could take the current privileged position that certifi takes, or be a higher priority than certifi, as an optional dependency that is used if present on the system. Thoughts? This is currently a RFC, so please comment if you have opinions. /cc @sigmavirus24 @alex @kennethreitz @dstufft @glyph @reaperhulk @morganfainberg
{ "avatar_url": "https://avatars.githubusercontent.com/u/18519037?v=4", "events_url": "https://api.github.com/users/sethmlarson/events{/privacy}", "followers_url": "https://api.github.com/users/sethmlarson/followers", "following_url": "https://api.github.com/users/sethmlarson/following{/other_user}", "gists_url": "https://api.github.com/users/sethmlarson/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/sethmlarson", "id": 18519037, "login": "sethmlarson", "node_id": "MDQ6VXNlcjE4NTE5MDM3", "organizations_url": "https://api.github.com/users/sethmlarson/orgs", "received_events_url": "https://api.github.com/users/sethmlarson/received_events", "repos_url": "https://api.github.com/users/sethmlarson/repos", "site_admin": false, "starred_url": "https://api.github.com/users/sethmlarson/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sethmlarson/subscriptions", "type": "User", "url": "https://api.github.com/users/sethmlarson", "user_view_type": "public" }
{ "+1": 89, "-1": 0, "confused": 0, "eyes": 0, "heart": 3, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 92, "url": "https://api.github.com/repos/psf/requests/issues/2966/reactions" }
https://api.github.com/repos/psf/requests/issues/2966/timeline
null
completed
null
null
false
[ "I think the system trust stores (or not) essentially boils down to whether you want requests to act the same across platforms, or whether you want it to act in line with the platform it is running on. I do not think that _either_ of these options are wrong (or right), just different trade offs.\n\nI think that it'...
https://api.github.com/repos/psf/requests/issues/2965
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/2965/labels{/name}
https://api.github.com/repos/psf/requests/issues/2965/comments
https://api.github.com/repos/psf/requests/issues/2965/events
https://github.com/psf/requests/issues/2965
125,929,971
MDU6SXNzdWUxMjU5Mjk5NzE=
2,965
HTTPAdapter ignored
{ "avatar_url": "https://avatars.githubusercontent.com/u/5319224?v=4", "events_url": "https://api.github.com/users/swmerko/events{/privacy}", "followers_url": "https://api.github.com/users/swmerko/followers", "following_url": "https://api.github.com/users/swmerko/following{/other_user}", "gists_url": "https://api.github.com/users/swmerko/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/swmerko", "id": 5319224, "login": "swmerko", "node_id": "MDQ6VXNlcjUzMTkyMjQ=", "organizations_url": "https://api.github.com/users/swmerko/orgs", "received_events_url": "https://api.github.com/users/swmerko/received_events", "repos_url": "https://api.github.com/users/swmerko/repos", "site_admin": false, "starred_url": "https://api.github.com/users/swmerko/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/swmerko/subscriptions", "type": "User", "url": "https://api.github.com/users/swmerko", "user_view_type": "public" }
[]
closed
true
null
[]
null
4
2016-01-11T12:11:55Z
2021-09-08T20:00:48Z
2016-01-11T12:13:40Z
NONE
resolved
Hi, i'm trying to force ssl.PROTOCOL_TLSv1 as written in documentation: http://docs.python-requests.org/en/latest/user/advanced/#example-specific-ssl-version ``` from requests.adapters import HTTPAdapter from requests.packages.urllib3.poolmanager import PoolManager import ssl class MyAdapter(HTTPAdapter): def init_poolmanager(self, connections, maxsize, block=False): self.poolmanager = PoolManager(num_pools=connections, maxsize=maxsize, block=block, ssl_version=ssl.PROTOCOL_TLSv1) import requests s = requests.Session() s.mount('https://', MyAdapter()) requests.get('https://services.mailup.com/') ``` but this gives me ``` requests.exceptions.SSLError: [SSL: SSLV3_ALERT_HANDSHAKE_FAILURE] sslv3 alert handshake failure (_ssl.c:600) ``` so i tried to patch requests/packages/urllib3/poolmanager.py with: ``` class PoolManager(RequestMethods): proxy = None def __init__(self, num_pools=10, headers=None, **connection_pool_kw): RequestMethods.__init__(self, headers) connection_pool_kw['ssl_version'] = ssl.PROTOCOL_TLSv1 self.connection_pool_kw = connection_pool_kw self.pools = RecentlyUsedContainer(num_pools, dispose_func=lambda p: p.close()) ``` and i get: ``` >>> import requests >>> requests.get('https://services.mailup.com/') <Response [403]> ``` Any ideas? Thanks, Matteo
{ "avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4", "events_url": "https://api.github.com/users/Lukasa/events{/privacy}", "followers_url": "https://api.github.com/users/Lukasa/followers", "following_url": "https://api.github.com/users/Lukasa/following{/other_user}", "gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/Lukasa", "id": 1382556, "login": "Lukasa", "node_id": "MDQ6VXNlcjEzODI1NTY=", "organizations_url": "https://api.github.com/users/Lukasa/orgs", "received_events_url": "https://api.github.com/users/Lukasa/received_events", "repos_url": "https://api.github.com/users/Lukasa/repos", "site_admin": false, "starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions", "type": "User", "url": "https://api.github.com/users/Lukasa", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/2965/reactions" }
https://api.github.com/repos/psf/requests/issues/2965/timeline
null
completed
null
null
false
[ "@swmerko You have to route your request through the Session object. In your code example you create a Session object `s`, but then call `requests.get`. That's not how Session objects work. Change your last line to `s.get()` instead of `requests.get()` and your problem should be solved.\n", "Is there a way to def...
https://api.github.com/repos/psf/requests/issues/2964
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/2964/labels{/name}
https://api.github.com/repos/psf/requests/issues/2964/comments
https://api.github.com/repos/psf/requests/issues/2964/events
https://github.com/psf/requests/pull/2964
125,830,552
MDExOlB1bGxSZXF1ZXN0NTU1Njg4MDI=
2,964
Python 3.5 : AttributeError: 'socket' object has no attribute 'getpeercert'
{ "avatar_url": "https://avatars.githubusercontent.com/u/2358471?v=4", "events_url": "https://api.github.com/users/FabriceSalvaire/events{/privacy}", "followers_url": "https://api.github.com/users/FabriceSalvaire/followers", "following_url": "https://api.github.com/users/FabriceSalvaire/following{/other_user}", "gists_url": "https://api.github.com/users/FabriceSalvaire/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/FabriceSalvaire", "id": 2358471, "login": "FabriceSalvaire", "node_id": "MDQ6VXNlcjIzNTg0NzE=", "organizations_url": "https://api.github.com/users/FabriceSalvaire/orgs", "received_events_url": "https://api.github.com/users/FabriceSalvaire/received_events", "repos_url": "https://api.github.com/users/FabriceSalvaire/repos", "site_admin": false, "starred_url": "https://api.github.com/users/FabriceSalvaire/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/FabriceSalvaire/subscriptions", "type": "User", "url": "https://api.github.com/users/FabriceSalvaire", "user_view_type": "public" }
[]
closed
true
null
[]
null
1
2016-01-10T16:48:25Z
2021-09-08T05:01:05Z
2016-01-10T16:50:18Z
NONE
resolved
Traceback: File "/opt/python-virtual-env/py35/lib/python3.5/site-packages/yieldfrom/requests/api.py", line 61, in get r = yield from request('get', url, *_kwargs) File "/opt/python-virtual-env/py35/lib/python3.5/site-packages/yieldfrom/requests/api.py", line 49, in request r = yield from session.request(method=method, url=url, *_kwargs) File "/opt/python-virtual-env/py35/lib/python3.5/site-packages/yieldfrom/requests/sessions.py", line 465, in request resp = yield from self.send(prep, *_send_kwargs) File "/opt/python-virtual-env/py35/lib/python3.5/site-packages/yieldfrom/requests/sessions.py", line 579, in send r = yield from adapter.send(request, *_kwargs) File "/opt/python-virtual-env/py35/lib/python3.5/site-packages/yieldfrom/requests/adapters.py", line 364, in send timeout=timeout File "/opt/python-virtual-env/py35/lib/python3.5/site-packages/yieldfrom/urllib3/connectionpool.py", line 515, in urlopen body=body, headers=headers) File "/opt/python-virtual-env/py35/lib/python3.5/site-packages/yieldfrom/urllib3/connectionpool.py", line 309, in _make_request yield from self._validate_conn(conn) File "/opt/python-virtual-env/py35/lib/python3.5/site-packages/yieldfrom/urllib3/connectionpool.py", line 730, in _validate_conn yield from conn.connect() File "/opt/python-virtual-env/py35/lib/python3.5/site-packages/yieldfrom/urllib3/connection.py", line 295, in connect match_hostname(sock.getpeercert(), AttributeError: 'socket' object has no attribute 'getpeercert' sock instance is of type socket.socket
{ "avatar_url": "https://avatars.githubusercontent.com/u/2358471?v=4", "events_url": "https://api.github.com/users/FabriceSalvaire/events{/privacy}", "followers_url": "https://api.github.com/users/FabriceSalvaire/followers", "following_url": "https://api.github.com/users/FabriceSalvaire/following{/other_user}", "gists_url": "https://api.github.com/users/FabriceSalvaire/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/FabriceSalvaire", "id": 2358471, "login": "FabriceSalvaire", "node_id": "MDQ6VXNlcjIzNTg0NzE=", "organizations_url": "https://api.github.com/users/FabriceSalvaire/orgs", "received_events_url": "https://api.github.com/users/FabriceSalvaire/received_events", "repos_url": "https://api.github.com/users/FabriceSalvaire/repos", "site_admin": false, "starred_url": "https://api.github.com/users/FabriceSalvaire/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/FabriceSalvaire/subscriptions", "type": "User", "url": "https://api.github.com/users/FabriceSalvaire", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/2964/reactions" }
https://api.github.com/repos/psf/requests/issues/2964/timeline
null
null
false
{ "diff_url": "https://github.com/psf/requests/pull/2964.diff", "html_url": "https://github.com/psf/requests/pull/2964", "merged_at": null, "patch_url": "https://github.com/psf/requests/pull/2964.patch", "url": "https://api.github.com/repos/psf/requests/pulls/2964" }
true
[ "It is a mistake using \"New Pull Request\" from rdbhost:master. Sorry.\n" ]
https://api.github.com/repos/psf/requests/issues/2963
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/2963/labels{/name}
https://api.github.com/repos/psf/requests/issues/2963/comments
https://api.github.com/repos/psf/requests/issues/2963/events
https://github.com/psf/requests/issues/2963
125,295,072
MDU6SXNzdWUxMjUyOTUwNzI=
2,963
ResourceWarning still triggered when warnings enabled
{ "avatar_url": "https://avatars.githubusercontent.com/u/796623?v=4", "events_url": "https://api.github.com/users/anarcat/events{/privacy}", "followers_url": "https://api.github.com/users/anarcat/followers", "following_url": "https://api.github.com/users/anarcat/following{/other_user}", "gists_url": "https://api.github.com/users/anarcat/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/anarcat", "id": 796623, "login": "anarcat", "node_id": "MDQ6VXNlcjc5NjYyMw==", "organizations_url": "https://api.github.com/users/anarcat/orgs", "received_events_url": "https://api.github.com/users/anarcat/received_events", "repos_url": "https://api.github.com/users/anarcat/repos", "site_admin": false, "starred_url": "https://api.github.com/users/anarcat/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/anarcat/subscriptions", "type": "User", "url": "https://api.github.com/users/anarcat", "user_view_type": "public" }
[]
closed
true
null
[]
null
10
2016-01-07T00:25:14Z
2021-09-08T20:00:47Z
2016-01-07T11:04:50Z
NONE
resolved
I can reproducibly get ResourceWarnings when running incomplete requests with [iter_lines](http://docs.python-requests.org/en/latest/api/#requests.Response.iter_lines). this is my test code: ``` python #!/usr/bin/python3 from contextlib import closing import re import time import warnings import requests print("requests %s" % requests.__version__) max_bytes = 640*1024 def test_get_title_close(url): response = requests.get(url, stream=True) try: content = '' for line in response.iter_lines(decode_unicode=True): content += line if '</title>' in content or len(content) > max_bytes: break except (UnicodeDecodeError, TypeError): # Fail silently when data can't be decoded return finally: # need to close the connexion because we have not read all the data response.connection.close() response.connection.close() print('title found: %s' % re.sub(r'^.*<title>', '', re.sub(r'</title>.*$', '', content))) def test_get_title_closing(url): with closing(requests.get(url, stream=True)) as response: try: content = '' for line in response.iter_lines(decode_unicode=True): content += line if '</title>' in content or len(content) > max_bytes: break except (UnicodeDecodeError, TypeError): # Fail silently when data can't be decoded return finally: # need to close the connexion because we have not read all the data response.close() # also trying the undocumented ones response.connection.close() print('title found: %s' % re.sub(r'^.*<title>', '', re.sub(r'</title>.*$', '', content))) warnings.filterwarnings('default') test_get_title_closing('http://example.com/') # this should not warn, but does test_get_title_close('http://example.com/') # this should not warn, but does also ``` it's taken from this pull request: https://github.com/sopel-irc/sopel/pull/988 - which tries to switch an irc bot from using a homegrown http library to the more standard "requests". the original code does not yield such warnings even though it also does HTTPS connections. here is the output: ``` $ python3 test_requests_fail.py requests 2.9.1 title found: Example Domain ../test_requests_fail.py:53: ResourceWarning: unclosed <socket.socket fd=4, family=AddressFamily.AF_INET6, type=SocketType.SOCK_STREAM, proto=6, laddr=('2607:f2c0:f00f:8f00:ea9a:8fff:fe6e:f60', 39628, 0, 0), raddr=('2606:2800:220:1:248:1893:25c8:1946', 80, 0, 0)> test_get_title_closing('http://example.com/') # this should not warn, but does title found: Example Domain ../test_requests_fail.py:54: ResourceWarning: unclosed <socket.socket fd=4, family=AddressFamily.AF_INET6, type=SocketType.SOCK_STREAM, proto=6, laddr=('2607:f2c0:f00f:8f00:ea9a:8fff:fe6e:f60', 39630, 0, 0), raddr=('2606:2800:220:1:248:1893:25c8:1946', 80, 0, 0)> test_get_title_close('http://example.com/') # this should not warn, but does also ``` notice how i tried my best to close the resources, using various methods, none of which work. there's something definitely fishy about the way this works. this is on Debian Jessie 8.2, with the latest requests installed from pip (2.9.1), or jessie-backports (2.8.1-1~bpo8+1) and Python 3.4.2. oddly enough, older requests versions do _not_ have that problem: 2.4.3 from plain old jessie is actually fine! so it sure looks like something broke since 2.4.3 in the fix proposed in #1882 and #2004.
{ "avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4", "events_url": "https://api.github.com/users/Lukasa/events{/privacy}", "followers_url": "https://api.github.com/users/Lukasa/followers", "following_url": "https://api.github.com/users/Lukasa/following{/other_user}", "gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/Lukasa", "id": 1382556, "login": "Lukasa", "node_id": "MDQ6VXNlcjEzODI1NTY=", "organizations_url": "https://api.github.com/users/Lukasa/orgs", "received_events_url": "https://api.github.com/users/Lukasa/received_events", "repos_url": "https://api.github.com/users/Lukasa/repos", "site_admin": false, "starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions", "type": "User", "url": "https://api.github.com/users/Lukasa", "user_view_type": "public" }
{ "+1": 1, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 1, "url": "https://api.github.com/repos/psf/requests/issues/2963/reactions" }
https://api.github.com/repos/psf/requests/issues/2963/timeline
null
completed
null
null
false
[ "Requests works very hard to prevent you closing a response. This is because it gets in the way of our connection pooling. If you _really must_ close the connection, you need to close the underlying urllib3 connection: use `response.raw.close()`.\n\nThe reason the resource warnings are back is because we're much be...
https://api.github.com/repos/psf/requests/issues/2962
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/2962/labels{/name}
https://api.github.com/repos/psf/requests/issues/2962/comments
https://api.github.com/repos/psf/requests/issues/2962/events
https://github.com/psf/requests/issues/2962
125,270,260
MDU6SXNzdWUxMjUyNzAyNjA=
2,962
Stay in a queue
{ "avatar_url": "https://avatars.githubusercontent.com/u/1591920?v=4", "events_url": "https://api.github.com/users/Djokx/events{/privacy}", "followers_url": "https://api.github.com/users/Djokx/followers", "following_url": "https://api.github.com/users/Djokx/following{/other_user}", "gists_url": "https://api.github.com/users/Djokx/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/Djokx", "id": 1591920, "login": "Djokx", "node_id": "MDQ6VXNlcjE1OTE5MjA=", "organizations_url": "https://api.github.com/users/Djokx/orgs", "received_events_url": "https://api.github.com/users/Djokx/received_events", "repos_url": "https://api.github.com/users/Djokx/repos", "site_admin": false, "starred_url": "https://api.github.com/users/Djokx/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Djokx/subscriptions", "type": "User", "url": "https://api.github.com/users/Djokx", "user_view_type": "public" }
[]
closed
true
null
[]
null
3
2016-01-06T21:44:02Z
2021-09-08T20:00:48Z
2016-01-06T23:13:45Z
NONE
resolved
Hi, I've written a program which works perfectly well to seek inforamtions on a website. But when too many people are on this site, a queue is set in order to avoid crashes of the server. The issue is that the script stays in the queue forever. I mean, on a browser we the queue is there you join it automaticly and after a few minutes, you're on the website (even you reload the page, you keep your place in the queue). However, if we launch the site in a private navigation tab, it starts from afresh. So, I assume that is a question of Session or Cookies (it's not related to the IP). Does anyone have an idea of how to solve this issue ? I think it should be by using some Session/cookies function but I don't know how to do that. Thanks, Djokx.
{ "avatar_url": "https://avatars.githubusercontent.com/u/240830?v=4", "events_url": "https://api.github.com/users/sigmavirus24/events{/privacy}", "followers_url": "https://api.github.com/users/sigmavirus24/followers", "following_url": "https://api.github.com/users/sigmavirus24/following{/other_user}", "gists_url": "https://api.github.com/users/sigmavirus24/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/sigmavirus24", "id": 240830, "login": "sigmavirus24", "node_id": "MDQ6VXNlcjI0MDgzMA==", "organizations_url": "https://api.github.com/users/sigmavirus24/orgs", "received_events_url": "https://api.github.com/users/sigmavirus24/received_events", "repos_url": "https://api.github.com/users/sigmavirus24/repos", "site_admin": false, "starred_url": "https://api.github.com/users/sigmavirus24/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sigmavirus24/subscriptions", "type": "User", "url": "https://api.github.com/users/sigmavirus24", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/2962/reactions" }
https://api.github.com/repos/psf/requests/issues/2962/timeline
null
completed
null
null
false
[ "@Djokx are you using the requests library in your project? This is a repository for a Python library called requests, not a repository to request help for arbitrary problems. If you are using this library, could you share some code so we can help you debug whatever problem it is that you're running into? It's not ...
https://api.github.com/repos/psf/requests/issues/2961
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/2961/labels{/name}
https://api.github.com/repos/psf/requests/issues/2961/comments
https://api.github.com/repos/psf/requests/issues/2961/events
https://github.com/psf/requests/pull/2961
125,011,663
MDExOlB1bGxSZXF1ZXN0NTUxMTc5NzU=
2,961
Rename {Missing,Invalid}Schema to *Scheme
{ "avatar_url": "https://avatars.githubusercontent.com/u/134455?v=4", "events_url": "https://api.github.com/users/chadwhitacre/events{/privacy}", "followers_url": "https://api.github.com/users/chadwhitacre/followers", "following_url": "https://api.github.com/users/chadwhitacre/following{/other_user}", "gists_url": "https://api.github.com/users/chadwhitacre/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/chadwhitacre", "id": 134455, "login": "chadwhitacre", "node_id": "MDQ6VXNlcjEzNDQ1NQ==", "organizations_url": "https://api.github.com/users/chadwhitacre/orgs", "received_events_url": "https://api.github.com/users/chadwhitacre/received_events", "repos_url": "https://api.github.com/users/chadwhitacre/repos", "site_admin": false, "starred_url": "https://api.github.com/users/chadwhitacre/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/chadwhitacre/subscriptions", "type": "User", "url": "https://api.github.com/users/chadwhitacre", "user_view_type": "public" }
[]
closed
true
null
[]
null
7
2016-01-05T17:22:26Z
2021-09-08T05:01:05Z
2016-01-05T17:23:21Z
CONTRIBUTOR
resolved
As @merwok pointed out at https://github.com/kennethreitz/requests/pull/512#commitcomment-1296187, schemes are what they're called, not schemas. I got tripped up by this at https://github.com/CenterForOpenScience/osf.io/pull/4745#issuecomment-169038417, where "InvalidSchema" made me think I was hitting a database error, when in fact it was a configuration error in the format of a URL. This PR is a redo of #2960 against `proposed/3.0.0` instead of `master`.
{ "avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4", "events_url": "https://api.github.com/users/Lukasa/events{/privacy}", "followers_url": "https://api.github.com/users/Lukasa/followers", "following_url": "https://api.github.com/users/Lukasa/following{/other_user}", "gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/Lukasa", "id": 1382556, "login": "Lukasa", "node_id": "MDQ6VXNlcjEzODI1NTY=", "organizations_url": "https://api.github.com/users/Lukasa/orgs", "received_events_url": "https://api.github.com/users/Lukasa/received_events", "repos_url": "https://api.github.com/users/Lukasa/repos", "site_admin": false, "starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions", "type": "User", "url": "https://api.github.com/users/Lukasa", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/2961/reactions" }
https://api.github.com/repos/psf/requests/issues/2961/timeline
null
null
false
{ "diff_url": "https://github.com/psf/requests/pull/2961.diff", "html_url": "https://github.com/psf/requests/pull/2961", "merged_at": "2016-01-05T17:23:21Z", "patch_url": "https://github.com/psf/requests/pull/2961.patch", "url": "https://api.github.com/repos/psf/requests/pulls/2961" }
true
[ "\\o/ Thanks @whit537! :sparkles: :cake: :sparkles:\n", "Huzzah, thanks! :-)\n\n@Lukasa++\n", "@Lukasa please add release notes for this. I think it may be a good idea to have some shim for this as people may be catching `InvalidSchema` or `MissingSchema` exceptions and they won't be able to catch those anymore...
https://api.github.com/repos/psf/requests/issues/2960
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/2960/labels{/name}
https://api.github.com/repos/psf/requests/issues/2960/comments
https://api.github.com/repos/psf/requests/issues/2960/events
https://github.com/psf/requests/pull/2960
125,000,851
MDExOlB1bGxSZXF1ZXN0NTUxMTE1MzI=
2,960
Rename {Missing,Invalid}Schema to *Scheme
{ "avatar_url": "https://avatars.githubusercontent.com/u/134455?v=4", "events_url": "https://api.github.com/users/chadwhitacre/events{/privacy}", "followers_url": "https://api.github.com/users/chadwhitacre/followers", "following_url": "https://api.github.com/users/chadwhitacre/following{/other_user}", "gists_url": "https://api.github.com/users/chadwhitacre/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/chadwhitacre", "id": 134455, "login": "chadwhitacre", "node_id": "MDQ6VXNlcjEzNDQ1NQ==", "organizations_url": "https://api.github.com/users/chadwhitacre/orgs", "received_events_url": "https://api.github.com/users/chadwhitacre/received_events", "repos_url": "https://api.github.com/users/chadwhitacre/repos", "site_admin": false, "starred_url": "https://api.github.com/users/chadwhitacre/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/chadwhitacre/subscriptions", "type": "User", "url": "https://api.github.com/users/chadwhitacre", "user_view_type": "public" }
[ { "color": "eb6420", "default": false, "description": null, "id": 44501256, "name": "Breaking API Change", "node_id": "MDU6TGFiZWw0NDUwMTI1Ng==", "url": "https://api.github.com/repos/psf/requests/labels/Breaking%20API%20Change" }, { "color": "e11d21", "default": false, "d...
closed
true
null
[]
null
3
2016-01-05T16:30:37Z
2021-09-08T05:01:06Z
2016-01-05T17:15:13Z
CONTRIBUTOR
resolved
As @merwok pointed out at https://github.com/kennethreitz/requests/pull/512#commitcomment-1296187, schemes are what they're called, not schemas. I got tripped up by this at https://github.com/CenterForOpenScience/osf.io/pull/4745#issuecomment-169038417, where "InvalidSchema" made me think I was hitting a database error, when in fact it was a configuration error in the format of a URL.
{ "avatar_url": "https://avatars.githubusercontent.com/u/134455?v=4", "events_url": "https://api.github.com/users/chadwhitacre/events{/privacy}", "followers_url": "https://api.github.com/users/chadwhitacre/followers", "following_url": "https://api.github.com/users/chadwhitacre/following{/other_user}", "gists_url": "https://api.github.com/users/chadwhitacre/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/chadwhitacre", "id": 134455, "login": "chadwhitacre", "node_id": "MDQ6VXNlcjEzNDQ1NQ==", "organizations_url": "https://api.github.com/users/chadwhitacre/orgs", "received_events_url": "https://api.github.com/users/chadwhitacre/received_events", "repos_url": "https://api.github.com/users/chadwhitacre/repos", "site_admin": false, "starred_url": "https://api.github.com/users/chadwhitacre/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/chadwhitacre/subscriptions", "type": "User", "url": "https://api.github.com/users/chadwhitacre", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/2960/reactions" }
https://api.github.com/repos/psf/requests/issues/2960/timeline
null
null
false
{ "diff_url": "https://github.com/psf/requests/pull/2960.diff", "html_url": "https://github.com/psf/requests/pull/2960", "merged_at": null, "patch_url": "https://github.com/psf/requests/pull/2960.patch", "url": "https://api.github.com/repos/psf/requests/pulls/2960" }
true
[ "Thanks @whit537. Unfortunately, this is a breaking change so we can't accept it until 3.0.0: can you adjust this PR to point to the proposed/3.0.0 branch instead please?\n", "Sure thing. Closing this PR ...\n", "It occurs to me that it'd be possible to implement this in a backwards-compatible way, but since th...
https://api.github.com/repos/psf/requests/issues/2959
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/2959/labels{/name}
https://api.github.com/repos/psf/requests/issues/2959/comments
https://api.github.com/repos/psf/requests/issues/2959/events
https://github.com/psf/requests/issues/2959
124,929,466
MDU6SXNzdWUxMjQ5Mjk0NjY=
2,959
CERTIFICATE_VERIFY_FAILED with python-requests 2.8.1 and curl, but works in browsers
{ "avatar_url": "https://avatars.githubusercontent.com/u/406946?v=4", "events_url": "https://api.github.com/users/progval/events{/privacy}", "followers_url": "https://api.github.com/users/progval/followers", "following_url": "https://api.github.com/users/progval/following{/other_user}", "gists_url": "https://api.github.com/users/progval/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/progval", "id": 406946, "login": "progval", "node_id": "MDQ6VXNlcjQwNjk0Ng==", "organizations_url": "https://api.github.com/users/progval/orgs", "received_events_url": "https://api.github.com/users/progval/received_events", "repos_url": "https://api.github.com/users/progval/repos", "site_admin": false, "starred_url": "https://api.github.com/users/progval/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/progval/subscriptions", "type": "User", "url": "https://api.github.com/users/progval", "user_view_type": "public" }
[]
closed
true
null
[]
null
2
2016-01-05T09:43:27Z
2021-09-08T20:00:49Z
2016-01-05T10:13:19Z
NONE
resolved
``` $ python3 Python 3.4.2 (default, Oct 8 2014, 10:45:20) [GCC 4.9.1] on linux Type "help", "copyright", "credits" or "license" for more information. >>> import requests >>> requests.get('https://irestos.nuonet.fr/generation.php?crous=21&resto=351&ext=xml') Traceback (most recent call last): File "/home/progval/.local/lib/python3.4/site-packages/requests/packages/urllib3/connectionpool.py", line 559, in urlopen body=body, headers=headers) File "/home/progval/.local/lib/python3.4/site-packages/requests/packages/urllib3/connectionpool.py", line 345, in _make_request self._validate_conn(conn) File "/home/progval/.local/lib/python3.4/site-packages/requests/packages/urllib3/connectionpool.py", line 782, in _validate_conn conn.connect() File "/home/progval/.local/lib/python3.4/site-packages/requests/packages/urllib3/connection.py", line 250, in connect ssl_version=resolved_ssl_version) File "/home/progval/.local/lib/python3.4/site-packages/requests/packages/urllib3/util/ssl_.py", line 285, in ssl_wrap_socket return context.wrap_socket(sock, server_hostname=server_hostname) File "/usr/lib/python3.4/ssl.py", line 364, in wrap_socket _context=self) File "/usr/lib/python3.4/ssl.py", line 577, in __init__ self.do_handshake() File "/usr/lib/python3.4/ssl.py", line 804, in do_handshake self._sslobj.do_handshake() ssl.SSLError: [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed (_ssl.c:600) During handling of the above exception, another exception occurred: Traceback (most recent call last): File "/home/progval/.local/lib/python3.4/site-packages/requests/adapters.py", line 370, in send timeout=timeout File "/home/progval/.local/lib/python3.4/site-packages/requests/packages/urllib3/connectionpool.py", line 588, in urlopen raise SSLError(e) requests.packages.urllib3.exceptions.SSLError: [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed (_ssl.c:600) During handling of the above exception, another exception occurred: Traceback (most recent call last): File "<stdin>", line 1, in <module> File "/home/progval/.local/lib/python3.4/site-packages/requests/api.py", line 69, in get return request('get', url, params=params, **kwargs) File "/home/progval/.local/lib/python3.4/site-packages/requests/api.py", line 50, in request response = session.request(method=method, url=url, **kwargs) File "/home/progval/.local/lib/python3.4/site-packages/requests/sessions.py", line 468, in request resp = self.send(prep, **send_kwargs) File "/home/progval/.local/lib/python3.4/site-packages/requests/sessions.py", line 576, in send r = adapter.send(request, **kwargs) File "/home/progval/.local/lib/python3.4/site-packages/requests/adapters.py", line 433, in send raise SSLError(e, request=request) requests.exceptions.SSLError: [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed (_ssl.c:600) >>> requests.__version__ '2.8.1' ``` curl and openssl's CLI have the same issue: ``` $ curl https://irestos.nuonet.fr/generation.php\?crous\=21\&resto\=351\&ext\=xml curl: (60) SSL certificate problem: unable to get local issuer certificate ``` ``` $ openssl s_client -connect irestos.nuonet.fr:443 CONNECTED(00000003) depth=0 C = FR, ST = Picardie, L = AMIENS, O = CROUS d'Amiens-Picardie, OU = CROUS, CN = irestos.nuonet.fr verify error:num=20:unable to get local issuer certificate verify return:1 depth=0 C = FR, ST = Picardie, L = AMIENS, O = CROUS d'Amiens-Picardie, OU = CROUS, CN = irestos.nuonet.fr verify error:num=27:certificate not trusted verify return:1 depth=0 C = FR, ST = Picardie, L = AMIENS, O = CROUS d'Amiens-Picardie, OU = CROUS, CN = irestos.nuonet.fr verify error:num=21:unable to verify the first certificate verify return:1 --- Certificate chain 0 s:/C=FR/ST=Picardie/L=AMIENS/O=CROUS d'Amiens-Picardie/OU=CROUS/CN=irestos.nuonet.fr i:/C=NL/ST=Noord-Holland/L=Amsterdam/O=TERENA/CN=TERENA SSL CA 3 --- Server certificate -----BEGIN CERTIFICATE----- […] -----END CERTIFICATE----- subject=/C=FR/ST=Picardie/L=AMIENS/O=CROUS d'Amiens-Picardie/OU=CROUS/CN=irestos.nuonet.fr issuer=/C=NL/ST=Noord-Holland/L=Amsterdam/O=TERENA/CN=TERENA SSL CA 3 --- No client certificate CA names sent --- SSL handshake has read 2022 bytes and written 421 bytes --- New, TLSv1/SSLv3, Cipher is ECDHE-RSA-AES256-GCM-SHA384 Server public key is 2048 bit Secure Renegotiation IS supported Compression: NONE Expansion: NONE SSL-Session: Protocol : TLSv1.2 Cipher : ECDHE-RSA-AES256-GCM-SHA384 Session-ID: F603E70CBC9F7B2B5033280D6F72334EC63FA7F727464620B4790BA477556B25 Session-ID-ctx: Master-Key: C912001D02A8076AB864D9D51B2A056F76B49CD27B8A29EB7632EBA3EBB4124B1F908FAAF7CFE05028C51DAA07658762 Key-Arg : None PSK identity: None PSK identity hint: None SRP username: None TLS session ticket lifetime hint: 300 (seconds) TLS session ticket: 0000 - 46 7b 46 24 40 2f 6d ed-51 8c 7c e9 29 0a 55 99 F{F$@/m.Q.|.).U. 0010 - 20 61 4b 43 2a 9f 9e f8-15 0a 63 b3 e5 e7 20 75 aKC*.....c... u 0020 - d5 51 5c 8a 7b 26 cd 32-02 83 69 e6 ef 06 0d c6 .Q\.{&.2..i..... 0030 - 8a 35 40 82 d5 1b d3 c4-3e 57 dd 98 4d 29 f0 2d .5@.....>W..M).- 0040 - ed 62 d0 a5 ec 0e 41 1c-d4 61 e9 a2 d6 8f 2e 3e .b....A..a.....> 0050 - 29 a6 1e 83 43 40 4a 36-ac 01 6f f3 2f 6b e9 49 )...C@J6..o./k.I 0060 - b7 05 44 ff 57 5a e3 c6-8d 93 25 d1 ed 3f 7d 48 ..D.WZ....%..?}H 0070 - 8b dd 1b 3e f7 0f 36 3f-54 6a ac 36 8f a1 c0 97 ...>..6?Tj.6.... 0080 - ee ff 80 bf 52 a8 61 c3-e5 71 1e 4e 51 e3 d7 1f ....R.a..q.NQ... 0090 - 83 a3 f6 d1 79 9b e8 b4-b9 e7 d7 e0 d1 b4 1e e0 ....y........... 00a0 - 28 88 e0 5b e6 67 bd e1-96 50 5a 48 13 05 de b1 (..[.g...PZH.... 00b0 - 28 0b 1d e6 dd e1 d2 2f-8e 45 73 a7 8c 06 f7 47 (....../.Es....G Start Time: 1451986602 Timeout : 300 (sec) Verify return code: 21 (unable to verify the first certificate) --- ``` But the same URL works fine with Firefox 43 and Chromium 47.0.2526.80. System: Debian 8.2 (Jessie)
{ "avatar_url": "https://avatars.githubusercontent.com/u/406946?v=4", "events_url": "https://api.github.com/users/progval/events{/privacy}", "followers_url": "https://api.github.com/users/progval/followers", "following_url": "https://api.github.com/users/progval/following{/other_user}", "gists_url": "https://api.github.com/users/progval/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/progval", "id": 406946, "login": "progval", "node_id": "MDQ6VXNlcjQwNjk0Ng==", "organizations_url": "https://api.github.com/users/progval/orgs", "received_events_url": "https://api.github.com/users/progval/received_events", "repos_url": "https://api.github.com/users/progval/repos", "site_admin": false, "starred_url": "https://api.github.com/users/progval/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/progval/subscriptions", "type": "User", "url": "https://api.github.com/users/progval", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/2959/reactions" }
https://api.github.com/repos/psf/requests/issues/2959/timeline
null
completed
null
null
false
[ "This is almost certainly because the site is not sending its intermediate certificates.\n\nGenerally, when configuring a site for TLS, the site author should ensure that the TLS handshake sends both the leaf certificate (the one valid for that site) _and_ any intermediate certificates between the leaf and the root...
https://api.github.com/repos/psf/requests/issues/2958
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/2958/labels{/name}
https://api.github.com/repos/psf/requests/issues/2958/comments
https://api.github.com/repos/psf/requests/issues/2958/events
https://github.com/psf/requests/pull/2958
124,792,493
MDExOlB1bGxSZXF1ZXN0NTQ5OTQyOTM=
2,958
Add equality functions for authentication handlers
{ "avatar_url": "https://avatars.githubusercontent.com/u/1901599?v=4", "events_url": "https://api.github.com/users/Malizor/events{/privacy}", "followers_url": "https://api.github.com/users/Malizor/followers", "following_url": "https://api.github.com/users/Malizor/following{/other_user}", "gists_url": "https://api.github.com/users/Malizor/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/Malizor", "id": 1901599, "login": "Malizor", "node_id": "MDQ6VXNlcjE5MDE1OTk=", "organizations_url": "https://api.github.com/users/Malizor/orgs", "received_events_url": "https://api.github.com/users/Malizor/received_events", "repos_url": "https://api.github.com/users/Malizor/repos", "site_admin": false, "starred_url": "https://api.github.com/users/Malizor/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Malizor/subscriptions", "type": "User", "url": "https://api.github.com/users/Malizor", "user_view_type": "public" }
[]
closed
true
null
[]
null
8
2016-01-04T16:39:11Z
2021-09-08T05:01:02Z
2016-01-30T03:08:26Z
CONTRIBUTOR
resolved
A use case for this is mocking. If you have a function that wrap a call like `requests.post('http://my_url', auth=HTTPBasicAuth(user, password))` and mock requests.post in your tests, calling `assert_called_once_with('http://my_url', auth=HTTPBasicAuth(user, password))` will fail. Implementing equality functions solves this use case.
{ "avatar_url": "https://avatars.githubusercontent.com/u/119893?v=4", "events_url": "https://api.github.com/users/kennethreitz/events{/privacy}", "followers_url": "https://api.github.com/users/kennethreitz/followers", "following_url": "https://api.github.com/users/kennethreitz/following{/other_user}", "gists_url": "https://api.github.com/users/kennethreitz/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/kennethreitz", "id": 119893, "login": "kennethreitz", "node_id": "MDQ6VXNlcjExOTg5Mw==", "organizations_url": "https://api.github.com/users/kennethreitz/orgs", "received_events_url": "https://api.github.com/users/kennethreitz/received_events", "repos_url": "https://api.github.com/users/kennethreitz/repos", "site_admin": false, "starred_url": "https://api.github.com/users/kennethreitz/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/kennethreitz/subscriptions", "type": "User", "url": "https://api.github.com/users/kennethreitz", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/2958/reactions" }
https://api.github.com/repos/psf/requests/issues/2958/timeline
null
null
false
{ "diff_url": "https://github.com/psf/requests/pull/2958.diff", "html_url": "https://github.com/psf/requests/pull/2958", "merged_at": "2016-01-30T03:08:26Z", "patch_url": "https://github.com/psf/requests/pull/2958.patch", "url": "https://api.github.com/repos/psf/requests/pulls/2958" }
true
[ "Was there already a bug or discussion of this? I didn't notice it if there was.\n\nI'm pretty sure there's no other practical use of this which makes me very conflicted about accepting this.\n\nYes it would be nice to be able to use `assert_called_once_with` but there are many other ways to do exactly that while a...
https://api.github.com/repos/psf/requests/issues/2957
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/2957/labels{/name}
https://api.github.com/repos/psf/requests/issues/2957/comments
https://api.github.com/repos/psf/requests/issues/2957/events
https://github.com/psf/requests/issues/2957
124,580,502
MDU6SXNzdWUxMjQ1ODA1MDI=
2,957
Persistent Connection suffer from delay of Nagle
{ "avatar_url": "https://avatars.githubusercontent.com/u/4146182?v=4", "events_url": "https://api.github.com/users/zhangi/events{/privacy}", "followers_url": "https://api.github.com/users/zhangi/followers", "following_url": "https://api.github.com/users/zhangi/following{/other_user}", "gists_url": "https://api.github.com/users/zhangi/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/zhangi", "id": 4146182, "login": "zhangi", "node_id": "MDQ6VXNlcjQxNDYxODI=", "organizations_url": "https://api.github.com/users/zhangi/orgs", "received_events_url": "https://api.github.com/users/zhangi/received_events", "repos_url": "https://api.github.com/users/zhangi/repos", "site_admin": false, "starred_url": "https://api.github.com/users/zhangi/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/zhangi/subscriptions", "type": "User", "url": "https://api.github.com/users/zhangi", "user_view_type": "public" }
[]
closed
true
null
[]
null
5
2016-01-02T08:00:31Z
2021-09-08T20:00:49Z
2016-01-02T10:53:27Z
NONE
resolved
Not sure if this is a bug from urllib3 or Requests, the problem is that there is an extra delay introduced for all subsequent requests other than the first one when reusing a session object. The test are performed in Ubuntu 14 to a http server running on the localhost ``` python with requests.Session() as session: session.get(url) # this takes <1ms session.get(url) # this takes around 40ms session.get(url) # this takes around 40ms ``` Similar case was observed in httplib2 with Python 2.6(https://code.google.com/p/httplib2/issues/detail?id=91), and was fixed in Python 2.7.
{ "avatar_url": "https://avatars.githubusercontent.com/u/4146182?v=4", "events_url": "https://api.github.com/users/zhangi/events{/privacy}", "followers_url": "https://api.github.com/users/zhangi/followers", "following_url": "https://api.github.com/users/zhangi/following{/other_user}", "gists_url": "https://api.github.com/users/zhangi/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/zhangi", "id": 4146182, "login": "zhangi", "node_id": "MDQ6VXNlcjQxNDYxODI=", "organizations_url": "https://api.github.com/users/zhangi/orgs", "received_events_url": "https://api.github.com/users/zhangi/received_events", "repos_url": "https://api.github.com/users/zhangi/repos", "site_admin": false, "starred_url": "https://api.github.com/users/zhangi/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/zhangi/subscriptions", "type": "User", "url": "https://api.github.com/users/zhangi", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/2957/reactions" }
https://api.github.com/repos/psf/requests/issues/2957/timeline
null
completed
null
null
false
[ "There should not be a Nagle's algorithm delay, because by default we disable Nagle's algorithm. Can you please answer the questions from our [CONTRIBUTING.md](https://github.com/kennethreitz/requests/blob/master/CONTRIBUTING.md), specifically:\n\n> Tell us **what version of Requests you're using**, and **how you i...
https://api.github.com/repos/psf/requests/issues/2956
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/2956/labels{/name}
https://api.github.com/repos/psf/requests/issues/2956/comments
https://api.github.com/repos/psf/requests/issues/2956/events
https://github.com/psf/requests/issues/2956
124,484,256
MDU6SXNzdWUxMjQ0ODQyNTY=
2,956
API feature - POST request to HTML element by id
{ "avatar_url": "https://avatars.githubusercontent.com/u/11060902?v=4", "events_url": "https://api.github.com/users/aewhatley/events{/privacy}", "followers_url": "https://api.github.com/users/aewhatley/followers", "following_url": "https://api.github.com/users/aewhatley/following{/other_user}", "gists_url": "https://api.github.com/users/aewhatley/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/aewhatley", "id": 11060902, "login": "aewhatley", "node_id": "MDQ6VXNlcjExMDYwOTAy", "organizations_url": "https://api.github.com/users/aewhatley/orgs", "received_events_url": "https://api.github.com/users/aewhatley/received_events", "repos_url": "https://api.github.com/users/aewhatley/repos", "site_admin": false, "starred_url": "https://api.github.com/users/aewhatley/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/aewhatley/subscriptions", "type": "User", "url": "https://api.github.com/users/aewhatley", "user_view_type": "public" }
[]
closed
true
null
[]
null
1
2015-12-31T16:29:29Z
2021-09-08T20:00:49Z
2015-12-31T18:16:37Z
NONE
resolved
Right now, the requests.post() function only appears to send post requests to HTML elements by their name. Are there any plans of creating something like a requests.post_to_name() and requests.post_to_id(), so that the user can make post requests to HTML elements via their id instead, similar to the API used in Splinter for accessing HTML elements?
{ "avatar_url": "https://avatars.githubusercontent.com/u/240830?v=4", "events_url": "https://api.github.com/users/sigmavirus24/events{/privacy}", "followers_url": "https://api.github.com/users/sigmavirus24/followers", "following_url": "https://api.github.com/users/sigmavirus24/following{/other_user}", "gists_url": "https://api.github.com/users/sigmavirus24/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/sigmavirus24", "id": 240830, "login": "sigmavirus24", "node_id": "MDQ6VXNlcjI0MDgzMA==", "organizations_url": "https://api.github.com/users/sigmavirus24/orgs", "received_events_url": "https://api.github.com/users/sigmavirus24/received_events", "repos_url": "https://api.github.com/users/sigmavirus24/repos", "site_admin": false, "starred_url": "https://api.github.com/users/sigmavirus24/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sigmavirus24/subscriptions", "type": "User", "url": "https://api.github.com/users/sigmavirus24", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/2956/reactions" }
https://api.github.com/repos/psf/requests/issues/2956/timeline
null
completed
null
null
false
[ "@aewhatley requests is an _HTTP_ client and has nothing to do with _HTML_. POST requests are made to URLs, not HTML elements. As such, we would not be adding any such methods because they wouldn't make sense as part of our API.\n\nThanks for the suggestion but I think you're a little confused about how requests wo...
https://api.github.com/repos/psf/requests/issues/2955
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/2955/labels{/name}
https://api.github.com/repos/psf/requests/issues/2955/comments
https://api.github.com/repos/psf/requests/issues/2955/events
https://github.com/psf/requests/issues/2955
124,341,446
MDU6SXNzdWUxMjQzNDE0NDY=
2,955
Issue with Lets Encrypt certificates
{ "avatar_url": "https://avatars.githubusercontent.com/u/16189630?v=4", "events_url": "https://api.github.com/users/yhorian/events{/privacy}", "followers_url": "https://api.github.com/users/yhorian/followers", "following_url": "https://api.github.com/users/yhorian/following{/other_user}", "gists_url": "https://api.github.com/users/yhorian/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/yhorian", "id": 16189630, "login": "yhorian", "node_id": "MDQ6VXNlcjE2MTg5NjMw", "organizations_url": "https://api.github.com/users/yhorian/orgs", "received_events_url": "https://api.github.com/users/yhorian/received_events", "repos_url": "https://api.github.com/users/yhorian/repos", "site_admin": false, "starred_url": "https://api.github.com/users/yhorian/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/yhorian/subscriptions", "type": "User", "url": "https://api.github.com/users/yhorian", "user_view_type": "public" }
[]
closed
true
null
[]
null
13
2015-12-30T12:24:20Z
2021-09-08T18:00:40Z
2015-12-30T13:12:57Z
NONE
resolved
Having problems getting Requests to work with ssl certificates issued by lets encrypt. The error message is very unhelpful in narrowing down what the issue is exactly. Lets see if I can post the right error this time: File "E:\anaconda27\lib\site-packages\requests\api.py", line 67, in get return request('get', url, params=params, *_kwargs) File "E:\anaconda27\lib\site-packages\requests\api.py", line 53, in request return session.request(method=method, url=url, *_kwargs) File "E:\anaconda27\lib\site-packages\requests\sessions.py", line 468, in request resp = self.send(prep, *_send_kwargs) File "E:\anaconda27\lib\site-packages\requests\sessions.py", line 576, in send r = adapter.send(request, *_kwargs) File "E:\anaconda27\lib\site-packages\requests\adapters.py", line 447, in send raise SSLError(e, request=request) requests.exceptions.SSLError: [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed (_ssl.c:590)
{ "avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4", "events_url": "https://api.github.com/users/Lukasa/events{/privacy}", "followers_url": "https://api.github.com/users/Lukasa/followers", "following_url": "https://api.github.com/users/Lukasa/following{/other_user}", "gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/Lukasa", "id": 1382556, "login": "Lukasa", "node_id": "MDQ6VXNlcjEzODI1NTY=", "organizations_url": "https://api.github.com/users/Lukasa/orgs", "received_events_url": "https://api.github.com/users/Lukasa/received_events", "repos_url": "https://api.github.com/users/Lukasa/repos", "site_admin": false, "starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions", "type": "User", "url": "https://api.github.com/users/Lukasa", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/2955/reactions" }
https://api.github.com/repos/psf/requests/issues/2955/timeline
null
completed
null
null
false
[ "I previously submitted a post with error messages testing httplib2 and other libraries, which are having similar issues but aren't providing much more information on why they're returning this error when browser and a PHP script aren't having this problem.\n", "@yhorian1 Aha, there we go!\n\nSo, the problem here...
https://api.github.com/repos/psf/requests/issues/2954
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/2954/labels{/name}
https://api.github.com/repos/psf/requests/issues/2954/comments
https://api.github.com/repos/psf/requests/issues/2954/events
https://github.com/psf/requests/issues/2954
124,339,435
MDU6SXNzdWUxMjQzMzk0MzU=
2,954
HTTPS verification for Let's Encrypt certificates
{ "avatar_url": "https://avatars.githubusercontent.com/u/16189630?v=4", "events_url": "https://api.github.com/users/yhorian/events{/privacy}", "followers_url": "https://api.github.com/users/yhorian/followers", "following_url": "https://api.github.com/users/yhorian/following{/other_user}", "gists_url": "https://api.github.com/users/yhorian/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/yhorian", "id": 16189630, "login": "yhorian", "node_id": "MDQ6VXNlcjE2MTg5NjMw", "organizations_url": "https://api.github.com/users/yhorian/orgs", "received_events_url": "https://api.github.com/users/yhorian/received_events", "repos_url": "https://api.github.com/users/yhorian/repos", "site_admin": false, "starred_url": "https://api.github.com/users/yhorian/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/yhorian/subscriptions", "type": "User", "url": "https://api.github.com/users/yhorian", "user_view_type": "public" }
[]
closed
true
null
[]
null
1
2015-12-30T12:01:29Z
2021-09-08T20:00:50Z
2015-12-30T12:04:52Z
NONE
resolved
I've been trying to get requests to work with sites using Let's Encrypt SSL certificates but getting a very unhelpful error: ``` File "E:\anaconda27\lib\site-packages\httplib2\__init__.py", line 1609, in request (response, content) = self._request(conn, authority, uri, request_uri, method, body, headers, redirections, cachekey) File "E:\anaconda27\lib\site-packages\httplib2\__init__.py", line 1351, in _request (response, content) = self._conn_request(conn, request_uri, method, body, headers) File "E:\anaconda27\lib\site-packages\httplib2\__init__.py", line 1272, in _conn_request conn.connect() File "E:\anaconda27\lib\site-packages\httplib2\__init__.py", line 1059, in connect raise SSLHandshakeError(e) httplib2.SSLHandshakeError: [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed (_ssl.c:590) ``` I've replicated this in Python 3.4 and 3.5, with lib/ssl.py failing.
{ "avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4", "events_url": "https://api.github.com/users/Lukasa/events{/privacy}", "followers_url": "https://api.github.com/users/Lukasa/followers", "following_url": "https://api.github.com/users/Lukasa/following{/other_user}", "gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/Lukasa", "id": 1382556, "login": "Lukasa", "node_id": "MDQ6VXNlcjEzODI1NTY=", "organizations_url": "https://api.github.com/users/Lukasa/orgs", "received_events_url": "https://api.github.com/users/Lukasa/received_events", "repos_url": "https://api.github.com/users/Lukasa/repos", "site_admin": false, "starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions", "type": "User", "url": "https://api.github.com/users/Lukasa", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/2954/reactions" }
https://api.github.com/repos/psf/requests/issues/2954/timeline
null
completed
null
null
false
[ "@yhorian1 Your bug is in httplib2. This is not httplib2.\n" ]
https://api.github.com/repos/psf/requests/issues/2953
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/2953/labels{/name}
https://api.github.com/repos/psf/requests/issues/2953/comments
https://api.github.com/repos/psf/requests/issues/2953/events
https://github.com/psf/requests/pull/2953
124,332,472
MDExOlB1bGxSZXF1ZXN0NTQ3OTE0ODg=
2,953
SOCKS Proxy Support
{ "avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4", "events_url": "https://api.github.com/users/Lukasa/events{/privacy}", "followers_url": "https://api.github.com/users/Lukasa/followers", "following_url": "https://api.github.com/users/Lukasa/following{/other_user}", "gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/Lukasa", "id": 1382556, "login": "Lukasa", "node_id": "MDQ6VXNlcjEzODI1NTY=", "organizations_url": "https://api.github.com/users/Lukasa/orgs", "received_events_url": "https://api.github.com/users/Lukasa/received_events", "repos_url": "https://api.github.com/users/Lukasa/repos", "site_admin": false, "starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions", "type": "User", "url": "https://api.github.com/users/Lukasa", "user_view_type": "public" }
[]
closed
true
{ "avatar_url": "https://avatars.githubusercontent.com/u/240830?v=4", "events_url": "https://api.github.com/users/sigmavirus24/events{/privacy}", "followers_url": "https://api.github.com/users/sigmavirus24/followers", "following_url": "https://api.github.com/users/sigmavirus24/following{/other_user}", "gists_url": "https://api.github.com/users/sigmavirus24/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/sigmavirus24", "id": 240830, "login": "sigmavirus24", "node_id": "MDQ6VXNlcjI0MDgzMA==", "organizations_url": "https://api.github.com/users/sigmavirus24/orgs", "received_events_url": "https://api.github.com/users/sigmavirus24/received_events", "repos_url": "https://api.github.com/users/sigmavirus24/repos", "site_admin": false, "starred_url": "https://api.github.com/users/sigmavirus24/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sigmavirus24/subscriptions", "type": "User", "url": "https://api.github.com/users/sigmavirus24", "user_view_type": "public" }
[ { "avatar_url": "https://avatars.githubusercontent.com/u/240830?v=4", "events_url": "https://api.github.com/users/sigmavirus24/events{/privacy}", "followers_url": "https://api.github.com/users/sigmavirus24/followers", "following_url": "https://api.github.com/users/sigmavirus24/following{/other_user}...
{ "closed_at": "2016-09-06T00:07:25Z", "closed_issues": 1, "created_at": "2015-12-15T14:43:38Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4", "events_url": "https://api.github.com/users/Lukasa/events{/privacy}", "followers_url": "https://api.github.com/users/Lukasa/followers", "following_url": "https://api.github.com/users/Lukasa/following{/other_user}", "gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/Lukasa", "id": 1382556, "login": "Lukasa", "node_id": "MDQ6VXNlcjEzODI1NTY=", "organizations_url": "https://api.github.com/users/Lukasa/orgs", "received_events_url": "https://api.github.com/users/Lukasa/received_events", "repos_url": "https://api.github.com/users/Lukasa/repos", "site_admin": false, "starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions", "type": "User", "url": "https://api.github.com/users/Lukasa", "user_view_type": "public" }, "description": null, "due_on": null, "html_url": "https://github.com/psf/requests/milestone/27", "id": 1461386, "labels_url": "https://api.github.com/repos/psf/requests/milestones/27/labels", "node_id": "MDk6TWlsZXN0b25lMTQ2MTM4Ng==", "number": 27, "open_issues": 0, "state": "closed", "title": "2.10.0", "updated_at": "2016-09-06T14:26:04Z", "url": "https://api.github.com/repos/psf/requests/milestones/27" }
27
2015-12-30T10:46:50Z
2021-09-08T04:01:02Z
2016-04-29T22:03:04Z
MEMBER
resolved
This pull request _finally_ adds SOCKS proxy support to the Requests module, pretty much four years _to the day_ since we were first asked (in #324 for those who want to follow it). This pull request relies on a pull request I have opened against urllib3, so we can't land it until urllib3 1.14.1 is released containing that code. However, once that's done this PR should be ready to rock. I'm setting this up for the 2.10.0 milestone as I see no reason to wait for 3.0.0 for SOCKS support. Resolves #324, #723, #1147, #1982, #2156, #2425, and #2562.
{ "avatar_url": "https://avatars.githubusercontent.com/u/119893?v=4", "events_url": "https://api.github.com/users/kennethreitz/events{/privacy}", "followers_url": "https://api.github.com/users/kennethreitz/followers", "following_url": "https://api.github.com/users/kennethreitz/following{/other_user}", "gists_url": "https://api.github.com/users/kennethreitz/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/kennethreitz", "id": 119893, "login": "kennethreitz", "node_id": "MDQ6VXNlcjExOTg5Mw==", "organizations_url": "https://api.github.com/users/kennethreitz/orgs", "received_events_url": "https://api.github.com/users/kennethreitz/received_events", "repos_url": "https://api.github.com/users/kennethreitz/repos", "site_admin": false, "starred_url": "https://api.github.com/users/kennethreitz/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/kennethreitz/subscriptions", "type": "User", "url": "https://api.github.com/users/kennethreitz", "user_view_type": "public" }
{ "+1": 3, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 3, "url": "https://api.github.com/repos/psf/requests/issues/2953/reactions" }
https://api.github.com/repos/psf/requests/issues/2953/timeline
null
null
false
{ "diff_url": "https://github.com/psf/requests/pull/2953.diff", "html_url": "https://github.com/psf/requests/pull/2953", "merged_at": "2016-04-29T22:03:04Z", "patch_url": "https://github.com/psf/requests/pull/2953.patch", "url": "https://api.github.com/repos/psf/requests/pulls/2953" }
true
[ ":pray: \n", ":+1: on the code and :+1: on the milestone.\n", "@Lukasa what do you think about having a `socks` extra for requests that installs `PySocks` and whatever else?\n", "Done. =)\n", "Does PySocks require any compilation during installation? We should consider vendoring it if we want to consider th...
https://api.github.com/repos/psf/requests/issues/2952
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/2952/labels{/name}
https://api.github.com/repos/psf/requests/issues/2952/comments
https://api.github.com/repos/psf/requests/issues/2952/events
https://github.com/psf/requests/pull/2952
124,273,309
MDExOlB1bGxSZXF1ZXN0NTQ3NjEwMzk=
2,952
Discard 0-byte chunks from request body iterators
{ "avatar_url": "https://avatars.githubusercontent.com/u/4432952?v=4", "events_url": "https://api.github.com/users/tipabu/events{/privacy}", "followers_url": "https://api.github.com/users/tipabu/followers", "following_url": "https://api.github.com/users/tipabu/following{/other_user}", "gists_url": "https://api.github.com/users/tipabu/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/tipabu", "id": 4432952, "login": "tipabu", "node_id": "MDQ6VXNlcjQ0MzI5NTI=", "organizations_url": "https://api.github.com/users/tipabu/orgs", "received_events_url": "https://api.github.com/users/tipabu/received_events", "repos_url": "https://api.github.com/users/tipabu/repos", "site_admin": false, "starred_url": "https://api.github.com/users/tipabu/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/tipabu/subscriptions", "type": "User", "url": "https://api.github.com/users/tipabu", "user_view_type": "public" }
[]
closed
true
null
[]
null
1
2015-12-29T21:51:44Z
2021-09-08T05:01:06Z
2015-12-29T22:06:16Z
NONE
resolved
Previously, an empty chunk in a request body iterator would be faithfully translated to a 0-length chunk on the wire, which the server would interpret as the end of the transfer. That is, a request like ``` def data(): yield 'foo' yield '' yield 'bar' requests.put(url, data=data()) ``` ... would cause the server to receive a chunk for 'foo', receive an empty chunk, and close the connection before receiving 'bar'. Further, if `Connection: keep-alive` is set, the server will attempt (and fail) to parse the next chunk, serve a 400, and close the connection. Now, the empty chunk will be ignored, and the server should receive all of the actual bytes emitted from the iterable.
{ "avatar_url": "https://avatars.githubusercontent.com/u/240830?v=4", "events_url": "https://api.github.com/users/sigmavirus24/events{/privacy}", "followers_url": "https://api.github.com/users/sigmavirus24/followers", "following_url": "https://api.github.com/users/sigmavirus24/following{/other_user}", "gists_url": "https://api.github.com/users/sigmavirus24/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/sigmavirus24", "id": 240830, "login": "sigmavirus24", "node_id": "MDQ6VXNlcjI0MDgzMA==", "organizations_url": "https://api.github.com/users/sigmavirus24/orgs", "received_events_url": "https://api.github.com/users/sigmavirus24/received_events", "repos_url": "https://api.github.com/users/sigmavirus24/repos", "site_admin": false, "starred_url": "https://api.github.com/users/sigmavirus24/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sigmavirus24/subscriptions", "type": "User", "url": "https://api.github.com/users/sigmavirus24", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/2952/reactions" }
https://api.github.com/repos/psf/requests/issues/2952/timeline
null
null
false
{ "diff_url": "https://github.com/psf/requests/pull/2952.diff", "html_url": "https://github.com/psf/requests/pull/2952", "merged_at": null, "patch_url": "https://github.com/psf/requests/pull/2952.patch", "url": "https://api.github.com/repos/psf/requests/pulls/2952" }
true
[ "This is a breaking change that cannot be merged for 2.x but has been fixed for 3.0.0 in #2631 by @neosab.\n" ]
https://api.github.com/repos/psf/requests/issues/2951
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/2951/labels{/name}
https://api.github.com/repos/psf/requests/issues/2951/comments
https://api.github.com/repos/psf/requests/issues/2951/events
https://github.com/psf/requests/issues/2951
124,191,541
MDU6SXNzdWUxMjQxOTE1NDE=
2,951
TypeError: unsupported operand type(s) for -=: 'unicode' and 'int'
{ "avatar_url": "https://avatars.githubusercontent.com/u/13664257?v=4", "events_url": "https://api.github.com/users/vkosuri/events{/privacy}", "followers_url": "https://api.github.com/users/vkosuri/followers", "following_url": "https://api.github.com/users/vkosuri/following{/other_user}", "gists_url": "https://api.github.com/users/vkosuri/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/vkosuri", "id": 13664257, "login": "vkosuri", "node_id": "MDQ6VXNlcjEzNjY0MjU3", "organizations_url": "https://api.github.com/users/vkosuri/orgs", "received_events_url": "https://api.github.com/users/vkosuri/received_events", "repos_url": "https://api.github.com/users/vkosuri/repos", "site_admin": false, "starred_url": "https://api.github.com/users/vkosuri/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/vkosuri/subscriptions", "type": "User", "url": "https://api.github.com/users/vkosuri", "user_view_type": "public" }
[]
closed
true
null
[]
null
11
2015-12-29T10:22:09Z
2021-09-08T20:00:51Z
2015-12-29T18:30:34Z
NONE
resolved
While sending huge amount requests to Unit rejecting requests, However I am using max_retries=20 still i am getting this error message ``` File "/home/mkosuri/venv/local/lib/python2.7/site-packages/RequestsLibrary/RequestsKeywords.py", line 258, in post_request response = self._post_request(session, uri, data, headers, files, redir, timeout) File "/home/mkosuri/venv/local/lib/python2.7/site-packages/RequestsLibrary/RequestsKeywords.py", line 556, in _post_request allow_redirects=allow_redirects) File "/home/mkosuri/venv/local/lib/python2.7/site-packages/requests/sessions.py", line 511, in post return self.request('POST', url, data=data, json=json, **kwargs) File "/home/mkosuri/venv/local/lib/python2.7/site-packages/requests/sessions.py", line 468, in request resp = self.send(prep, **send_kwargs) File "/home/mkosuri/venv/local/lib/python2.7/site-packages/requests/sessions.py", line 576, in send r = adapter.send(request, **kwargs) File "/home/mkosuri/venv/local/lib/python2.7/site-packages/requests/adapters.py", line 370, in send timeout=timeout File "/home/mkosuri/yang_gen/venv/local/lib/python2.7/site-packages/requests/packages/urllib3/connectionpool.py", line 609, in urlopen _stacktrace=sys.exc_info()[2]) File "/home/mkosuri/venv/local/lib/python2.7/site-packages/requests/packages/urllib3/util/retry.py", line 226, in increment total -= 1 ``` Any workaround for this issue?
{ "avatar_url": "https://avatars.githubusercontent.com/u/13664257?v=4", "events_url": "https://api.github.com/users/vkosuri/events{/privacy}", "followers_url": "https://api.github.com/users/vkosuri/followers", "following_url": "https://api.github.com/users/vkosuri/following{/other_user}", "gists_url": "https://api.github.com/users/vkosuri/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/vkosuri", "id": 13664257, "login": "vkosuri", "node_id": "MDQ6VXNlcjEzNjY0MjU3", "organizations_url": "https://api.github.com/users/vkosuri/orgs", "received_events_url": "https://api.github.com/users/vkosuri/received_events", "repos_url": "https://api.github.com/users/vkosuri/repos", "site_admin": false, "starred_url": "https://api.github.com/users/vkosuri/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/vkosuri/subscriptions", "type": "User", "url": "https://api.github.com/users/vkosuri", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/2951/reactions" }
https://api.github.com/repos/psf/requests/issues/2951/timeline
null
completed
null
null
false
[ "Do you receive it always? Under what conditions do you receive it? What does your code look like? What version of requests are you using? From where did you install it?\n", "Do you receive it always? \n\n> Yes\n\nUnder what conditions do you receive it? \n\n> I am sending around different 5K combination of GET,...
https://api.github.com/repos/psf/requests/issues/2950
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/2950/labels{/name}
https://api.github.com/repos/psf/requests/issues/2950/comments
https://api.github.com/repos/psf/requests/issues/2950/events
https://github.com/psf/requests/issues/2950
124,181,847
MDU6SXNzdWUxMjQxODE4NDc=
2,950
Unable to upload chunks to Flask
{ "avatar_url": "https://avatars.githubusercontent.com/u/5459596?v=4", "events_url": "https://api.github.com/users/johaven/events{/privacy}", "followers_url": "https://api.github.com/users/johaven/followers", "following_url": "https://api.github.com/users/johaven/following{/other_user}", "gists_url": "https://api.github.com/users/johaven/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/johaven", "id": 5459596, "login": "johaven", "node_id": "MDQ6VXNlcjU0NTk1OTY=", "organizations_url": "https://api.github.com/users/johaven/orgs", "received_events_url": "https://api.github.com/users/johaven/received_events", "repos_url": "https://api.github.com/users/johaven/repos", "site_admin": false, "starred_url": "https://api.github.com/users/johaven/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/johaven/subscriptions", "type": "User", "url": "https://api.github.com/users/johaven", "user_view_type": "public" }
[]
closed
true
null
[]
null
32
2015-12-29T08:46:10Z
2015-12-31T14:26:03Z
2015-12-29T13:35:40Z
NONE
null
I do not know if it comes from flask or requests , I link this issue posted on Flask issues https://github.com/mitsuhiko/flask/issues/1668
{ "avatar_url": "https://avatars.githubusercontent.com/u/240830?v=4", "events_url": "https://api.github.com/users/sigmavirus24/events{/privacy}", "followers_url": "https://api.github.com/users/sigmavirus24/followers", "following_url": "https://api.github.com/users/sigmavirus24/following{/other_user}", "gists_url": "https://api.github.com/users/sigmavirus24/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/sigmavirus24", "id": 240830, "login": "sigmavirus24", "node_id": "MDQ6VXNlcjI0MDgzMA==", "organizations_url": "https://api.github.com/users/sigmavirus24/orgs", "received_events_url": "https://api.github.com/users/sigmavirus24/received_events", "repos_url": "https://api.github.com/users/sigmavirus24/repos", "site_admin": false, "starred_url": "https://api.github.com/users/sigmavirus24/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sigmavirus24/subscriptions", "type": "User", "url": "https://api.github.com/users/sigmavirus24", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/2950/reactions" }
https://api.github.com/repos/psf/requests/issues/2950/timeline
null
completed
null
null
false
[ "Are you sure the headers you posted in the Flask issue are right? They look totally invalid. \n", "Yes, these headers are received by Flask.\nI'm working on localhost, request between \"requests\" and \"Flask\" are send directly.\n\nHowever I just tested this same case on a server with (flask / uwsgi / nginx and...
https://api.github.com/repos/psf/requests/issues/2949
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/2949/labels{/name}
https://api.github.com/repos/psf/requests/issues/2949/comments
https://api.github.com/repos/psf/requests/issues/2949/events
https://github.com/psf/requests/issues/2949
124,130,987
MDU6SXNzdWUxMjQxMzA5ODc=
2,949
Session's Authorization header isn't sent on redirect
{ "avatar_url": "https://avatars.githubusercontent.com/u/287161?v=4", "events_url": "https://api.github.com/users/jwineinger/events{/privacy}", "followers_url": "https://api.github.com/users/jwineinger/followers", "following_url": "https://api.github.com/users/jwineinger/following{/other_user}", "gists_url": "https://api.github.com/users/jwineinger/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jwineinger", "id": 287161, "login": "jwineinger", "node_id": "MDQ6VXNlcjI4NzE2MQ==", "organizations_url": "https://api.github.com/users/jwineinger/orgs", "received_events_url": "https://api.github.com/users/jwineinger/received_events", "repos_url": "https://api.github.com/users/jwineinger/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jwineinger/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jwineinger/subscriptions", "type": "User", "url": "https://api.github.com/users/jwineinger", "user_view_type": "public" }
[ { "color": "e10c02", "default": false, "description": null, "id": 117744, "name": "Bug", "node_id": "MDU6TGFiZWwxMTc3NDQ=", "url": "https://api.github.com/repos/psf/requests/labels/Bug" } ]
closed
true
null
[]
null
37
2015-12-28T21:44:14Z
2021-12-07T23:00:27Z
2021-09-08T22:43:04Z
NONE
resolved
I'm using requests to hit developer-api.nest.com and setting an Authorization header with a bearer token. On some requests, that API responds with an 307 redirect. When that happens, I still need the Authorization header to be sent on the subsequent request. I've tried using `requests.get()` as well as a session. I suppose I could work around this by not allowing redirects, detecting the 307 and then issuing the new request myself but I'm wondering if this is a bug. Should I expect that the Authorization header would be sent on all requests made within the context of a session? ``` python In [41]: s = requests.Session() In [42]: s.headers Out[42]: {'Accept': '*/*', 'Accept-Encoding': 'gzip, deflate', 'Connection': 'keep-alive', 'User-Agent': 'python-requests/2.7.0 CPython/3.4.3 Darwin/15.2.0'} In [43]: s.headers['Authorization'] = "Bearer <snip>" In [45]: s.get("https://developer-api.nest.com/devices/thermostats/") Out[45]: <Response [401]> In [46]: s.get("https://developer-api.nest.com/devices/thermostats/") Out[46]: <Response [200]> In [49]: Out[45].history Out[49]: [<Response [307]>] In [50]: Out[46].history Out[50]: [] In [51]: Out[45].request.headers Out[51]: {'Accept': '*/*', 'Accept-Encoding': 'gzip, deflate', 'Connection': 'keep-alive', 'User-Agent': 'python-requests/2.7.0 CPython/3.4.3 Darwin/15.2.0'} In [52]: Out[46].request.headers Out[52]: {'Accept': '*/*', 'Accept-Encoding': 'gzip, deflate', 'Connection': 'keep-alive', 'User-Agent': 'python-requests/2.7.0 CPython/3.4.3 Darwin/15.2.0', 'Authorization': 'Bearer <snip>'} ```
{ "avatar_url": "https://avatars.githubusercontent.com/u/240830?v=4", "events_url": "https://api.github.com/users/sigmavirus24/events{/privacy}", "followers_url": "https://api.github.com/users/sigmavirus24/followers", "following_url": "https://api.github.com/users/sigmavirus24/following{/other_user}", "gists_url": "https://api.github.com/users/sigmavirus24/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/sigmavirus24", "id": 240830, "login": "sigmavirus24", "node_id": "MDQ6VXNlcjI0MDgzMA==", "organizations_url": "https://api.github.com/users/sigmavirus24/orgs", "received_events_url": "https://api.github.com/users/sigmavirus24/received_events", "repos_url": "https://api.github.com/users/sigmavirus24/repos", "site_admin": false, "starred_url": "https://api.github.com/users/sigmavirus24/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sigmavirus24/subscriptions", "type": "User", "url": "https://api.github.com/users/sigmavirus24", "user_view_type": "public" }
{ "+1": 3, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 3, "url": "https://api.github.com/repos/psf/requests/issues/2949/reactions" }
https://api.github.com/repos/psf/requests/issues/2949/timeline
null
completed
null
null
false
[ "Where is the redirect to?\n", "Ah, a different domain. firebase-apiserver03-tah01-iad01.dapi.production.nest.com\n", "Yup, so that's somewhat deliberate: we're very aggressive with stripping authorization headers when redirected to a new host. This is a safety feature to deal with [CVE 2014-1829](http://www.cv...
https://api.github.com/repos/psf/requests/issues/2948
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/2948/labels{/name}
https://api.github.com/repos/psf/requests/issues/2948/comments
https://api.github.com/repos/psf/requests/issues/2948/events
https://github.com/psf/requests/pull/2948
124,080,084
MDExOlB1bGxSZXF1ZXN0NTQ2NjIwMDE=
2,948
advanced: use "client.*" to designate client certificate
{ "avatar_url": "https://avatars.githubusercontent.com/u/631446?v=4", "events_url": "https://api.github.com/users/vincentbernat/events{/privacy}", "followers_url": "https://api.github.com/users/vincentbernat/followers", "following_url": "https://api.github.com/users/vincentbernat/following{/other_user}", "gists_url": "https://api.github.com/users/vincentbernat/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/vincentbernat", "id": 631446, "login": "vincentbernat", "node_id": "MDQ6VXNlcjYzMTQ0Ng==", "organizations_url": "https://api.github.com/users/vincentbernat/orgs", "received_events_url": "https://api.github.com/users/vincentbernat/received_events", "repos_url": "https://api.github.com/users/vincentbernat/repos", "site_admin": false, "starred_url": "https://api.github.com/users/vincentbernat/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/vincentbernat/subscriptions", "type": "User", "url": "https://api.github.com/users/vincentbernat", "user_view_type": "public" }
[]
closed
true
null
[]
null
1
2015-12-28T15:22:45Z
2021-09-08T05:01:06Z
2015-12-28T15:58:54Z
CONTRIBUTOR
resolved
Using "server.crt" is confusing as one may try to put the server certificate while this is really the client certificate that should be put here. Instead, use "client.cert", "client.key" and "client.pem".
{ "avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4", "events_url": "https://api.github.com/users/Lukasa/events{/privacy}", "followers_url": "https://api.github.com/users/Lukasa/followers", "following_url": "https://api.github.com/users/Lukasa/following{/other_user}", "gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/Lukasa", "id": 1382556, "login": "Lukasa", "node_id": "MDQ6VXNlcjEzODI1NTY=", "organizations_url": "https://api.github.com/users/Lukasa/orgs", "received_events_url": "https://api.github.com/users/Lukasa/received_events", "repos_url": "https://api.github.com/users/Lukasa/repos", "site_admin": false, "starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions", "type": "User", "url": "https://api.github.com/users/Lukasa", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/2948/reactions" }
https://api.github.com/repos/psf/requests/issues/2948/timeline
null
null
false
{ "diff_url": "https://github.com/psf/requests/pull/2948.diff", "html_url": "https://github.com/psf/requests/pull/2948", "merged_at": "2015-12-28T15:58:54Z", "patch_url": "https://github.com/psf/requests/pull/2948.patch", "url": "https://api.github.com/repos/psf/requests/pulls/2948" }
true
[ "Good spot, thanks! :sparkles: :cake: :sparkles:\n" ]
https://api.github.com/repos/psf/requests/issues/2947
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/2947/labels{/name}
https://api.github.com/repos/psf/requests/issues/2947/comments
https://api.github.com/repos/psf/requests/issues/2947/events
https://github.com/psf/requests/issues/2947
124,023,695
MDU6SXNzdWUxMjQwMjM2OTU=
2,947
No protection against line breaks in header values
{ "avatar_url": "https://avatars.githubusercontent.com/u/555363?v=4", "events_url": "https://api.github.com/users/dsavenko/events{/privacy}", "followers_url": "https://api.github.com/users/dsavenko/followers", "following_url": "https://api.github.com/users/dsavenko/following{/other_user}", "gists_url": "https://api.github.com/users/dsavenko/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/dsavenko", "id": 555363, "login": "dsavenko", "node_id": "MDQ6VXNlcjU1NTM2Mw==", "organizations_url": "https://api.github.com/users/dsavenko/orgs", "received_events_url": "https://api.github.com/users/dsavenko/received_events", "repos_url": "https://api.github.com/users/dsavenko/repos", "site_admin": false, "starred_url": "https://api.github.com/users/dsavenko/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/dsavenko/subscriptions", "type": "User", "url": "https://api.github.com/users/dsavenko", "user_view_type": "public" }
[]
closed
true
null
[]
null
10
2015-12-28T06:17:25Z
2021-09-08T15:00:54Z
2016-09-06T00:07:58Z
NONE
resolved
Hi, The following call leads to 'another-header' appearing in the headers sent to the server: ``` >>> r = requests.get('https://httpbin.org/get', params={'q': 'query'}, headers={'my-header': 'a\r\nanother-header: b'}) ``` I expected either the line break to be escaped in some way, or an exception to be raised. A new header silently appearing in the request doesn't look right. Requests version is 2.9.1, installed with pip.
{ "avatar_url": "https://avatars.githubusercontent.com/u/240830?v=4", "events_url": "https://api.github.com/users/sigmavirus24/events{/privacy}", "followers_url": "https://api.github.com/users/sigmavirus24/followers", "following_url": "https://api.github.com/users/sigmavirus24/following{/other_user}", "gists_url": "https://api.github.com/users/sigmavirus24/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/sigmavirus24", "id": 240830, "login": "sigmavirus24", "node_id": "MDQ6VXNlcjI0MDgzMA==", "organizations_url": "https://api.github.com/users/sigmavirus24/orgs", "received_events_url": "https://api.github.com/users/sigmavirus24/received_events", "repos_url": "https://api.github.com/users/sigmavirus24/repos", "site_admin": false, "starred_url": "https://api.github.com/users/sigmavirus24/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sigmavirus24/subscriptions", "type": "User", "url": "https://api.github.com/users/sigmavirus24", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/2947/reactions" }
https://api.github.com/repos/psf/requests/issues/2947/timeline
null
completed
null
null
false
[ "Ugh, yeah, good spot. This isn't really ideal: while what occurs here is kinda exactly what you'd expect if you have an understanding of the system, it provides a nice shiny footgun for developers who aren't expecting it, potentially allowing for header injection if they're passing user-provided data directly to a...
https://api.github.com/repos/psf/requests/issues/2946
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/2946/labels{/name}
https://api.github.com/repos/psf/requests/issues/2946/comments
https://api.github.com/repos/psf/requests/issues/2946/events
https://github.com/psf/requests/issues/2946
123,902,291
MDU6SXNzdWUxMjM5MDIyOTE=
2,946
getting unexpected output
{ "avatar_url": "https://avatars.githubusercontent.com/u/3628354?v=4", "events_url": "https://api.github.com/users/L1ghtn1ng/events{/privacy}", "followers_url": "https://api.github.com/users/L1ghtn1ng/followers", "following_url": "https://api.github.com/users/L1ghtn1ng/following{/other_user}", "gists_url": "https://api.github.com/users/L1ghtn1ng/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/L1ghtn1ng", "id": 3628354, "login": "L1ghtn1ng", "node_id": "MDQ6VXNlcjM2MjgzNTQ=", "organizations_url": "https://api.github.com/users/L1ghtn1ng/orgs", "received_events_url": "https://api.github.com/users/L1ghtn1ng/received_events", "repos_url": "https://api.github.com/users/L1ghtn1ng/repos", "site_admin": false, "starred_url": "https://api.github.com/users/L1ghtn1ng/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/L1ghtn1ng/subscriptions", "type": "User", "url": "https://api.github.com/users/L1ghtn1ng", "user_view_type": "public" }
[]
closed
true
null
[]
null
3
2015-12-26T00:44:53Z
2021-09-08T20:00:51Z
2015-12-26T11:30:11Z
NONE
resolved
So I am creating a script to interact with an API for https://haveibeenpwned.com/API/v2 (link to the API docs) so when I run this from the example on the site in python3 this works as expected. ``` #!/usr/bin/python3 import requests import pprint headers = {'User-agent': 'Have I been pwn module'} API = 'https://haveibeenpwned.com/api/v2/breachedaccount/foo@bar.com' request = requests.get(API, headers=headers) res = request.json() pprint.pprint(res) ``` but when changing out the foo@bar.com email address to my personal email, I should get `404 Not found — the account could not be found and has therefore not been pwned` status code but get this instead ``` Traceback (most recent call last): File "/home/jay/.PyCharm50/config/scratches/scratch_4", line 11, in <module> res = request.json() File "/usr/lib/python3.5/site-packages/requests/models.py", line 808, in json return complexjson.loads(self.text, **kwargs) File "/usr/lib/python3.5/site-packages/simplejson/__init__.py", line 505, in loads return _default_decoder.decode(s) File "/usr/lib/python3.5/site-packages/simplejson/decoder.py", line 370, in decode obj, end = self.raw_decode(s) File "/usr/lib/python3.5/site-packages/simplejson/decoder.py", line 400, in raw_decode return self.scan_once(s, idx=_w(s, idx).end()) simplejson.scanner.JSONDecodeError: Expecting value: line 1 column 1 (char 0) Process finished with exit code 1 ``` Hope its not me being silly?
{ "avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4", "events_url": "https://api.github.com/users/Lukasa/events{/privacy}", "followers_url": "https://api.github.com/users/Lukasa/followers", "following_url": "https://api.github.com/users/Lukasa/following{/other_user}", "gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/Lukasa", "id": 1382556, "login": "Lukasa", "node_id": "MDQ6VXNlcjEzODI1NTY=", "organizations_url": "https://api.github.com/users/Lukasa/orgs", "received_events_url": "https://api.github.com/users/Lukasa/received_events", "repos_url": "https://api.github.com/users/Lukasa/repos", "site_admin": false, "starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions", "type": "User", "url": "https://api.github.com/users/Lukasa", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/2946/reactions" }
https://api.github.com/repos/psf/requests/issues/2946/timeline
null
completed
null
null
false
[ "Can you let us know what your email address is? Do you feel comfortable with that?\n", "@Lukasa I would prefer not to but if you under the API var put your email address you should hit the same issue I am having as long as you are not in any of the breach lists\n", "@L1ghtn1ng So in both Python 3 and Python 2 ...
https://api.github.com/repos/psf/requests/issues/2945
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/2945/labels{/name}
https://api.github.com/repos/psf/requests/issues/2945/comments
https://api.github.com/repos/psf/requests/issues/2945/events
https://github.com/psf/requests/pull/2945
123,316,909
MDExOlB1bGxSZXF1ZXN0NTQyNzg1Mjg=
2,945
Docs: clarify the precedence of `auth=` over `netrc`
{ "avatar_url": "https://avatars.githubusercontent.com/u/235903?v=4", "events_url": "https://api.github.com/users/ibnIrshad/events{/privacy}", "followers_url": "https://api.github.com/users/ibnIrshad/followers", "following_url": "https://api.github.com/users/ibnIrshad/following{/other_user}", "gists_url": "https://api.github.com/users/ibnIrshad/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/ibnIrshad", "id": 235903, "login": "ibnIrshad", "node_id": "MDQ6VXNlcjIzNTkwMw==", "organizations_url": "https://api.github.com/users/ibnIrshad/orgs", "received_events_url": "https://api.github.com/users/ibnIrshad/received_events", "repos_url": "https://api.github.com/users/ibnIrshad/repos", "site_admin": false, "starred_url": "https://api.github.com/users/ibnIrshad/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/ibnIrshad/subscriptions", "type": "User", "url": "https://api.github.com/users/ibnIrshad", "user_view_type": "public" }
[]
closed
true
null
[]
null
1
2015-12-21T16:57:08Z
2021-09-08T05:01:07Z
2015-12-21T18:49:52Z
NONE
resolved
This closes #2062 by clarifying in the docs which auth header takes precedence: 1st auth= 2nd .netrc 3rd headers= This precedence order is already tested in test_requests.py, in the test_basicauth_with_netrc method. Perhaps we should add further tests for non-basic auth schemes.
{ "avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4", "events_url": "https://api.github.com/users/Lukasa/events{/privacy}", "followers_url": "https://api.github.com/users/Lukasa/followers", "following_url": "https://api.github.com/users/Lukasa/following{/other_user}", "gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/Lukasa", "id": 1382556, "login": "Lukasa", "node_id": "MDQ6VXNlcjEzODI1NTY=", "organizations_url": "https://api.github.com/users/Lukasa/orgs", "received_events_url": "https://api.github.com/users/Lukasa/received_events", "repos_url": "https://api.github.com/users/Lukasa/repos", "site_admin": false, "starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions", "type": "User", "url": "https://api.github.com/users/Lukasa", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/2945/reactions" }
https://api.github.com/repos/psf/requests/issues/2945/timeline
null
null
false
{ "diff_url": "https://github.com/psf/requests/pull/2945.diff", "html_url": "https://github.com/psf/requests/pull/2945", "merged_at": "2015-12-21T18:49:52Z", "patch_url": "https://github.com/psf/requests/pull/2945.patch", "url": "https://api.github.com/repos/psf/requests/pulls/2945" }
true
[ "Thanks! :sparkles: :cake: :sparkles:\n" ]
https://api.github.com/repos/psf/requests/issues/2944
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/2944/labels{/name}
https://api.github.com/repos/psf/requests/issues/2944/comments
https://api.github.com/repos/psf/requests/issues/2944/events
https://github.com/psf/requests/pull/2944
123,201,647
MDExOlB1bGxSZXF1ZXN0NTQyMTY2NjI=
2,944
Clarification of .netrc and auth= precedence
{ "avatar_url": "https://avatars.githubusercontent.com/u/235903?v=4", "events_url": "https://api.github.com/users/ibnIrshad/events{/privacy}", "followers_url": "https://api.github.com/users/ibnIrshad/followers", "following_url": "https://api.github.com/users/ibnIrshad/following{/other_user}", "gists_url": "https://api.github.com/users/ibnIrshad/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/ibnIrshad", "id": 235903, "login": "ibnIrshad", "node_id": "MDQ6VXNlcjIzNTkwMw==", "organizations_url": "https://api.github.com/users/ibnIrshad/orgs", "received_events_url": "https://api.github.com/users/ibnIrshad/received_events", "repos_url": "https://api.github.com/users/ibnIrshad/repos", "site_admin": false, "starred_url": "https://api.github.com/users/ibnIrshad/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/ibnIrshad/subscriptions", "type": "User", "url": "https://api.github.com/users/ibnIrshad", "user_view_type": "public" }
[]
closed
true
null
[]
null
0
2015-12-21T03:00:40Z
2021-09-08T05:01:08Z
2015-12-21T03:01:15Z
NONE
resolved
This closes #2062 by clarifying which auth header takes precedence: 1. auth= 2. .netrc 3. headers=
{ "avatar_url": "https://avatars.githubusercontent.com/u/235903?v=4", "events_url": "https://api.github.com/users/ibnIrshad/events{/privacy}", "followers_url": "https://api.github.com/users/ibnIrshad/followers", "following_url": "https://api.github.com/users/ibnIrshad/following{/other_user}", "gists_url": "https://api.github.com/users/ibnIrshad/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/ibnIrshad", "id": 235903, "login": "ibnIrshad", "node_id": "MDQ6VXNlcjIzNTkwMw==", "organizations_url": "https://api.github.com/users/ibnIrshad/orgs", "received_events_url": "https://api.github.com/users/ibnIrshad/received_events", "repos_url": "https://api.github.com/users/ibnIrshad/repos", "site_admin": false, "starred_url": "https://api.github.com/users/ibnIrshad/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/ibnIrshad/subscriptions", "type": "User", "url": "https://api.github.com/users/ibnIrshad", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/2944/reactions" }
https://api.github.com/repos/psf/requests/issues/2944/timeline
null
null
false
{ "diff_url": "https://github.com/psf/requests/pull/2944.diff", "html_url": "https://github.com/psf/requests/pull/2944", "merged_at": null, "patch_url": "https://github.com/psf/requests/pull/2944.patch", "url": "https://api.github.com/repos/psf/requests/pulls/2944" }
true
[]
https://api.github.com/repos/psf/requests/issues/2943
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/2943/labels{/name}
https://api.github.com/repos/psf/requests/issues/2943/comments
https://api.github.com/repos/psf/requests/issues/2943/events
https://github.com/psf/requests/issues/2943
123,200,811
MDU6SXNzdWUxMjMyMDA4MTE=
2,943
Add json parameter to put methods
{ "avatar_url": "https://avatars.githubusercontent.com/u/763608?v=4", "events_url": "https://api.github.com/users/ibuchanan/events{/privacy}", "followers_url": "https://api.github.com/users/ibuchanan/followers", "following_url": "https://api.github.com/users/ibuchanan/following{/other_user}", "gists_url": "https://api.github.com/users/ibuchanan/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/ibuchanan", "id": 763608, "login": "ibuchanan", "node_id": "MDQ6VXNlcjc2MzYwOA==", "organizations_url": "https://api.github.com/users/ibuchanan/orgs", "received_events_url": "https://api.github.com/users/ibuchanan/received_events", "repos_url": "https://api.github.com/users/ibuchanan/repos", "site_admin": false, "starred_url": "https://api.github.com/users/ibuchanan/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/ibuchanan/subscriptions", "type": "User", "url": "https://api.github.com/users/ibuchanan", "user_view_type": "public" }
[]
closed
true
null
[]
null
2
2015-12-21T02:50:21Z
2021-09-08T20:00:53Z
2015-12-21T16:57:50Z
NONE
resolved
I enjoy both `requests.post(json=payload)` and `session.post(json=payload)`. I would like to have the same for both `requests.put()` and `session.put()`. In a cursory examination of the code, it looks like a simple change. I would be happy to create a pull request for it. Is there a reason the convenience wasn't already propagated to PUTs?
{ "avatar_url": "https://avatars.githubusercontent.com/u/763608?v=4", "events_url": "https://api.github.com/users/ibuchanan/events{/privacy}", "followers_url": "https://api.github.com/users/ibuchanan/followers", "following_url": "https://api.github.com/users/ibuchanan/following{/other_user}", "gists_url": "https://api.github.com/users/ibuchanan/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/ibuchanan", "id": 763608, "login": "ibuchanan", "node_id": "MDQ6VXNlcjc2MzYwOA==", "organizations_url": "https://api.github.com/users/ibuchanan/orgs", "received_events_url": "https://api.github.com/users/ibuchanan/received_events", "repos_url": "https://api.github.com/users/ibuchanan/repos", "site_admin": false, "starred_url": "https://api.github.com/users/ibuchanan/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/ibuchanan/subscriptions", "type": "User", "url": "https://api.github.com/users/ibuchanan", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/2943/reactions" }
https://api.github.com/repos/psf/requests/issues/2943/timeline
null
completed
null
null
false
[ "> Is there a reason the convenience wasn't already propagated to PUTs?\n\nIt was. =) All our keyword arguments work on _all_ verbs, which means `json=` works on PUT as well as POST. The only thing we didn't do was add it as an explicit keyword argument so that it appears in the documentation. Would you like to mak...
https://api.github.com/repos/psf/requests/issues/2942
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/2942/labels{/name}
https://api.github.com/repos/psf/requests/issues/2942/comments
https://api.github.com/repos/psf/requests/issues/2942/events
https://github.com/psf/requests/issues/2942
123,200,656
MDU6SXNzdWUxMjMyMDA2NTY=
2,942
How to POST a very Big file with 'chunk' mode?
{ "avatar_url": "https://avatars.githubusercontent.com/u/4278114?v=4", "events_url": "https://api.github.com/users/jchluo/events{/privacy}", "followers_url": "https://api.github.com/users/jchluo/followers", "following_url": "https://api.github.com/users/jchluo/following{/other_user}", "gists_url": "https://api.github.com/users/jchluo/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jchluo", "id": 4278114, "login": "jchluo", "node_id": "MDQ6VXNlcjQyNzgxMTQ=", "organizations_url": "https://api.github.com/users/jchluo/orgs", "received_events_url": "https://api.github.com/users/jchluo/received_events", "repos_url": "https://api.github.com/users/jchluo/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jchluo/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jchluo/subscriptions", "type": "User", "url": "https://api.github.com/users/jchluo", "user_view_type": "public" }
[]
closed
true
null
[]
null
3
2015-12-21T02:49:02Z
2021-09-08T20:00:53Z
2015-12-21T09:49:27Z
NONE
resolved
I want to Post to a very big file to the server, will requests use the "chunk" mode ? if >>> f = open("very big file") >>> requests.post(url, data=f) From the `PreparedRequest.prepare_body` method, file length can get from `util.super_len`, then the `'Content-Length'` will be a number, which make chunk mode False. Is these any way to use the chunk mode when post a big file ? Thank you!
{ "avatar_url": "https://avatars.githubusercontent.com/u/4278114?v=4", "events_url": "https://api.github.com/users/jchluo/events{/privacy}", "followers_url": "https://api.github.com/users/jchluo/followers", "following_url": "https://api.github.com/users/jchluo/following{/other_user}", "gists_url": "https://api.github.com/users/jchluo/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jchluo", "id": 4278114, "login": "jchluo", "node_id": "MDQ6VXNlcjQyNzgxMTQ=", "organizations_url": "https://api.github.com/users/jchluo/orgs", "received_events_url": "https://api.github.com/users/jchluo/received_events", "repos_url": "https://api.github.com/users/jchluo/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jchluo/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jchluo/subscriptions", "type": "User", "url": "https://api.github.com/users/jchluo", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/2942/reactions" }
https://api.github.com/repos/psf/requests/issues/2942/timeline
null
completed
null
null
false
[ "Requests will not chunk the file, but neither will it read it all into memory. Instead, it will \"stream\" it: that is, send it from the file directly to the network. Do you really specifically need chunked-transfer-encoding here? What does chunked transfer encoding get you that the streaming method does not?\n", ...
https://api.github.com/repos/psf/requests/issues/2941
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/2941/labels{/name}
https://api.github.com/repos/psf/requests/issues/2941/comments
https://api.github.com/repos/psf/requests/issues/2941/events
https://github.com/psf/requests/issues/2941
123,151,294
MDU6SXNzdWUxMjMxNTEyOTQ=
2,941
COC?
{ "avatar_url": "https://avatars.githubusercontent.com/u/1840865?v=4", "events_url": "https://api.github.com/users/alison985/events{/privacy}", "followers_url": "https://api.github.com/users/alison985/followers", "following_url": "https://api.github.com/users/alison985/following{/other_user}", "gists_url": "https://api.github.com/users/alison985/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/alison985", "id": 1840865, "login": "alison985", "node_id": "MDQ6VXNlcjE4NDA4NjU=", "organizations_url": "https://api.github.com/users/alison985/orgs", "received_events_url": "https://api.github.com/users/alison985/received_events", "repos_url": "https://api.github.com/users/alison985/repos", "site_admin": false, "starred_url": "https://api.github.com/users/alison985/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/alison985/subscriptions", "type": "User", "url": "https://api.github.com/users/alison985", "user_view_type": "public" }
[]
closed
true
null
[]
null
1
2015-12-20T10:12:16Z
2021-09-08T20:00:54Z
2015-12-20T11:55:10Z
NONE
resolved
Hi, I'm just wondering what your code of conduct is for this project? Thanks, Alison
{ "avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4", "events_url": "https://api.github.com/users/Lukasa/events{/privacy}", "followers_url": "https://api.github.com/users/Lukasa/followers", "following_url": "https://api.github.com/users/Lukasa/following{/other_user}", "gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/Lukasa", "id": 1382556, "login": "Lukasa", "node_id": "MDQ6VXNlcjEzODI1NTY=", "organizations_url": "https://api.github.com/users/Lukasa/orgs", "received_events_url": "https://api.github.com/users/Lukasa/received_events", "repos_url": "https://api.github.com/users/Lukasa/repos", "site_admin": false, "starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions", "type": "User", "url": "https://api.github.com/users/Lukasa", "user_view_type": "public" }
{ "+1": 0, "-1": 1, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 1, "url": "https://api.github.com/repos/psf/requests/issues/2941/reactions" }
https://api.github.com/repos/psf/requests/issues/2941/timeline
null
completed
null
null
false
[ "Hi @alison985!\n\nCurrently our relatively minor code of conduct is [defined here](http://docs.python-requests.org/en/latest/dev/contributing/). There is interest amongst some of the maintainers in moving to something based on the [Contributor Covenant](http://contributor-covenant.org/), given that both myself and...
https://api.github.com/repos/psf/requests/issues/2940
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/2940/labels{/name}
https://api.github.com/repos/psf/requests/issues/2940/comments
https://api.github.com/repos/psf/requests/issues/2940/events
https://github.com/psf/requests/issues/2940
123,109,372
MDU6SXNzdWUxMjMxMDkzNzI=
2,940
Add response.closed attribute
{ "avatar_url": "https://avatars.githubusercontent.com/u/76945?v=4", "events_url": "https://api.github.com/users/vitorbaptista/events{/privacy}", "followers_url": "https://api.github.com/users/vitorbaptista/followers", "following_url": "https://api.github.com/users/vitorbaptista/following{/other_user}", "gists_url": "https://api.github.com/users/vitorbaptista/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/vitorbaptista", "id": 76945, "login": "vitorbaptista", "node_id": "MDQ6VXNlcjc2OTQ1", "organizations_url": "https://api.github.com/users/vitorbaptista/orgs", "received_events_url": "https://api.github.com/users/vitorbaptista/received_events", "repos_url": "https://api.github.com/users/vitorbaptista/repos", "site_admin": false, "starred_url": "https://api.github.com/users/vitorbaptista/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/vitorbaptista/subscriptions", "type": "User", "url": "https://api.github.com/users/vitorbaptista", "user_view_type": "public" }
[]
closed
true
null
[]
null
4
2015-12-19T20:35:13Z
2021-09-08T20:00:54Z
2015-12-21T11:54:38Z
NONE
resolved
I'm able to explictly close a response by calling `response.close()`, but as far as I could see, the only way to check if the response is closed or not is calling `response.raw.closed`. This feels like violating Demeter's Law, so I would suggest adding a `response.closed` attribute. If you agree, I'd be happy to send a pull request with this change.
{ "avatar_url": "https://avatars.githubusercontent.com/u/76945?v=4", "events_url": "https://api.github.com/users/vitorbaptista/events{/privacy}", "followers_url": "https://api.github.com/users/vitorbaptista/followers", "following_url": "https://api.github.com/users/vitorbaptista/following{/other_user}", "gists_url": "https://api.github.com/users/vitorbaptista/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/vitorbaptista", "id": 76945, "login": "vitorbaptista", "node_id": "MDQ6VXNlcjc2OTQ1", "organizations_url": "https://api.github.com/users/vitorbaptista/orgs", "received_events_url": "https://api.github.com/users/vitorbaptista/received_events", "repos_url": "https://api.github.com/users/vitorbaptista/repos", "site_admin": false, "starred_url": "https://api.github.com/users/vitorbaptista/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/vitorbaptista/subscriptions", "type": "User", "url": "https://api.github.com/users/vitorbaptista", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/2940/reactions" }
https://api.github.com/repos/psf/requests/issues/2940/timeline
null
completed
null
null
false
[ "@vitorbaptista Out of interest, why do you care if the response object is closed?\n", "I have a class that internally uses requests, but not through contexts (I have to keep the response around for a while, so I can't use contexts). I want to write a test to ensure that the response is closed after the object is...
https://api.github.com/repos/psf/requests/issues/2939
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/2939/labels{/name}
https://api.github.com/repos/psf/requests/issues/2939/comments
https://api.github.com/repos/psf/requests/issues/2939/events
https://github.com/psf/requests/issues/2939
123,086,277
MDU6SXNzdWUxMjMwODYyNzc=
2,939
Multiple Location headers in response are concatenated
{ "avatar_url": "https://avatars.githubusercontent.com/u/1921370?v=4", "events_url": "https://api.github.com/users/L2501/events{/privacy}", "followers_url": "https://api.github.com/users/L2501/followers", "following_url": "https://api.github.com/users/L2501/following{/other_user}", "gists_url": "https://api.github.com/users/L2501/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/L2501", "id": 1921370, "login": "L2501", "node_id": "MDQ6VXNlcjE5MjEzNzA=", "organizations_url": "https://api.github.com/users/L2501/orgs", "received_events_url": "https://api.github.com/users/L2501/received_events", "repos_url": "https://api.github.com/users/L2501/repos", "site_admin": false, "starred_url": "https://api.github.com/users/L2501/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/L2501/subscriptions", "type": "User", "url": "https://api.github.com/users/L2501", "user_view_type": "public" }
[]
closed
true
null
[]
{ "closed_at": null, "closed_issues": 29, "created_at": "2013-11-17T11:29:34Z", "creator": { "avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4", "events_url": "https://api.github.com/users/Lukasa/events{/privacy}", "followers_url": "https://api.github.com/users/Lukasa/followers", "following_url": "https://api.github.com/users/Lukasa/following{/other_user}", "gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/Lukasa", "id": 1382556, "login": "Lukasa", "node_id": "MDQ6VXNlcjEzODI1NTY=", "organizations_url": "https://api.github.com/users/Lukasa/orgs", "received_events_url": "https://api.github.com/users/Lukasa/received_events", "repos_url": "https://api.github.com/users/Lukasa/repos", "site_admin": false, "starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions", "type": "User", "url": "https://api.github.com/users/Lukasa", "user_view_type": "public" }, "description": null, "due_on": null, "html_url": "https://github.com/psf/requests/milestone/20", "id": 487518, "labels_url": "https://api.github.com/repos/psf/requests/milestones/20/labels", "node_id": "MDk6TWlsZXN0b25lNDg3NTE4", "number": 20, "open_issues": 12, "state": "open", "title": "3.0.0", "updated_at": "2024-05-19T18:43:00Z", "url": "https://api.github.com/repos/psf/requests/milestones/20" }
28
2015-12-19T13:50:05Z
2021-09-08T15:00:54Z
2016-09-06T00:07:12Z
NONE
resolved
tested with requests 2.9 when a http server resonds with multiple Location headers in 301 redirect the locations are concatenated eg Location: http://foo.com Location: http://foo.com results in a redirect to "http://foo.com,http://foo.com" pretty sure this behavior is not present in any other http clients
{ "avatar_url": "https://avatars.githubusercontent.com/u/240830?v=4", "events_url": "https://api.github.com/users/sigmavirus24/events{/privacy}", "followers_url": "https://api.github.com/users/sigmavirus24/followers", "following_url": "https://api.github.com/users/sigmavirus24/following{/other_user}", "gists_url": "https://api.github.com/users/sigmavirus24/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/sigmavirus24", "id": 240830, "login": "sigmavirus24", "node_id": "MDQ6VXNlcjI0MDgzMA==", "organizations_url": "https://api.github.com/users/sigmavirus24/orgs", "received_events_url": "https://api.github.com/users/sigmavirus24/received_events", "repos_url": "https://api.github.com/users/sigmavirus24/repos", "site_admin": false, "starred_url": "https://api.github.com/users/sigmavirus24/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sigmavirus24/subscriptions", "type": "User", "url": "https://api.github.com/users/sigmavirus24", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/2939/reactions" }
https://api.github.com/repos/psf/requests/issues/2939/timeline
null
completed
null
null
false
[ "A web server MUST NOT respond with multiple location header fields. From [RFC 7320 Section 3.2.2](https://tools.ietf.org/html/rfc7230#section-3.2.2):\n\n> A sender MUST NOT generate multiple header fields with the same field name in a message unless either the entire field value for that header field is defined as...
https://api.github.com/repos/psf/requests/issues/2938
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/2938/labels{/name}
https://api.github.com/repos/psf/requests/issues/2938/comments
https://api.github.com/repos/psf/requests/issues/2938/events
https://github.com/psf/requests/issues/2938
123,062,910
MDU6SXNzdWUxMjMwNjI5MTA=
2,938
Unicode decode error with PATCH request
{ "avatar_url": "https://avatars.githubusercontent.com/u/4306733?v=4", "events_url": "https://api.github.com/users/scossu/events{/privacy}", "followers_url": "https://api.github.com/users/scossu/followers", "following_url": "https://api.github.com/users/scossu/following{/other_user}", "gists_url": "https://api.github.com/users/scossu/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/scossu", "id": 4306733, "login": "scossu", "node_id": "MDQ6VXNlcjQzMDY3MzM=", "organizations_url": "https://api.github.com/users/scossu/orgs", "received_events_url": "https://api.github.com/users/scossu/received_events", "repos_url": "https://api.github.com/users/scossu/repos", "site_admin": false, "starred_url": "https://api.github.com/users/scossu/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/scossu/subscriptions", "type": "User", "url": "https://api.github.com/users/scossu", "user_view_type": "public" }
[]
closed
true
null
[]
null
1
2015-12-19T05:06:23Z
2021-09-08T20:00:54Z
2015-12-19T08:39:01Z
NONE
resolved
In requests 2.9.0: ``` >>> requests.patch('https://example.org', data=bytes('ô', 'utf-8')) Traceback (most recent call last): File "<stdin>", line 1, in <module> File "/usr/local/combine/virtualenv/lib/python3.4/site-packages/requests/api.py", line 133, in patch return request('patch', url, data=data, **kwargs) File "/usr/local/combine/virtualenv/lib/python3.4/site-packages/requests/api.py", line 53, in request return session.request(method=method, url=url, **kwargs) File "/usr/local/combine/virtualenv/lib/python3.4/site-packages/requests/sessions.py", line 454, in request prep = self.prepare_request(req) File "/usr/local/combine/virtualenv/lib/python3.4/site-packages/requests/sessions.py", line 388, in prepare_request hooks=merge_hooks(request.hooks, self.hooks), File "/usr/local/combine/virtualenv/lib/python3.4/site-packages/requests/models.py", line 296, in prepare self.prepare_body(data, files, json) File "/usr/local/combine/virtualenv/lib/python3.4/site-packages/requests/models.py", line 447, in prepare_body body = self._encode_params(data) File "/usr/local/combine/virtualenv/lib/python3.4/site-packages/requests/models.py", line 84, in _encode_params return to_native_string(data) File "/usr/local/combine/virtualenv/lib/python3.4/site-packages/requests/utils.py", line 700, in to_native_string out = string.decode(encoding) UnicodeDecodeError: 'ascii' codec can't decode byte 0xc3 in position 0: ordinal not in range(128) ``` This seems to be a problem with all strings containing Unicode characters. It works without problems in 2.8.1.
{ "avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4", "events_url": "https://api.github.com/users/Lukasa/events{/privacy}", "followers_url": "https://api.github.com/users/Lukasa/followers", "following_url": "https://api.github.com/users/Lukasa/following{/other_user}", "gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/Lukasa", "id": 1382556, "login": "Lukasa", "node_id": "MDQ6VXNlcjEzODI1NTY=", "organizations_url": "https://api.github.com/users/Lukasa/orgs", "received_events_url": "https://api.github.com/users/Lukasa/received_events", "repos_url": "https://api.github.com/users/Lukasa/repos", "site_admin": false, "starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions", "type": "User", "url": "https://api.github.com/users/Lukasa", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/2938/reactions" }
https://api.github.com/repos/psf/requests/issues/2938/timeline
null
completed
null
null
false
[ "This is a duplicate of #2933 and #2930, and is fixed in #2931. Thanks for the report, but in future please check both open and **closed** issues before filing a bug, as the issue may already be known. A new release of requests will be made on Monday that contains the fix for this issue.\n\nThanks! :sparkles: :cake...
https://api.github.com/repos/psf/requests/issues/2937
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/2937/labels{/name}
https://api.github.com/repos/psf/requests/issues/2937/comments
https://api.github.com/repos/psf/requests/issues/2937/events
https://github.com/psf/requests/pull/2937
122,917,318
MDExOlB1bGxSZXF1ZXN0NTQwODM1NDM=
2,937
Release 2.9.1
{ "avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4", "events_url": "https://api.github.com/users/Lukasa/events{/privacy}", "followers_url": "https://api.github.com/users/Lukasa/followers", "following_url": "https://api.github.com/users/Lukasa/following{/other_user}", "gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/Lukasa", "id": 1382556, "login": "Lukasa", "node_id": "MDQ6VXNlcjEzODI1NTY=", "organizations_url": "https://api.github.com/users/Lukasa/orgs", "received_events_url": "https://api.github.com/users/Lukasa/received_events", "repos_url": "https://api.github.com/users/Lukasa/repos", "site_admin": false, "starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions", "type": "User", "url": "https://api.github.com/users/Lukasa", "user_view_type": "public" }
[ { "color": "009800", "default": false, "description": null, "id": 44501218, "name": "Ready To Merge", "node_id": "MDU6TGFiZWw0NDUwMTIxOA==", "url": "https://api.github.com/repos/psf/requests/labels/Ready%20To%20Merge" } ]
closed
true
null
[]
null
16
2015-12-18T09:56:33Z
2021-09-08T05:01:07Z
2015-12-21T14:51:21Z
MEMBER
resolved
This release is scheduled for Monday. I'm aiming to set this up now so that it's an easy release to push on Monday. @shazow, what are the odds that we can get a urllib3 patch release 1.13.1 containing the fix for shazow/urllib3#761 by Monday? I'd owe you lots of :custard: if we could get it! :heart:
{ "avatar_url": "https://avatars.githubusercontent.com/u/240830?v=4", "events_url": "https://api.github.com/users/sigmavirus24/events{/privacy}", "followers_url": "https://api.github.com/users/sigmavirus24/followers", "following_url": "https://api.github.com/users/sigmavirus24/following{/other_user}", "gists_url": "https://api.github.com/users/sigmavirus24/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/sigmavirus24", "id": 240830, "login": "sigmavirus24", "node_id": "MDQ6VXNlcjI0MDgzMA==", "organizations_url": "https://api.github.com/users/sigmavirus24/orgs", "received_events_url": "https://api.github.com/users/sigmavirus24/received_events", "repos_url": "https://api.github.com/users/sigmavirus24/repos", "site_admin": false, "starred_url": "https://api.github.com/users/sigmavirus24/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sigmavirus24/subscriptions", "type": "User", "url": "https://api.github.com/users/sigmavirus24", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/2937/reactions" }
https://api.github.com/repos/psf/requests/issues/2937/timeline
null
null
false
{ "diff_url": "https://github.com/psf/requests/pull/2937.diff", "html_url": "https://github.com/psf/requests/pull/2937", "merged_at": "2015-12-21T14:51:21Z", "patch_url": "https://github.com/psf/requests/pull/2937.patch", "url": "https://api.github.com/repos/psf/requests/pulls/2937" }
true
[ "Note: please don't merge this until we're ready to release on Monday! We may land other patches between now and then, and we'll want to make sure the changelog is updated!\n\nFor those who are interested: the reason we're enforcing a delay between 2.9.0 and 2.9.1 is to try to land as many regression fixes as possi...
https://api.github.com/repos/psf/requests/issues/2936
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/2936/labels{/name}
https://api.github.com/repos/psf/requests/issues/2936/comments
https://api.github.com/repos/psf/requests/issues/2936/events
https://github.com/psf/requests/pull/2936
122,911,202
MDExOlB1bGxSZXF1ZXN0NTQwODA2NjE=
2,936
Handle bytes and unicode URLs for netloc
{ "avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4", "events_url": "https://api.github.com/users/Lukasa/events{/privacy}", "followers_url": "https://api.github.com/users/Lukasa/followers", "following_url": "https://api.github.com/users/Lukasa/following{/other_user}", "gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/Lukasa", "id": 1382556, "login": "Lukasa", "node_id": "MDQ6VXNlcjEzODI1NTY=", "organizations_url": "https://api.github.com/users/Lukasa/orgs", "received_events_url": "https://api.github.com/users/Lukasa/received_events", "repos_url": "https://api.github.com/users/Lukasa/repos", "site_admin": false, "starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions", "type": "User", "url": "https://api.github.com/users/Lukasa", "user_view_type": "public" }
[]
closed
true
{ "avatar_url": "https://avatars.githubusercontent.com/u/240830?v=4", "events_url": "https://api.github.com/users/sigmavirus24/events{/privacy}", "followers_url": "https://api.github.com/users/sigmavirus24/followers", "following_url": "https://api.github.com/users/sigmavirus24/following{/other_user}", "gists_url": "https://api.github.com/users/sigmavirus24/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/sigmavirus24", "id": 240830, "login": "sigmavirus24", "node_id": "MDQ6VXNlcjI0MDgzMA==", "organizations_url": "https://api.github.com/users/sigmavirus24/orgs", "received_events_url": "https://api.github.com/users/sigmavirus24/received_events", "repos_url": "https://api.github.com/users/sigmavirus24/repos", "site_admin": false, "starred_url": "https://api.github.com/users/sigmavirus24/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sigmavirus24/subscriptions", "type": "User", "url": "https://api.github.com/users/sigmavirus24", "user_view_type": "public" }
[ { "avatar_url": "https://avatars.githubusercontent.com/u/240830?v=4", "events_url": "https://api.github.com/users/sigmavirus24/events{/privacy}", "followers_url": "https://api.github.com/users/sigmavirus24/followers", "following_url": "https://api.github.com/users/sigmavirus24/following{/other_user}...
null
1
2015-12-18T09:23:48Z
2021-09-08T05:01:08Z
2015-12-19T17:34:34Z
MEMBER
resolved
Spotted this on my local machine running tests on Python 3. Annoyingly, we didn't see this on the CI rig because the Jenkins box doesn't have a netrc file, so it never gets that far in the function. However, tests preparing bytes URLs fail here on Python 3 because the splitter is the wrong type. This change ensures that we use the appropriate type. Feels like this is safe for 2.9.1.
{ "avatar_url": "https://avatars.githubusercontent.com/u/240830?v=4", "events_url": "https://api.github.com/users/sigmavirus24/events{/privacy}", "followers_url": "https://api.github.com/users/sigmavirus24/followers", "following_url": "https://api.github.com/users/sigmavirus24/following{/other_user}", "gists_url": "https://api.github.com/users/sigmavirus24/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/sigmavirus24", "id": 240830, "login": "sigmavirus24", "node_id": "MDQ6VXNlcjI0MDgzMA==", "organizations_url": "https://api.github.com/users/sigmavirus24/orgs", "received_events_url": "https://api.github.com/users/sigmavirus24/received_events", "repos_url": "https://api.github.com/users/sigmavirus24/repos", "site_admin": false, "starred_url": "https://api.github.com/users/sigmavirus24/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sigmavirus24/subscriptions", "type": "User", "url": "https://api.github.com/users/sigmavirus24", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/2936/reactions" }
https://api.github.com/repos/psf/requests/issues/2936/timeline
null
null
false
{ "diff_url": "https://github.com/psf/requests/pull/2936.diff", "html_url": "https://github.com/psf/requests/pull/2936", "merged_at": "2015-12-19T17:34:34Z", "patch_url": "https://github.com/psf/requests/pull/2936.patch", "url": "https://api.github.com/repos/psf/requests/pulls/2936" }
true
[ "Woot! :+1: \n\nThanks @Lukasa (also YAY OUR CI IS WORKING AGAIN)\n" ]
https://api.github.com/repos/psf/requests/issues/2935
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/2935/labels{/name}
https://api.github.com/repos/psf/requests/issues/2935/comments
https://api.github.com/repos/psf/requests/issues/2935/events
https://github.com/psf/requests/issues/2935
122,853,114
MDU6SXNzdWUxMjI4NTMxMTQ=
2,935
KeyError in connectionpool?
{ "avatar_url": "https://avatars.githubusercontent.com/u/56894?v=4", "events_url": "https://api.github.com/users/Kronuz/events{/privacy}", "followers_url": "https://api.github.com/users/Kronuz/followers", "following_url": "https://api.github.com/users/Kronuz/following{/other_user}", "gists_url": "https://api.github.com/users/Kronuz/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/Kronuz", "id": 56894, "login": "Kronuz", "node_id": "MDQ6VXNlcjU2ODk0", "organizations_url": "https://api.github.com/users/Kronuz/orgs", "received_events_url": "https://api.github.com/users/Kronuz/received_events", "repos_url": "https://api.github.com/users/Kronuz/repos", "site_admin": false, "starred_url": "https://api.github.com/users/Kronuz/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Kronuz/subscriptions", "type": "User", "url": "https://api.github.com/users/Kronuz", "user_view_type": "public" }
[ { "color": "e10c02", "default": false, "description": null, "id": 117744, "name": "Bug", "node_id": "MDU6TGFiZWwxMTc3NDQ=", "url": "https://api.github.com/repos/psf/requests/labels/Bug" }, { "color": "fef2c0", "default": false, "description": null, "id": 298537994, ...
closed
true
null
[]
null
44
2015-12-18T00:38:06Z
2021-09-08T19:00:30Z
2016-03-09T08:17:03Z
NONE
resolved
I'm getting a weird error during this call `conn = old_pool.get(block=False)` in connectionpool.py:410. The Error in Sentry is: `Queue in get, KeyError: (1, True)` And this is the traceback, which doesn't make sense, as `requests/packages/urllib3/connectionpool.py` catches that Empty exception; plus I have no idea what that KeyError is coming from ... any ideas?: ``` python Stacktrace (most recent call last): File "pac/business/views.py", line 49, in get_eticket response = requests.get(url, timeout=timeout, verify=False) File "requests/api.py", line 69, in get return request('get', url, params=params, **kwargs) File "requests/api.py", line 54, in request session.close() File "requests/sessions.py", line 649, in close v.close() File "requests/adapters.py", line 264, in close self.poolmanager.clear() File "requests/packages/urllib3/poolmanager.py", line 99, in clear self.pools.clear() File "requests/packages/urllib3/_collections.py", line 93, in clear self.dispose_func(value) File "requests/packages/urllib3/poolmanager.py", line 65, in <lambda> dispose_func=lambda p: p.close()) File "requests/packages/urllib3/connectionpool.py", line 410, in close conn = old_pool.get(block=False) File "python2.7/Queue.py", line 165, in get raise Empty ```
{ "avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4", "events_url": "https://api.github.com/users/Lukasa/events{/privacy}", "followers_url": "https://api.github.com/users/Lukasa/followers", "following_url": "https://api.github.com/users/Lukasa/following{/other_user}", "gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/Lukasa", "id": 1382556, "login": "Lukasa", "node_id": "MDQ6VXNlcjEzODI1NTY=", "organizations_url": "https://api.github.com/users/Lukasa/orgs", "received_events_url": "https://api.github.com/users/Lukasa/received_events", "repos_url": "https://api.github.com/users/Lukasa/repos", "site_admin": false, "starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions", "type": "User", "url": "https://api.github.com/users/Lukasa", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/2935/reactions" }
https://api.github.com/repos/psf/requests/issues/2935/timeline
null
completed
null
null
false
[ "@Kronuz What version of requests are you using, please?\n", "Sorry, forgot to say. I'm using v2.8.1, from PyPI.\n", "Are you running Python 3?\n", "Nope, I'm using Python 2.7.11\n", "Ok, so I'm inclined to believe that the traceback you're showing me cannot be right. It just doesn't seem to make any sense ...
https://api.github.com/repos/psf/requests/issues/2934
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/2934/labels{/name}
https://api.github.com/repos/psf/requests/issues/2934/comments
https://api.github.com/repos/psf/requests/issues/2934/events
https://github.com/psf/requests/issues/2934
122,744,855
MDU6SXNzdWUxMjI3NDQ4NTU=
2,934
DigestAuth doesn't re-auth with provided WWW-Authenticate
{ "avatar_url": "https://avatars.githubusercontent.com/u/39889?v=4", "events_url": "https://api.github.com/users/yarikoptic/events{/privacy}", "followers_url": "https://api.github.com/users/yarikoptic/followers", "following_url": "https://api.github.com/users/yarikoptic/following{/other_user}", "gists_url": "https://api.github.com/users/yarikoptic/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/yarikoptic", "id": 39889, "login": "yarikoptic", "node_id": "MDQ6VXNlcjM5ODg5", "organizations_url": "https://api.github.com/users/yarikoptic/orgs", "received_events_url": "https://api.github.com/users/yarikoptic/received_events", "repos_url": "https://api.github.com/users/yarikoptic/repos", "site_admin": false, "starred_url": "https://api.github.com/users/yarikoptic/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/yarikoptic/subscriptions", "type": "User", "url": "https://api.github.com/users/yarikoptic", "user_view_type": "public" }
[]
closed
true
null
[]
null
2
2015-12-17T14:29:27Z
2021-09-08T20:00:55Z
2015-12-17T16:02:04Z
NONE
resolved
I am trying to use DigestAuth but it seems that requests doesn't try to complete the negotiation: ``` In [19]: url = 'http://crawdad.org//download/cambridge/haggle/imote-trace1.tar.gz' *In [20]: r = requests.get(url, auth=requests.auth.HTTPDigestAuth(user, passw)) INFO:requests.packages.urllib3.connectionpool:Starting new HTTP connection (1): crawdad.org send: 'GET //download/cambridge/haggle/imote-trace1.tar.gz HTTP/1.1\r\nHost: crawdad.org\r\nConnection: keep-alive\r\nAccept-Encoding: gzip, deflate\r\nAccept: */*\r\nUser-Agent: python-requests/2.8.1\r\n\r\n' reply: 'HTTP/1.1 401 Unauthorized\r\n' header: Date: Thu, 17 Dec 2015 14:20:14 GMT header: Server: Apache/2.4.10 (Fedora) header: WWW-Authenticate: Basic realm="Dartmouth wireless-network traces" header: Content-Length: 88 header: Connection: close header: Content-Type: text/html; charset=iso-8859-1 DEBUG:requests.packages.urllib3.connectionpool:"GET //download/cambridge/haggle/imote-trace1.tar.gz HTTP/1.1" 401 88 In [21]: r.status_code Out[21]: 401 In [22]: requests.__version__ Out[22]: '2.8.1' ``` note how it goes with wget (credentials are within ~/.netrc, I have masked out ETag and Authorization fields in the trace below): ``` $> wget -S --debug http://crawdad.org//download/cambridge/haggle/imote-trace1.tar.gz DEBUG output created by Wget 1.16.3 on linux-gnu. URI encoding = ‘UTF-8’ --2015-12-17 09:26:07-- http://crawdad.org//download/cambridge/haggle/imote-trace1.tar.gz Host ‘crawdad.org’ has not issued a general basic challenge. Resolving crawdad.org (crawdad.org)... 129.170.213.101 Caching crawdad.org => 129.170.213.101 Connecting to crawdad.org (crawdad.org)|129.170.213.101|:80... connected. Created socket 4. Releasing 0x00005578fbb08ee0 (new refcount 1). ---request begin--- GET //download/cambridge/haggle/imote-trace1.tar.gz HTTP/1.1 User-Agent: Wget/1.16.3 (linux-gnu) Accept: */* Accept-Encoding: identity Host: crawdad.org Connection: Keep-Alive ---request end--- HTTP request sent, awaiting response... ---response begin--- HTTP/1.1 401 Unauthorized Date: Thu, 17 Dec 2015 14:26:07 GMT Server: Apache/2.4.10 (Fedora) WWW-Authenticate: Basic realm="Dartmouth wireless-network traces" Content-Length: 88 Connection: close Content-Type: text/html; charset=iso-8859-1 ---response end--- HTTP/1.1 401 Unauthorized Date: Thu, 17 Dec 2015 14:26:07 GMT Server: Apache/2.4.10 (Fedora) WWW-Authenticate: Basic realm="Dartmouth wireless-network traces" Content-Length: 88 Connection: close Content-Type: text/html; charset=iso-8859-1 Closed fd 4 Auth scheme found 'Basic' Auth param list ' realm="Dartmouth wireless-network traces"' Auth param realm=Dartmouth wireless-network traces Authentication selected: Basic realm="Dartmouth wireless-network traces" Inserted ‘crawdad.org’ into basic_authed_hosts Found crawdad.org in host_name_addresses_map (0x5578fbb08ee0) Connecting to crawdad.org (crawdad.org)|129.170.213.101|:80... connected. Created socket 4. Releasing 0x00005578fbb08ee0 (new refcount 1). ---request begin--- GET //download/cambridge/haggle/imote-trace1.tar.gz HTTP/1.1 User-Agent: Wget/1.16.3 (linux-gnu) Accept: */* Accept-Encoding: identity Host: crawdad.org Connection: Keep-Alive Authorization: Basic XXXXXXXXXXXXXXXXXX== ---request end--- HTTP request sent, awaiting response... ---response begin--- HTTP/1.1 200 OK Date: Thu, 17 Dec 2015 14:26:08 GMT Server: Apache/2.4.10 (Fedora) Last-Modified: Tue, 17 Oct 2006 21:49:43 GMT ETag: "XXXX-XXXXXXXXXXXXXX" Accept-Ranges: bytes Content-Length: 29345 Connection: close Content-Type: application/x-gzip ---response end--- HTTP/1.1 200 OK Date: Thu, 17 Dec 2015 14:26:08 GMT Server: Apache/2.4.10 (Fedora) Last-Modified: Tue, 17 Oct 2006 21:49:43 GMT ETag: "XXXX-XXXXXXXXXXXXXX" Accept-Ranges: bytes Content-Length: 29345 Connection: close Content-Type: application/x-gzip Length: 29345 (29K) [application/x-gzip] Saving to: ‘imote-trace1.tar.gz.4’ imote-trace1.tar.gz.4 100%[==========================================================>] 28.66K --.-KB/s in 0.002s Closed fd 4 2015-12-17 09:26:08 (13.3 MB/s) - ‘imote-trace1.tar.gz.4’ saved [29345/29345] ``` P.S. if you are to decide to access that file, http://crawdad.org/joinup.html is the registration page
{ "avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4", "events_url": "https://api.github.com/users/Lukasa/events{/privacy}", "followers_url": "https://api.github.com/users/Lukasa/followers", "following_url": "https://api.github.com/users/Lukasa/following{/other_user}", "gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/Lukasa", "id": 1382556, "login": "Lukasa", "node_id": "MDQ6VXNlcjEzODI1NTY=", "organizations_url": "https://api.github.com/users/Lukasa/orgs", "received_events_url": "https://api.github.com/users/Lukasa/received_events", "repos_url": "https://api.github.com/users/Lukasa/repos", "site_admin": false, "starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions", "type": "User", "url": "https://api.github.com/users/Lukasa", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/2934/reactions" }
https://api.github.com/repos/psf/requests/issues/2934/timeline
null
completed
null
null
false
[ "The reason you're not authenticating is because the remote service isn't doing Digest auth, it's doing basic. Try `r = requests.get(url, auth=(user, passw))`.\n", "Thank you @Lukasa . I guess something else went wrong for me originally (when I thought I did use basic auth), and I did misread wget output (which ...
https://api.github.com/repos/psf/requests/issues/2933
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/2933/labels{/name}
https://api.github.com/repos/psf/requests/issues/2933/comments
https://api.github.com/repos/psf/requests/issues/2933/events
https://github.com/psf/requests/issues/2933
122,599,228
MDU6SXNzdWUxMjI1OTkyMjg=
2,933
Problem with bytes body in request 2.9 in Py 3.5
{ "avatar_url": "https://avatars.githubusercontent.com/u/1050156?v=4", "events_url": "https://api.github.com/users/lmazuel/events{/privacy}", "followers_url": "https://api.github.com/users/lmazuel/followers", "following_url": "https://api.github.com/users/lmazuel/following{/other_user}", "gists_url": "https://api.github.com/users/lmazuel/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/lmazuel", "id": 1050156, "login": "lmazuel", "node_id": "MDQ6VXNlcjEwNTAxNTY=", "organizations_url": "https://api.github.com/users/lmazuel/orgs", "received_events_url": "https://api.github.com/users/lmazuel/received_events", "repos_url": "https://api.github.com/users/lmazuel/repos", "site_admin": false, "starred_url": "https://api.github.com/users/lmazuel/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/lmazuel/subscriptions", "type": "User", "url": "https://api.github.com/users/lmazuel", "user_view_type": "public" }
[]
closed
true
null
[]
null
2
2015-12-16T20:55:44Z
2021-09-08T20:00:55Z
2015-12-16T21:19:07Z
NONE
resolved
Hello, Our library suddenly stops to works in Python 3 for our users after `requests` 2.9 release, for instance: https://github.com/Azure/azure-storage-python/issues/89 I investigated the stack trace, and I found that when the body of the requests contains "real" bytes ("real" stands for OSImage, PDF,... not something readable), the code breaks. Especially, `requests` 2.9 in `requests.models#_encode_params` calls a new method `requests.utils#to_native_string` which tries to convert my bytes data using an ASCII encoder which is not possible if data are "real" bytes. This is the interesting part of the stacktrace extracting from the previously mentioned bug ``` self.response = self.session.request(self.method, self.uri, data=request_body, headers=self.headers, timeout=self.timeout) File "/usr/local/lib/python3.5/site-packages/requests/sessions.py", line 454, in request prep = self.prepare_request(req) File "/usr/local/lib/python3.5/site-packages/requests/sessions.py", line 388, in prepare_request hooks=merge_hooks(request.hooks, self.hooks), File "/usr/local/lib/python3.5/site-packages/requests/models.py", line 296, in prepare self.prepare_body(data, files, json) File "/usr/local/lib/python3.5/site-packages/requests/models.py", line 447, in prepare_body body = self._encode_params(data) File "/usr/local/lib/python3.5/site-packages/requests/models.py", line 84, in _encode_params return to_native_string(data) File "/usr/local/lib/python3.5/site-packages/requests/utils.py", line 700, in to_native_string out = string.decode(encoding) UnicodeDecodeError: 'ascii' codec can't decode byte 0xd0 in position 0: ordinal not in range(128) ``` What do you think? Tell me if I can help for anything. Thank you,
{ "avatar_url": "https://avatars.githubusercontent.com/u/240830?v=4", "events_url": "https://api.github.com/users/sigmavirus24/events{/privacy}", "followers_url": "https://api.github.com/users/sigmavirus24/followers", "following_url": "https://api.github.com/users/sigmavirus24/following{/other_user}", "gists_url": "https://api.github.com/users/sigmavirus24/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/sigmavirus24", "id": 240830, "login": "sigmavirus24", "node_id": "MDQ6VXNlcjI0MDgzMA==", "organizations_url": "https://api.github.com/users/sigmavirus24/orgs", "received_events_url": "https://api.github.com/users/sigmavirus24/received_events", "repos_url": "https://api.github.com/users/sigmavirus24/repos", "site_admin": false, "starred_url": "https://api.github.com/users/sigmavirus24/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sigmavirus24/subscriptions", "type": "User", "url": "https://api.github.com/users/sigmavirus24", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/2933/reactions" }
https://api.github.com/repos/psf/requests/issues/2933/timeline
null
completed
null
null
false
[ "This is already fixed in #2931. In the future, please check open _and_ closed issues before filing new issues.\n", "Sorry, yes I forgot to check closed issues.\nThank you for the report.\n" ]
https://api.github.com/repos/psf/requests/issues/2932
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/2932/labels{/name}
https://api.github.com/repos/psf/requests/issues/2932/comments
https://api.github.com/repos/psf/requests/issues/2932/events
https://github.com/psf/requests/issues/2932
122,560,251
MDU6SXNzdWUxMjI1NjAyNTE=
2,932
PyPI doesn't know about python 3 support
{ "avatar_url": "https://avatars.githubusercontent.com/u/528022?v=4", "events_url": "https://api.github.com/users/mrterry/events{/privacy}", "followers_url": "https://api.github.com/users/mrterry/followers", "following_url": "https://api.github.com/users/mrterry/following{/other_user}", "gists_url": "https://api.github.com/users/mrterry/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/mrterry", "id": 528022, "login": "mrterry", "node_id": "MDQ6VXNlcjUyODAyMg==", "organizations_url": "https://api.github.com/users/mrterry/orgs", "received_events_url": "https://api.github.com/users/mrterry/received_events", "repos_url": "https://api.github.com/users/mrterry/repos", "site_admin": false, "starred_url": "https://api.github.com/users/mrterry/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/mrterry/subscriptions", "type": "User", "url": "https://api.github.com/users/mrterry", "user_view_type": "public" }
[]
closed
true
null
[]
null
1
2015-12-16T17:26:32Z
2021-09-08T20:00:56Z
2015-12-16T17:34:29Z
NONE
resolved
PyPI doesn't seem to know that requests supports Python 3 (3.3, 3.4, & 3.5!). As a result, [caniusepython3](https://caniusepython3.com/) thinks `requests` is a Python 3 blocker and `requests` is in red on the [Python 3 Wall of Superpowers](https://python3wos.appspot.com/). Requests is awesome and it should get the credit it deserves.
{ "avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4", "events_url": "https://api.github.com/users/Lukasa/events{/privacy}", "followers_url": "https://api.github.com/users/Lukasa/followers", "following_url": "https://api.github.com/users/Lukasa/following{/other_user}", "gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/Lukasa", "id": 1382556, "login": "Lukasa", "node_id": "MDQ6VXNlcjEzODI1NTY=", "organizations_url": "https://api.github.com/users/Lukasa/orgs", "received_events_url": "https://api.github.com/users/Lukasa/received_events", "repos_url": "https://api.github.com/users/Lukasa/repos", "site_admin": false, "starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions", "type": "User", "url": "https://api.github.com/users/Lukasa", "user_view_type": "public" }
{ "+1": 0, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 0, "url": "https://api.github.com/repos/psf/requests/issues/2932/reactions" }
https://api.github.com/repos/psf/requests/issues/2932/timeline
null
completed
null
null
false
[ "Annoyingly, our trove classifiers appear to have disappeared again. I've re-uploaded them. Thanks!\n" ]