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/4661
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4661/labels{/name}
https://api.github.com/repos/psf/requests/issues/4661/comments
https://api.github.com/repos/psf/requests/issues/4661/events
https://github.com/psf/requests/pull/4661
326,773,738
MDExOlB1bGxSZXF1ZXN0MTkwNzYyODg4
4,661
Response.content minor perf improvement
{ "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
2
2018-05-26T23:11:52Z
2021-09-03T00:10:56Z
2018-05-27T00:00:26Z
CONTRIBUTOR
resolved
Python 2 ```console $ python -m timeit -s "blist = [b'foo', b'bar'];" "bytes().join(blist)" 1000000 loops, best of 3: 0.243 usec per loop $ python -m timeit -s "blist = [b'foo', b'bar'];" "b''.join(blist)" 10000000 loops, best of 3: 0.125 usec per loop ``` Python 3 ```console $ python -m timeit -s "blist = [b'foo', b'bar'];" "bytes().join(blist)" 1000000 loops, best of 3: 0.285 usec per loop $ python -m timeit -s "blist = [b'foo', b'bar'];" "b''.join(blist)" 10000000 loops, best of 3: 0.161 usec per loop ```
{ "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/4661/reactions" }
https://api.github.com/repos/psf/requests/issues/4661/timeline
null
null
false
{ "diff_url": "https://github.com/psf/requests/pull/4661.diff", "html_url": "https://github.com/psf/requests/pull/4661", "merged_at": "2018-05-27T00:00:26Z", "patch_url": "https://github.com/psf/requests/pull/4661.patch", "url": "https://api.github.com/repos/psf/requests/pulls/4661" }
true
[ "# [Codecov](https://codecov.io/gh/requests/requests/pull/4661?src=pr&el=h1) Report\n> Merging [#4661](https://codecov.io/gh/requests/requests/pull/4661?src=pr&el=desc) into [master](https://codecov.io/gh/requests/requests/commit/fe8290b3d0ca21dd8ae5471a59a8bf13d3dcb31e?src=pr&el=desc) will **not change** coverage....
https://api.github.com/repos/psf/requests/issues/4660
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4660/labels{/name}
https://api.github.com/repos/psf/requests/issues/4660/comments
https://api.github.com/repos/psf/requests/issues/4660/events
https://github.com/psf/requests/issues/4660
326,713,537
MDU6SXNzdWUzMjY3MTM1Mzc=
4,660
Multipart PUT?
{ "avatar_url": "https://avatars.githubusercontent.com/u/2229284?v=4", "events_url": "https://api.github.com/users/aparamon/events{/privacy}", "followers_url": "https://api.github.com/users/aparamon/followers", "following_url": "https://api.github.com/users/aparamon/following{/other_user}", "gists_url": "https://api.github.com/users/aparamon/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/aparamon", "id": 2229284, "login": "aparamon", "node_id": "MDQ6VXNlcjIyMjkyODQ=", "organizations_url": "https://api.github.com/users/aparamon/orgs", "received_events_url": "https://api.github.com/users/aparamon/received_events", "repos_url": "https://api.github.com/users/aparamon/repos", "site_admin": false, "starred_url": "https://api.github.com/users/aparamon/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/aparamon/subscriptions", "type": "User", "url": "https://api.github.com/users/aparamon", "user_view_type": "public" }
[]
closed
true
null
[]
null
1
2018-05-26T06:05:08Z
2021-09-08T02:09:54Z
2018-05-26T11:38:32Z
NONE
resolved
Does `requests` currently support Multipart-encoded files in `PUT` requests? It seems that both http://docs.python-requests.org/en/master/user/quickstart/#post-a-multipart-encoded-file and https://toolbelt.readthedocs.io/en/latest/uploading-data.html only work with `POST`. For `PUT` requests, I keep getting error "413 Request Entity Too Large" from my Apache httpd. Should that be considered a bug, improvement suggestion, or there is some fundamental limitation why `PUT` shouldn't upload large files? (yes, my `GET` would stream the huge file unmodified) Original StackOverflow question: https://stackoverflow.com/questions/50533901/multipart-put-with-requests
{ "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/4660/reactions" }
https://api.github.com/repos/psf/requests/issues/4660/timeline
null
completed
null
null
false
[ "> I keep getting error \"413 Request Entity Too Large\" from my Apache httpd.\r\n\r\nThe documentation might be misleading, but we do support `multipart/form-data` content in a `PUT`. `POST` requests are merely the 99% use-case. It seems your Apache server, however, will not accept the request you're sending for l...
https://api.github.com/repos/psf/requests/issues/4659
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4659/labels{/name}
https://api.github.com/repos/psf/requests/issues/4659/comments
https://api.github.com/repos/psf/requests/issues/4659/events
https://github.com/psf/requests/issues/4659
326,541,881
MDU6SXNzdWUzMjY1NDE4ODE=
4,659
requests[security] breaks on Python 2.6 after pyOpenSSL 18.0.0 (2018-05-16) drops support
{ "avatar_url": "https://avatars.githubusercontent.com/u/454042?v=4", "events_url": "https://api.github.com/users/dwightgunning/events{/privacy}", "followers_url": "https://api.github.com/users/dwightgunning/followers", "following_url": "https://api.github.com/users/dwightgunning/following{/other_user}", "gists_url": "https://api.github.com/users/dwightgunning/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/dwightgunning", "id": 454042, "login": "dwightgunning", "node_id": "MDQ6VXNlcjQ1NDA0Mg==", "organizations_url": "https://api.github.com/users/dwightgunning/orgs", "received_events_url": "https://api.github.com/users/dwightgunning/received_events", "repos_url": "https://api.github.com/users/dwightgunning/repos", "site_admin": false, "starred_url": "https://api.github.com/users/dwightgunning/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/dwightgunning/subscriptions", "type": "User", "url": "https://api.github.com/users/dwightgunning", "user_view_type": "public" }
[]
closed
true
null
[]
null
9
2018-05-25T14:15:59Z
2021-09-08T01:21:22Z
2018-06-12T15:29:42Z
NONE
resolved
WIth the 18.0.0 release, pyOpenSSL dropped support for Python 2.6. As requests[security] pins pyOpenSSL with only a minimum version, fresh installations of requests pick up the latest and incompatible dependency. ## Expected Result Requests[security] functions to work. ## Actual Result ```python NameError: global name 'memoryview' is not defined ``` ## Reproduction Steps ```python >>> import requests /Users/dwight/.local/share/virtualenvs/stream-python-z8k7CN8K/lib/python2.6/site-packages/cryptography/__init__.py:26: DeprecationWarning: Python 2.6 is no longer supported by the Python core team, please upgrade your Python. The next version of cryptography will drop support for Python 2.6 DeprecationWarning >>> requests.get('https://www.dwightgunning.com') Traceback (most recent call last): File "<stdin>", line 1, in <module> File "/Users/dwight/.local/share/virtualenvs/stream-python-z8k7CN8K/lib/python2.6/site-packages/requests/api.py", line 72, in get return request('get', url, params=params, **kwargs) File "/Users/dwight/.local/share/virtualenvs/stream-python-z8k7CN8K/lib/python2.6/site-packages/requests/api.py", line 58, in request return session.request(method=method, url=url, **kwargs) File "/Users/dwight/.local/share/virtualenvs/stream-python-z8k7CN8K/lib/python2.6/site-packages/requests/sessions.py", line 508, in request resp = self.send(prep, **send_kwargs) File "/Users/dwight/.local/share/virtualenvs/stream-python-z8k7CN8K/lib/python2.6/site-packages/requests/sessions.py", line 618, in send r = adapter.send(request, **kwargs) File "/Users/dwight/.local/share/virtualenvs/stream-python-z8k7CN8K/lib/python2.6/site-packages/requests/adapters.py", line 440, in send timeout=timeout File "/Users/dwight/.local/share/virtualenvs/stream-python-z8k7CN8K/lib/python2.6/site-packages/urllib3/connectionpool.py", line 601, in urlopen chunked=chunked) File "/Users/dwight/.local/share/virtualenvs/stream-python-z8k7CN8K/lib/python2.6/site-packages/urllib3/connectionpool.py", line 357, in _make_request conn.request(method, url, **httplib_request_kw) File "/Users/dwight/.pyenv/versions/2.6.6/lib/python2.6/httplib.py", line 914, in request self._send_request(method, url, body, headers) File "/Users/dwight/.pyenv/versions/2.6.6/lib/python2.6/httplib.py", line 951, in _send_request self.endheaders() File "/Users/dwight/.pyenv/versions/2.6.6/lib/python2.6/httplib.py", line 908, in endheaders self._send_output() File "/Users/dwight/.pyenv/versions/2.6.6/lib/python2.6/httplib.py", line 780, in _send_output self.send(msg) File "/Users/dwight/.pyenv/versions/2.6.6/lib/python2.6/httplib.py", line 759, in send self.sock.sendall(str) File "/Users/dwight/.local/share/virtualenvs/stream-python-z8k7CN8K/lib/python2.6/site-packages/urllib3/contrib/pyopenssl.py", line 316, in sendall sent = self._send_until_done(data[total_sent:total_sent + SSL_WRITE_BLOCKSIZE]) File "/Users/dwight/.local/share/virtualenvs/stream-python-z8k7CN8K/lib/python2.6/site-packages/urllib3/contrib/pyopenssl.py", line 304, in _send_until_done return self.connection.send(data) File "build/bdist.macosx-10.13-x86_64/egg/OpenSSL/SSL.py", line 1719, in send NameError: global name 'memoryview' is not defined ``` ## System Information ```bash $ python --version Python 2.6.6 $ python -m requests.help /Users/dwight/.local/share/virtualenvs/stream-python-z8k7CN8K/lib/python2.6/site-packages/cryptography/__init__.py:26: DeprecationWarning: Python 2.6 is no longer supported by the Python core team, please upgrade your Python. The next version of cryptography will drop support for Python 2.6 DeprecationWarning { "chardet": { "version": "3.0.4" }, "cryptography": { "version": "2.1.4" }, "idna": { "version": "2.6" }, "implementation": { "name": "CPython", "version": "2.6.6" }, "platform": { "release": "17.5.0", "system": "Darwin" }, "pyOpenSSL": { "openssl_version": "100020ff", "version": "18.0.0" }, "requests": { "version": "2.18.4" }, "system_ssl": { "version": "" }, "urllib3": { "version": "1.22" }, "using_pyopenssl": true } ```
{ "avatar_url": "https://avatars.githubusercontent.com/u/5271761?v=4", "events_url": "https://api.github.com/users/nateprewitt/events{/privacy}", "followers_url": "https://api.github.com/users/nateprewitt/followers", "following_url": "https://api.github.com/users/nateprewitt/following{/other_user}", "gists_url": "https://api.github.com/users/nateprewitt/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/nateprewitt", "id": 5271761, "login": "nateprewitt", "node_id": "MDQ6VXNlcjUyNzE3NjE=", "organizations_url": "https://api.github.com/users/nateprewitt/orgs", "received_events_url": "https://api.github.com/users/nateprewitt/received_events", "repos_url": "https://api.github.com/users/nateprewitt/repos", "site_admin": false, "starred_url": "https://api.github.com/users/nateprewitt/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/nateprewitt/subscriptions", "type": "User", "url": "https://api.github.com/users/nateprewitt", "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/4659/reactions" }
https://api.github.com/repos/psf/requests/issues/4659/timeline
null
completed
null
null
false
[ "Hey @dwightgunning, thanks for bringing this to our attention! I think the easiest option is to pin a max version for Python 2.6 specifically in our `security` section of setup.py. Similar to how we handle `win_inet_pton`.\r\n\r\nOne thing we may want to consider is the implications of further supporting 2.6 as a ...
https://api.github.com/repos/psf/requests/issues/4658
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4658/labels{/name}
https://api.github.com/repos/psf/requests/issues/4658/comments
https://api.github.com/repos/psf/requests/issues/4658/events
https://github.com/psf/requests/issues/4658
325,737,344
MDU6SXNzdWUzMjU3MzczNDQ=
4,658
KeyError with Instabot on python 2.7.15 for mac
{ "avatar_url": "https://avatars.githubusercontent.com/u/39561770?v=4", "events_url": "https://api.github.com/users/hamadberlin/events{/privacy}", "followers_url": "https://api.github.com/users/hamadberlin/followers", "following_url": "https://api.github.com/users/hamadberlin/following{/other_user}", "gists_url": "https://api.github.com/users/hamadberlin/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/hamadberlin", "id": 39561770, "login": "hamadberlin", "node_id": "MDQ6VXNlcjM5NTYxNzcw", "organizations_url": "https://api.github.com/users/hamadberlin/orgs", "received_events_url": "https://api.github.com/users/hamadberlin/received_events", "repos_url": "https://api.github.com/users/hamadberlin/repos", "site_admin": false, "starred_url": "https://api.github.com/users/hamadberlin/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/hamadberlin/subscriptions", "type": "User", "url": "https://api.github.com/users/hamadberlin", "user_view_type": "public" }
[]
closed
true
null
[]
null
1
2018-05-23T14:39:47Z
2021-09-08T02:09:54Z
2018-05-23T22:35:47Z
NONE
resolved
hey guys, i'm really trying to fix that problem and did research on internet but im not able to finde the selution. can someone help me? *please *freshman MacBook-Air:instabot.py-master2 XXX$ python example.py 23.05.2018_16:30 Instabot v1.2.0 started at 23.05.2018 16:30: 23.05.2018_16:30 Trying to login as XXXX... Traceback (most recent call last): File "example.py", line 52, in <module> unfollow_whitelist=['example_user_1', 'example_user_2']) File "/Users/XXX/Desktop/instabot.py-master2/src/instabot.py", line 232, in __init__ self.login() File "/Users/XXX/Desktop/instabot.py-master2/src/instabot.py", line 283, in login self.s.headers.update({'X-CSRFToken': r.cookies['csrftoken']}) File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/requests/cookies.py", line 329, in __getitem__ return self._find_no_duplicates(name) File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/requests/cookies.py", line 400, in _find_no_duplicates raise KeyError('name=%r, domain=%r, path=%r' % (name, domain, path)) KeyError: "name='csrftoken', domain=None, path=None"
{ "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/4658/reactions" }
https://api.github.com/repos/psf/requests/issues/4658/timeline
null
completed
null
null
false
[ "solution here: https://github.com/instabot-py/instabot.py/issues/1287\r\n\r\nCLOSED" ]
https://api.github.com/repos/psf/requests/issues/4657
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4657/labels{/name}
https://api.github.com/repos/psf/requests/issues/4657/comments
https://api.github.com/repos/psf/requests/issues/4657/events
https://github.com/psf/requests/issues/4657
325,447,919
MDU6SXNzdWUzMjU0NDc5MTk=
4,657
Certificate verify failed SSLError
{ "avatar_url": "https://avatars.githubusercontent.com/u/14719521?v=4", "events_url": "https://api.github.com/users/pmesgari/events{/privacy}", "followers_url": "https://api.github.com/users/pmesgari/followers", "following_url": "https://api.github.com/users/pmesgari/following{/other_user}", "gists_url": "https://api.github.com/users/pmesgari/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/pmesgari", "id": 14719521, "login": "pmesgari", "node_id": "MDQ6VXNlcjE0NzE5NTIx", "organizations_url": "https://api.github.com/users/pmesgari/orgs", "received_events_url": "https://api.github.com/users/pmesgari/received_events", "repos_url": "https://api.github.com/users/pmesgari/repos", "site_admin": false, "starred_url": "https://api.github.com/users/pmesgari/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/pmesgari/subscriptions", "type": "User", "url": "https://api.github.com/users/pmesgari", "user_view_type": "public" }
[]
closed
true
null
[]
null
10
2018-05-22T20:19:44Z
2021-09-08T02:09:54Z
2018-05-23T22:47:24Z
NONE
resolved
Calling a google calendar API results in `certificate verify failure`. ## Expected Result A successful API response, since the API endpoint is running fine ## Actual Result ``` C:\Workspace\Techroom\venvs\lazyhour\lazyhour\Scripts\python.exe C:/Workspace/Techroom/lazyhour-server/main.py * Serving Flask app "main" (lazy loading) * Environment: development * Debug mode: on * Restarting with stat * Debugger is active! * Debugger PIN: 279-826-945 * Running on http://localhost:5000/ (Press CTRL+C to quit) C:\Workspace\Techroom\lazyhour-server\util\service_account.json 127.0.0.1 - - [22/May/2018 15:22:56] "GET /calendar/list HTTP/1.1" 500 - Traceback (most recent call last): File "C:\Workspace\Techroom\venvs\lazyhour\lazyhour\lib\site-packages\flask\app.py", line 2309, in __call__ return self.wsgi_app(environ, start_response) File "C:\Workspace\Techroom\venvs\lazyhour\lazyhour\lib\site-packages\flask\app.py", line 2295, in wsgi_app response = self.handle_exception(e) File "C:\Workspace\Techroom\venvs\lazyhour\lazyhour\lib\site-packages\flask_cors\extension.py", line 161, in wrapped_function return cors_after_request(app.make_response(f(*args, **kwargs))) File "C:\Workspace\Techroom\venvs\lazyhour\lazyhour\lib\site-packages\flask_restful\__init__.py", line 273, in error_router return original_handler(e) File "C:\Workspace\Techroom\venvs\lazyhour\lazyhour\lib\site-packages\flask\app.py", line 1741, in handle_exception reraise(exc_type, exc_value, tb) File "C:\Workspace\Techroom\venvs\lazyhour\lazyhour\lib\site-packages\flask\_compat.py", line 34, in reraise raise value.with_traceback(tb) File "C:\Workspace\Techroom\venvs\lazyhour\lazyhour\lib\site-packages\flask\app.py", line 2292, in wsgi_app response = self.full_dispatch_request() File "C:\Workspace\Techroom\venvs\lazyhour\lazyhour\lib\site-packages\flask\app.py", line 1815, in full_dispatch_request rv = self.handle_user_exception(e) File "C:\Workspace\Techroom\venvs\lazyhour\lazyhour\lib\site-packages\flask_cors\extension.py", line 161, in wrapped_function return cors_after_request(app.make_response(f(*args, **kwargs))) File "C:\Workspace\Techroom\venvs\lazyhour\lazyhour\lib\site-packages\flask_restful\__init__.py", line 273, in error_router return original_handler(e) File "C:\Workspace\Techroom\venvs\lazyhour\lazyhour\lib\site-packages\flask\app.py", line 1718, in handle_user_exception reraise(exc_type, exc_value, tb) File "C:\Workspace\Techroom\venvs\lazyhour\lazyhour\lib\site-packages\flask\_compat.py", line 34, in reraise raise value.with_traceback(tb) File "C:\Workspace\Techroom\venvs\lazyhour\lazyhour\lib\site-packages\flask\app.py", line 1813, in full_dispatch_request rv = self.dispatch_request() File "C:\Workspace\Techroom\venvs\lazyhour\lazyhour\lib\site-packages\flask\app.py", line 1799, in dispatch_request return self.view_functions[rule.endpoint](**req.view_args) File "C:\Workspace\Techroom\venvs\lazyhour\lazyhour\lib\site-packages\flask_restful\__init__.py", line 480, in wrapper resp = resource(*args, **kwargs) File "C:\Workspace\Techroom\venvs\lazyhour\lazyhour\lib\site-packages\flask\views.py", line 88, in view return self.dispatch_request(*args, **kwargs) File "C:\Workspace\Techroom\venvs\lazyhour\lazyhour\lib\site-packages\flask_restful\__init__.py", line 595, in dispatch_request resp = meth(*args, **kwargs) File "C:\Workspace\Techroom\venvs\lazyhour\lazyhour\lib\site-packages\flask_httpauth.py", line 93, in decorated return f(*args, **kwargs) File "C:\Workspace\Techroom\lazyhour-server\main.py", line 45, in get return calendar_service.get_calendar_list() File "C:\Workspace\Techroom\lazyhour-server\util\calendar_service.py", line 25, in get_calendar_list response = self.authed_session.get(self.service_base_url) File "C:\Workspace\Techroom\venvs\lazyhour\lazyhour\lib\site-packages\requests\sessions.py", line 521, in get return self.request('GET', url, **kwargs) File "C:\Workspace\Techroom\venvs\lazyhour\lazyhour\lib\site-packages\google\auth\transport\requests.py", line 198, in request self._auth_request, method, url, request_headers) File "C:\Workspace\Techroom\venvs\lazyhour\lazyhour\lib\site-packages\google\auth\credentials.py", line 121, in before_request self.refresh(request) File "C:\Workspace\Techroom\venvs\lazyhour\lazyhour\lib\site-packages\google\oauth2\service_account.py", line 322, in refresh request, self._token_uri, assertion) File "C:\Workspace\Techroom\venvs\lazyhour\lazyhour\lib\site-packages\google\oauth2\_client.py", line 145, in jwt_grant response_data = _token_endpoint_request(request, token_uri, body) File "C:\Workspace\Techroom\venvs\lazyhour\lazyhour\lib\site-packages\google\oauth2\_client.py", line 106, in _token_endpoint_request method='POST', url=token_uri, headers=headers, body=body) File "C:\Workspace\Techroom\venvs\lazyhour\lazyhour\lib\site-packages\google\auth\transport\requests.py", line 124, in __call__ six.raise_from(new_exc, caught_exc) File "<string>", line 3, in raise_from # Permission is hereby granted, free of charge, to any person obtaining a copy google.auth.exceptions.TransportError: HTTPSConnectionPool(host='accounts.google.com', port=443): Max retries exceeded with url: /o/oauth2/token (Caused by SSLError(SSLError(1, '[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed (_ssl.c:749)'),)) ``` ## Reproduction Steps ``` from .auth_service import get_credentials from google.auth.transport.requests import AuthorizedSession import json # Calendar service class CalendarService: def __init__(self, calendar_id=''): self.credentials = get_credentials() self.authed_session = AuthorizedSession(self.credentials) self.service_base_url = 'https://www.googleapis.com/calendar/v3/users/me/calendarList' self.calendar_id = calendar_id def get_service_url(self): return('{base_url}/{calendar_id}'.format( base_url=self.service_base_url, calendar_id=self.calendar_id)) def get_calendar(self): response = self.authed_session.get(self.get_service_url()) calendar = response.json() return calendar def get_calendar_list(self): response = self.authed_session.get(self.service_base_url) calendar_list = response.json() return calendar_list ``` ## System Information The output of pip freeze is: ``` aniso8601==3.0.0 cachetools==2.1.0 certifi==2018.4.16 chardet==3.0.4 click==6.7 Flask==1.0.2 Flask-Cors==3.0.4 Flask-HTTPAuth==3.2.3 Flask-RESTful==0.3.6 google-auth==1.4.1 idna==2.6 itsdangerous==0.24 Jinja2==2.10 MarkupSafe==1.0 pyasn1==0.4.2 pyasn1-modules==0.2.1 pytz==2018.4 requests==2.18.4 rsa==3.4.2 six==1.11.0 urllib3==1.22 Werkzeug==0.14.1 ``` Python 3.6 Windows 10 This command is only available on Requests v2.16.4 and greater. Otherwise, please provide some basic information about your system (Python version, operating system, &c).
{ "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/4657/reactions" }
https://api.github.com/repos/psf/requests/issues/4657/timeline
null
completed
null
null
false
[ "I changed the default value for `verify` argument in `sessions.py` file. and the error is gone Here is the method that defines the `request`:\r\n```\r\n def request(self, method, url,\r\n params=None, data=None, headers=None, cookies=None, files=None,\r\n auth=None, timeout=None, allow_red...
https://api.github.com/repos/psf/requests/issues/4656
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4656/labels{/name}
https://api.github.com/repos/psf/requests/issues/4656/comments
https://api.github.com/repos/psf/requests/issues/4656/events
https://github.com/psf/requests/issues/4656
325,395,151
MDU6SXNzdWUzMjUzOTUxNTE=
4,656
Requests to groupon 403 response
{ "avatar_url": "https://avatars.githubusercontent.com/u/5991118?v=4", "events_url": "https://api.github.com/users/GinVlad/events{/privacy}", "followers_url": "https://api.github.com/users/GinVlad/followers", "following_url": "https://api.github.com/users/GinVlad/following{/other_user}", "gists_url": "https://api.github.com/users/GinVlad/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/GinVlad", "id": 5991118, "login": "GinVlad", "node_id": "MDQ6VXNlcjU5OTExMTg=", "organizations_url": "https://api.github.com/users/GinVlad/orgs", "received_events_url": "https://api.github.com/users/GinVlad/received_events", "repos_url": "https://api.github.com/users/GinVlad/repos", "site_admin": false, "starred_url": "https://api.github.com/users/GinVlad/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/GinVlad/subscriptions", "type": "User", "url": "https://api.github.com/users/GinVlad", "user_view_type": "public" }
[]
closed
true
null
[]
null
1
2018-05-22T17:36:16Z
2021-09-08T02:09:55Z
2018-05-22T17:39:32Z
NONE
resolved
`import requests as re headers = { 'User-Agent': 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:60.0) Gecko/20100101 Firefox/60.0', 'Accept': 'text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8', 'Accept-Language': 'en-US,en;q=0.5', 'Accept-Encoding': 'gzip, deflate, br', 'Connection': 'keep-alive', } r = re.Session() print r.get('https://www.groupon.com/signup?ref=https%3A%2F%2Fwww.groupon.com%2Fmyaccount', headers=headers)` I receive 403 response. How to pass it
{ "avatar_url": "https://avatars.githubusercontent.com/u/5271761?v=4", "events_url": "https://api.github.com/users/nateprewitt/events{/privacy}", "followers_url": "https://api.github.com/users/nateprewitt/followers", "following_url": "https://api.github.com/users/nateprewitt/following{/other_user}", "gists_url": "https://api.github.com/users/nateprewitt/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/nateprewitt", "id": 5271761, "login": "nateprewitt", "node_id": "MDQ6VXNlcjUyNzE3NjE=", "organizations_url": "https://api.github.com/users/nateprewitt/orgs", "received_events_url": "https://api.github.com/users/nateprewitt/received_events", "repos_url": "https://api.github.com/users/nateprewitt/repos", "site_admin": false, "starred_url": "https://api.github.com/users/nateprewitt/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/nateprewitt/subscriptions", "type": "User", "url": "https://api.github.com/users/nateprewitt", "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/4656/reactions" }
https://api.github.com/repos/psf/requests/issues/4656/timeline
null
completed
null
null
false
[ "Hi @GinVlad, this looks like a request for help. As per our issue tracker guidelines, requests for help should be directed to [StackOverflow](https://stackoverflow.com). You can use the `python-requests` tag to better surface the question. Thanks!" ]
https://api.github.com/repos/psf/requests/issues/4655
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4655/labels{/name}
https://api.github.com/repos/psf/requests/issues/4655/comments
https://api.github.com/repos/psf/requests/issues/4655/events
https://github.com/psf/requests/issues/4655
325,329,832
MDU6SXNzdWUzMjUzMjk4MzI=
4,655
Connection Reset by Peer
{ "avatar_url": "https://avatars.githubusercontent.com/u/2609402?v=4", "events_url": "https://api.github.com/users/etothepii/events{/privacy}", "followers_url": "https://api.github.com/users/etothepii/followers", "following_url": "https://api.github.com/users/etothepii/following{/other_user}", "gists_url": "https://api.github.com/users/etothepii/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/etothepii", "id": 2609402, "login": "etothepii", "node_id": "MDQ6VXNlcjI2MDk0MDI=", "organizations_url": "https://api.github.com/users/etothepii/orgs", "received_events_url": "https://api.github.com/users/etothepii/received_events", "repos_url": "https://api.github.com/users/etothepii/repos", "site_admin": false, "starred_url": "https://api.github.com/users/etothepii/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/etothepii/subscriptions", "type": "User", "url": "https://api.github.com/users/etothepii", "user_view_type": "public" }
[ { "color": "f7c6c7", "default": false, "description": null, "id": 167537670, "name": "Propose Close", "node_id": "MDU6TGFiZWwxNjc1Mzc2NzA=", "url": "https://api.github.com/repos/psf/requests/labels/Propose%20Close" } ]
closed
true
null
[]
null
10
2018-05-22T14:49:54Z
2021-09-08T01:21:23Z
2018-06-12T15:24:11Z
NONE
resolved
## Summary While making an HTTPS GET request to fema.gov I get a Connection Reset Error, this is confirmed on multiple machines not to happen in Python 2 but does happen on Python 3, both are using the same version of requests. Very bizarrely (in this case) the failure occurs when trying to read the 3704 byte. (discovered by using lower level functions). Below is the URL: `https://hazards.fema.gov/gis/nfhl/rest/services/public/NFHL/MapServer/16/query?where=&text=&objectIds=&time=&geometry=-9240000%2C4400000%2C-9230000%2C4410000&geometryType=esriGeometryEnvelope&inSR=102100&spatialRel=esriSpatialRelIntersects&relationParam=&outFields=&returnGeometry=true&maxAllowableOffset=&geometryPrecision=&outSR=&returnIdsOnly=false&returnCountOnly=false&orderByFields=&groupByFieldsForStatistics=&outStatistics=&returnZ=false&returnM=false&gdbVersion=&returnDistinctValues=false&returnTrueCurves=false&resultOffset=&resultRecordCount=&f=pjson` Things I have tried: * User-Agent strings * Disabling verify * Using machines with different IP addresses * Matching all libraries except openssl_version to the working Python 2.7 environment ## Reproduction Steps ``` python import requests url ="https://hazards.fema.gov/gis/nfhl/rest/services/public/NFHL/MapServer/16/query?where=&text=&objectIds=&time=&geometry=-9240000%2C4400000%2C-9230000%2C4410000&geometryType=esriGeometryEnvelope&inSR=102100&spatialRel=esriSpatialRelIntersects&relationParam=&outFields=&returnGeometry=true&maxAllowableOffset=&geometryPrecision=&outSR=&returnIdsOnly=false&returnCountOnly=false&orderByFields=&groupByFieldsForStatistics=&outStatistics=&returnZ=false&returnM=false&gdbVersion=&returnDistinctValues=false&returnTrueCurves=false&resultOffset=&resultRecordCount=&f=pjson" response=requests.get(url) ``` ## System Information ``` $ python -m requests.help { "chardet": { "version": "3.0.4" }, "cryptography": { "version": "2.2.2" }, "idna": { "version": "2.6" }, "implementation": { "name": "CPython", "version": "3.6.4" }, "platform": { "release": "4.13.0-21-generic", "system": "Linux" }, "pyOpenSSL": { "openssl_version": "1010008f", "version": "18.0.0" }, "requests": { "version": "2.18.4" }, "system_ssl": { "version": "1010006f" }, "urllib3": { "version": "1.22" }, "using_pyopenssl": true } ``` As noted above the request works fine in Python 2.7 ``` $ python -m requests.help { "chardet": { "version": "3.0.4" }, "cryptography": { "version": "1.9" }, "implementation": { "name": "CPython", "version": "2.7.14" }, "platform": { "release": "4.13.0-21-generic", "system": "Linux" }, "pyOpenSSL": { "openssl_version": "1000207f", "version": "16.2.0" }, "requests": { "version": "2.18.1" }, "system_ssl": { "version": "1000207f" }, "urllib3": { "version": "1.21.1" }, "using_pyopenssl": true } ``` I have tried to get the versions of my Python 3 to match but even doing this the request still fails in Python 3. ``` $ python -m requests.help { "chardet": { "version": "3.0.4" }, "cryptography": { "version": "1.9" }, "implementation": { "name": "CPython", "version": "3.6.4" }, "platform": { "release": "4.13.0-21-generic", "system": "Linux" }, "pyOpenSSL": { "openssl_version": "1010006f", "version": "16.2.0" }, "requests": { "version": "2.18.1" }, "system_ssl": { "version": "1010006f" }, "urllib3": { "version": "1.21.1" }, "using_pyopenssl": true } ```
{ "avatar_url": "https://avatars.githubusercontent.com/u/5271761?v=4", "events_url": "https://api.github.com/users/nateprewitt/events{/privacy}", "followers_url": "https://api.github.com/users/nateprewitt/followers", "following_url": "https://api.github.com/users/nateprewitt/following{/other_user}", "gists_url": "https://api.github.com/users/nateprewitt/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/nateprewitt", "id": 5271761, "login": "nateprewitt", "node_id": "MDQ6VXNlcjUyNzE3NjE=", "organizations_url": "https://api.github.com/users/nateprewitt/orgs", "received_events_url": "https://api.github.com/users/nateprewitt/received_events", "repos_url": "https://api.github.com/users/nateprewitt/repos", "site_admin": false, "starred_url": "https://api.github.com/users/nateprewitt/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/nateprewitt/subscriptions", "type": "User", "url": "https://api.github.com/users/nateprewitt", "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/4655/reactions" }
https://api.github.com/repos/psf/requests/issues/4655/timeline
null
completed
null
null
false
[ "Have you ever tried that using a browser to get the response of the API?\r\nIt seems that the problem was caused by the remote server error.", "Works in a browser, works in CURL, works in python 2.7. Works in Python 3.6 using this awful, awful code\r\n\r\n``` \r\ncmd = \"curl -o {cache_file} {url}\".forma...
https://api.github.com/repos/psf/requests/issues/4654
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4654/labels{/name}
https://api.github.com/repos/psf/requests/issues/4654/comments
https://api.github.com/repos/psf/requests/issues/4654/events
https://github.com/psf/requests/issues/4654
325,254,950
MDU6SXNzdWUzMjUyNTQ5NTA=
4,654
Windows - SSL Error (certificate verify failed) with bundle
{ "avatar_url": "https://avatars.githubusercontent.com/u/30751516?v=4", "events_url": "https://api.github.com/users/danieldaeschle/events{/privacy}", "followers_url": "https://api.github.com/users/danieldaeschle/followers", "following_url": "https://api.github.com/users/danieldaeschle/following{/other_user}", "gists_url": "https://api.github.com/users/danieldaeschle/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/danieldaeschle", "id": 30751516, "login": "danieldaeschle", "node_id": "MDQ6VXNlcjMwNzUxNTE2", "organizations_url": "https://api.github.com/users/danieldaeschle/orgs", "received_events_url": "https://api.github.com/users/danieldaeschle/received_events", "repos_url": "https://api.github.com/users/danieldaeschle/repos", "site_admin": false, "starred_url": "https://api.github.com/users/danieldaeschle/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/danieldaeschle/subscriptions", "type": "User", "url": "https://api.github.com/users/danieldaeschle", "user_view_type": "public" }
[]
closed
true
null
[]
null
1
2018-05-22T11:37:16Z
2021-09-08T02:09:55Z
2018-05-22T13:29:44Z
NONE
resolved
**Note** - Under WSL it works, but not under Windows When i use (this also doesn't work on WSL) ``` requests.get('https://domain', verify='/path/to/my/bundle') ``` I get: ``` >>> requests.get('https://google.de', verify='C:/Users/i01002704/Documents/SSL-Certificate_Chain_PEM/k') Traceback (most recent call last): File "C:\Users\i01002704\AppData\Local\Programs\Python\Python36-32\lib\site-packages\urllib3\contrib\pyopenssl.py", line 441, in wrap_socket cnx.do_handshake() File "C:\Users\i01002704\AppData\Local\Programs\Python\Python36-32\lib\site-packages\OpenSSL\SSL.py", line 1806, in do_handshake self._raise_ssl_error(self._ssl, result) File "C:\Users\i01002704\AppData\Local\Programs\Python\Python36-32\lib\site-packages\OpenSSL\SSL.py", line 1546, in _raise_ssl_error _raise_current_error() File "C:\Users\i01002704\AppData\Local\Programs\Python\Python36-32\lib\site-packages\OpenSSL\_util.py", line 54, in exception_from_error_queue raise exception_type(errors) OpenSSL.SSL.Error: [('SSL routines', 'tls_process_server_certificate', 'certificate verify failed')] During handling of the above exception, another exception occurred: Traceback (most recent call last): File "C:\Users\i01002704\AppData\Local\Programs\Python\Python36-32\lib\site-packages\urllib3\connectionpool.py", line 595, in urlopen self._prepare_proxy(conn) File "C:\Users\i01002704\AppData\Local\Programs\Python\Python36-32\lib\site-packages\urllib3\connectionpool.py", line 816, in _prepare_proxy conn.connect() File "C:\Users\i01002704\AppData\Local\Programs\Python\Python36-32\lib\site-packages\urllib3\connection.py", line 326, in connect ssl_context=context) File "C:\Users\i01002704\AppData\Local\Programs\Python\Python36-32\lib\site-packages\urllib3\util\ssl_.py", line 329, in ssl_wrap_socket return context.wrap_socket(sock, server_hostname=server_hostname) File "C:\Users\i01002704\AppData\Local\Programs\Python\Python36-32\lib\site-packages\urllib3\contrib\pyopenssl.py", line 448, in wrap_socket raise ssl.SSLError('bad handshake: %r' % e) ssl.SSLError: ("bad handshake: Error([('SSL routines', 'tls_process_server_certificate', 'certificate verify failed')],)",) During handling of the above exception, another exception occurred: Traceback (most recent call last): File "C:\Users\i01002704\AppData\Local\Programs\Python\Python36-32\lib\site-packages\requests\adapters.py", line 440, in send timeout=timeout File "C:\Users\i01002704\AppData\Local\Programs\Python\Python36-32\lib\site-packages\urllib3\connectionpool.py", line 639, in urlopen _stacktrace=sys.exc_info()[2]) File "C:\Users\i01002704\AppData\Local\Programs\Python\Python36-32\lib\site-packages\urllib3\util\retry.py", line 388, in increment raise MaxRetryError(_pool, url, error or ResponseError(cause)) urllib3.exceptions.MaxRetryError: HTTPSConnectionPool(host='google.de', port=443): Max retries exceeded with url: / (Caused by SSLError(SSLError("bad handshake: Error([('SSL routines', 'tls_process_server_certificate', 'certificate verify failed')],)",),)) During handling of the above exception, another exception occurred: Traceback (most recent call last): File "<stdin>", line 1, in <module> File "C:\Users\i01002704\AppData\Local\Programs\Python\Python36-32\lib\site-packages\requests\api.py", line 72, in get return request('get', url, params=params, **kwargs) File "C:\Users\i01002704\AppData\Local\Programs\Python\Python36-32\lib\site-packages\requests\api.py", line 58, in request return session.request(method=method, url=url, **kwargs) File "C:\Users\i01002704\AppData\Local\Programs\Python\Python36-32\lib\site-packages\requests\sessions.py", line 508, in request resp = self.send(prep, **send_kwargs) File "C:\Users\i01002704\AppData\Local\Programs\Python\Python36-32\lib\site-packages\requests\sessions.py", line 618, in send r = adapter.send(request, **kwargs) File "C:\Users\i01002704\AppData\Local\Programs\Python\Python36-32\lib\site-packages\requests\adapters.py", line 506, in send raise SSLError(e, request=request) requests.exceptions.SSLError: HTTPSConnectionPool(host='google.de', port=443): Max retries exceeded with url: / (Caused by SSLError(SSLError("bad handshake: Error([('SSL routines', 'tls_process_server_certificate', 'certificate verify failed')],)",),)) ``` Another try was using path to directory where certificates are stored instead of bundle (this works on WSL) /path/to/certs/ which looks like: ![image](https://user-images.githubusercontent.com/30751516/40360073-21d5853a-5dc5-11e8-910b-ee83343cd8a5.png) I created the bundle with: ``` cat File1 File2 File3 >> bundle.pem ``` I always get this error. Why? I hope you can help me.
{ "avatar_url": "https://avatars.githubusercontent.com/u/30751516?v=4", "events_url": "https://api.github.com/users/danieldaeschle/events{/privacy}", "followers_url": "https://api.github.com/users/danieldaeschle/followers", "following_url": "https://api.github.com/users/danieldaeschle/following{/other_user}", "gists_url": "https://api.github.com/users/danieldaeschle/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/danieldaeschle", "id": 30751516, "login": "danieldaeschle", "node_id": "MDQ6VXNlcjMwNzUxNTE2", "organizations_url": "https://api.github.com/users/danieldaeschle/orgs", "received_events_url": "https://api.github.com/users/danieldaeschle/received_events", "repos_url": "https://api.github.com/users/danieldaeschle/repos", "site_admin": false, "starred_url": "https://api.github.com/users/danieldaeschle/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/danieldaeschle/subscriptions", "type": "User", "url": "https://api.github.com/users/danieldaeschle", "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/4654/reactions" }
https://api.github.com/repos/psf/requests/issues/4654/timeline
null
completed
null
null
false
[ "i can make request without cert bundle. nvm. it works now behind proxy....." ]
https://api.github.com/repos/psf/requests/issues/4653
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4653/labels{/name}
https://api.github.com/repos/psf/requests/issues/4653/comments
https://api.github.com/repos/psf/requests/issues/4653/events
https://github.com/psf/requests/issues/4653
324,825,494
MDU6SXNzdWUzMjQ4MjU0OTQ=
4,653
Content-Length is not correct while sending post request
{ "avatar_url": "https://avatars.githubusercontent.com/u/2647332?v=4", "events_url": "https://api.github.com/users/zhanglue/events{/privacy}", "followers_url": "https://api.github.com/users/zhanglue/followers", "following_url": "https://api.github.com/users/zhanglue/following{/other_user}", "gists_url": "https://api.github.com/users/zhanglue/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/zhanglue", "id": 2647332, "login": "zhanglue", "node_id": "MDQ6VXNlcjI2NDczMzI=", "organizations_url": "https://api.github.com/users/zhanglue/orgs", "received_events_url": "https://api.github.com/users/zhanglue/received_events", "repos_url": "https://api.github.com/users/zhanglue/repos", "site_admin": false, "starred_url": "https://api.github.com/users/zhanglue/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/zhanglue/subscriptions", "type": "User", "url": "https://api.github.com/users/zhanglue", "user_view_type": "public" }
[]
closed
true
null
[]
null
3
2018-05-21T08:08:34Z
2021-09-08T02:09:55Z
2018-05-21T12:34:54Z
NONE
resolved
Hello~ I find the "REAL" CL, by 'tcpdump' the server host, is not according to the 'body data'. The type of data is serialized protobuf string, and I have specified it in headers as "'Content-type': 'application/x-protobuf'". Known point: 1. Content-Length(ab. CL) will be replaced even if it is specified in "headers". 2. CL can be set arbitrarily by Session. After times of failed trying, I send the same PB string by 'httplib' instead, which works well. Comparing the data dumped by tcpdumps, it seems like that data server received has been modified by 'requests' , while 'httplib' did not, even if the string dumped is not human readable. So I found I did it in a wrong way, the point is how to send bytes string by 'requests' but how to set CL. Right?
{ "avatar_url": "https://avatars.githubusercontent.com/u/2647332?v=4", "events_url": "https://api.github.com/users/zhanglue/events{/privacy}", "followers_url": "https://api.github.com/users/zhanglue/followers", "following_url": "https://api.github.com/users/zhanglue/following{/other_user}", "gists_url": "https://api.github.com/users/zhanglue/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/zhanglue", "id": 2647332, "login": "zhanglue", "node_id": "MDQ6VXNlcjI2NDczMzI=", "organizations_url": "https://api.github.com/users/zhanglue/orgs", "received_events_url": "https://api.github.com/users/zhanglue/received_events", "repos_url": "https://api.github.com/users/zhanglue/repos", "site_admin": false, "starred_url": "https://api.github.com/users/zhanglue/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/zhanglue/subscriptions", "type": "User", "url": "https://api.github.com/users/zhanglue", "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/4653/reactions" }
https://api.github.com/repos/psf/requests/issues/4653/timeline
null
completed
null
null
false
[ "I tired another way to send data in post: \r\n```\r\n...\r\nfiles = {\r\n 'field_A': (\r\n 'fileName_A', \r\n open('./pbFile.data', 'rb'),\r\n 'application/x-protobuf', \r\n )\r\n }\r\nresponse = requests.post(url, headers = headers, files=files)\r\n```\r\n...
https://api.github.com/repos/psf/requests/issues/4652
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4652/labels{/name}
https://api.github.com/repos/psf/requests/issues/4652/comments
https://api.github.com/repos/psf/requests/issues/4652/events
https://github.com/psf/requests/issues/4652
324,739,070
MDU6SXNzdWUzMjQ3MzkwNzA=
4,652
Non-ASCII filename uploads don't comply with RFC 7578
{ "avatar_url": "https://avatars.githubusercontent.com/u/160562?v=4", "events_url": "https://api.github.com/users/bdarnell/events{/privacy}", "followers_url": "https://api.github.com/users/bdarnell/followers", "following_url": "https://api.github.com/users/bdarnell/following{/other_user}", "gists_url": "https://api.github.com/users/bdarnell/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/bdarnell", "id": 160562, "login": "bdarnell", "node_id": "MDQ6VXNlcjE2MDU2Mg==", "organizations_url": "https://api.github.com/users/bdarnell/orgs", "received_events_url": "https://api.github.com/users/bdarnell/received_events", "repos_url": "https://api.github.com/users/bdarnell/repos", "site_admin": false, "starred_url": "https://api.github.com/users/bdarnell/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/bdarnell/subscriptions", "type": "User", "url": "https://api.github.com/users/bdarnell", "user_view_type": "public" }
[]
closed
true
null
[]
null
3
2018-05-20T20:20:10Z
2021-09-04T00:06:17Z
2018-05-21T15:33:54Z
NONE
resolved
When uploading a file with a non-ascii filename, that filename is encoded according to the method of RFC 5987 >>> requests.post('http://ya.ru', files={'file': (u'файл', '123')}).request.body b'--5cb06bfe9bc549e09dc080ed257f9555\r\nContent-Disposition: form-data; name="file"; filename*=utf-8\'\'%D1%84%D0%B0%D0%B9%D0%BB\r\n\r\n123\r\n--5cb06bfe9bc549e09dc080ed257f9555--\r\n' However, RFC 7578 (the current version of the `multipart/form-data` spec) explicitly prohibits the use of this encoding for the `filename` field of a `Content-Disposition` header (in a `multipart/form-data` body): > NOTE: The encoding method described in [RFC5987], which would add a > "filename*" parameter to the Content-Disposition header field, MUST > NOT be used. it's unclear to me why RFC 7578 made this decision, especially when its predecessor RFC 2388 said that RFC 2231 (which defines the encoding used in RFC 5987) "might" be used. This may be an example of an RFC that is at odds with practical usage. However, since it is quite explicit on this point we should consider whether following the new RFC would be better than the current implementation. Note that to add to the confusion, `Content-Disposition` when used *as an HTTP header* instead of in `multipart/form-data` is defined by RFC 6266, which specifies the use of RFC 5987. A lot of the references used to argue in favor of the RFC 5987 behavior in #2117 were actually about the HTTP header, not the form-data header (such as [this SO question](https://stackoverflow.com/questions/7967079/special-characters-in-content-disposition-filename)). For context, I'm looking at this as a result of a [PR](https://github.com/tornadoweb/tornado/pull/1898) to add RFC 5987 support to Tornado's multipart/form-data parser. We don't currently decode percent-encoded filenames according to RFC 7578 either, so something has to change on our side either way, but I thought I'd raise this issue since it's not clear that `requests` is handling this the right way. ## Expected Result A `Content-Disposition` header containing `filename=%D1%84%D0%B0%D0%B9%D0%BB` ## Actual Result A `Content-Disposition` header containing a `filename*=` header instead. ## Reproduction Steps ```python import requests print(requests.post('http://ya.ru', files={'file': (u'файл', '123')}).request.body) ``` ## System Information $ python -m requests.help ``` $ /tmp/reqs/bin/python -m requests.help { "chardet": { "version": "3.0.4" }, "cryptography": { "version": "" }, "idna": { "version": "2.6" }, "implementation": { "name": "CPython", "version": "3.6.5" }, "platform": { "release": "17.5.0", "system": "Darwin" }, "pyOpenSSL": { "openssl_version": "", "version": null }, "requests": { "version": "2.18.4" }, "system_ssl": { "version": "100020ff" }, "urllib3": { "version": "1.22" }, "using_pyopenssl": false } ```
{ "avatar_url": "https://avatars.githubusercontent.com/u/160562?v=4", "events_url": "https://api.github.com/users/bdarnell/events{/privacy}", "followers_url": "https://api.github.com/users/bdarnell/followers", "following_url": "https://api.github.com/users/bdarnell/following{/other_user}", "gists_url": "https://api.github.com/users/bdarnell/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/bdarnell", "id": 160562, "login": "bdarnell", "node_id": "MDQ6VXNlcjE2MDU2Mg==", "organizations_url": "https://api.github.com/users/bdarnell/orgs", "received_events_url": "https://api.github.com/users/bdarnell/received_events", "repos_url": "https://api.github.com/users/bdarnell/repos", "site_admin": false, "starred_url": "https://api.github.com/users/bdarnell/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/bdarnell/subscriptions", "type": "User", "url": "https://api.github.com/users/bdarnell", "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/4652/reactions" }
https://api.github.com/repos/psf/requests/issues/4652/timeline
null
completed
null
null
false
[ "Thanks for brining this to our attention! This belongs in urllib3/urllib3 however because that is the project that actually handles this encoding logic.", "OK. Looks like there's already an issue for this over there: https://github.com/urllib3/urllib3/issues/303", "(FYI, underlying urllib3 issue was [fixed](ht...
https://api.github.com/repos/psf/requests/issues/4651
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4651/labels{/name}
https://api.github.com/repos/psf/requests/issues/4651/comments
https://api.github.com/repos/psf/requests/issues/4651/events
https://github.com/psf/requests/issues/4651
324,073,255
MDU6SXNzdWUzMjQwNzMyNTU=
4,651
Could not fetch URL https://pypi.python.org/simple/spacy/: There was a problem confirming the ssl certificate: [Errno 1] _ssl.c:499: error:1407742E:SSL routines:SSL23_GET_SERVER_HELLO:tlsv1 alert protocol version - skipping
{ "avatar_url": "https://avatars.githubusercontent.com/u/32710596?v=4", "events_url": "https://api.github.com/users/AnilJagtap036/events{/privacy}", "followers_url": "https://api.github.com/users/AnilJagtap036/followers", "following_url": "https://api.github.com/users/AnilJagtap036/following{/other_user}", "gists_url": "https://api.github.com/users/AnilJagtap036/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/AnilJagtap036", "id": 32710596, "login": "AnilJagtap036", "node_id": "MDQ6VXNlcjMyNzEwNTk2", "organizations_url": "https://api.github.com/users/AnilJagtap036/orgs", "received_events_url": "https://api.github.com/users/AnilJagtap036/received_events", "repos_url": "https://api.github.com/users/AnilJagtap036/repos", "site_admin": false, "starred_url": "https://api.github.com/users/AnilJagtap036/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/AnilJagtap036/subscriptions", "type": "User", "url": "https://api.github.com/users/AnilJagtap036", "user_view_type": "public" }
[]
closed
true
null
[]
null
1
2018-05-17T15:25:53Z
2018-05-17T16:07:29Z
2018-05-17T16:05:36Z
NONE
off-topic
Please refer to our [StackOverflow tag](https://stackoverflow.com/questions/tagged/python-requests) for guidance. I'm using Stanford library in my python app. Now, I want to install Spacy library to implement some text parsing logic. When i'm trying to install Spacy library with python 2.7 version and pip 9.0.1 version. getting following error ``` C:\Users\Anil Jagtap>pip install -U spacy Collecting spacy c:\python27\lib\site-packages\pip\_vendor\requests\packages\urllib3\util\ssl_.py:318: SNIMissingWarning: An HTTPS request has been made, but the SNI (Subject Name Indication) extension to TLS is not available on this platform. This may cause the server to present an incorrect TLS certificate, which can cause validation failures. You can upgrade to a newer version of Python to solve this. For more information, see https://urllib3.readthedocs.io/en/latest/security.html#snimissingwarning. SNIMissingWarning c:\python27\lib\site-packages\pip\_vendor\requests\packages\urllib3\util\ssl_.py:122: InsecurePlatformWarning: A true SSLContext object is not available. This prevents urllib3 from configuring SSL appropriately and may cause certain SSL connections to fail. You can upgrade to a newer version of Python to solve this. For more information, see https://urllib3.readthedocs.io/en/latest/security.html#insecureplatformwarning. InsecurePlatformWarning Could not fetch URL https://pypi.python.org/simple/spacy/: There was a problem confirming the ssl certificate: [Errno 1] _ssl.c:499: error:1407742E:SSL routines:SSL23_GET_SERVER_HELLO:tlsv1 alert protocol version - skipping Could not find a version that satisfies the requirement spacy (from versions: ) No matching distribution found for spacy c:\python27\lib\site-packages\pip\_vendor\requests\packages\urllib3\util\ssl_.py:122: InsecurePlatformWarning: A true SSLContext object is not available. This prevents urllib3 from configuring SSL appropriately and may cause certain SSL connections to fail. You can upgrade to a newer version of Python to solve this. For more information, see https://urllib3.readthedocs.io/en/latest/security.html#insecureplatformwarning. InsecurePlatformWarning ``` How can I install Spacy library? Please help me. I'm facing this problem last 2 days.
{ "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/4651/reactions" }
https://api.github.com/repos/psf/requests/issues/4651/timeline
null
completed
null
null
false
[ "We ask you to search StackOverflow first because these problems are often already there.\r\n\r\nTo push you in the right direction here's what I've found: https://stackoverflow.com/a/23093834/1953283" ]
https://api.github.com/repos/psf/requests/issues/4650
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4650/labels{/name}
https://api.github.com/repos/psf/requests/issues/4650/comments
https://api.github.com/repos/psf/requests/issues/4650/events
https://github.com/psf/requests/issues/4650
323,979,686
MDU6SXNzdWUzMjM5Nzk2ODY=
4,650
verify in Session object ignored when REQUESTS_CA_BUNDLE is set
{ "avatar_url": "https://avatars.githubusercontent.com/u/7480559?v=4", "events_url": "https://api.github.com/users/jellestoel/events{/privacy}", "followers_url": "https://api.github.com/users/jellestoel/followers", "following_url": "https://api.github.com/users/jellestoel/following{/other_user}", "gists_url": "https://api.github.com/users/jellestoel/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jellestoel", "id": 7480559, "login": "jellestoel", "node_id": "MDQ6VXNlcjc0ODA1NTk=", "organizations_url": "https://api.github.com/users/jellestoel/orgs", "received_events_url": "https://api.github.com/users/jellestoel/received_events", "repos_url": "https://api.github.com/users/jellestoel/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jellestoel/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jellestoel/subscriptions", "type": "User", "url": "https://api.github.com/users/jellestoel", "user_view_type": "public" }
[]
closed
true
null
[]
null
1
2018-05-17T11:19:25Z
2021-09-08T02:09:58Z
2018-05-17T12:15:35Z
NONE
resolved
Summary. When REQUESTS_CA_BUNDLE has been set as an environment variable, the verify property in a requests.Session() will always be ignored. ## Expected Result requests.Session always uses REQUESTS_CA_BUNDLE unless a certificate bundle has been assigned ## Actual Result requests.Session always uses REQUESTS_CA_BUNDLE and overides any certificate bundle set on the Session object. ## Reproduction Steps ```REQUESTS_CA_BUNDLE="/lib/python3.6/site-packages/pip/_vendor/certifi/cacert.pem"``` ```python import requests s = requests.Session() s.verify = "/non_existing_bundle" s.get("https://google.com") ``` Expected result: ```OSError: Could not find a suitable TLS CA certificate bundle, invalid path: /non_existing_bundle``` Actual result: ```<Response [200]>``` ## System Information $ python -m requests.help ``` { "chardet": { "version": "3.0.4" }, "cryptography": { "version": "" }, "idna": { "version": "" }, "implementation": { "name": "CPython", "version": "3.6.4" }, "platform": { "release": "3.10.0-693.11.6.el7.x86_64", "system": "Linux" }, "pyOpenSSL": { "openssl_version": "", "version": null }, "requests": { "version": "2.18.4" }, "system_ssl": { "version": "100020bf" }, "urllib3": { "version": "1.22" }, "using_pyopenssl": false } ``` Not sure if this is a bug, but I now need to unset the environment variable first before I can use a different certificate bundle in a session object or use the following workaround. sessions.py: ``` #if verify is True or verify is None: if verify is True or verify is None and not isinstance(self.verify, str): verify = (os.environ.get('REQUESTS_CA_BUNDLE') or os.environ.get('CURL_CA_BUNDLE')) ```
{ "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/4650/reactions" }
https://api.github.com/repos/psf/requests/issues/4650/timeline
null
completed
null
null
false
[ "In the future, please search **closed and** open issues before creating new ones that are duplicates.\r\n\r\nDuplicate of #3829 " ]
https://api.github.com/repos/psf/requests/issues/4649
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4649/labels{/name}
https://api.github.com/repos/psf/requests/issues/4649/comments
https://api.github.com/repos/psf/requests/issues/4649/events
https://github.com/psf/requests/issues/4649
323,695,232
MDU6SXNzdWUzMjM2OTUyMzI=
4,649
utf-8 passwords in url don't work
{ "avatar_url": "https://avatars.githubusercontent.com/u/8750682?v=4", "events_url": "https://api.github.com/users/emmnx/events{/privacy}", "followers_url": "https://api.github.com/users/emmnx/followers", "following_url": "https://api.github.com/users/emmnx/following{/other_user}", "gists_url": "https://api.github.com/users/emmnx/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/emmnx", "id": 8750682, "login": "emmnx", "node_id": "MDQ6VXNlcjg3NTA2ODI=", "organizations_url": "https://api.github.com/users/emmnx/orgs", "received_events_url": "https://api.github.com/users/emmnx/received_events", "repos_url": "https://api.github.com/users/emmnx/repos", "site_admin": false, "starred_url": "https://api.github.com/users/emmnx/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/emmnx/subscriptions", "type": "User", "url": "https://api.github.com/users/emmnx", "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
2018-05-16T16:25:58Z
2021-09-07T00:06:14Z
2018-10-03T16:11:33Z
NONE
resolved
_Summary:_ ```curl -s --url http://user1:enganação@127.0.0.1:8080 --data '{"method": "help"}'``` works ``` #!/usr/bin/env python2 import requests import json payload = {'method': 'help'} url = 'http://user1:enganação@127.0.0.1:8080' requests.post(url, headers={'Content-type': 'text/plain; charset=utf-8'}, data=json.dumps(payload)) ``` also works. But... use `#!/usr/bin/env python3` instead, and it doesn't work anymore. requests messes things up. ## Expected Result Work as curl and requests in python2 do. ## Actual Result requests in python3 messes with encoding. ## Reproduction Steps ```python3 import requests import json payload = {'method': 'help'} url = 'http://user1:enganação@127.0.0.1:8080' requests.post(url, headers={'Content-type': 'text/plain; charset=utf-8'}, data=json.dumps(payload)) ``` ## System Information ``` Python 3.5.2 ```
{ "avatar_url": "https://avatars.githubusercontent.com/u/8750682?v=4", "events_url": "https://api.github.com/users/emmnx/events{/privacy}", "followers_url": "https://api.github.com/users/emmnx/followers", "following_url": "https://api.github.com/users/emmnx/following{/other_user}", "gists_url": "https://api.github.com/users/emmnx/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/emmnx", "id": 8750682, "login": "emmnx", "node_id": "MDQ6VXNlcjg3NTA2ODI=", "organizations_url": "https://api.github.com/users/emmnx/orgs", "received_events_url": "https://api.github.com/users/emmnx/received_events", "repos_url": "https://api.github.com/users/emmnx/repos", "site_admin": false, "starred_url": "https://api.github.com/users/emmnx/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/emmnx/subscriptions", "type": "User", "url": "https://api.github.com/users/emmnx", "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/4649/reactions" }
https://api.github.com/repos/psf/requests/issues/4649/timeline
null
completed
null
null
false
[ "Hi @Emmanux this needs more information. There are many versions of requests in the wild. We cannot begin to help debug this until you provide the information requested in the original issue template.", "`requests==2.9.1`\r\n(python3, this fails)\r\n\r\nand\r\n`requests==2.18.4`\r\n(python2, this is ok)", "I j...
https://api.github.com/repos/psf/requests/issues/4648
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4648/labels{/name}
https://api.github.com/repos/psf/requests/issues/4648/comments
https://api.github.com/repos/psf/requests/issues/4648/events
https://github.com/psf/requests/pull/4648
323,659,331
MDExOlB1bGxSZXF1ZXN0MTg4NDYyMTYy
4,648
bring Pipfile.lock up to date with current constraints
{ "avatar_url": "https://avatars.githubusercontent.com/u/5271761?v=4", "events_url": "https://api.github.com/users/nateprewitt/events{/privacy}", "followers_url": "https://api.github.com/users/nateprewitt/followers", "following_url": "https://api.github.com/users/nateprewitt/following{/other_user}", "gists_url": "https://api.github.com/users/nateprewitt/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/nateprewitt", "id": 5271761, "login": "nateprewitt", "node_id": "MDQ6VXNlcjUyNzE3NjE=", "organizations_url": "https://api.github.com/users/nateprewitt/orgs", "received_events_url": "https://api.github.com/users/nateprewitt/received_events", "repos_url": "https://api.github.com/users/nateprewitt/repos", "site_admin": false, "starred_url": "https://api.github.com/users/nateprewitt/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/nateprewitt/subscriptions", "type": "User", "url": "https://api.github.com/users/nateprewitt", "user_view_type": "public" }
[]
closed
true
null
[]
null
5
2018-05-16T14:57:14Z
2021-09-03T00:10:57Z
2018-05-16T19:31:49Z
MEMBER
resolved
The Pipfile has strayed a bit from our current build constraints and contains information that's no longer consistent with Warehouse. Updating should help with installation and prevent problems like pypa/packaging-problems#147 from reoccurring when users pick Requests as a model for their packages.
{ "avatar_url": "https://avatars.githubusercontent.com/u/5271761?v=4", "events_url": "https://api.github.com/users/nateprewitt/events{/privacy}", "followers_url": "https://api.github.com/users/nateprewitt/followers", "following_url": "https://api.github.com/users/nateprewitt/following{/other_user}", "gists_url": "https://api.github.com/users/nateprewitt/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/nateprewitt", "id": 5271761, "login": "nateprewitt", "node_id": "MDQ6VXNlcjUyNzE3NjE=", "organizations_url": "https://api.github.com/users/nateprewitt/orgs", "received_events_url": "https://api.github.com/users/nateprewitt/received_events", "repos_url": "https://api.github.com/users/nateprewitt/repos", "site_admin": false, "starred_url": "https://api.github.com/users/nateprewitt/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/nateprewitt/subscriptions", "type": "User", "url": "https://api.github.com/users/nateprewitt", "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/4648/reactions" }
https://api.github.com/repos/psf/requests/issues/4648/timeline
null
null
false
{ "diff_url": "https://github.com/psf/requests/pull/4648.diff", "html_url": "https://github.com/psf/requests/pull/4648", "merged_at": "2018-05-16T19:31:49Z", "patch_url": "https://github.com/psf/requests/pull/4648.patch", "url": "https://api.github.com/repos/psf/requests/pulls/4648" }
true
[ "# [Codecov](https://codecov.io/gh/requests/requests/pull/4648?src=pr&el=h1) Report\n> Merging [#4648](https://codecov.io/gh/requests/requests/pull/4648?src=pr&el=desc) into [master](https://codecov.io/gh/requests/requests/commit/f3fc892b901abe2c3605f2669af4f6469b896e88?src=pr&el=desc) will **not change** coverage....
https://api.github.com/repos/psf/requests/issues/4647
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4647/labels{/name}
https://api.github.com/repos/psf/requests/issues/4647/comments
https://api.github.com/repos/psf/requests/issues/4647/events
https://github.com/psf/requests/pull/4647
323,479,597
MDExOlB1bGxSZXF1ZXN0MTg4MzI2Nzgx
4,647
fix appveyor
{ "avatar_url": "https://avatars.githubusercontent.com/u/5271761?v=4", "events_url": "https://api.github.com/users/nateprewitt/events{/privacy}", "followers_url": "https://api.github.com/users/nateprewitt/followers", "following_url": "https://api.github.com/users/nateprewitt/following{/other_user}", "gists_url": "https://api.github.com/users/nateprewitt/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/nateprewitt", "id": 5271761, "login": "nateprewitt", "node_id": "MDQ6VXNlcjUyNzE3NjE=", "organizations_url": "https://api.github.com/users/nateprewitt/orgs", "received_events_url": "https://api.github.com/users/nateprewitt/received_events", "repos_url": "https://api.github.com/users/nateprewitt/repos", "site_admin": false, "starred_url": "https://api.github.com/users/nateprewitt/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/nateprewitt/subscriptions", "type": "User", "url": "https://api.github.com/users/nateprewitt", "user_view_type": "public" }
[]
closed
true
null
[]
null
3
2018-05-16T06:04:37Z
2021-09-03T00:10:58Z
2018-05-16T13:14:38Z
MEMBER
resolved
I don't know what's going on with Appveyor/Pipenv but it's no longer liking `-e .` installs out of the Pipfile. I went back to a version of Pipenv that we have successful builds for and it's still broken. I'd like to get builds fixed while we determine root cause.
{ "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/4647/reactions" }
https://api.github.com/repos/psf/requests/issues/4647/timeline
null
null
false
{ "diff_url": "https://github.com/psf/requests/pull/4647.diff", "html_url": "https://github.com/psf/requests/pull/4647", "merged_at": "2018-05-16T13:14:38Z", "patch_url": "https://github.com/psf/requests/pull/4647.patch", "url": "https://api.github.com/repos/psf/requests/pulls/4647" }
true
[ "# [Codecov](https://codecov.io/gh/requests/requests/pull/4647?src=pr&el=h1) Report\n> Merging [#4647](https://codecov.io/gh/requests/requests/pull/4647?src=pr&el=desc) into [master](https://codecov.io/gh/requests/requests/commit/9616f82905f86173477fdb3bf24f2f7228eed3a0?src=pr&el=desc) will **increase** coverage by...
https://api.github.com/repos/psf/requests/issues/4646
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4646/labels{/name}
https://api.github.com/repos/psf/requests/issues/4646/comments
https://api.github.com/repos/psf/requests/issues/4646/events
https://github.com/psf/requests/pull/4646
323,374,985
MDExOlB1bGxSZXF1ZXN0MTg4MjQ5MjAx
4,646
Add wheel hash for pluggy
{ "avatar_url": "https://avatars.githubusercontent.com/u/954310?v=4", "events_url": "https://api.github.com/users/techalchemy/events{/privacy}", "followers_url": "https://api.github.com/users/techalchemy/followers", "following_url": "https://api.github.com/users/techalchemy/following{/other_user}", "gists_url": "https://api.github.com/users/techalchemy/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/techalchemy", "id": 954310, "login": "techalchemy", "node_id": "MDQ6VXNlcjk1NDMxMA==", "organizations_url": "https://api.github.com/users/techalchemy/orgs", "received_events_url": "https://api.github.com/users/techalchemy/received_events", "repos_url": "https://api.github.com/users/techalchemy/repos", "site_admin": false, "starred_url": "https://api.github.com/users/techalchemy/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/techalchemy/subscriptions", "type": "User", "url": "https://api.github.com/users/techalchemy", "user_view_type": "public" }
[]
closed
true
null
[]
null
3
2018-05-15T20:40:38Z
2021-09-03T00:10:58Z
2018-05-16T06:38:23Z
NONE
resolved
- Lockfile was created when only the sdist was available
{ "avatar_url": "https://avatars.githubusercontent.com/u/5271761?v=4", "events_url": "https://api.github.com/users/nateprewitt/events{/privacy}", "followers_url": "https://api.github.com/users/nateprewitt/followers", "following_url": "https://api.github.com/users/nateprewitt/following{/other_user}", "gists_url": "https://api.github.com/users/nateprewitt/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/nateprewitt", "id": 5271761, "login": "nateprewitt", "node_id": "MDQ6VXNlcjUyNzE3NjE=", "organizations_url": "https://api.github.com/users/nateprewitt/orgs", "received_events_url": "https://api.github.com/users/nateprewitt/received_events", "repos_url": "https://api.github.com/users/nateprewitt/repos", "site_admin": false, "starred_url": "https://api.github.com/users/nateprewitt/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/nateprewitt/subscriptions", "type": "User", "url": "https://api.github.com/users/nateprewitt", "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/4646/reactions" }
https://api.github.com/repos/psf/requests/issues/4646/timeline
null
null
false
{ "diff_url": "https://github.com/psf/requests/pull/4646.diff", "html_url": "https://github.com/psf/requests/pull/4646", "merged_at": null, "patch_url": "https://github.com/psf/requests/pull/4646.patch", "url": "https://api.github.com/repos/psf/requests/pulls/4646" }
true
[ "Thanks for the PR, @techalchemy. We've had issues in the past with resolution conflicts around this particular extras_requires string.\r\n\r\n`'socks:sys_platform == \"win32\" and (python_version == \"2.7\" or python_version == \"2.6\")': ['win_inet_pton']`\r\n\r\nI got things worked out and have a new lockfile we...
https://api.github.com/repos/psf/requests/issues/4645
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4645/labels{/name}
https://api.github.com/repos/psf/requests/issues/4645/comments
https://api.github.com/repos/psf/requests/issues/4645/events
https://github.com/psf/requests/issues/4645
323,317,729
MDU6SXNzdWUzMjMzMTc3Mjk=
4,645
import requests throws ValueError on urllib3.__version__.split
{ "avatar_url": "https://avatars.githubusercontent.com/u/212252?v=4", "events_url": "https://api.github.com/users/synhershko/events{/privacy}", "followers_url": "https://api.github.com/users/synhershko/followers", "following_url": "https://api.github.com/users/synhershko/following{/other_user}", "gists_url": "https://api.github.com/users/synhershko/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/synhershko", "id": 212252, "login": "synhershko", "node_id": "MDQ6VXNlcjIxMjI1Mg==", "organizations_url": "https://api.github.com/users/synhershko/orgs", "received_events_url": "https://api.github.com/users/synhershko/received_events", "repos_url": "https://api.github.com/users/synhershko/repos", "site_admin": false, "starred_url": "https://api.github.com/users/synhershko/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/synhershko/subscriptions", "type": "User", "url": "https://api.github.com/users/synhershko", "user_view_type": "public" }
[]
closed
true
null
[]
null
1
2018-05-15T17:44:30Z
2021-09-08T02:09:59Z
2018-05-15T17:49:41Z
NONE
resolved
It may be an environment issue but I keep reproducing this error with latest requests: ``` ➜ python3 Python 3.6.5 (default, Mar 30 2018, 06:41:53) [GCC 4.2.1 Compatible Apple LLVM 9.0.0 (clang-900.0.39.2)] on darwin Type "help", "copyright", "credits" or "license" for more information. >>> import requests Traceback (most recent call last): File "<stdin>", line 1, in <module> File "/usr/local/lib/python3.6/site-packages/requests/__init__.py", line 49, in <module> major, minor, patch = urllib3.__version__.split('.')[:3] ValueError: not enough values to unpack (expected 3, got 2) ``` Here is a snip from `pip3 freeze`: ``` requests==2.18.4 requests2==2.16.0 rsa==3.4.2 urllib3==1.22 ``` Please advise
{ "avatar_url": "https://avatars.githubusercontent.com/u/212252?v=4", "events_url": "https://api.github.com/users/synhershko/events{/privacy}", "followers_url": "https://api.github.com/users/synhershko/followers", "following_url": "https://api.github.com/users/synhershko/following{/other_user}", "gists_url": "https://api.github.com/users/synhershko/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/synhershko", "id": 212252, "login": "synhershko", "node_id": "MDQ6VXNlcjIxMjI1Mg==", "organizations_url": "https://api.github.com/users/synhershko/orgs", "received_events_url": "https://api.github.com/users/synhershko/received_events", "repos_url": "https://api.github.com/users/synhershko/repos", "site_admin": false, "starred_url": "https://api.github.com/users/synhershko/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/synhershko/subscriptions", "type": "User", "url": "https://api.github.com/users/synhershko", "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/4645/reactions" }
https://api.github.com/repos/psf/requests/issues/4645/timeline
null
completed
null
null
false
[ "Was due to version clashes which I just was able to fix, closing" ]
https://api.github.com/repos/psf/requests/issues/4644
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4644/labels{/name}
https://api.github.com/repos/psf/requests/issues/4644/comments
https://api.github.com/repos/psf/requests/issues/4644/events
https://github.com/psf/requests/issues/4644
322,511,290
MDU6SXNzdWUzMjI1MTEyOTA=
4,644
Requests memory leak: Caused computer to crash
{ "avatar_url": "https://avatars.githubusercontent.com/u/39217719?v=4", "events_url": "https://api.github.com/users/Kodingu/events{/privacy}", "followers_url": "https://api.github.com/users/Kodingu/followers", "following_url": "https://api.github.com/users/Kodingu/following{/other_user}", "gists_url": "https://api.github.com/users/Kodingu/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/Kodingu", "id": 39217719, "login": "Kodingu", "node_id": "MDQ6VXNlcjM5MjE3NzE5", "organizations_url": "https://api.github.com/users/Kodingu/orgs", "received_events_url": "https://api.github.com/users/Kodingu/received_events", "repos_url": "https://api.github.com/users/Kodingu/repos", "site_admin": false, "starred_url": "https://api.github.com/users/Kodingu/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Kodingu/subscriptions", "type": "User", "url": "https://api.github.com/users/Kodingu", "user_view_type": "public" }
[]
closed
true
null
[]
null
3
2018-05-12T13:23:52Z
2021-09-08T02:09:57Z
2018-05-20T18:49:51Z
NONE
resolved
So as I was working on coding a notifier for a website, I came across an issue where my computer would gradually slow down after a long period of time. I thought it was nothing until my computer crashed. I then decided to look up on this issue by testing every single line of code in my while loop until i finally found out that it was caused by the requests module. I decided to look up on google if anyone else has gotten an issue like this and I actually did manage to find a page with someone who had this exact same problem. My code that I used to create this memory leak was this: ``` import requests ListedItems = {} while True: r = requests.get("urlToGet").json() time.sleep(1) for itm in r: print(itm) del r ``` I even tried to delete the r variable after I got everything I needed, but it still resulted in my computer to crash after a few hours. Please note that I need to have this program running for days.
{ "avatar_url": "https://avatars.githubusercontent.com/u/5271761?v=4", "events_url": "https://api.github.com/users/nateprewitt/events{/privacy}", "followers_url": "https://api.github.com/users/nateprewitt/followers", "following_url": "https://api.github.com/users/nateprewitt/following{/other_user}", "gists_url": "https://api.github.com/users/nateprewitt/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/nateprewitt", "id": 5271761, "login": "nateprewitt", "node_id": "MDQ6VXNlcjUyNzE3NjE=", "organizations_url": "https://api.github.com/users/nateprewitt/orgs", "received_events_url": "https://api.github.com/users/nateprewitt/received_events", "repos_url": "https://api.github.com/users/nateprewitt/repos", "site_admin": false, "starred_url": "https://api.github.com/users/nateprewitt/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/nateprewitt/subscriptions", "type": "User", "url": "https://api.github.com/users/nateprewitt", "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/4644/reactions" }
https://api.github.com/repos/psf/requests/issues/4644/timeline
null
completed
null
null
false
[ "Hi @Kodingu, we have another issue open (#4601) for something similar, but haven't been given enough information to identify a problem.\r\n\r\nCould you please provide the information originally requested in the template used to create this ticket? It also looks like you may have been storing items in `ListedItems...
https://api.github.com/repos/psf/requests/issues/4643
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4643/labels{/name}
https://api.github.com/repos/psf/requests/issues/4643/comments
https://api.github.com/repos/psf/requests/issues/4643/events
https://github.com/psf/requests/issues/4643
322,483,356
MDU6SXNzdWUzMjI0ODMzNTY=
4,643
Can not get the cookies from localhost
{ "avatar_url": "https://avatars.githubusercontent.com/u/22488270?v=4", "events_url": "https://api.github.com/users/MrThanlon/events{/privacy}", "followers_url": "https://api.github.com/users/MrThanlon/followers", "following_url": "https://api.github.com/users/MrThanlon/following{/other_user}", "gists_url": "https://api.github.com/users/MrThanlon/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/MrThanlon", "id": 22488270, "login": "MrThanlon", "node_id": "MDQ6VXNlcjIyNDg4Mjcw", "organizations_url": "https://api.github.com/users/MrThanlon/orgs", "received_events_url": "https://api.github.com/users/MrThanlon/received_events", "repos_url": "https://api.github.com/users/MrThanlon/repos", "site_admin": false, "starred_url": "https://api.github.com/users/MrThanlon/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/MrThanlon/subscriptions", "type": "User", "url": "https://api.github.com/users/MrThanlon", "user_view_type": "public" }
[]
closed
true
null
[]
null
3
2018-05-12T05:07:32Z
2021-08-28T00:06:01Z
2018-05-20T18:59:28Z
NONE
resolved
Summary. ## Expected Result ``` >>>import requests >>>requests.get('http://localhost/test.php').cookies <RequestsCookieJar[Cookie(....)]> ``` ## Actual Result ``` >>>import requests >>>requests.get('http://localhost/test.php').cookies <RequestsCookieJar[]> ``` ## Reproduction Steps ```python import requests requests.get('http://localhost/test.php').cookies ``` ## System Information $ python -m requests.help ``` { "chardet": { "version": "3.0.4" }, "cryptography": { "version": "" }, "idna": { "version": "2.6" }, "implementation": { "name": "CPython", "version": "2.7.14" }, "platform": { "release": "7", "system": "Windows" }, "pyOpenSSL": { "openssl_version": "", "version": null }, "requests": { "version": "2.18.4" }, "system_ssl": { "version": "100020bf" }, "urllib3": { "version": "1.22" }, "using_pyopenssl": false } ``` This command is only available on Requests v2.16.4 and greater. Otherwise, please provide some basic information about your system (Python version, operating system, &c). ---- ### I found it when I test a php script.I put it on IIS and explorer worked.Howerver requests did not got the cookies,response header showed there was a key "Set-Cookie".Strangely,when I put the php script on my site whose domain is not localhost,requests successfully got the cookies. ### The session is the same situation. ### Sorry for my poor English.
{ "avatar_url": "https://avatars.githubusercontent.com/u/5271761?v=4", "events_url": "https://api.github.com/users/nateprewitt/events{/privacy}", "followers_url": "https://api.github.com/users/nateprewitt/followers", "following_url": "https://api.github.com/users/nateprewitt/following{/other_user}", "gists_url": "https://api.github.com/users/nateprewitt/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/nateprewitt", "id": 5271761, "login": "nateprewitt", "node_id": "MDQ6VXNlcjUyNzE3NjE=", "organizations_url": "https://api.github.com/users/nateprewitt/orgs", "received_events_url": "https://api.github.com/users/nateprewitt/received_events", "repos_url": "https://api.github.com/users/nateprewitt/repos", "site_admin": false, "starred_url": "https://api.github.com/users/nateprewitt/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/nateprewitt/subscriptions", "type": "User", "url": "https://api.github.com/users/nateprewitt", "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/4643/reactions" }
https://api.github.com/repos/psf/requests/issues/4643/timeline
null
completed
null
null
false
[ "Hi @MrThanlon, can you please show us the value of `history` on the `Response` object? ", "Hi again @MrThanlon, here's a simple POC showing that cookies work fine on localhost. It looks like your IIS instance is doing some kind of redirect which is affecting the cookies on the response object. I'm closing this o...
https://api.github.com/repos/psf/requests/issues/4642
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4642/labels{/name}
https://api.github.com/repos/psf/requests/issues/4642/comments
https://api.github.com/repos/psf/requests/issues/4642/events
https://github.com/psf/requests/issues/4642
322,067,684
MDU6SXNzdWUzMjIwNjc2ODQ=
4,642
Raise exception if response does not match Content-Type header
{ "avatar_url": "https://avatars.githubusercontent.com/u/1330770?v=4", "events_url": "https://api.github.com/users/Stevoisiak/events{/privacy}", "followers_url": "https://api.github.com/users/Stevoisiak/followers", "following_url": "https://api.github.com/users/Stevoisiak/following{/other_user}", "gists_url": "https://api.github.com/users/Stevoisiak/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/Stevoisiak", "id": 1330770, "login": "Stevoisiak", "node_id": "MDQ6VXNlcjEzMzA3NzA=", "organizations_url": "https://api.github.com/users/Stevoisiak/orgs", "received_events_url": "https://api.github.com/users/Stevoisiak/received_events", "repos_url": "https://api.github.com/users/Stevoisiak/repos", "site_admin": false, "starred_url": "https://api.github.com/users/Stevoisiak/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Stevoisiak/subscriptions", "type": "User", "url": "https://api.github.com/users/Stevoisiak", "user_view_type": "public" }
[]
closed
true
null
[]
null
4
2018-05-10T20:12:17Z
2021-09-08T02:10:01Z
2018-05-11T16:43:46Z
CONTRIBUTOR
resolved
After sending a request, there should be an exception if the response Content-Type does not match the request Content-Type. (ie: `text/xml` vs `text/html`) (For backwards compatibility, this could be configurable with with an optional boolean argument) ## Expected Result An Exception should be raised if the response Content-Type does not match the request. ## Actual Result The request will proceed without any warning, even if the response Content-Type does not match. ## Reproduction Steps ```python import requests url = "http://www.example.com" xml_data = "<Request Object='System' Action='Ping'/>" headers = {"Content-Type": "text/xml"} response = requests.post(url, headers=headers, data=xml_data) print(response.headers) # {'Content-Type': 'text/html'} ``` ## System Information ``` { "chardet": { "version": "3.0.4" }, "cryptography": { "version": "" }, "idna": { "version": "2.6" }, "implementation": { "name": "CPython", "version": "3.6.4" }, "platform": { "release": "7", "system": "Windows" }, "pyOpenSSL": { "openssl_version": "", "version": null }, "requests": { "version": "2.18.4" }, "system_ssl": { "version": "100020bf" }, "urllib3": { "version": "1.22" }, "using_pyopenssl": false } ```
{ "avatar_url": "https://avatars.githubusercontent.com/u/1330770?v=4", "events_url": "https://api.github.com/users/Stevoisiak/events{/privacy}", "followers_url": "https://api.github.com/users/Stevoisiak/followers", "following_url": "https://api.github.com/users/Stevoisiak/following{/other_user}", "gists_url": "https://api.github.com/users/Stevoisiak/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/Stevoisiak", "id": 1330770, "login": "Stevoisiak", "node_id": "MDQ6VXNlcjEzMzA3NzA=", "organizations_url": "https://api.github.com/users/Stevoisiak/orgs", "received_events_url": "https://api.github.com/users/Stevoisiak/received_events", "repos_url": "https://api.github.com/users/Stevoisiak/repos", "site_admin": false, "starred_url": "https://api.github.com/users/Stevoisiak/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Stevoisiak/subscriptions", "type": "User", "url": "https://api.github.com/users/Stevoisiak", "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/4642/reactions" }
https://api.github.com/repos/psf/requests/issues/4642/timeline
null
completed
null
null
false
[ "Correct me if I'm wrong but isn't this fine?\r\n\r\nThe content-type header in the request tells the server what type of data you are posting, the content-type header in the response tells the client what type of data the server returned.\r\n\r\nAre you thinking about the Accept header where the client informs the...
https://api.github.com/repos/psf/requests/issues/4641
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4641/labels{/name}
https://api.github.com/repos/psf/requests/issues/4641/comments
https://api.github.com/repos/psf/requests/issues/4641/events
https://github.com/psf/requests/issues/4641
322,021,576
MDU6SXNzdWUzMjIwMjE1NzY=
4,641
Use a more descriptive error message for SSLError
{ "avatar_url": "https://avatars.githubusercontent.com/u/1330770?v=4", "events_url": "https://api.github.com/users/Stevoisiak/events{/privacy}", "followers_url": "https://api.github.com/users/Stevoisiak/followers", "following_url": "https://api.github.com/users/Stevoisiak/following{/other_user}", "gists_url": "https://api.github.com/users/Stevoisiak/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/Stevoisiak", "id": 1330770, "login": "Stevoisiak", "node_id": "MDQ6VXNlcjEzMzA3NzA=", "organizations_url": "https://api.github.com/users/Stevoisiak/orgs", "received_events_url": "https://api.github.com/users/Stevoisiak/received_events", "repos_url": "https://api.github.com/users/Stevoisiak/repos", "site_admin": false, "starred_url": "https://api.github.com/users/Stevoisiak/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Stevoisiak/subscriptions", "type": "User", "url": "https://api.github.com/users/Stevoisiak", "user_view_type": "public" }
[]
closed
true
null
[]
null
1
2018-05-10T17:50:33Z
2021-09-08T02:10:00Z
2018-05-13T10:57:41Z
CONTRIBUTOR
resolved
When a `requests.exceptions.SSLError` is raised due to certificate verification, the error message is inherited from `urllib3`. Unlike other `Requests` errors, the message is difficult to understand for the average user. ## Expected Result The traceback should display a single traceback with an easy to understand error message. Example: > requests.exceptions.SSLError: Secure connection failed. Cannot validate the certificate for 'https://expired.badssl.com/'. ## Actual Result The error message is reused directly from `urllib3`. > requests.exceptions.SSLError: HTTPSConnectionPool(host='expired.badssl.com', port=443): Max retries exceeded with url: / (Caused by SSLError(SSLError(1, '[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed (_ssl.c:777)'),)) The console log contains 3 separate tracebacks for what are essentially variations of the same error. ``` Traceback (most recent call last): File "C:\Users\svascellar\AppData\Local\Programs\Python\Python36-32\lib\site-packages\urllib3-1.22-py3.6.egg\urllib3\connectionpool.py", line 601, in urlopen chunked=chunked) File "C:\Users\svascellar\AppData\Local\Programs\Python\Python36-32\lib\site-packages\urllib3-1.22-py3.6.egg\urllib3\connectionpool.py", line 346, in _make_request self._validate_conn(conn) File "C:\Users\svascellar\AppData\Local\Programs\Python\Python36-32\lib\site-packages\urllib3-1.22-py3.6.egg\urllib3\connectionpool.py", line 850, in _validate_conn conn.connect() File "C:\Users\svascellar\AppData\Local\Programs\Python\Python36-32\lib\site-packages\urllib3-1.22-py3.6.egg\urllib3\connection.py", line 326, in connect ssl_context=context) File "C:\Users\svascellar\AppData\Local\Programs\Python\Python36-32\lib\site-packages\urllib3-1.22-py3.6.egg\urllib3\util\ssl_.py", line 329, in ssl_wrap_socket return context.wrap_socket(sock, server_hostname=server_hostname) File "C:\Users\svascellar\AppData\Local\Programs\Python\Python36-32\lib\ssl.py", line 407, in wrap_socket _context=self, _session=session) File "C:\Users\svascellar\AppData\Local\Programs\Python\Python36-32\lib\ssl.py", line 814, in __init__ self.do_handshake() File "C:\Users\svascellar\AppData\Local\Programs\Python\Python36-32\lib\ssl.py", line 1068, in do_handshake self._sslobj.do_handshake() File "C:\Users\svascellar\AppData\Local\Programs\Python\Python36-32\lib\ssl.py", line 689, in do_handshake self._sslobj.do_handshake() ssl.SSLError: [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed (_ssl.c:777) During handling of the above exception, another exception occurred: Traceback (most recent call last): File "C:\Users\svascellar\AppData\Local\Programs\Python\Python36-32\lib\site-packages\requests\adapters.py", line 440, in send timeout=timeout File "C:\Users\svascellar\AppData\Local\Programs\Python\Python36-32\lib\site-packages\urllib3-1.22-py3.6.egg\urllib3\connectionpool.py", line 639, in urlopen _stacktrace=sys.exc_info()[2]) File "C:\Users\svascellar\AppData\Local\Programs\Python\Python36-32\lib\site-packages\urllib3-1.22-py3.6.egg\urllib3\util\retry.py", line 388, in increment raise MaxRetryError(_pool, url, error or ResponseError(cause)) urllib3.exceptions.MaxRetryError: HTTPSConnectionPool(host='expired.badssl.com', port=443): Max retries exceeded with url: / (Caused by SSLError(SSLError(1, '[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed (_ssl.c:777)'),)) During handling of the above exception, another exception occurred: Traceback (most recent call last): File "C:/Users/svascellar/.PyCharmCE2018.1/config/scratches/scratch.py", line 3, in <module> response = requests.get('https://expired.badssl.com/') File "C:\Users\svascellar\AppData\Local\Programs\Python\Python36-32\lib\site-packages\requests\api.py", line 72, in get return request('get', url, params=params, **kwargs) File "C:\Users\svascellar\AppData\Local\Programs\Python\Python36-32\lib\site-packages\requests\api.py", line 58, in request return session.request(method=method, url=url, **kwargs) File "C:\Users\svascellar\AppData\Local\Programs\Python\Python36-32\lib\site-packages\requests\sessions.py", line 508, in request resp = self.send(prep, **send_kwargs) File "C:\Users\svascellar\AppData\Local\Programs\Python\Python36-32\lib\site-packages\requests\sessions.py", line 618, in send r = adapter.send(request, **kwargs) File "C:\Users\svascellar\AppData\Local\Programs\Python\Python36-32\lib\site-packages\requests\adapters.py", line 506, in send raise SSLError(e, request=request) requests.exceptions.SSLError: HTTPSConnectionPool(host='expired.badssl.com', port=443): Max retries exceeded with url: / (Caused by SSLError(SSLError(1, '[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed (_ssl.c:777)'),)) ``` ## Reproduction Steps ```python import requests response = requests.get('https://expired.badssl.com/') ``` ## System Information ``` { "chardet": { "version": "3.0.4" }, "cryptography": { "version": "" }, "idna": { "version": "2.6" }, "implementation": { "name": "CPython", "version": "3.6.4" }, "platform": { "release": "7", "system": "Windows" }, "pyOpenSSL": { "openssl_version": "", "version": null }, "requests": { "version": "2.18.4" }, "system_ssl": { "version": "100020bf" }, "urllib3": { "version": "1.22" }, "using_pyopenssl": 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" }
{ "+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/4641/reactions" }
https://api.github.com/repos/psf/requests/issues/4641/timeline
null
completed
null
null
false
[ "Hi @Stevoisiak, thanks for starting the discussion on this. While I agree that the messages generated from the SSL module leave something to be desired, I'm not sure Requests is an ideal place to solve this. We would need to be able to identify and rewrap every type of SSL exception inside the Requests code base w...
https://api.github.com/repos/psf/requests/issues/4640
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4640/labels{/name}
https://api.github.com/repos/psf/requests/issues/4640/comments
https://api.github.com/repos/psf/requests/issues/4640/events
https://github.com/psf/requests/issues/4640
321,868,546
MDU6SXNzdWUzMjE4Njg1NDY=
4,640
Send http request, header passed dictionary type error
{ "avatar_url": "https://avatars.githubusercontent.com/u/21286480?v=4", "events_url": "https://api.github.com/users/lvorcool/events{/privacy}", "followers_url": "https://api.github.com/users/lvorcool/followers", "following_url": "https://api.github.com/users/lvorcool/following{/other_user}", "gists_url": "https://api.github.com/users/lvorcool/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/lvorcool", "id": 21286480, "login": "lvorcool", "node_id": "MDQ6VXNlcjIxMjg2NDgw", "organizations_url": "https://api.github.com/users/lvorcool/orgs", "received_events_url": "https://api.github.com/users/lvorcool/received_events", "repos_url": "https://api.github.com/users/lvorcool/repos", "site_admin": false, "starred_url": "https://api.github.com/users/lvorcool/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/lvorcool/subscriptions", "type": "User", "url": "https://api.github.com/users/lvorcool", "user_view_type": "public" }
[]
closed
true
null
[]
null
1
2018-05-10T09:32:18Z
2021-09-08T02:10:02Z
2018-05-10T10:18:35Z
NONE
resolved
Summary. requests2.18.1 ## Expected Result Send http request, header pass dictionary type OK ## Actual Result The header when sending the http request is a dictionary, but an error occurred ```request.exceptions.InvalidHeader:` header value must be of type str or bytes, not <class 'dict'>``` ## Reproduction Steps The header I send is ``` { "X-L-REQ-HEADER": { "lgId": "aaasssssssssssss", "userToken": "aaasssssssssssss", "appVersion": "1.4.0.1", "deviceType": 102, "reqVersion": 60300 } } ``` ```python import requests url = "https://xxxx.com/v1/aaaaa/bbbbb/cccccc/dddddd" querystring = {"pageNo":"1","pageSize":"20"} headers = {"X-L-REQ-HEADER": {"lgId": "aaasssssssssssss","userToken": "aaasssssssssssss","appVersion": "1.4.0.1","deviceType": 102,"reqVersion": 60300}} response = requests.request("GET", url, headers=headers, params=querystring) print(response.text) ``` ## System Information $ python -m requests.help ``` <paste here> ![image](https://user-images.githubusercontent.com/21286480/39863014-008d7d20-5478-11e8-8c8e-3324d79f958a.png) ``` This command is only available on Requests v2.18.1 and greater. Otherwise, please provide some basic information about your system (Python version, operating system, &c).
{ "avatar_url": "https://avatars.githubusercontent.com/u/5271761?v=4", "events_url": "https://api.github.com/users/nateprewitt/events{/privacy}", "followers_url": "https://api.github.com/users/nateprewitt/followers", "following_url": "https://api.github.com/users/nateprewitt/following{/other_user}", "gists_url": "https://api.github.com/users/nateprewitt/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/nateprewitt", "id": 5271761, "login": "nateprewitt", "node_id": "MDQ6VXNlcjUyNzE3NjE=", "organizations_url": "https://api.github.com/users/nateprewitt/orgs", "received_events_url": "https://api.github.com/users/nateprewitt/received_events", "repos_url": "https://api.github.com/users/nateprewitt/repos", "site_admin": false, "starred_url": "https://api.github.com/users/nateprewitt/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/nateprewitt/subscriptions", "type": "User", "url": "https://api.github.com/users/nateprewitt", "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/4640/reactions" }
https://api.github.com/repos/psf/requests/issues/4640/timeline
null
completed
null
null
false
[ "Hi @lvorcool2016, as the exception says we need you to tell us what the header value looks like, either as a string or bytes string. Requests won’t try to serialize ambiguous values like a dictionary. I’m going to close this out since it’s intended behavior. Thanks for checking in!" ]
https://api.github.com/repos/psf/requests/issues/4639
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4639/labels{/name}
https://api.github.com/repos/psf/requests/issues/4639/comments
https://api.github.com/repos/psf/requests/issues/4639/events
https://github.com/psf/requests/issues/4639
321,794,034
MDU6SXNzdWUzMjE3OTQwMzQ=
4,639
if reqeusts is called in while loop, it always return same value even if data has been updated in database.
{ "avatar_url": "https://avatars.githubusercontent.com/u/16734697?v=4", "events_url": "https://api.github.com/users/FrancisJen/events{/privacy}", "followers_url": "https://api.github.com/users/FrancisJen/followers", "following_url": "https://api.github.com/users/FrancisJen/following{/other_user}", "gists_url": "https://api.github.com/users/FrancisJen/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/FrancisJen", "id": 16734697, "login": "FrancisJen", "node_id": "MDQ6VXNlcjE2NzM0Njk3", "organizations_url": "https://api.github.com/users/FrancisJen/orgs", "received_events_url": "https://api.github.com/users/FrancisJen/received_events", "repos_url": "https://api.github.com/users/FrancisJen/repos", "site_admin": false, "starred_url": "https://api.github.com/users/FrancisJen/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/FrancisJen/subscriptions", "type": "User", "url": "https://api.github.com/users/FrancisJen", "user_view_type": "public" }
[]
closed
true
null
[]
null
11
2018-05-10T03:06:06Z
2021-09-08T02:09:58Z
2018-05-12T13:42:28Z
NONE
resolved
Summary. if reqeuests is called in while loop, it always return same value even if data has been updated in database. the request content is: "res = json.loads(requests.get(url, data, verify=False).text)" after stop the call to test_deposit and call again the return value "res = json.loads(requests.get(url, data, verify=False).text)", then the value was updated ## Expected Result the return value of res = json.loads(requests.get(url, data, verify=False).text) should be updated immediately because of the value in database has been updated. ## Actual Result the return value of res = json.loads(requests.get(url, data, verify=False).text) always be same even if the value in database has been updated. ## Reproduction Steps ``` def test_deposit(self): receipt = self.kovan.send_ether_to_contract(0.0001) self.assertEqual(receipt['status'], 'added', "充值交易进入区块成功") txn_receipt = receipt['txn_receipt'] block_number = txn_receipt['blockNumber'] print(txn_receipt) print('first block is:' + str(block_number)) # 轮询6个区块来测试着期间充值不到账 # current_block_number = self.w3.eth.blockNumber balance_before_deposit = self.test_get_balance() print('before is:' + str(balance_before_deposit)) count = 0 while self.w3.eth.blockNumber < (block_number + 16 - 1) and count < 30: print(self.w3.eth.blockNumber) # # test_get_balance缓存清理 # cache_info = self.test_get_balance.cache_info() # print(cache_info) # self.test_get_balance.cache_clear # balance_after_deposit = self.test_get_balance() # print(balance_after_deposit) url = self.prefix + 'balance' data = { 'address': self.wallet_address } # res = self.run.request(url, 'GET', data=data) res = json.loads(requests.get(url, data, verify=False).text) self.assertIn('Success', res['message'], "测试成功") balance_after_deposit = res['data']['result'][0]['tokenAmount'] print('after is ' + str(balance_after_deposit)) self.assertEqual(balance_before_deposit, balance_after_deposit, '未经过6个区块充值不应到账') gc_status = gc.isenabled() print(gc_status) # 内存释放 del balance_after_deposit gc.collect() time.sleep(10) count = count + 1 print('到账时间总计花费:' + str(count * 20)) # if self.w3.eth.blockNumber >= block_number + 6 - 1: # balance_after_deposit = self.test_get_balance() # if balance_after_deposit > ``` ## System Information $ python -m requests.help ``` { "chardet": { "version": "3.0.4" }, "cryptography": { "version": "" }, "idna": { "version": "2.6" }, "implementation": { "name": "CPython", "version": "3.6.5" }, "platform": { "release": "17.4.0", "system": "Darwin" }, "pyOpenSSL": { "openssl_version": "", "version": null }, "requests": { "version": "2.18.4" }, "system_ssl": { "version": "100020ff" }, "urllib3": { "version": "1.22" }, "using_pyopenssl": false } ```
{ "avatar_url": "https://avatars.githubusercontent.com/u/5271761?v=4", "events_url": "https://api.github.com/users/nateprewitt/events{/privacy}", "followers_url": "https://api.github.com/users/nateprewitt/followers", "following_url": "https://api.github.com/users/nateprewitt/following{/other_user}", "gists_url": "https://api.github.com/users/nateprewitt/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/nateprewitt", "id": 5271761, "login": "nateprewitt", "node_id": "MDQ6VXNlcjUyNzE3NjE=", "organizations_url": "https://api.github.com/users/nateprewitt/orgs", "received_events_url": "https://api.github.com/users/nateprewitt/received_events", "repos_url": "https://api.github.com/users/nateprewitt/repos", "site_admin": false, "starred_url": "https://api.github.com/users/nateprewitt/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/nateprewitt/subscriptions", "type": "User", "url": "https://api.github.com/users/nateprewitt", "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/4639/reactions" }
https://api.github.com/repos/psf/requests/issues/4639/timeline
null
completed
null
null
false
[ "Unless I'm missing something, I don't see you update the value of `data` or `url` in your while loop.\r\n\r\nI'm not sure what framework you are using but if you have an instance of a record and that record is updated in the database, you probably need to fetch the object again to get the updates.\r\n\r\nThat bein...
https://api.github.com/repos/psf/requests/issues/4638
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4638/labels{/name}
https://api.github.com/repos/psf/requests/issues/4638/comments
https://api.github.com/repos/psf/requests/issues/4638/events
https://github.com/psf/requests/issues/4638
321,582,926
MDU6SXNzdWUzMjE1ODI5MjY=
4,638
OpenSSL.SSL.SysCallError: (-1, 'Unexpected EOF')
{ "avatar_url": "https://avatars.githubusercontent.com/u/8337939?v=4", "events_url": "https://api.github.com/users/fygul/events{/privacy}", "followers_url": "https://api.github.com/users/fygul/followers", "following_url": "https://api.github.com/users/fygul/following{/other_user}", "gists_url": "https://api.github.com/users/fygul/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/fygul", "id": 8337939, "login": "fygul", "node_id": "MDQ6VXNlcjgzMzc5Mzk=", "organizations_url": "https://api.github.com/users/fygul/orgs", "received_events_url": "https://api.github.com/users/fygul/received_events", "repos_url": "https://api.github.com/users/fygul/repos", "site_admin": false, "starred_url": "https://api.github.com/users/fygul/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/fygul/subscriptions", "type": "User", "url": "https://api.github.com/users/fygul", "user_view_type": "public" }
[]
closed
true
null
[]
null
8
2018-05-09T14:00:53Z
2021-09-08T02:10:01Z
2018-05-12T14:47:55Z
NONE
resolved
I run following code to retrieve a page on www.cnyes.com ```python import requests url = 'https://www.cnyes.com/global/IndexImmediateQuotedPrice/' r = requests.get(url) ``` Following errors occur ## Actual Result C:\ProgramData\Anaconda3\envs\p36\python.exe D:/projects/DailyReport/scripts/test/test_requests.py Traceback (most recent call last): File "C:\ProgramData\Anaconda3\envs\p36\lib\site-packages\urllib3\contrib\pyopenssl.py", line 441, in wrap_socket cnx.do_handshake() File "C:\ProgramData\Anaconda3\envs\p36\lib\site-packages\OpenSSL\SSL.py", line 1806, in do_handshake self._raise_ssl_error(self._ssl, result) File "C:\ProgramData\Anaconda3\envs\p36\lib\site-packages\OpenSSL\SSL.py", line 1539, in _raise_ssl_error raise SysCallError(-1, "Unexpected EOF") OpenSSL.SSL.SysCallError: (-1, 'Unexpected EOF') During handling of the above exception, another exception occurred: Traceback (most recent call last): File "C:\ProgramData\Anaconda3\envs\p36\lib\site-packages\urllib3\connectionpool.py", line 601, in urlopen chunked=chunked) File "C:\ProgramData\Anaconda3\envs\p36\lib\site-packages\urllib3\connectionpool.py", line 346, in _make_request self._validate_conn(conn) File "C:\ProgramData\Anaconda3\envs\p36\lib\site-packages\urllib3\connectionpool.py", line 850, in _validate_conn conn.connect() File "C:\ProgramData\Anaconda3\envs\p36\lib\site-packages\urllib3\connection.py", line 326, in connect ssl_context=context) File "C:\ProgramData\Anaconda3\envs\p36\lib\site-packages\urllib3\util\ssl_.py", line 329, in ssl_wrap_socket return context.wrap_socket(sock, server_hostname=server_hostname) File "C:\ProgramData\Anaconda3\envs\p36\lib\site-packages\urllib3\contrib\pyopenssl.py", line 448, in wrap_socket raise ssl.SSLError('bad handshake: %r' % e) ssl.SSLError: ("bad handshake: SysCallError(-1, 'Unexpected EOF')",) During handling of the above exception, another exception occurred: Traceback (most recent call last): File "C:\ProgramData\Anaconda3\envs\p36\lib\site-packages\requests\adapters.py", line 440, in send timeout=timeout File "C:\ProgramData\Anaconda3\envs\p36\lib\site-packages\urllib3\connectionpool.py", line 639, in urlopen _stacktrace=sys.exc_info()[2]) File "C:\ProgramData\Anaconda3\envs\p36\lib\site-packages\urllib3\util\retry.py", line 388, in increment raise MaxRetryError(_pool, url, error or ResponseError(cause)) urllib3.exceptions.MaxRetryError: HTTPSConnectionPool(host='www.cnyes.com', port=443): Max retries exceeded with url: /global/IndexImmediateQuotedPrice/ (Caused by SSLError(SSLError("bad handshake: SysCallError(-1, 'Unexpected EOF')",),)) During handling of the above exception, another exception occurred: Traceback (most recent call last): File "D:/projects/DailyReport/scripts/test/test_requests.py", line 9, in <module> r = requests.get(url) File "C:\ProgramData\Anaconda3\envs\p36\lib\site-packages\requests\api.py", line 72, in get return request('get', url, params=params, **kwargs) File "C:\ProgramData\Anaconda3\envs\p36\lib\site-packages\requests\api.py", line 58, in request return session.request(method=method, url=url, **kwargs) File "C:\ProgramData\Anaconda3\envs\p36\lib\site-packages\requests\sessions.py", line 508, in request resp = self.send(prep, **send_kwargs) File "C:\ProgramData\Anaconda3\envs\p36\lib\site-packages\requests\sessions.py", line 618, in send r = adapter.send(request, **kwargs) File "C:\ProgramData\Anaconda3\envs\p36\lib\site-packages\requests\adapters.py", line 506, in send raise SSLError(e, request=request) requests.exceptions.SSLError: HTTPSConnectionPool(host='www.cnyes.com', port=443): Max retries exceeded with url: /global/IndexImmediateQuotedPrice/ (Caused by SSLError(SSLError("bad handshake: SysCallError(-1, 'Unexpected EOF')",),)) ### Some Information on Security Panel of Google Chrome DevTools I use DevTools to Inspect www.cnyes.com: Connection Protocol TLS 1.0 Key exchange RSA Cipher 3DES_EDE_CBC with HMAC-SHA1 Refer to the red circle on attach image. ![devtools](https://user-images.githubusercontent.com/8337939/39818749-30a542da-53d4-11e8-9bf4-569f5eb87de2.png) Firefox Developer Tools shows Cipher suite: TLS_RSA_WITH_3DES_EDE_CBC_SHA ![firefox](https://user-images.githubusercontent.com/8337939/39869525-6b30adce-5490-11e8-9e93-62ab76666fe9.png) ## System Information $ python -m requests.help ``` { "chardet": { "version": "3.0.4" }, "cryptography": { "version": "2.2.2" }, "idna": { "version": "2.6" }, "implementation": { "name": "CPython", "version": "3.6.5" }, "platform": { "release": "8.1", "system": "Windows" }, "pyOpenSSL": { "openssl_version": "1010008f", "version": "17.5.0" }, "requests": { "version": "2.18.4" }, "system_ssl": { "version": "100020bf" }, "urllib3": { "version": "1.22" }, "using_pyopenssl": true } ``` Windows 8.1 Python 3.6.5 pip install request[security] pip list Package Version ------------ --------- asn1crypto 0.24.0 certifi 2018.4.16 cffi 1.11.5 chardet 3.0.4 cryptography 2.2.2 idna 2.6 pip 10.0.1 pycparser 2.18 pyOpenSSL 17.5.0 requests 2.18.4 setuptools 39.1.0 six 1.11.0 urllib3 1.22 wheel 0.31.0 wincertstore 0.2
{ "avatar_url": "https://avatars.githubusercontent.com/u/5271761?v=4", "events_url": "https://api.github.com/users/nateprewitt/events{/privacy}", "followers_url": "https://api.github.com/users/nateprewitt/followers", "following_url": "https://api.github.com/users/nateprewitt/following{/other_user}", "gists_url": "https://api.github.com/users/nateprewitt/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/nateprewitt", "id": 5271761, "login": "nateprewitt", "node_id": "MDQ6VXNlcjUyNzE3NjE=", "organizations_url": "https://api.github.com/users/nateprewitt/orgs", "received_events_url": "https://api.github.com/users/nateprewitt/received_events", "repos_url": "https://api.github.com/users/nateprewitt/repos", "site_admin": false, "starred_url": "https://api.github.com/users/nateprewitt/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/nateprewitt/subscriptions", "type": "User", "url": "https://api.github.com/users/nateprewitt", "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/4638/reactions" }
https://api.github.com/repos/psf/requests/issues/4638/timeline
null
completed
null
null
false
[ "I try to add DES-CBC3-SHA:EDH-RSA-DES-CBC3-SHA to CIPHERS, but it doesn't work.\r\n\r\n``` python\r\nimport requests\r\nfrom requests.adapters import HTTPAdapter\r\nfrom urllib3.poolmanager import PoolManager\r\nfrom urllib3.util.ssl_ import create_urllib3_context\r\n\r\nCIPHERS = (\r\n 'ECDH+AESGCM:DH+AESGCM:E...
https://api.github.com/repos/psf/requests/issues/4637
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4637/labels{/name}
https://api.github.com/repos/psf/requests/issues/4637/comments
https://api.github.com/repos/psf/requests/issues/4637/events
https://github.com/psf/requests/issues/4637
321,480,327
MDU6SXNzdWUzMjE0ODAzMjc=
4,637
requests unexpectedly decode gzip content in some case
{ "avatar_url": "https://avatars.githubusercontent.com/u/1853708?v=4", "events_url": "https://api.github.com/users/sthenault/events{/privacy}", "followers_url": "https://api.github.com/users/sthenault/followers", "following_url": "https://api.github.com/users/sthenault/following{/other_user}", "gists_url": "https://api.github.com/users/sthenault/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/sthenault", "id": 1853708, "login": "sthenault", "node_id": "MDQ6VXNlcjE4NTM3MDg=", "organizations_url": "https://api.github.com/users/sthenault/orgs", "received_events_url": "https://api.github.com/users/sthenault/received_events", "repos_url": "https://api.github.com/users/sthenault/repos", "site_admin": false, "starred_url": "https://api.github.com/users/sthenault/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sthenault/subscriptions", "type": "User", "url": "https://api.github.com/users/sthenault", "user_view_type": "public" }
[]
closed
true
null
[]
null
4
2018-05-09T08:37:57Z
2021-09-08T02:10:02Z
2018-05-09T11:26:24Z
NONE
resolved
I'm attempting to retrieve https://donneespubliques.meteofrance.fr/donnees_libres/Txt/Synop/Archive/synop.201803.csv.gz using python requests. However, when accessing response's content I get the csv data, not the gzipped-csv data like I would have expected. ## Actual Result >>> url 'https://donneespubliques.meteofrance.fr/donnees_libres/Txt/Synop/Archive/synop.201803.csv.gz' >>> resp = requests.get(url) >>> resp.headers {'Date': 'Thu, 19 Apr 2018 10:48:11 GMT', 'Server': 'MFWS', 'Last-Modified': 'Sat, 31 Mar 2018 21:10:09 GMT', 'ETag': '"3066bd-a2dce-568bbc81bee40"', 'Accept-Ranges': 'bytes', 'Content-Length': '667086', 'Content-Type': 'application/x-gzip', 'Content-Encoding': 'gzip', 'Content-Disposition': 'attachment', 'Keep-Alive': 'timeout=5, max=300', 'Connection': 'Keep-Alive'} >>> resp.content[:30] b'numer_sta;date;pmer;tend;cod_t' >>> requests.__version__ '2.18.4' ## Expected Result I would have expected to get the gzip file, consistently with the 'Content-Type' header. If I access the same URL with e.g. curl I get the gzipped content as expected: $ curl https://donneespubliques.meteofrance.fr/donnees_libres/Txt/Synop/Archive/synop.201803.csv.gz -s > data $ file data data: gzip compressed data, was "synop.201803.csv", last modified: Sat Mar 31 21:10:08 2018, from Unix Same thing with direct use of urllib3: >>> http = urllib3.PoolManager() >>> resp = http.request('GET', 'https://donneespubliques.meteofrance.fr/donnees_libres/Txt/Synop/Archive/synop.201804.csv.gz') >>> resp.data[:30] b'\x1f\x8b\x08\x081\x86\xe7Z\x00\x03synop.201804.csv\x00\xcc\xfd\xd9' Is this a requests feature I don't get? A server misconfiguration? ## System Information ``` { "chardet": { "version": "3.0.4" }, "cryptography": { "version": "" }, "idna": { "version": "2.6" }, "implementation": { "name": "CPython", "version": "3.6.5rc1" }, "platform": { "release": "4.16.0-1-amd64", "system": "Linux" }, "pyOpenSSL": { "openssl_version": "", "version": null }, "requests": { "version": "2.18.4" }, "system_ssl": { "version": "1010008f" }, "urllib3": { "version": "1.22" }, "using_pyopenssl": 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" }
{ "+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/4637/reactions" }
https://api.github.com/repos/psf/requests/issues/4637/timeline
null
completed
null
null
false
[ "The server specified the content encoding and we pass `decode_content` to urllib3. This checks the content encoding and decodes it for you. \r\n\r\nYou can disable this by passing stream=True to requests. However it seems that the server doesn’t want the file decoded on the client side natively so maybe this is al...
https://api.github.com/repos/psf/requests/issues/4636
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4636/labels{/name}
https://api.github.com/repos/psf/requests/issues/4636/comments
https://api.github.com/repos/psf/requests/issues/4636/events
https://github.com/psf/requests/pull/4636
321,065,605
MDExOlB1bGxSZXF1ZXN0MTg2NTQzNDI2
4,636
Add check proxies not none in line 683
{ "avatar_url": "https://avatars.githubusercontent.com/u/14043779?v=4", "events_url": "https://api.github.com/users/kartikeyaj0/events{/privacy}", "followers_url": "https://api.github.com/users/kartikeyaj0/followers", "following_url": "https://api.github.com/users/kartikeyaj0/following{/other_user}", "gists_url": "https://api.github.com/users/kartikeyaj0/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/kartikeyaj0", "id": 14043779, "login": "kartikeyaj0", "node_id": "MDQ6VXNlcjE0MDQzNzc5", "organizations_url": "https://api.github.com/users/kartikeyaj0/orgs", "received_events_url": "https://api.github.com/users/kartikeyaj0/received_events", "repos_url": "https://api.github.com/users/kartikeyaj0/repos", "site_admin": false, "starred_url": "https://api.github.com/users/kartikeyaj0/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/kartikeyaj0/subscriptions", "type": "User", "url": "https://api.github.com/users/kartikeyaj0", "user_view_type": "public" }
[]
closed
true
null
[]
null
1
2018-05-08T07:01:47Z
2021-09-03T00:11:00Z
2018-05-12T14:53:35Z
NONE
resolved
fixes #4635 In function merge_environment_settings before entering the loop
{ "avatar_url": "https://avatars.githubusercontent.com/u/5271761?v=4", "events_url": "https://api.github.com/users/nateprewitt/events{/privacy}", "followers_url": "https://api.github.com/users/nateprewitt/followers", "following_url": "https://api.github.com/users/nateprewitt/following{/other_user}", "gists_url": "https://api.github.com/users/nateprewitt/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/nateprewitt", "id": 5271761, "login": "nateprewitt", "node_id": "MDQ6VXNlcjUyNzE3NjE=", "organizations_url": "https://api.github.com/users/nateprewitt/orgs", "received_events_url": "https://api.github.com/users/nateprewitt/received_events", "repos_url": "https://api.github.com/users/nateprewitt/repos", "site_admin": false, "starred_url": "https://api.github.com/users/nateprewitt/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/nateprewitt/subscriptions", "type": "User", "url": "https://api.github.com/users/nateprewitt", "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/4636/reactions" }
https://api.github.com/repos/psf/requests/issues/4636/timeline
null
null
false
{ "diff_url": "https://github.com/psf/requests/pull/4636.diff", "html_url": "https://github.com/psf/requests/pull/4636", "merged_at": null, "patch_url": "https://github.com/psf/requests/pull/4636.patch", "url": "https://api.github.com/repos/psf/requests/pulls/4636" }
true
[ "Hi @kartikeyaj0, thanks for contributing to Requests. From the issue and this pull request it's not immediately clear how you're entering this state. Proxies will be assigned to an empty dictionary if `None` is passed to the session, and the docstring explicitly states it must be a dictionary.\r\n\r\nIn the event ...
https://api.github.com/repos/psf/requests/issues/4635
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4635/labels{/name}
https://api.github.com/repos/psf/requests/issues/4635/comments
https://api.github.com/repos/psf/requests/issues/4635/events
https://github.com/psf/requests/issues/4635
321,058,819
MDU6SXNzdWUzMjEwNTg4MTk=
4,635
Loop if 'proxies' is not None in requests/sessions.py line 679
{ "avatar_url": "https://avatars.githubusercontent.com/u/14778970?v=4", "events_url": "https://api.github.com/users/Harshish/events{/privacy}", "followers_url": "https://api.github.com/users/Harshish/followers", "following_url": "https://api.github.com/users/Harshish/following{/other_user}", "gists_url": "https://api.github.com/users/Harshish/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/Harshish", "id": 14778970, "login": "Harshish", "node_id": "MDQ6VXNlcjE0Nzc4OTcw", "organizations_url": "https://api.github.com/users/Harshish/orgs", "received_events_url": "https://api.github.com/users/Harshish/received_events", "repos_url": "https://api.github.com/users/Harshish/repos", "site_admin": false, "starred_url": "https://api.github.com/users/Harshish/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Harshish/subscriptions", "type": "User", "url": "https://api.github.com/users/Harshish", "user_view_type": "public" }
[]
closed
true
null
[]
null
1
2018-05-08T06:32:21Z
2021-09-08T02:10:00Z
2018-05-12T14:55:34Z
NONE
resolved
function merge_environment_settings
{ "avatar_url": "https://avatars.githubusercontent.com/u/5271761?v=4", "events_url": "https://api.github.com/users/nateprewitt/events{/privacy}", "followers_url": "https://api.github.com/users/nateprewitt/followers", "following_url": "https://api.github.com/users/nateprewitt/following{/other_user}", "gists_url": "https://api.github.com/users/nateprewitt/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/nateprewitt", "id": 5271761, "login": "nateprewitt", "node_id": "MDQ6VXNlcjUyNzE3NjE=", "organizations_url": "https://api.github.com/users/nateprewitt/orgs", "received_events_url": "https://api.github.com/users/nateprewitt/received_events", "repos_url": "https://api.github.com/users/nateprewitt/repos", "site_admin": false, "starred_url": "https://api.github.com/users/nateprewitt/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/nateprewitt/subscriptions", "type": "User", "url": "https://api.github.com/users/nateprewitt", "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/4635/reactions" }
https://api.github.com/repos/psf/requests/issues/4635/timeline
null
completed
null
null
false
[ "Closing with [this response](https://github.com/requests/requests/pull/4636#issuecomment-388560509) in the associated PR. We need more info to do anything actionable with this and the proposed solution will mask problems." ]
https://api.github.com/repos/psf/requests/issues/4634
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4634/labels{/name}
https://api.github.com/repos/psf/requests/issues/4634/comments
https://api.github.com/repos/psf/requests/issues/4634/events
https://github.com/psf/requests/pull/4634
320,894,838
MDExOlB1bGxSZXF1ZXN0MTg2NDE4MDI3
4,634
Spelling.
{ "avatar_url": "https://avatars.githubusercontent.com/u/52390?v=4", "events_url": "https://api.github.com/users/vshih/events{/privacy}", "followers_url": "https://api.github.com/users/vshih/followers", "following_url": "https://api.github.com/users/vshih/following{/other_user}", "gists_url": "https://api.github.com/users/vshih/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/vshih", "id": 52390, "login": "vshih", "node_id": "MDQ6VXNlcjUyMzkw", "organizations_url": "https://api.github.com/users/vshih/orgs", "received_events_url": "https://api.github.com/users/vshih/received_events", "repos_url": "https://api.github.com/users/vshih/repos", "site_admin": false, "starred_url": "https://api.github.com/users/vshih/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/vshih/subscriptions", "type": "User", "url": "https://api.github.com/users/vshih", "user_view_type": "public" }
[]
closed
true
null
[]
null
1
2018-05-07T17:52:02Z
2021-09-03T00:11:01Z
2018-05-08T11:12:33Z
CONTRIBUTOR
resolved
{ "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/4634/reactions" }
https://api.github.com/repos/psf/requests/issues/4634/timeline
null
null
false
{ "diff_url": "https://github.com/psf/requests/pull/4634.diff", "html_url": "https://github.com/psf/requests/pull/4634", "merged_at": "2018-05-08T11:12:33Z", "patch_url": "https://github.com/psf/requests/pull/4634.patch", "url": "https://api.github.com/repos/psf/requests/pulls/4634" }
true
[ "Thank you @vshih!" ]
https://api.github.com/repos/psf/requests/issues/4633
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4633/labels{/name}
https://api.github.com/repos/psf/requests/issues/4633/comments
https://api.github.com/repos/psf/requests/issues/4633/events
https://github.com/psf/requests/issues/4633
320,548,826
MDU6SXNzdWUzMjA1NDg4MjY=
4,633
Humans
{ "avatar_url": "https://avatars.githubusercontent.com/u/35662044?v=4", "events_url": "https://api.github.com/users/lgjmac/events{/privacy}", "followers_url": "https://api.github.com/users/lgjmac/followers", "following_url": "https://api.github.com/users/lgjmac/following{/other_user}", "gists_url": "https://api.github.com/users/lgjmac/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/lgjmac", "id": 35662044, "login": "lgjmac", "node_id": "MDQ6VXNlcjM1NjYyMDQ0", "organizations_url": "https://api.github.com/users/lgjmac/orgs", "received_events_url": "https://api.github.com/users/lgjmac/received_events", "repos_url": "https://api.github.com/users/lgjmac/repos", "site_admin": false, "starred_url": "https://api.github.com/users/lgjmac/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/lgjmac/subscriptions", "type": "User", "url": "https://api.github.com/users/lgjmac", "user_view_type": "public" }
[]
closed
true
null
[]
null
0
2018-05-05T23:18:58Z
2021-09-08T02:10:03Z
2018-05-06T14:08:29Z
NONE
resolved
Kenneth, Could you please do a 'Humans Guide for Humans'. Everything else you do is so simple, efficient and perfect that I feel I could really benefit. Thanks,
{ "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/4633/reactions" }
https://api.github.com/repos/psf/requests/issues/4633/timeline
null
completed
null
null
false
[]
https://api.github.com/repos/psf/requests/issues/4632
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4632/labels{/name}
https://api.github.com/repos/psf/requests/issues/4632/comments
https://api.github.com/repos/psf/requests/issues/4632/events
https://github.com/psf/requests/pull/4632
320,466,777
MDExOlB1bGxSZXF1ZXN0MTg2MTMxMzU3
4,632
Update license copyright to 2018
{ "avatar_url": "https://avatars.githubusercontent.com/u/6178510?v=4", "events_url": "https://api.github.com/users/mingrammer/events{/privacy}", "followers_url": "https://api.github.com/users/mingrammer/followers", "following_url": "https://api.github.com/users/mingrammer/following{/other_user}", "gists_url": "https://api.github.com/users/mingrammer/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/mingrammer", "id": 6178510, "login": "mingrammer", "node_id": "MDQ6VXNlcjYxNzg1MTA=", "organizations_url": "https://api.github.com/users/mingrammer/orgs", "received_events_url": "https://api.github.com/users/mingrammer/received_events", "repos_url": "https://api.github.com/users/mingrammer/repos", "site_admin": false, "starred_url": "https://api.github.com/users/mingrammer/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/mingrammer/subscriptions", "type": "User", "url": "https://api.github.com/users/mingrammer", "user_view_type": "public" }
[]
closed
true
null
[]
null
0
2018-05-05T00:58:18Z
2021-09-03T00:11:00Z
2018-05-13T17:30:58Z
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/4632/reactions" }
https://api.github.com/repos/psf/requests/issues/4632/timeline
null
null
false
{ "diff_url": "https://github.com/psf/requests/pull/4632.diff", "html_url": "https://github.com/psf/requests/pull/4632", "merged_at": "2018-05-13T17:30:58Z", "patch_url": "https://github.com/psf/requests/pull/4632.patch", "url": "https://api.github.com/repos/psf/requests/pulls/4632" }
true
[]
https://api.github.com/repos/psf/requests/issues/4631
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4631/labels{/name}
https://api.github.com/repos/psf/requests/issues/4631/comments
https://api.github.com/repos/psf/requests/issues/4631/events
https://github.com/psf/requests/pull/4631
320,236,936
MDExOlB1bGxSZXF1ZXN0MTg1OTU0NDU4
4,631
Add long_description_content_type to setup.py
{ "avatar_url": "https://avatars.githubusercontent.com/u/3275593?v=4", "events_url": "https://api.github.com/users/pradyunsg/events{/privacy}", "followers_url": "https://api.github.com/users/pradyunsg/followers", "following_url": "https://api.github.com/users/pradyunsg/following{/other_user}", "gists_url": "https://api.github.com/users/pradyunsg/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/pradyunsg", "id": 3275593, "login": "pradyunsg", "node_id": "MDQ6VXNlcjMyNzU1OTM=", "organizations_url": "https://api.github.com/users/pradyunsg/orgs", "received_events_url": "https://api.github.com/users/pradyunsg/received_events", "repos_url": "https://api.github.com/users/pradyunsg/repos", "site_admin": false, "starred_url": "https://api.github.com/users/pradyunsg/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/pradyunsg/subscriptions", "type": "User", "url": "https://api.github.com/users/pradyunsg", "user_view_type": "public" }
[]
closed
true
null
[]
null
9
2018-05-04T11:13:35Z
2021-09-03T00:10:57Z
2018-05-17T14:34:07Z
CONTRIBUTOR
resolved
See: - https://packaging.python.org/guides/making-a-pypi-friendly-readme/ - https://pypi.org/p/requests/
{ "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/4631/reactions" }
https://api.github.com/repos/psf/requests/issues/4631/timeline
null
null
false
{ "diff_url": "https://github.com/psf/requests/pull/4631.diff", "html_url": "https://github.com/psf/requests/pull/4631", "merged_at": "2018-05-17T14:34:07Z", "patch_url": "https://github.com/psf/requests/pull/4631.patch", "url": "https://api.github.com/repos/psf/requests/pulls/4631" }
true
[ "Duplicate of #4623 ", "Oh. Wait, it should be `text/x-rst`. Do you want me to open a new PR?", "Or update this one!", "My understanding was that if the readme is in RST, this isn't necessary to specify. Did the PEP change?", "I think it's nice-to-have. ", "I'll certianly reference it a lot, and it'll be ...
https://api.github.com/repos/psf/requests/issues/4630
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4630/labels{/name}
https://api.github.com/repos/psf/requests/issues/4630/comments
https://api.github.com/repos/psf/requests/issues/4630/events
https://github.com/psf/requests/issues/4630
320,167,729
MDU6SXNzdWUzMjAxNjc3Mjk=
4,630
Error reading Proxy certificates. (tlsv1 alert unknown ca)
{ "avatar_url": "https://avatars.githubusercontent.com/u/4972699?v=4", "events_url": "https://api.github.com/users/micafer/events{/privacy}", "followers_url": "https://api.github.com/users/micafer/followers", "following_url": "https://api.github.com/users/micafer/following{/other_user}", "gists_url": "https://api.github.com/users/micafer/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/micafer", "id": 4972699, "login": "micafer", "node_id": "MDQ6VXNlcjQ5NzI2OTk=", "organizations_url": "https://api.github.com/users/micafer/orgs", "received_events_url": "https://api.github.com/users/micafer/received_events", "repos_url": "https://api.github.com/users/micafer/repos", "site_admin": false, "starred_url": "https://api.github.com/users/micafer/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/micafer/subscriptions", "type": "User", "url": "https://api.github.com/users/micafer", "user_view_type": "public" }
[]
closed
true
null
[]
null
2
2018-05-04T06:42:14Z
2021-09-08T02:09:51Z
2018-05-04T11:41:07Z
NONE
resolved
Error reading Proxy certificates. It works for requests versions 2.11.1 and older. But it does not work for 2.12.0 and newer versions. ## Expected Result ``` <Response [200]> ``` ## Actual Result ``` requests.exceptions.ConnectionError: HTTPSConnectionPool(host='cloud.recas.ba.infn.it', port=5000): Max retries exceeded with url: /v2.0/tokens (Caused by SSLError(SSLError("bad handshake: Error([('SSL routines', 'ssl3_read_bytes', 'tlsv1 alert unknown ca')],)",),)) ``` ## Reproduction Steps ```python import requests body = '{"auth":{"voms":true}}' headers = {'Accept': 'application/json', 'Connection': 'close', 'Content-Type': 'application/json'} url = "https://<keystone_server>:5000/v2.0/tokens" # it is a grid proxy certificate cert = "/tmp/proxy.pem" # or cert = ("/tmp/proxy.pem", "/tmp/proxy.pem") requests.request('POST', url, verify=False, cert=cert, headers=headers, data=body) ``` ## System Information $ python -m requests.help ``` { "chardet": { "version": "3.0.4" }, "cryptography": { "version": "2.2.2" }, "idna": { "version": "2.6" }, "implementation": { "name": "CPython", "version": "2.7.13" }, "platform": { "release": "4.4.0-121-generic", "system": "Linux" }, "pyOpenSSL": { "openssl_version": "1010008f", "version": "17.5.0" }, "requests": { "version": "2.18.4" }, "system_ssl": { "version": "1010006f" }, "urllib3": { "version": "1.22" }, "using_pyopenssl": 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" }
{ "+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/4630/reactions" }
https://api.github.com/repos/psf/requests/issues/4630/timeline
null
completed
null
null
false
[ "The primary difference that looks potentially relevant to this [between 2.11.1 and 2.12.0](https://github.com/requests/requests/compare/v2.11.1...v2.12.0) is in urllib3. I believe that if the certificate authority file is false, we attempt to load the default file for the operating system. It seems that the code i...
https://api.github.com/repos/psf/requests/issues/4629
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4629/labels{/name}
https://api.github.com/repos/psf/requests/issues/4629/comments
https://api.github.com/repos/psf/requests/issues/4629/events
https://github.com/psf/requests/pull/4629
320,151,821
MDExOlB1bGxSZXF1ZXN0MTg1ODkxMTQ5
4,629
Fix iter_lines boundary bug when CRLF straddles two chunks
{ "avatar_url": "https://avatars.githubusercontent.com/u/282869?v=4", "events_url": "https://api.github.com/users/nanotone/events{/privacy}", "followers_url": "https://api.github.com/users/nanotone/followers", "following_url": "https://api.github.com/users/nanotone/following{/other_user}", "gists_url": "https://api.github.com/users/nanotone/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/nanotone", "id": 282869, "login": "nanotone", "node_id": "MDQ6VXNlcjI4Mjg2OQ==", "organizations_url": "https://api.github.com/users/nanotone/orgs", "received_events_url": "https://api.github.com/users/nanotone/received_events", "repos_url": "https://api.github.com/users/nanotone/repos", "site_admin": false, "starred_url": "https://api.github.com/users/nanotone/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/nanotone/subscriptions", "type": "User", "url": "https://api.github.com/users/nanotone", "user_view_type": "public" }
[]
closed
true
null
[]
null
1
2018-05-04T04:36:22Z
2021-09-03T00:11:01Z
2018-05-04T13:42:58Z
NONE
resolved
In `Response.iter_lines`, if a `\r\n` sequence (the only multi-character line boundary) straddles two chunks, the `\r` and `\n` are treated as two separate boundaries. Consequently, `iter_lines` will yield one extra blank line, as an empty string. This addresses the issue by checking if a chunk ends with `\r`, and when appropriate, leaving the trailing line in `pending` until the next chunk or EOF arrives.
{ "avatar_url": "https://avatars.githubusercontent.com/u/5271761?v=4", "events_url": "https://api.github.com/users/nateprewitt/events{/privacy}", "followers_url": "https://api.github.com/users/nateprewitt/followers", "following_url": "https://api.github.com/users/nateprewitt/following{/other_user}", "gists_url": "https://api.github.com/users/nateprewitt/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/nateprewitt", "id": 5271761, "login": "nateprewitt", "node_id": "MDQ6VXNlcjUyNzE3NjE=", "organizations_url": "https://api.github.com/users/nateprewitt/orgs", "received_events_url": "https://api.github.com/users/nateprewitt/received_events", "repos_url": "https://api.github.com/users/nateprewitt/repos", "site_admin": false, "starred_url": "https://api.github.com/users/nateprewitt/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/nateprewitt/subscriptions", "type": "User", "url": "https://api.github.com/users/nateprewitt", "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/4629/reactions" }
https://api.github.com/repos/psf/requests/issues/4629/timeline
null
null
false
{ "diff_url": "https://github.com/psf/requests/pull/4629.diff", "html_url": "https://github.com/psf/requests/pull/4629", "merged_at": null, "patch_url": "https://github.com/psf/requests/pull/4629.patch", "url": "https://api.github.com/repos/psf/requests/pulls/4629" }
true
[ "Hi @nanotone, thanks for putting this together! This has actually already been addressed and is patched for Requests-3.0 (#3984). We won't be able to merge this into the current master branch because it's a breaking change for some users which isn't backwards compatible." ]
https://api.github.com/repos/psf/requests/issues/4628
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4628/labels{/name}
https://api.github.com/repos/psf/requests/issues/4628/comments
https://api.github.com/repos/psf/requests/issues/4628/events
https://github.com/psf/requests/issues/4628
320,144,100
MDU6SXNzdWUzMjAxNDQxMDA=
4,628
Booleans in form data are being incorrectly encoded in post requests
{ "avatar_url": "https://avatars.githubusercontent.com/u/5299236?v=4", "events_url": "https://api.github.com/users/dteh/events{/privacy}", "followers_url": "https://api.github.com/users/dteh/followers", "following_url": "https://api.github.com/users/dteh/following{/other_user}", "gists_url": "https://api.github.com/users/dteh/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/dteh", "id": 5299236, "login": "dteh", "node_id": "MDQ6VXNlcjUyOTkyMzY=", "organizations_url": "https://api.github.com/users/dteh/orgs", "received_events_url": "https://api.github.com/users/dteh/received_events", "repos_url": "https://api.github.com/users/dteh/repos", "site_admin": false, "starred_url": "https://api.github.com/users/dteh/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/dteh/subscriptions", "type": "User", "url": "https://api.github.com/users/dteh", "user_view_type": "public" }
[]
closed
true
null
[]
null
1
2018-05-04T03:27:35Z
2021-09-08T02:10:03Z
2018-05-04T13:50:58Z
NONE
resolved
When sending form data, values which are booleans are encoded as "True" and "False" as opposed to "true" and "false". This is because of the urllib.parse.urlencode function. Perhaps it is non standard to pass a boolean as form data, but I think this is non obvious to regular users. Maybe it should raise an exception or perform a conversion to lowercase. ## Expected Result ``` >>> data = {"key": True, "key2": "true"} >>> req = requests.post("http://www.google.com", data=data) >>> req.request.body 'key=true&key2=true' ``` ## Actual Result ``` >>> data = {"key": True, "key2": "true"} >>> req = requests.post("http://www.google.com", data=data) >>> req.request.body 'key=True&key2=true' ``` ## Reproduction Steps Pass a dictionary with a key/value pair with a boolean value to the data param of a post.
{ "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/4628/reactions" }
https://api.github.com/repos/psf/requests/issues/4628/timeline
null
completed
null
null
false
[ "In the future, please search **closed and** open issues before creating new ones that are duplicates. I'm not going to go find the duplicates right now. Given all of the possible representations of \"True\" on the internet, we can't really just pick one. Further, we rely on the stdlib to provide the serialization ...
https://api.github.com/repos/psf/requests/issues/4627
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4627/labels{/name}
https://api.github.com/repos/psf/requests/issues/4627/comments
https://api.github.com/repos/psf/requests/issues/4627/events
https://github.com/psf/requests/pull/4627
320,134,200
MDExOlB1bGxSZXF1ZXN0MTg1ODc4NjAw
4,627
Strip whitespace for proxy urls, test for same. #4613
{ "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
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" }
2
2018-05-04T02:02:04Z
2024-05-20T14:35:51Z
2024-05-20T14:35:51Z
NONE
null
I'm not sure this is the right place to do this operation, but it does solve the problem. Or at least it passes the test that I wrote for it. Quite likely I'm not reading them correctly, but as far as I can tell the other test methods related to proxies don't test something like a `requests.get()` call with the expectation of a successful result. I found a ton of tests for error cases, though, and modeled the test for this situation on those, but it seems like there would be a better way.
{ "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/4627/reactions" }
https://api.github.com/repos/psf/requests/issues/4627/timeline
null
null
false
{ "diff_url": "https://github.com/psf/requests/pull/4627.diff", "html_url": "https://github.com/psf/requests/pull/4627", "merged_at": null, "patch_url": "https://github.com/psf/requests/pull/4627.patch", "url": "https://api.github.com/repos/psf/requests/pulls/4627" }
true
[ "# [Codecov](https://codecov.io/gh/requests/requests/pull/4627?src=pr&el=h1) Report\n> Merging [#4627](https://codecov.io/gh/requests/requests/pull/4627?src=pr&el=desc) into [master](https://codecov.io/gh/requests/requests/commit/fe8290b3d0ca21dd8ae5471a59a8bf13d3dcb31e?src=pr&el=desc) will **not change** coverage....
https://api.github.com/repos/psf/requests/issues/4626
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4626/labels{/name}
https://api.github.com/repos/psf/requests/issues/4626/comments
https://api.github.com/repos/psf/requests/issues/4626/events
https://github.com/psf/requests/pull/4626
320,133,517
MDExOlB1bGxSZXF1ZXN0MTg1ODc4MTMy
4,626
Add test for stripping of proxy url.
{ "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
0
2018-05-04T01:56:17Z
2021-09-03T00:11:02Z
2018-05-04T01:59:08Z
NONE
resolved
Strip whitespace from proxy URLs in get_connection to resolve #4613. I'm not sure this is the right place to do this operation, but it does solve the problem. Or at least it passes the test that I wrote for it. Quite likely I'm not reading them correctly, but as far as I can tell the other test methods related to proxies don't test something like a `requests.get()` call with the expectation of a successful result. I found a ton of tests for error cases, though and modeled the test for this situation on those, but it seems like there would be a better way.
null
{ "+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/4626/reactions" }
https://api.github.com/repos/psf/requests/issues/4626/timeline
null
null
false
{ "diff_url": "https://github.com/psf/requests/pull/4626.diff", "html_url": "https://github.com/psf/requests/pull/4626", "merged_at": null, "patch_url": "https://github.com/psf/requests/pull/4626.patch", "url": "https://api.github.com/repos/psf/requests/pulls/4626" }
true
[]
https://api.github.com/repos/psf/requests/issues/4625
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4625/labels{/name}
https://api.github.com/repos/psf/requests/issues/4625/comments
https://api.github.com/repos/psf/requests/issues/4625/events
https://github.com/psf/requests/pull/4625
319,977,963
MDExOlB1bGxSZXF1ZXN0MTg1NzYwMTQ0
4,625
Certifi.io broken
{ "avatar_url": "https://avatars.githubusercontent.com/u/5297556?v=4", "events_url": "https://api.github.com/users/nicktimko/events{/privacy}", "followers_url": "https://api.github.com/users/nicktimko/followers", "following_url": "https://api.github.com/users/nicktimko/following{/other_user}", "gists_url": "https://api.github.com/users/nicktimko/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/nicktimko", "id": 5297556, "login": "nicktimko", "node_id": "MDQ6VXNlcjUyOTc1NTY=", "organizations_url": "https://api.github.com/users/nicktimko/orgs", "received_events_url": "https://api.github.com/users/nicktimko/received_events", "repos_url": "https://api.github.com/users/nicktimko/repos", "site_admin": false, "starred_url": "https://api.github.com/users/nicktimko/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/nicktimko/subscriptions", "type": "User", "url": "https://api.github.com/users/nicktimko", "user_view_type": "public" }
[]
closed
true
null
[]
null
2
2018-05-03T15:48:07Z
2021-09-03T00:10:59Z
2018-05-14T16:22:11Z
CONTRIBUTOR
resolved
http://certifi.io/ -> https://certifiio.readthedocs.io/
{ "avatar_url": "https://avatars.githubusercontent.com/u/5271761?v=4", "events_url": "https://api.github.com/users/nateprewitt/events{/privacy}", "followers_url": "https://api.github.com/users/nateprewitt/followers", "following_url": "https://api.github.com/users/nateprewitt/following{/other_user}", "gists_url": "https://api.github.com/users/nateprewitt/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/nateprewitt", "id": 5271761, "login": "nateprewitt", "node_id": "MDQ6VXNlcjUyNzE3NjE=", "organizations_url": "https://api.github.com/users/nateprewitt/orgs", "received_events_url": "https://api.github.com/users/nateprewitt/received_events", "repos_url": "https://api.github.com/users/nateprewitt/repos", "site_admin": false, "starred_url": "https://api.github.com/users/nateprewitt/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/nateprewitt/subscriptions", "type": "User", "url": "https://api.github.com/users/nateprewitt", "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/4625/reactions" }
https://api.github.com/repos/psf/requests/issues/4625/timeline
null
null
false
{ "diff_url": "https://github.com/psf/requests/pull/4625.diff", "html_url": "https://github.com/psf/requests/pull/4625", "merged_at": "2018-05-14T16:22:11Z", "patch_url": "https://github.com/psf/requests/pull/4625.patch", "url": "https://api.github.com/repos/psf/requests/pulls/4625" }
true
[ "Hey @nicktimko, thanks for this! Would you mind rebasing this onto the current master branch?", "Thanks @nicktimko!" ]
https://api.github.com/repos/psf/requests/issues/4624
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4624/labels{/name}
https://api.github.com/repos/psf/requests/issues/4624/comments
https://api.github.com/repos/psf/requests/issues/4624/events
https://github.com/psf/requests/issues/4624
319,847,877
MDU6SXNzdWUzMTk4NDc4Nzc=
4,624
recv block forever
{ "avatar_url": "https://avatars.githubusercontent.com/u/6950099?v=4", "events_url": "https://api.github.com/users/zhangyuchun/events{/privacy}", "followers_url": "https://api.github.com/users/zhangyuchun/followers", "following_url": "https://api.github.com/users/zhangyuchun/following{/other_user}", "gists_url": "https://api.github.com/users/zhangyuchun/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/zhangyuchun", "id": 6950099, "login": "zhangyuchun", "node_id": "MDQ6VXNlcjY5NTAwOTk=", "organizations_url": "https://api.github.com/users/zhangyuchun/orgs", "received_events_url": "https://api.github.com/users/zhangyuchun/received_events", "repos_url": "https://api.github.com/users/zhangyuchun/repos", "site_admin": false, "starred_url": "https://api.github.com/users/zhangyuchun/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/zhangyuchun/subscriptions", "type": "User", "url": "https://api.github.com/users/zhangyuchun", "user_view_type": "public" }
[]
closed
true
null
[]
null
2
2018-05-03T09:31:10Z
2021-09-04T00:06:21Z
2018-05-03T09:40:37Z
NONE
resolved
Summary. ## Expected Result don't block forever. ## Actual Result block forever ## Reproduction Steps i write a python3 spider using requests . it can run for a long time normally. but sometimes it block recv data forever . i don't this is either a python3's bug or a requests's bug. can you help me ? please ask me for more info if need, info below: strace -p 12585: strace: Process 12585 attached recvfrom(5, strack 12585: #0 0x00007f16e10b9a3d in recv () from /lib64/libpthread.so.0 #1 0x00007f16d99d3da1 in sock_recv_impl (data=0x7ffec7c72170, s=0x7f16d3df8b28) at /root/deploy/Python-3.6.5/Modules/socketmodule.c:3064 #2 sock_call_ex (s=s@entry=0x7f16d3df8b28, data=data@entry=0x7ffec7c72170, timeout=-1000000000, err=0x0, connect=0, sock_func=0x7f16d99d1c60 <sock_recv_impl>, writing=0) at /root/deploy/Python-3.6.5/Modules/socketmodule.c:898 #3 0x00007f16d99d3f18 in sock_call (data=0x7ffec7c72170, func=0x7f16d99d1c60 <sock_recv_impl>, writing=0, s=0x7f16d3df8b28) at /root/deploy/Python-3.6.5/Modules/socketmodule.c:950 #4 sock_recv_guts (flags=<optimized out>, len=<optimized out>, cbuf=<optimized out>, s=0x7f16d3df8b28) at /root/deploy/Python-3.6.5/Modules/socketmodule.c:3096 #5 sock_recv_into (s=0x7f16d3df8b28, args=<optimized out>, kwds=<optimized out>) at /root/deploy/Python-3.6.5/Modules/socketmodule.c:3191 #6 0x00000000004aa107 in _PyCFunction_FastCallDict (kwargs=0x0, nargs=1, args=0x7f16d99d3e50 <sock_recv_into>, func_obj=0x7f16d3a5c9d8) at Objects/methodobject.c:231 #7 _PyCFunction_FastCallKeywords (func=func@entry=0x7f16d3a5c9d8, stack=stack@entry=0x15741d0, nargs=1, kwnames=kwnames@entry=0x0) at Objects/methodobject.c:294 #8 0x0000000000540e84 in call_function (pp_stack=pp_stack@entry=0x7ffec7c723a0, oparg=oparg@entry=1, kwnames=kwnames@entry=0x0) at Python/ceval.c:4824 #9 0x0000000000545cdc in _PyEval_EvalFrameDefault (f=<optimized out>, throwflag=<optimized out>) at Python/ceval.c:3322 #10 0x000000000053fe31 in PyEval_EvalFrameEx (throwflag=0, f=0x1574038) at Python/ceval.c:753 #11 _PyFunction_FastCall (co=co@entry=0x7f16da0a7d20, args=<optimized out>, args@entry=0x7ffec7c725a0, nargs=nargs@entry=2, globals=globals@entry=0x7f16da0a50d8) at Python/ceval.c:4906 #12 0x0000000000549d86 in _PyFunction_FastCallDict (func=func@entry=0x7f16da0546a8, args=args@entry=0x7ffec7c725a0, nargs=nargs@entry=2, kwargs=kwargs@entry=0x0) at Python/ceval.c:5008 #13 0x000000000045214f in _PyObject_FastCallDict (func=0x7f16da0546a8, args=0x7ffec7c725a0, nargs=2, kwargs=0x0) at Objects/abstract.c:2310 #14 0x000000000045224b in _PyObject_Call_Prepend (func=0x7f16da0546a8, obj=0x7f16d35983c8, args=0x7f16d3c77160, kwargs=0x0) at Objects/abstract.c:2373 #15 0x0000000000452002 in _PyObject_FastCallDict (func=0x7f16d3a82088, args=0x7ffec7c72690, nargs=1, kwargs=0x0) at Objects/abstract.c:2331 #16 0x0000000000453186 in PyObject_CallMethodObjArgs (callable=0x7f16d3a82088, name=<optimized out>) at Objects/abstract.c:2759 #17 0x00000000005bc155 in _bufferedreader_raw_read (self=self@entry=0x7f16d575dca8, start=<optimized out>, len=8192) at ./Modules/_io/bufferedio.c:1498 #18 0x00000000005be99c in _bufferedreader_fill_buffer (self=0x7f16d575dca8) at ./Modules/_io/bufferedio.c:1530 #19 _buffered_readline (self=self@entry=0x7f16d575dca8, limit=65537) at ./Modules/_io/bufferedio.c:1159 #20 0x00000000005bed61 in _io__Buffered_readline_impl (size=<optimized out>, self=0x7f16d575dca8) at ./Modules/_io/bufferedio.c:1219 #21 _io__Buffered_readline (self=0x7f16d575dca8, args=<optimized out>) at ./Modules/_io/clinic/bufferedio.c.h:251 #22 0x00000000004a9f89 in _PyCFunction_FastCallDict (kwargs=0x0, nargs=1, args=0x5bed20 <_io__Buffered_readline>, func_obj=0x7f16d34c9dc8) at Objects/methodobject.c:234 #23 _PyCFunction_FastCallKeywords (func=func@entry=0x7f16d34c9dc8, stack=stack@entry=0x1573f58, nargs=1, kwnames=kwnames@entry=0x0) at Objects/methodobject.c:294 #24 0x0000000000540e84 in call_function (pp_stack=pp_stack@entry=0x7ffec7c72a80, oparg=oparg@entry=1, kwnames=kwnames@entry=0x0) at Python/ceval.c:4824 #25 0x0000000000545cdc in _PyEval_EvalFrameDefault (f=<optimized out>, throwflag=<optimized out>) at Python/ceval.c:3322 #26 0x000000000053fe31 in PyEval_EvalFrameEx (throwflag=0, f=0x1573da8) at Python/ceval.c:753 #27 _PyFunction_FastCall (co=<optimized out>, args=<optimized out>, nargs=1, globals=globals@entry=0x7f16d9519240) at Python/ceval.c:4906 #28 0x0000000000540fc7 in fast_function (kwnames=0x0, nargs=<optimized out>, stack=<optimized out>, func=0x7f16d6415f28) at Python/ceval.c:4941 #29 call_function (pp_stack=pp_stack@entry=0x7ffec7c72ca0, oparg=oparg@entry=0, kwnames=kwnames@entry=0x0) at Python/ceval.c:4845 #30 0x0000000000545cdc in _PyEval_EvalFrameDefault (f=<optimized out>, throwflag=<optimized out>) at Python/ceval.c:3322 #31 0x000000000053fe31 in PyEval_EvalFrameEx (throwflag=0, f=0x1573b68) at Python/ceval.c:753 #32 _PyFunction_FastCall (co=<optimized out>, args=<optimized out>, nargs=1, globals=globals@entry=0x7f16d9519240) at Python/ceval.c:4906 #33 0x0000000000540fc7 in fast_function (kwnames=0x0, nargs=<optimized out>, stack=<optimized out>, func=0x7f16d6419048) at Python/ceval.c:4941 #34 call_function (pp_stack=pp_stack@entry=0x7ffec7c72ec0, oparg=oparg@entry=0, kwnames=kwnames@entry=0x0) at Python/ceval.c:4845 #35 0x0000000000545cdc in _PyEval_EvalFrameDefault (f=<optimized out>, throwflag=<optimized out>) at Python/ceval.c:3322 #36 0x000000000053fe31 in PyEval_EvalFrameEx (throwflag=0, f=0x1571498) at Python/ceval.c:753 #37 _PyFunction_FastCall (co=<optimized out>, args=<optimized out>, nargs=1, globals=globals@entry=0x7f16d9519240) at Python/ceval.c:4906 #38 0x0000000000540fc7 in fast_function (kwnames=0x0, nargs=<optimized out>, stack=<optimized out>, func=0x7f16d641bae8) at Python/ceval.c:4941 #39 call_function (pp_stack=pp_stack@entry=0x7ffec7c730e0, oparg=oparg@entry=0, kwnames=kwnames@entry=0x0) at Python/ceval.c:4845 #40 0x0000000000545cdc in _PyEval_EvalFrameDefault (f=<optimized out>, throwflag=<optimized out>) at Python/ceval.c:3322 #41 0x0000000000540aa1 in PyEval_EvalFrameEx (throwflag=0, f=0x1570058) at Python/ceval.c:753 #42 _PyEval_EvalCodeWithName (_co=0x7f16da061810, globals=globals@entry=0x7f16da05f048, locals=locals@entry=0x0, args=<optimized out>, argcount=4, kwnames=0x7f16da06a0b0, kwargs=kwargs@entry=0x156f418, kwcount=4, kwstep=kwstep@entry=1, defs=0x7f16d5d1e0e0, defcount=defcount@entry=2, kwdefs=0x0, closure=0x0, name=name@entry=0x7f16da062fb0, qualname=0x7f16da068138) at Python/ceval.c:4153 #43 0x0000000000540d9f in fast_function (kwnames=0x156f418, nargs=<optimized out>, stack=<optimized out>, func=0x7f16d5d31bf8) at Python/ceval.c:4965 #44 call_function (pp_stack=pp_stack@entry=0x7ffec7c73380, oparg=oparg@entry=7, kwnames=kwnames@entry=0x7f16da06a098) at Python/ceval.c:4845 #45 0x00000000005461cb in _PyEval_EvalFrameDefault (f=<optimized out>, throwflag=<optimized out>) at Python/ceval.c:3338 #46 0x0000000000540aa1 in PyEval_EvalFrameEx (throwflag=0, f=0x156f1a8) at Python/ceval.c:753 #47 _PyEval_EvalCodeWithName (_co=0x7f16da061ae0, globals=globals@entry=0x7f16da05f048, locals=locals@entry=0x0, args=<optimized out>, argcount=1, kwnames=0x7f16d56b71e0, kwargs=kwargs@entry=0x156d4e8, kwcount=10, kwstep=kwstep@entry=1, defs=0x7f16d638e8e0, defcount=defcount@entry=10, kwdefs=0x0, closure=0x0, name=name@entry=0x7f16da064ae8, qualname=0x7f16da06a170) at Python/ceval.c:4153 #48 0x0000000000540d9f in fast_function (kwnames=0x156d4e8, nargs=<optimized out>, stack=<optimized out>, func=0x7f16d5d31e18) at Python/ceval.c:4965 #49 call_function (pp_stack=pp_stack@entry=0x7ffec7c73610, oparg=oparg@entry=10, kwnames=kwnames@entry=0x7f16d56b71c8) at Python/ceval.c:4845 #50 0x00000000005461cb in _PyEval_EvalFrameDefault (f=<optimized out>, throwflag=<optimized out>) at Python/ceval.c:3338 #51 0x0000000000540aa1 in PyEval_EvalFrameEx (throwflag=0, f=0x156d2c8) at Python/ceval.c:753 #52 _PyEval_EvalCodeWithName (_co=_co@entry=0x7f16d539f660, globals=globals@entry=0x7f16d539c5a0, locals=locals@entry=0x0, args=args@entry=0x7ffec7c73870, argcount=argcount@entry=2, kwnames=kwnames@entry=0x7f16d538cee0, kwargs=kwargs@entry=0x7f16d538cee8, kwcount=10, kwcount@entry=5, kwstep=kwstep@entry=2, defs=0x7f16d53a21c0, defcount=5, kwdefs=0x0, closure=0x0, name=0x7f16e14bc420, qualname=0x7f16d539cc90) at Python/ceval.c:4153 #53 0x0000000000549ca6 in _PyFunction_FastCallDict (func=func@entry=0x7f16d53a9598, args=args@entry=0x7ffec7c73870, nargs=nargs@entry=2, kwargs=kwargs@entry=0x7f16d36d61f8) at Python/ceval.c:5057 #54 0x000000000045214f in _PyObject_FastCallDict (func=0x7f16d53a9598, args=0x7ffec7c73870, nargs=2, kwargs=0x7f16d36d61f8) at Objects/abstract.c:2310 #55 0x000000000045224b in _PyObject_Call_Prepend (func=0x7f16d53a9598, obj=0x7f16d3e052b0, args=0x7f16d38709e8, kwargs=0x7f16d36d61f8) at Objects/abstract.c:2373 #56 0x0000000000451e20 in PyObject_Call (func=func@entry=0x7f16d5337b88, args=args@entry=0x7f16d38709e8, kwargs=kwargs@entry=0x7f16d36d61f8) at Objects/abstract.c:2261 #57 0x00000000005460d2 in do_call_core (kwdict=0x7f16d36d61f8, callargs=0x7f16d38709e8, func=0x7f16d5337b88) at Python/ceval.c:5093 #58 _PyEval_EvalFrameDefault (f=<optimized out>, throwflag=<optimized out>) at Python/ceval.c:3391 #59 0x0000000000540aa1 in PyEval_EvalFrameEx (throwflag=0, f=0x15bde38) at Python/ceval.c:753 #60 _PyEval_EvalCodeWithName (_co=_co@entry=0x7f16d539b420, globals=globals@entry=0x7f16d5394900, locals=locals@entry=0x0, args=args@entry=0x7ffec7c73c20, argcount=argcount@entry=2, kwnames=kwnames@entry=0x7f16d534e690, kwargs=kwargs@entry=0x7f16d534e698, kwcount=12, kwcount@entry=6, kwstep=kwstep@entry=2, defs=0x0, defcount=0, kwdefs=0x0, closure=0x0, name=0x7f16e14bc420, qualname=0x7f16d539a9f0) at Python/ceval.c:4153 #61 0x0000000000549ca6 in _PyFunction_FastCallDict (func=func@entry=0x7f16d53aa048, args=args@entry=0x7ffec7c73c20, nargs=nargs@entry=2, kwargs=kwargs@entry=0x7f16d36d63f0) at Python/ceval.c:5057 #62 0x000000000045214f in _PyObject_FastCallDict (func=0x7f16d53aa048, args=0x7ffec7c73c20, nargs=2, kwargs=0x7f16d36d63f0) at Objects/abstract.c:2310 #63 0x000000000045224b in _PyObject_Call_Prepend (func=0x7f16d53aa048, obj=0x7f16e133c5c0, args=0x7f16d3c770f0, kwargs=0x7f16d36d63f0) at Objects/abstract.c:2373 #64 0x0000000000451e20 in PyObject_Call (func=func@entry=0x7f16d3a82a88, args=args@entry=0x7f16d3c770f0, kwargs=kwargs@entry=0x7f16d36d63f0) at Objects/abstract.c:2261 #65 0x00000000005460d2 in do_call_core (kwdict=0x7f16d36d63f0, callargs=0x7f16d3c770f0, func=0x7f16d3a82a88) at Python/ceval.c:5093 #66 _PyEval_EvalFrameDefault (f=<optimized out>, throwflag=<optimized out>) at Python/ceval.c:3391 #67 0x0000000000540aa1 in PyEval_EvalFrameEx (throwflag=0, f=0x1568dd8) at Python/ceval.c:753 #68 _PyEval_EvalCodeWithName (_co=_co@entry=0x7f16d538eed0, globals=globals@entry=0x7f16d5394900, locals=locals@entry=0x0, args=args@entry=0x7ffec7c73fd0, argcount=argcount@entry=3, kwnames=kwnames@entry=0x7f16d34f6b00, kwargs=kwargs@entry=0x7f16d34f6b08, kwcount=4, kwcount@entry=2, kwstep=kwstep@entry=2, defs=0x7f16d5744600, defcount=14, kwdefs=0x0, closure=0x0, name=0x7f16da0a45a8, qualname=0x7f16d539a470) at Python/ceval.c:4153 #69 0x0000000000549ca6 in _PyFunction_FastCallDict (func=func@entry=0x7f16d53a9b70, args=args@entry=0x7ffec7c73fd0, nargs=nargs@entry=3, kwargs=kwargs@entry=0x7f16d36d6ea0) at Python/ceval.c:5057 #70 0x000000000045214f in _PyObject_FastCallDict (func=0x7f16d53a9b70, args=0x7ffec7c73fd0, nargs=3, kwargs=0x7f16d36d6ea0) at Objects/abstract.c:2310 #71 0x000000000045224b in _PyObject_Call_Prepend (func=0x7f16d53a9b70, obj=0x7f16e133c5c0, args=0x7f16d3b744c8, kwargs=0x7f16d36d6ea0) at Objects/abstract.c:2373 #72 0x0000000000451e20 in PyObject_Call (func=func@entry=0x7f16d3a42888, args=args@entry=0x7f16d3b744c8, kwargs=kwargs@entry=0x7f16d36d6ea0) at Objects/abstract.c:2261 #73 0x00000000005460d2 in do_call_core (kwdict=0x7f16d36d6ea0, callargs=0x7f16d3b744c8, func=0x7f16d3a42888) at Python/ceval.c:5093 #74 _PyEval_EvalFrameDefault (f=<optimized out>, throwflag=<optimized out>) at Python/ceval.c:3391 #75 0x0000000000540aa1 in PyEval_EvalFrameEx (throwflag=0, f=0x7f16d5331768) at Python/ceval.c:753 #76 _PyEval_EvalCodeWithName (_co=0x7f16d538ef60, globals=globals@entry=0x7f16d5394900, locals=locals@entry=0x0, args=<optimized out>, argcount=2, kwnames=0x7f16e12fd1b0, kwargs=kwargs@entry=0x15c2238, kwcount=1, kwstep=kwstep@entry=1, defs=0x0, defcount=defcount@entry=0, kwdefs=0x0, closure=0x0, name=name@entry=0x7f16e14a5490, qualname=0x7f16d539a530) at Python/ceval.c:4153 #77 0x0000000000540d9f in fast_function (kwnames=0x15c2238, nargs=<optimized out>, stack=<optimized out>, func=0x7f16d53a9bf8) at Python/ceval.c:4965 #78 call_function (pp_stack=pp_stack@entry=0x7ffec7c743b0, oparg=oparg@entry=2, kwnames=kwnames@entry=0x7f16e12fd198) at Python/ceval.c:4845 #79 0x00000000005461cb in _PyEval_EvalFrameDefault (f=<optimized out>, throwflag=<optimized out>) at Python/ceval.c:3338 #80 0x000000000053fe31 in PyEval_EvalFrameEx (throwflag=0, f=0x15c2058) at Python/ceval.c:753 #81 _PyFunction_FastCall (co=<optimized out>, args=<optimized out>, nargs=4, globals=globals@entry=0x7f16e144c1b0) at Python/ceval.c:4906 #82 0x0000000000540fc7 in fast_function (kwnames=0x0, nargs=<optimized out>, stack=<optimized out>, func=0x7f16d531a378) at Python/ceval.c:4941 #83 call_function (pp_stack=pp_stack@entry=0x7ffec7c745c0, oparg=oparg@entry=4, kwnames=kwnames@entry=0x0) at Python/ceval.c:4845 #84 0x0000000000545cdc in _PyEval_EvalFrameDefault (f=<optimized out>, throwflag=<optimized out>) at Python/ceval.c:3322 #85 0x0000000000540aa1 in PyEval_EvalFrameEx (throwflag=0, f=0x12d7ab8) at Python/ceval.c:753 #86 _PyEval_EvalCodeWithName (_co=_co@entry=0x7f16e13cac00, globals=globals@entry=0x7f16e1338828, locals=locals@entry=0x7f16e1359d18, args=args@entry=0x0, argcount=argcount@entry=0, kwnames=kwnames@entry=0x0, kwargs=kwargs@entry=0x0, kwcount=kwcount@entry=0, kwstep=kwstep@entry=2, defs=defs@entry=0x0, defcount=defcount@entry=0, kwdefs=kwdefs@entry=0x0, closure=closure@entry=0x0, name=name@entry=0x0, qualname=qualname@entry=0x0) at Python/ceval.c:4153 #87 0x00000000005418e0 in PyEval_EvalCodeEx (closure=0x0, kwdefs=0x0, defcount=0, defs=0x0, kwcount=0, kws=0x0, argcount=0, args=0x0, locals=locals@entry=0x7f16e1359d18, globals=globals@entry=0x7f16e1338828, _co=_co@entry=0x7f16e13cac00) at Python/ceval.c:4174 #88 PyEval_EvalCode (co=co@entry=0x7f16e13cac00, globals=globals@entry=0x7f16e144c1b0, locals=locals@entry=0x7f16e144c1b0) at Python/ceval.c:730 #89 0x0000000000426768 in run_mod (arena=0x7f16e1466150, flags=0x7ffec7c748d0, locals=0x7f16e144c1b0, globals=0x7f16e144c1b0, filename=0x7f16e1359d18, mod=0x12e3e38) at Python/pythonrun.c:1025 #90 PyRun_FileExFlags (fp=0x1276480, filename_str=<optimized out>, start=<optimized out>, globals=0x7f16e144c1b0, locals=0x7f16e144c1b0, closeit=1, flags=0x7ffec7c748d0) at Python/pythonrun.c:978 #91 0x000000000042694d in PyRun_SimpleFileExFlags (fp=0x1276480, filename=<optimized out>, closeit=1, flags=0x7ffec7c748d0) at Python/pythonrun.c:420 #92 0x000000000043baea in run_file (p_cf=0x7ffec7c748d0, filename=0x12352a0 L"main.py", fp=0x1276480) at Modules/main.c:340 #93 Py_Main (argc=argc@entry=3, argv=argv@entry=0x1234010) at Modules/main.c:810 #94 0x000000000041d962 in main (argc=3, argv=<optimized out>) at ./Programs/python.c:69 ## System Information $ python -m requests.help { "chardet": { "version": "3.0.4" }, "cryptography": { "version": "" }, "idna": { "version": "2.6" }, "implementation": { "name": "CPython", "version": "3.6.5" }, "platform": { "release": "3.10.0-693.el7.x86_64", "system": "Linux" }, "pyOpenSSL": { "openssl_version": "", "version": null }, "requests": { "version": "2.18.4" }, "system_ssl": { "version": "100020bf" }, "urllib3": { "version": "1.22" }, "using_pyopenssl": false } ls -al /proc/12585/fd: total 0 dr-x------ 2 root root 0 May 3 16:55 . dr-xr-xr-x 9 root root 0 Apr 26 20:50 .. l-wx------ 1 root root 64 May 3 16:55 0 -> /dev/null l-wx------ 1 root root 64 May 3 16:55 1 -> /root/server/data.log l-wx------ 1 root root 64 May 3 16:55 2 -> /root/server/data.log lrwx------ 1 root root 64 May 3 16:55 3 -> socket:[168821] lrwx------ 1 root root 64 May 3 16:55 4 -> socket:[168836] lrwx------ 1 root root 64 May 3 16:55 5 -> socket:[170894] cat /proc/12585/net/tcp: sl local_address rem_address st tx_queue rx_queue tr tm->when retrnsmt uid timeout inode 0: 00000000:006F 00000000:0000 0A 00000000:00000000 00:00000000 00000000 0 0 15883 1 ffff8800b6168000 100 0 0 10 0 1: 0100007F:0019 00000000:0000 0A 00000000:00000000 00:00000000 00000000 0 0 19668 1 ffff8800b61687c0 100 0 0 10 0 2: 00000000:E49A 00000000:0000 0A 00000000:00000000 00:00000000 00000000 0 0 17210 1 ffff880137f60000 100 0 0 10 0 3: E5C6230A:B0D6 E6D0210A:0050 08 00000000:00000001 00:00000000 00000000 0 0 168821 1 ffff8800b616ae80 22 4 0 10 -1 4: E5C6230A:97D0 CCDB200A:0050 01 00000000:00000000 00:00000000 00000000 0 0 170894 1 ffff8800b616cd80 20 0 0 10 -1 5: E5C6230A:E49A C3C6230A:C525 01 00000000:00000000 02:0009A9F7 00000000 0 0 366844 4 ffff8800b6169f00 20 4 31 10 -1 netstat -anlp | grep python3: tcp 1 0 10.35.198.229:45270 10.33.208.230:80 CLOSE_WAIT 12585/python3 tcp 0 0 10.35.198.229:38864 10.32.219.204:80 ESTABLISHED 12585/python3 This command is only available on Requests v2.16.4 and greater. Otherwise, please provide some basic information about your system (Python version, operating system, &c).
{ "avatar_url": "https://avatars.githubusercontent.com/u/6950099?v=4", "events_url": "https://api.github.com/users/zhangyuchun/events{/privacy}", "followers_url": "https://api.github.com/users/zhangyuchun/followers", "following_url": "https://api.github.com/users/zhangyuchun/following{/other_user}", "gists_url": "https://api.github.com/users/zhangyuchun/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/zhangyuchun", "id": 6950099, "login": "zhangyuchun", "node_id": "MDQ6VXNlcjY5NTAwOTk=", "organizations_url": "https://api.github.com/users/zhangyuchun/orgs", "received_events_url": "https://api.github.com/users/zhangyuchun/received_events", "repos_url": "https://api.github.com/users/zhangyuchun/repos", "site_admin": false, "starred_url": "https://api.github.com/users/zhangyuchun/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/zhangyuchun/subscriptions", "type": "User", "url": "https://api.github.com/users/zhangyuchun", "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/4624/reactions" }
https://api.github.com/repos/psf/requests/issues/4624/timeline
null
completed
null
null
false
[ "use timeout arg.", "I'm seeing the same issue, and I am using the timeout arg.\r\n\r\n```\r\nsudo strace -p 68636\r\nstrace: Process 68636 attached\r\nrecvfrom(4, \r\n```\r\n\r\nAnd as far as I can tell this is happening during:\r\n```\r\n r = requests.post(config.get('ad_url'), oauth_params, timeout=10)\r\n```...
https://api.github.com/repos/psf/requests/issues/4623
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4623/labels{/name}
https://api.github.com/repos/psf/requests/issues/4623/comments
https://api.github.com/repos/psf/requests/issues/4623/events
https://github.com/psf/requests/pull/4623
319,785,285
MDExOlB1bGxSZXF1ZXN0MTg1NjE1MTc0
4,623
add long_description_content_type to setup.py
{ "avatar_url": "https://avatars.githubusercontent.com/u/3126246?v=4", "events_url": "https://api.github.com/users/ngoldbaum/events{/privacy}", "followers_url": "https://api.github.com/users/ngoldbaum/followers", "following_url": "https://api.github.com/users/ngoldbaum/following{/other_user}", "gists_url": "https://api.github.com/users/ngoldbaum/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/ngoldbaum", "id": 3126246, "login": "ngoldbaum", "node_id": "MDQ6VXNlcjMxMjYyNDY=", "organizations_url": "https://api.github.com/users/ngoldbaum/orgs", "received_events_url": "https://api.github.com/users/ngoldbaum/received_events", "repos_url": "https://api.github.com/users/ngoldbaum/repos", "site_admin": false, "starred_url": "https://api.github.com/users/ngoldbaum/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/ngoldbaum/subscriptions", "type": "User", "url": "https://api.github.com/users/ngoldbaum", "user_view_type": "public" }
[]
closed
true
null
[]
null
0
2018-05-03T04:31:17Z
2021-09-03T00:11:02Z
2018-05-03T14:16:38Z
NONE
resolved
This will make the readme render correctly on pypi. https://packaging.python.org/tutorials/distributing-packages/#description
{ "avatar_url": "https://avatars.githubusercontent.com/u/3126246?v=4", "events_url": "https://api.github.com/users/ngoldbaum/events{/privacy}", "followers_url": "https://api.github.com/users/ngoldbaum/followers", "following_url": "https://api.github.com/users/ngoldbaum/following{/other_user}", "gists_url": "https://api.github.com/users/ngoldbaum/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/ngoldbaum", "id": 3126246, "login": "ngoldbaum", "node_id": "MDQ6VXNlcjMxMjYyNDY=", "organizations_url": "https://api.github.com/users/ngoldbaum/orgs", "received_events_url": "https://api.github.com/users/ngoldbaum/received_events", "repos_url": "https://api.github.com/users/ngoldbaum/repos", "site_admin": false, "starred_url": "https://api.github.com/users/ngoldbaum/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/ngoldbaum/subscriptions", "type": "User", "url": "https://api.github.com/users/ngoldbaum", "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/4623/reactions" }
https://api.github.com/repos/psf/requests/issues/4623/timeline
null
null
false
{ "diff_url": "https://github.com/psf/requests/pull/4623.diff", "html_url": "https://github.com/psf/requests/pull/4623", "merged_at": null, "patch_url": "https://github.com/psf/requests/pull/4623.patch", "url": "https://api.github.com/repos/psf/requests/pulls/4623" }
true
[]
https://api.github.com/repos/psf/requests/issues/4622
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4622/labels{/name}
https://api.github.com/repos/psf/requests/issues/4622/comments
https://api.github.com/repos/psf/requests/issues/4622/events
https://github.com/psf/requests/issues/4622
319,722,773
MDU6SXNzdWUzMTk3MjI3NzM=
4,622
.. is not interpreted correctly with redirections
{ "avatar_url": "https://avatars.githubusercontent.com/u/2804645?v=4", "events_url": "https://api.github.com/users/hydrargyrum/events{/privacy}", "followers_url": "https://api.github.com/users/hydrargyrum/followers", "following_url": "https://api.github.com/users/hydrargyrum/following{/other_user}", "gists_url": "https://api.github.com/users/hydrargyrum/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/hydrargyrum", "id": 2804645, "login": "hydrargyrum", "node_id": "MDQ6VXNlcjI4MDQ2NDU=", "organizations_url": "https://api.github.com/users/hydrargyrum/orgs", "received_events_url": "https://api.github.com/users/hydrargyrum/received_events", "repos_url": "https://api.github.com/users/hydrargyrum/repos", "site_admin": false, "starred_url": "https://api.github.com/users/hydrargyrum/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/hydrargyrum/subscriptions", "type": "User", "url": "https://api.github.com/users/hydrargyrum", "user_view_type": "public" }
[]
closed
true
null
[]
null
1
2018-05-02T21:43:23Z
2021-09-08T02:10:04Z
2018-05-02T23:08:54Z
NONE
resolved
When a site redirects to an URL containing "/../", requests passes it verbatim instead of interpreting it. ## Expected Result requests should remove the ".." component and the previous component, by interpreting the ".." as meaning "parent folder". All real browsers do it. libcurl/curl (and wget) does it too. Test for example https://httpbin.org/redirect-to?url=https%3A%2F%2Fhttpbin.org%2Ffoo%2F%2E%2E%2Fget ## Actual Result requests fails to interpret it like other HTTP clients do and passes the "/../" verbatim, leading to errors on servers, ranging from 500 errors to 404 errors (as for httpbin). ## Reproduction Steps ```python import requests r = requests.get('https://httpbin.org/redirect-to?url=https%3A%2F%2Fhttpbin.org%2Ffoo%2F%2E%2E%2Fget') print(r.status_code, r.url) ``` ## System Information $ python -m requests.help ``` { "chardet": { "version": "3.0.4" }, "cryptography": { "version": "" }, "idna": { "version": "2.6" }, "implementation": { "name": "CPython", "version": "2.7.15" }, "platform": { "release": "4.15.0-1-amd64", "system": "Linux" }, "pyOpenSSL": { "openssl_version": "", "version": null }, "requests": { "version": "2.18.4" }, "system_ssl": { "version": "1010008f" }, "urllib3": { "version": "1.22" }, "using_pyopenssl": false } ```
{ "avatar_url": "https://avatars.githubusercontent.com/u/5271761?v=4", "events_url": "https://api.github.com/users/nateprewitt/events{/privacy}", "followers_url": "https://api.github.com/users/nateprewitt/followers", "following_url": "https://api.github.com/users/nateprewitt/following{/other_user}", "gists_url": "https://api.github.com/users/nateprewitt/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/nateprewitt", "id": 5271761, "login": "nateprewitt", "node_id": "MDQ6VXNlcjUyNzE3NjE=", "organizations_url": "https://api.github.com/users/nateprewitt/orgs", "received_events_url": "https://api.github.com/users/nateprewitt/received_events", "repos_url": "https://api.github.com/users/nateprewitt/repos", "site_admin": false, "starred_url": "https://api.github.com/users/nateprewitt/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/nateprewitt/subscriptions", "type": "User", "url": "https://api.github.com/users/nateprewitt", "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/4622/reactions" }
https://api.github.com/repos/psf/requests/issues/4622/timeline
null
completed
null
null
false
[ "Hi @hydrargyrum, thanks for taking the time to bring this to our attention. This is actually a known issue and duplicate of #2982. We can’t currently resolve it in the Requests 2.x branch for backwards compatibility reasons. We have a todo for Requests 3.0 to resolve it, either by moving to the rfc3986 library for...
https://api.github.com/repos/psf/requests/issues/4621
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4621/labels{/name}
https://api.github.com/repos/psf/requests/issues/4621/comments
https://api.github.com/repos/psf/requests/issues/4621/events
https://github.com/psf/requests/pull/4621
319,067,955
MDExOlB1bGxSZXF1ZXN0MTg1MDg4ODE1
4,621
Fix: safe proxies reading
{ "avatar_url": "https://avatars.githubusercontent.com/u/19318157?v=4", "events_url": "https://api.github.com/users/bradsbrown/events{/privacy}", "followers_url": "https://api.github.com/users/bradsbrown/followers", "following_url": "https://api.github.com/users/bradsbrown/following{/other_user}", "gists_url": "https://api.github.com/users/bradsbrown/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/bradsbrown", "id": 19318157, "login": "bradsbrown", "node_id": "MDQ6VXNlcjE5MzE4MTU3", "organizations_url": "https://api.github.com/users/bradsbrown/orgs", "received_events_url": "https://api.github.com/users/bradsbrown/received_events", "repos_url": "https://api.github.com/users/bradsbrown/repos", "site_admin": false, "starred_url": "https://api.github.com/users/bradsbrown/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/bradsbrown/subscriptions", "type": "User", "url": "https://api.github.com/users/bradsbrown", "user_view_type": "public" }
[]
closed
true
null
[]
null
4
2018-04-30T23:19:08Z
2022-02-26T04:00:40Z
2021-11-28T03:27:30Z
NONE
resolved
Set up `proxies` safely for the `.setdefault()` call a few lines below by coercing it into a dict if passed in as `None`, and adjust the one line that was potentially expecting a `None`.
{ "avatar_url": "https://avatars.githubusercontent.com/u/5271761?v=4", "events_url": "https://api.github.com/users/nateprewitt/events{/privacy}", "followers_url": "https://api.github.com/users/nateprewitt/followers", "following_url": "https://api.github.com/users/nateprewitt/following{/other_user}", "gists_url": "https://api.github.com/users/nateprewitt/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/nateprewitt", "id": 5271761, "login": "nateprewitt", "node_id": "MDQ6VXNlcjUyNzE3NjE=", "organizations_url": "https://api.github.com/users/nateprewitt/orgs", "received_events_url": "https://api.github.com/users/nateprewitt/received_events", "repos_url": "https://api.github.com/users/nateprewitt/repos", "site_admin": false, "starred_url": "https://api.github.com/users/nateprewitt/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/nateprewitt/subscriptions", "type": "User", "url": "https://api.github.com/users/nateprewitt", "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/4621/reactions" }
https://api.github.com/repos/psf/requests/issues/4621/timeline
null
null
false
{ "diff_url": "https://github.com/psf/requests/pull/4621.diff", "html_url": "https://github.com/psf/requests/pull/4621", "merged_at": null, "patch_url": "https://github.com/psf/requests/pull/4621.patch", "url": "https://api.github.com/repos/psf/requests/pulls/4621" }
true
[ "Hi @bradsbrown it sounds like you ran into a bug that you're trying to fix here. Could you share the code you used to encounter it and what the stack trace was?", "@sigmavirus24 Absolutely! Meant to add this last night, and got pulled away. Here's what triggered this for me - I was running some work that relies ...
https://api.github.com/repos/psf/requests/issues/4620
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4620/labels{/name}
https://api.github.com/repos/psf/requests/issues/4620/comments
https://api.github.com/repos/psf/requests/issues/4620/events
https://github.com/psf/requests/pull/4620
318,734,874
MDExOlB1bGxSZXF1ZXN0MTg0ODQ1NDcx
4,620
fix windows builds
{ "avatar_url": "https://avatars.githubusercontent.com/u/5271761?v=4", "events_url": "https://api.github.com/users/nateprewitt/events{/privacy}", "followers_url": "https://api.github.com/users/nateprewitt/followers", "following_url": "https://api.github.com/users/nateprewitt/following{/other_user}", "gists_url": "https://api.github.com/users/nateprewitt/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/nateprewitt", "id": 5271761, "login": "nateprewitt", "node_id": "MDQ6VXNlcjUyNzE3NjE=", "organizations_url": "https://api.github.com/users/nateprewitt/orgs", "received_events_url": "https://api.github.com/users/nateprewitt/received_events", "repos_url": "https://api.github.com/users/nateprewitt/repos", "site_admin": false, "starred_url": "https://api.github.com/users/nateprewitt/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/nateprewitt/subscriptions", "type": "User", "url": "https://api.github.com/users/nateprewitt", "user_view_type": "public" }
[]
closed
true
null
[]
null
0
2018-04-29T17:38:03Z
2021-09-03T00:10:59Z
2018-04-29T23:56:10Z
MEMBER
resolved
Appveyor isn't able to replace the running executable. We'll run it from inside the interpreter to fix build issues. This is lifted from the fix over on urllib3/urllib3#1369 which was configured to run the same way.
{ "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/4620/reactions" }
https://api.github.com/repos/psf/requests/issues/4620/timeline
null
null
false
{ "diff_url": "https://github.com/psf/requests/pull/4620.diff", "html_url": "https://github.com/psf/requests/pull/4620", "merged_at": "2018-04-29T23:56:10Z", "patch_url": "https://github.com/psf/requests/pull/4620.patch", "url": "https://api.github.com/repos/psf/requests/pulls/4620" }
true
[]
https://api.github.com/repos/psf/requests/issues/4619
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4619/labels{/name}
https://api.github.com/repos/psf/requests/issues/4619/comments
https://api.github.com/repos/psf/requests/issues/4619/events
https://github.com/psf/requests/issues/4619
318,561,976
MDU6SXNzdWUzMTg1NjE5NzY=
4,619
request to https server fails with bad handshake
{ "avatar_url": "https://avatars.githubusercontent.com/u/874719?v=4", "events_url": "https://api.github.com/users/jacob-keller/events{/privacy}", "followers_url": "https://api.github.com/users/jacob-keller/followers", "following_url": "https://api.github.com/users/jacob-keller/following{/other_user}", "gists_url": "https://api.github.com/users/jacob-keller/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jacob-keller", "id": 874719, "login": "jacob-keller", "node_id": "MDQ6VXNlcjg3NDcxOQ==", "organizations_url": "https://api.github.com/users/jacob-keller/orgs", "received_events_url": "https://api.github.com/users/jacob-keller/received_events", "repos_url": "https://api.github.com/users/jacob-keller/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jacob-keller/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jacob-keller/subscriptions", "type": "User", "url": "https://api.github.com/users/jacob-keller", "user_view_type": "public" }
[]
closed
true
null
[]
null
2
2018-04-27T21:59:52Z
2021-09-08T02:10:06Z
2018-04-29T17:45:17Z
NONE
resolved
Summary. I am attempting to connect to an https server (unfortunately private internal server) which request.get() fails to connect, but curl succeeds. Specifically, I'm using gertty and attempting to connect to an internal gerrit server. ## Expected Result python requests library succeeds to connect and allows me to work with the server. ## Actual Result the connection fails with: requests.exceptions.SSLError: HTTPSConnectionPool(host='<gerrit server>', port=443): Max retries exceeded with url: /gerrit/a/config/server/version (Caused by SSLError(SSLError("bad handshake: Error([('SSL routines', 'ssl3_read_bytes', 'sslv3 alert handshake failure')],)",),)) ## Reproduction Steps ```python import requests requests.get("gerrit-server") ``` ## System Information $ python -m requests.help ``` { "chardet": { "version": "3.0.4" }, "cryptography": { "version": "2.0.2" }, "idna": { "version": "" }, "implementation": { "name": "CPython", "version": "2.7.14" }, "platform": { "release": "4.15.15-300.fc27.x86_64", "system": "Linux" }, "pyOpenSSL": { "openssl_version": "1010006f", "version": "17.2.0" }, "requests": { "version": "2.18.4" }, "system_ssl": { "version": "1010008f" }, "urllib3": { "version": "1.22" }, "using_pyopenssl": true } ``` At first, I thought this was because the certificate was invalid, but I tried using curl, and it succeeded (well, ok it failed with unauthorized, since I haven't provided login credentials yet, but it did succeed the TLS handshake). I used wireshark to compare the client hello message with the one from curl, and I found that the only major difference was that the successful curl request included more cipher suites, and the server appears to want to select one of those, so when the requests base client hello message is sent, it gets rejected. Specifically, the server wants to use TLS_RSA_WITH_3DES_EDE_CBC_SHA, which is supported by curl, but not by the requests connection. Any idea what is going on here, or whether there's a way to work around this issue in gertty? I am unable to use gertty with my internal server unless this is fixed.
{ "avatar_url": "https://avatars.githubusercontent.com/u/5271761?v=4", "events_url": "https://api.github.com/users/nateprewitt/events{/privacy}", "followers_url": "https://api.github.com/users/nateprewitt/followers", "following_url": "https://api.github.com/users/nateprewitt/following{/other_user}", "gists_url": "https://api.github.com/users/nateprewitt/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/nateprewitt", "id": 5271761, "login": "nateprewitt", "node_id": "MDQ6VXNlcjUyNzE3NjE=", "organizations_url": "https://api.github.com/users/nateprewitt/orgs", "received_events_url": "https://api.github.com/users/nateprewitt/received_events", "repos_url": "https://api.github.com/users/nateprewitt/repos", "site_admin": false, "starred_url": "https://api.github.com/users/nateprewitt/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/nateprewitt/subscriptions", "type": "User", "url": "https://api.github.com/users/nateprewitt", "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/4619/reactions" }
https://api.github.com/repos/psf/requests/issues/4619/timeline
null
completed
null
null
false
[ "I *believe* this issue is very similar to an issue in scrapy: https://github.com/scrapy/scrapy/issues/2717 as that was what led me down the path of checking the cipher suite to see if it was sending the same values.", "Hi @jacob-keller, Requests no longer supports 3DES out of the box because of the known securit...
https://api.github.com/repos/psf/requests/issues/4618
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4618/labels{/name}
https://api.github.com/repos/psf/requests/issues/4618/comments
https://api.github.com/repos/psf/requests/issues/4618/events
https://github.com/psf/requests/pull/4618
318,551,543
MDExOlB1bGxSZXF1ZXN0MTg0NzI5MjAy
4,618
Use multi-line import for __version__
{ "avatar_url": "https://avatars.githubusercontent.com/u/1330770?v=4", "events_url": "https://api.github.com/users/Stevoisiak/events{/privacy}", "followers_url": "https://api.github.com/users/Stevoisiak/followers", "following_url": "https://api.github.com/users/Stevoisiak/following{/other_user}", "gists_url": "https://api.github.com/users/Stevoisiak/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/Stevoisiak", "id": 1330770, "login": "Stevoisiak", "node_id": "MDQ6VXNlcjEzMzA3NzA=", "organizations_url": "https://api.github.com/users/Stevoisiak/orgs", "received_events_url": "https://api.github.com/users/Stevoisiak/received_events", "repos_url": "https://api.github.com/users/Stevoisiak/repos", "site_admin": false, "starred_url": "https://api.github.com/users/Stevoisiak/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Stevoisiak/subscriptions", "type": "User", "url": "https://api.github.com/users/Stevoisiak", "user_view_type": "public" }
[]
closed
true
null
[]
null
3
2018-04-27T21:12:55Z
2021-09-02T00:07:43Z
2018-04-27T21:57:53Z
CONTRIBUTOR
resolved
{ "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/4618/reactions" }
https://api.github.com/repos/psf/requests/issues/4618/timeline
null
null
false
{ "diff_url": "https://github.com/psf/requests/pull/4618.diff", "html_url": "https://github.com/psf/requests/pull/4618", "merged_at": null, "patch_url": "https://github.com/psf/requests/pull/4618.patch", "url": "https://api.github.com/repos/psf/requests/pulls/4618" }
true
[ "Hi there @Stevoisiak ! Thanks for sending this PR along. We don’t accept stylistic changes, unfortunately as this project has its own style guide that we haven’t had a chance to document. ", "@sigmavirus24 Should single-line imports over 100 characters be left alone as well?\r\n\r\nhttps://github.com/requests/r...
https://api.github.com/repos/psf/requests/issues/4617
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4617/labels{/name}
https://api.github.com/repos/psf/requests/issues/4617/comments
https://api.github.com/repos/psf/requests/issues/4617/events
https://github.com/psf/requests/issues/4617
318,548,831
MDU6SXNzdWUzMTg1NDg4MzE=
4,617
AppVeyor builds failing on master
{ "avatar_url": "https://avatars.githubusercontent.com/u/1330770?v=4", "events_url": "https://api.github.com/users/Stevoisiak/events{/privacy}", "followers_url": "https://api.github.com/users/Stevoisiak/followers", "following_url": "https://api.github.com/users/Stevoisiak/following{/other_user}", "gists_url": "https://api.github.com/users/Stevoisiak/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/Stevoisiak", "id": 1330770, "login": "Stevoisiak", "node_id": "MDQ6VXNlcjEzMzA3NzA=", "organizations_url": "https://api.github.com/users/Stevoisiak/orgs", "received_events_url": "https://api.github.com/users/Stevoisiak/received_events", "repos_url": "https://api.github.com/users/Stevoisiak/repos", "site_admin": false, "starred_url": "https://api.github.com/users/Stevoisiak/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Stevoisiak/subscriptions", "type": "User", "url": "https://api.github.com/users/Stevoisiak", "user_view_type": "public" }
[]
closed
true
null
[]
null
4
2018-04-27T21:02:18Z
2021-09-08T02:10:04Z
2018-04-30T20:02:52Z
CONTRIBUTOR
resolved
For the past month, all pull requests to `master` have been [failing to build on AppVeyor](https://ci.appveyor.com/project/kennethreitz/requests/history). From what I can tell, the build [started failing sometime around March 8th](https://ci.appveyor.com/project/kennethreitz/requests/build/1.0.383). Commit https://github.com/requests/requests/commit/8f3f022c54db7c8348c84c079dfe7f7c354f1062 may have fixed the issue in the `3.0` branch, but the fix does not seem to have been merged to `master`. ## Expected Result Pull requests should report a successful build. ## Actual Result All pull requests report a build status of failure. ## Reproduction Steps 1. Submit a pull request to `master`. 2. Wait for AppVeyor to finish building 3. [Check the build status](https://github.com/requests/requests/pull/4616).
{ "avatar_url": "https://avatars.githubusercontent.com/u/1330770?v=4", "events_url": "https://api.github.com/users/Stevoisiak/events{/privacy}", "followers_url": "https://api.github.com/users/Stevoisiak/followers", "following_url": "https://api.github.com/users/Stevoisiak/following{/other_user}", "gists_url": "https://api.github.com/users/Stevoisiak/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/Stevoisiak", "id": 1330770, "login": "Stevoisiak", "node_id": "MDQ6VXNlcjEzMzA3NzA=", "organizations_url": "https://api.github.com/users/Stevoisiak/orgs", "received_events_url": "https://api.github.com/users/Stevoisiak/received_events", "repos_url": "https://api.github.com/users/Stevoisiak/repos", "site_admin": false, "starred_url": "https://api.github.com/users/Stevoisiak/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Stevoisiak/subscriptions", "type": "User", "url": "https://api.github.com/users/Stevoisiak", "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/4617/reactions" }
https://api.github.com/repos/psf/requests/issues/4617/timeline
null
completed
null
null
false
[ "Hi @Stevoisiak, thanks for reporting this. We have a solution to address this in #4620.", "@nateprewitt This seems to have fixed Appveyor, but now it looks like [Travis CI builds](https://github.com/requests/requests/pull/4616) may be failing.", "@Stevoisiak, yes, we're aware. This is an issue with the recent ...
https://api.github.com/repos/psf/requests/issues/4616
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4616/labels{/name}
https://api.github.com/repos/psf/requests/issues/4616/comments
https://api.github.com/repos/psf/requests/issues/4616/events
https://github.com/psf/requests/pull/4616
318,460,228
MDExOlB1bGxSZXF1ZXN0MTg0NjYwNTA5
4,616
Add module docstring to __version__.py
{ "avatar_url": "https://avatars.githubusercontent.com/u/1330770?v=4", "events_url": "https://api.github.com/users/Stevoisiak/events{/privacy}", "followers_url": "https://api.github.com/users/Stevoisiak/followers", "following_url": "https://api.github.com/users/Stevoisiak/following{/other_user}", "gists_url": "https://api.github.com/users/Stevoisiak/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/Stevoisiak", "id": 1330770, "login": "Stevoisiak", "node_id": "MDQ6VXNlcjEzMzA3NzA=", "organizations_url": "https://api.github.com/users/Stevoisiak/orgs", "received_events_url": "https://api.github.com/users/Stevoisiak/received_events", "repos_url": "https://api.github.com/users/Stevoisiak/repos", "site_admin": false, "starred_url": "https://api.github.com/users/Stevoisiak/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Stevoisiak/subscriptions", "type": "User", "url": "https://api.github.com/users/Stevoisiak", "user_view_type": "public" }
[]
closed
true
null
[]
null
2
2018-04-27T15:48:46Z
2021-09-02T00:07:42Z
2018-05-23T19:07:08Z
CONTRIBUTOR
resolved
Adds a docstring to `__version__.py`.
{ "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/4616/reactions" }
https://api.github.com/repos/psf/requests/issues/4616/timeline
null
null
false
{ "diff_url": "https://github.com/psf/requests/pull/4616.diff", "html_url": "https://github.com/psf/requests/pull/4616", "merged_at": null, "patch_url": "https://github.com/psf/requests/pull/4616.patch", "url": "https://api.github.com/repos/psf/requests/pulls/4616" }
true
[ "# [Codecov](https://codecov.io/gh/requests/requests/pull/4616?src=pr&el=h1) Report\n> Merging [#4616](https://codecov.io/gh/requests/requests/pull/4616?src=pr&el=desc) into [master](https://codecov.io/gh/requests/requests/commit/fe8290b3d0ca21dd8ae5471a59a8bf13d3dcb31e?src=pr&el=desc) will **decrease** coverage by...
https://api.github.com/repos/psf/requests/issues/4615
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4615/labels{/name}
https://api.github.com/repos/psf/requests/issues/4615/comments
https://api.github.com/repos/psf/requests/issues/4615/events
https://github.com/psf/requests/issues/4615
318,345,069
MDU6SXNzdWUzMTgzNDUwNjk=
4,615
problem with parsing: HTTPSConnectionPool
{ "avatar_url": "https://avatars.githubusercontent.com/u/38782539?v=4", "events_url": "https://api.github.com/users/tomasbaviera/events{/privacy}", "followers_url": "https://api.github.com/users/tomasbaviera/followers", "following_url": "https://api.github.com/users/tomasbaviera/following{/other_user}", "gists_url": "https://api.github.com/users/tomasbaviera/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/tomasbaviera", "id": 38782539, "login": "tomasbaviera", "node_id": "MDQ6VXNlcjM4NzgyNTM5", "organizations_url": "https://api.github.com/users/tomasbaviera/orgs", "received_events_url": "https://api.github.com/users/tomasbaviera/received_events", "repos_url": "https://api.github.com/users/tomasbaviera/repos", "site_admin": false, "starred_url": "https://api.github.com/users/tomasbaviera/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/tomasbaviera/subscriptions", "type": "User", "url": "https://api.github.com/users/tomasbaviera", "user_view_type": "public" }
[]
closed
true
null
[]
null
7
2018-04-27T09:46:02Z
2021-09-08T02:10:06Z
2018-04-28T11:21:48Z
NONE
resolved
I am trying to parse several news webpages. I have no problem with them using requests.get, except with one website: www.redaccionmedica.com. ## Expected Result I would expect that requests.get() worked as expected, with no excepction. ## Actual Result However, this is what really happens when I try to get a webpage from that particular site: ``` Traceback (most recent call last): File "/Users/tomasbaviera/PycharmProjects/Scienceflows/venv/lib/python3.5/site-packages/urllib3/connectionpool.py", line 601, in urlopen chunked=chunked) File "/Users/tomasbaviera/PycharmProjects/Scienceflows/venv/lib/python3.5/site-packages/urllib3/connectionpool.py", line 346, in _make_request self._validate_conn(conn) File "/Users/tomasbaviera/PycharmProjects/Scienceflows/venv/lib/python3.5/site-packages/urllib3/connectionpool.py", line 850, in _validate_conn conn.connect() File "/Users/tomasbaviera/PycharmProjects/Scienceflows/venv/lib/python3.5/site-packages/urllib3/connection.py", line 326, in connect ssl_context=context) File "/Users/tomasbaviera/PycharmProjects/Scienceflows/venv/lib/python3.5/site-packages/urllib3/util/ssl_.py", line 329, 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 "/Users/tomasbaviera/PycharmProjects/Scienceflows/venv/lib/python3.5/site-packages/requests/adapters.py", line 440, in send timeout=timeout File "/Users/tomasbaviera/PycharmProjects/Scienceflows/venv/lib/python3.5/site-packages/urllib3/connectionpool.py", line 639, in urlopen _stacktrace=sys.exc_info()[2]) File "/Users/tomasbaviera/PycharmProjects/Scienceflows/venv/lib/python3.5/site-packages/urllib3/util/retry.py", line 388, in increment raise MaxRetryError(_pool, url, error or ResponseError(cause)) urllib3.exceptions.MaxRetryError: HTTPSConnectionPool(host='www.redaccionmedica.com', port=443): Max retries exceeded with url: /noticia/los-medicos-ven-legitimo-prescribir-homeopatia-pero-solo-si-lo-hacen-ellos-93938 (Caused by SSLError(SSLError(1, '[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/tomasbaviera/PycharmProjects/Scienceflows/prueba_redaccion_medica.py", line 9, in <module> r = requests.get(url) File "/Users/tomasbaviera/PycharmProjects/Scienceflows/venv/lib/python3.5/site-packages/requests/api.py", line 72, in get return request('get', url, params=params, **kwargs) File "/Users/tomasbaviera/PycharmProjects/Scienceflows/venv/lib/python3.5/site-packages/requests/api.py", line 58, in request return session.request(method=method, url=url, **kwargs) File "/Users/tomasbaviera/PycharmProjects/Scienceflows/venv/lib/python3.5/site-packages/requests/sessions.py", line 508, in request resp = self.send(prep, **send_kwargs) File "/Users/tomasbaviera/PycharmProjects/Scienceflows/venv/lib/python3.5/site-packages/requests/sessions.py", line 640, in send history = [resp for resp in gen] if allow_redirects else [] File "/Users/tomasbaviera/PycharmProjects/Scienceflows/venv/lib/python3.5/site-packages/requests/sessions.py", line 640, in <listcomp> history = [resp for resp in gen] if allow_redirects else [] File "/Users/tomasbaviera/PycharmProjects/Scienceflows/venv/lib/python3.5/site-packages/requests/sessions.py", line 218, in resolve_redirects **adapter_kwargs File "/Users/tomasbaviera/PycharmProjects/Scienceflows/venv/lib/python3.5/site-packages/requests/sessions.py", line 618, in send r = adapter.send(request, **kwargs) File "/Users/tomasbaviera/PycharmProjects/Scienceflows/venv/lib/python3.5/site-packages/requests/adapters.py", line 506, in send raise SSLError(e, request=request) requests.exceptions.SSLError: HTTPSConnectionPool(host='www.redaccionmedica.com', port=443): Max retries exceeded with url: /noticia/los-medicos-ven-legitimo-prescribir-homeopatia-pero-solo-si-lo-hacen-ellos-93938 (Caused by SSLError(SSLError(1, '[SSL: SSLV3_ALERT_HANDSHAKE_FAILURE] sslv3 alert handshake failure (_ssl.c:645)'),)) Process finished with exit code 1 ``` ## Reproduction Steps The code executed is this one: ```python import requests url = "http://www.redaccionmedica.com/noticia/los-medicos-ven-legitimo-prescribir-homeopatia-pero-solo-si-lo-hacen-ellos-93938" r = requests.get(url) ``` I have tried also with this other code, but I got the same result: ```python import requests url = "http://www.redaccionmedica.com/noticia/los-medicos-ven-legitimo-prescribir-homeopatia-pero-solo-si-lo-hacen-ellos-93938" r = requests.get(url, Verify=False) ``` ## System Information $ python -m requests.help ``` /usr/bin/python: No module named requests ``` My python version is 2.18.4, and I work with a Mac OSX. Any help would be appreciated very much. Thanks in advance.
{ "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/4615/reactions" }
https://api.github.com/repos/psf/requests/issues/4615/timeline
null
completed
null
null
false
[ "I'm having trouble reproducing this, what version of python are you using? \r\n\r\n```bash\r\npython -m requests.help\r\n```\r\n\r\n```python\r\n{\r\n \"chardet\": {\r\n \"version\": \"3.0.4\"\r\n }, \r\n \"cryptography\": {\r\n \"version\": \"\"\r\n }, \r\n \"idna\": {\r\n \"version\": \"2.6\"\r\n ...
https://api.github.com/repos/psf/requests/issues/4614
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4614/labels{/name}
https://api.github.com/repos/psf/requests/issues/4614/comments
https://api.github.com/repos/psf/requests/issues/4614/events
https://github.com/psf/requests/issues/4614
318,151,091
MDU6SXNzdWUzMTgxNTEwOTE=
4,614
AttribueError at iter_content
{ "avatar_url": "https://avatars.githubusercontent.com/u/5700057?v=4", "events_url": "https://api.github.com/users/andrewshokhin/events{/privacy}", "followers_url": "https://api.github.com/users/andrewshokhin/followers", "following_url": "https://api.github.com/users/andrewshokhin/following{/other_user}", "gists_url": "https://api.github.com/users/andrewshokhin/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/andrewshokhin", "id": 5700057, "login": "andrewshokhin", "node_id": "MDQ6VXNlcjU3MDAwNTc=", "organizations_url": "https://api.github.com/users/andrewshokhin/orgs", "received_events_url": "https://api.github.com/users/andrewshokhin/received_events", "repos_url": "https://api.github.com/users/andrewshokhin/repos", "site_admin": false, "starred_url": "https://api.github.com/users/andrewshokhin/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/andrewshokhin/subscriptions", "type": "User", "url": "https://api.github.com/users/andrewshokhin", "user_view_type": "public" }
[ { "color": "fef2c0", "default": false, "description": null, "id": 298537994, "name": "Needs More Information", "node_id": "MDU6TGFiZWwyOTg1Mzc5OTQ=", "url": "https://api.github.com/repos/psf/requests/labels/Needs%20More%20Information" } ]
closed
true
null
[]
null
5
2018-04-26T18:40:59Z
2021-09-08T02:10:03Z
2018-05-05T23:40:39Z
NONE
resolved
I don't know who to blame (requests or urllib3), but though you guys can be interested: ``` Python 3.6.4 (v3.6.4:d48ecebad5, Dec 18 2017, 21:07:28) [GCC 4.2.1 (Apple Inc. build 5666) (dot 3)] on darwin Type "help", "copyright", "credits" or "license" for more information. >>> import requests >>> requests.get('http://imodules.com/') DEBUG:urllib3.connectionpool:Starting new HTTP connection (1): imodules.com DEBUG:urllib3.connectionpool:http://imodules.com:80 "GET / HTTP/1.1" 301 0 DEBUG:urllib3.connectionpool:Starting new HTTP connection (1): www.imodules.com DEBUG:urllib3.connectionpool:http://www.imodules.com:80 "GET / HTTP/1.1" 302 None Traceback (most recent call last): File "<stdin>", line 1, in <module> File "/Users/ashokhin/.venv/adstxt/lib/python3.6/site-packages/requests/api.py", line 72, in get return request('get', url, params=params, **kwargs) File "/Users/ashokhin/.venv/adstxt/lib/python3.6/site-packages/requests/api.py", line 58, in request return session.request(method=method, url=url, **kwargs) File "/Users/ashokhin/.venv/adstxt/lib/python3.6/site-packages/requests/sessions.py", line 508, in request resp = self.send(prep, **send_kwargs) File "/Users/ashokhin/.venv/adstxt/lib/python3.6/site-packages/requests/sessions.py", line 640, in send history = [resp for resp in gen] if allow_redirects else [] File "/Users/ashokhin/.venv/adstxt/lib/python3.6/site-packages/requests/sessions.py", line 640, in <listcomp> history = [resp for resp in gen] if allow_redirects else [] File "/Users/ashokhin/.venv/adstxt/lib/python3.6/site-packages/requests/sessions.py", line 218, in resolve_redirects **adapter_kwargs File "/Users/ashokhin/.venv/adstxt/lib/python3.6/site-packages/requests/sessions.py", line 658, in send r.content File "/Users/ashokhin/.venv/adstxt/lib/python3.6/site-packages/requests/models.py", line 823, in content self._content = bytes().join(self.iter_content(CONTENT_CHUNK_SIZE)) or bytes() File "/Users/ashokhin/.venv/adstxt/lib/python3.6/site-packages/requests/models.py", line 745, in generate for chunk in self.raw.stream(chunk_size, decode_content=True): File "/Users/ashokhin/.venv/adstxt/lib/python3.6/site-packages/urllib3/response.py", line 432, in stream for line in self.read_chunked(amt, decode_content=decode_content): File "/Users/ashokhin/.venv/adstxt/lib/python3.6/site-packages/urllib3/response.py", line 598, in read_chunked self._update_chunk_length() File "/Users/ashokhin/.venv/adstxt/lib/python3.6/site-packages/urllib3/response.py", line 540, in _update_chunk_length line = self._fp.fp.readline() AttributeError: 'NoneType' object has no attribute 'readline' ``` $ python -m requests.help ``` { "chardet": { "version": "3.0.4" }, "cryptography": { "version": "" }, "idna": { "version": "2.6" }, "implementation": { "name": "CPython", "version": "3.6.4" }, "platform": { "release": "17.5.0", "system": "Darwin" }, "pyOpenSSL": { "openssl_version": "", "version": null }, "requests": { "version": "2.18.4" }, "system_ssl": { "version": "100020df" }, "urllib3": { "version": "1.22" }, "using_pyopenssl": false } ```
{ "avatar_url": "https://avatars.githubusercontent.com/u/5271761?v=4", "events_url": "https://api.github.com/users/nateprewitt/events{/privacy}", "followers_url": "https://api.github.com/users/nateprewitt/followers", "following_url": "https://api.github.com/users/nateprewitt/following{/other_user}", "gists_url": "https://api.github.com/users/nateprewitt/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/nateprewitt", "id": 5271761, "login": "nateprewitt", "node_id": "MDQ6VXNlcjUyNzE3NjE=", "organizations_url": "https://api.github.com/users/nateprewitt/orgs", "received_events_url": "https://api.github.com/users/nateprewitt/received_events", "repos_url": "https://api.github.com/users/nateprewitt/repos", "site_admin": false, "starred_url": "https://api.github.com/users/nateprewitt/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/nateprewitt/subscriptions", "type": "User", "url": "https://api.github.com/users/nateprewitt", "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/4614/reactions" }
https://api.github.com/repos/psf/requests/issues/4614/timeline
null
completed
null
null
false
[ "This issue is occurring when the redirects are being followed. Entering `https://www.imodules.com` works fine.", "@colinfike, this occurs when the underlying connection in urllib3 has been closed but the Request objects content field hasn’t been populated correctly.\r\n\r\nYou can find a couple similar issues th...
https://api.github.com/repos/psf/requests/issues/4613
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4613/labels{/name}
https://api.github.com/repos/psf/requests/issues/4613/comments
https://api.github.com/repos/psf/requests/issues/4613/events
https://github.com/psf/requests/issues/4613
318,065,875
MDU6SXNzdWUzMTgwNjU4NzU=
4,613
Proxies from environment parsing problem
{ "avatar_url": "https://avatars.githubusercontent.com/u/8102549?v=4", "events_url": "https://api.github.com/users/pbelskiy/events{/privacy}", "followers_url": "https://api.github.com/users/pbelskiy/followers", "following_url": "https://api.github.com/users/pbelskiy/following{/other_user}", "gists_url": "https://api.github.com/users/pbelskiy/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/pbelskiy", "id": 8102549, "login": "pbelskiy", "node_id": "MDQ6VXNlcjgxMDI1NDk=", "organizations_url": "https://api.github.com/users/pbelskiy/orgs", "received_events_url": "https://api.github.com/users/pbelskiy/received_events", "repos_url": "https://api.github.com/users/pbelskiy/repos", "site_admin": false, "starred_url": "https://api.github.com/users/pbelskiy/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/pbelskiy/subscriptions", "type": "User", "url": "https://api.github.com/users/pbelskiy", "user_view_type": "public" }
[]
closed
true
null
[]
null
5
2018-04-26T14:53:13Z
2021-08-31T00:07:02Z
2020-04-27T15:40:50Z
NONE
resolved
Hello, I've faced with a stupid problem, in my Ubuntu 16.04 in `/etc/environment` I wrote http proxy with end with one invisible space char at the end: `http_proxy=http://1.2.3.4:8080 `,and of course I didn't notice it when I just copy past proxies for my machines. And then when I used `requests.get()` I get a strange error: ``` Traceback (most recent call last): File "./t.py", line 5, in <module> x = requests.get("http://test/api") File "/usr/local/lib/python3.6/site-packages/requests/api.py", line 72, in get return request('get', url, params=params, **kwargs) File "/usr/local/lib/python3.6/site-packages/requests/api.py", line 58, in request return session.request(method=method, url=url, **kwargs) File "/usr/local/lib/python3.6/site-packages/requests/sessions.py", line 508, in request resp = self.send(prep, **send_kwargs) File "/usr/local/lib/python3.6/site-packages/requests/sessions.py", line 618, in send r = adapter.send(request, **kwargs) File "/usr/local/lib/python3.6/site-packages/requests/adapters.py", line 405, in send conn = self.get_connection(request.url, proxies) File "/usr/local/lib/python3.6/site-packages/requests/adapters.py", line 303, in get_connection proxy_manager = self.proxy_manager_for(proxy) File "/usr/local/lib/python3.6/site-packages/requests/adapters.py", line 197, in proxy_manager_for **proxy_kwargs) File "/usr/local/lib/python3.6/site-packages/urllib3/poolmanager.py", line 440, in proxy_from_url return ProxyManager(proxy_url=url, **kw) File "/usr/local/lib/python3.6/site-packages/urllib3/poolmanager.py", line 385, in __init__ proxy = parse_url(proxy_url) File "/usr/local/lib/python3.6/site-packages/urllib3/util/url.py", line 199, in parse_url raise LocationParseError(url) urllib3.exceptions.LocationParseError: Failed to parse: 1.2.3.4:8080 ``` And then I found out that problem with `getproxies()` from `urllib` which used by `requests` for getting proxies. **Maybe we can just `strip()` each proxy string? It will be conveniently.** ## Expected Result {'http': 'http://1.2.3.4:8080'} ## Actual Result {'http': 'http://1.2.3.4:8080 '} I got the string which ends with one space ## Reproduction Steps See above ## System Information ``` { "chardet": { "version": "3.0.4" }, "cryptography": { "version": "" }, "idna": { "version": "2.6" }, "implementation": { "name": "CPython", "version": "3.6.2" }, "platform": { "release": "4.4.0-112-generic", "system": "Linux" }, "pyOpenSSL": { "openssl_version": "", "version": null }, "requests": { "version": "2.18.4" }, "system_ssl": { "version": "1000207f" }, "urllib3": { "version": "1.22" }, "using_pyopenssl": false } ```
{ "avatar_url": "https://avatars.githubusercontent.com/u/8102549?v=4", "events_url": "https://api.github.com/users/pbelskiy/events{/privacy}", "followers_url": "https://api.github.com/users/pbelskiy/followers", "following_url": "https://api.github.com/users/pbelskiy/following{/other_user}", "gists_url": "https://api.github.com/users/pbelskiy/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/pbelskiy", "id": 8102549, "login": "pbelskiy", "node_id": "MDQ6VXNlcjgxMDI1NDk=", "organizations_url": "https://api.github.com/users/pbelskiy/orgs", "received_events_url": "https://api.github.com/users/pbelskiy/received_events", "repos_url": "https://api.github.com/users/pbelskiy/repos", "site_admin": false, "starred_url": "https://api.github.com/users/pbelskiy/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/pbelskiy/subscriptions", "type": "User", "url": "https://api.github.com/users/pbelskiy", "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/4613/reactions" }
https://api.github.com/repos/psf/requests/issues/4613/timeline
null
completed
null
null
false
[ "Hi @th3mis, it does look like we could be a bit more tolerant of bad input here. We don't actually do much with the proxies dictionary before sending it, unless we preform a redirect. It might be possible to add some cleaning to what we're passed in the `send` function, but we want to make sure not to modify what ...
https://api.github.com/repos/psf/requests/issues/4612
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4612/labels{/name}
https://api.github.com/repos/psf/requests/issues/4612/comments
https://api.github.com/repos/psf/requests/issues/4612/events
https://github.com/psf/requests/pull/4612
318,045,302
MDExOlB1bGxSZXF1ZXN0MTg0MzUxNzg3
4,612
update json param's description to avoid confusion
{ "avatar_url": "https://avatars.githubusercontent.com/u/2292121?v=4", "events_url": "https://api.github.com/users/Obeyed/events{/privacy}", "followers_url": "https://api.github.com/users/Obeyed/followers", "following_url": "https://api.github.com/users/Obeyed/following{/other_user}", "gists_url": "https://api.github.com/users/Obeyed/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/Obeyed", "id": 2292121, "login": "Obeyed", "node_id": "MDQ6VXNlcjIyOTIxMjE=", "organizations_url": "https://api.github.com/users/Obeyed/orgs", "received_events_url": "https://api.github.com/users/Obeyed/received_events", "repos_url": "https://api.github.com/users/Obeyed/repos", "site_admin": false, "starred_url": "https://api.github.com/users/Obeyed/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Obeyed/subscriptions", "type": "User", "url": "https://api.github.com/users/Obeyed", "user_view_type": "public" }
[]
closed
true
null
[]
null
5
2018-04-26T14:05:23Z
2021-09-03T00:11:02Z
2018-04-30T15:00:20Z
CONTRIBUTOR
resolved
- the Request class doesn't accept JSON, but a JSON serializable object
{ "avatar_url": "https://avatars.githubusercontent.com/u/5271761?v=4", "events_url": "https://api.github.com/users/nateprewitt/events{/privacy}", "followers_url": "https://api.github.com/users/nateprewitt/followers", "following_url": "https://api.github.com/users/nateprewitt/following{/other_user}", "gists_url": "https://api.github.com/users/nateprewitt/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/nateprewitt", "id": 5271761, "login": "nateprewitt", "node_id": "MDQ6VXNlcjUyNzE3NjE=", "organizations_url": "https://api.github.com/users/nateprewitt/orgs", "received_events_url": "https://api.github.com/users/nateprewitt/received_events", "repos_url": "https://api.github.com/users/nateprewitt/repos", "site_admin": false, "starred_url": "https://api.github.com/users/nateprewitt/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/nateprewitt/subscriptions", "type": "User", "url": "https://api.github.com/users/nateprewitt", "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/4612/reactions" }
https://api.github.com/repos/psf/requests/issues/4612/timeline
null
null
false
{ "diff_url": "https://github.com/psf/requests/pull/4612.diff", "html_url": "https://github.com/psf/requests/pull/4612", "merged_at": "2018-04-30T15:00:20Z", "patch_url": "https://github.com/psf/requests/pull/4612.patch", "url": "https://api.github.com/repos/psf/requests/pulls/4612" }
true
[ "Closing and re-opening to trigger a rebuild on AppVeyor", "# [Codecov](https://codecov.io/gh/requests/requests/pull/4612?src=pr&el=h1) Report\n> Merging [#4612](https://codecov.io/gh/requests/requests/pull/4612?src=pr&el=desc) into [master](https://codecov.io/gh/requests/requests/commit/2de907ad778de270911acaffe...
https://api.github.com/repos/psf/requests/issues/4611
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4611/labels{/name}
https://api.github.com/repos/psf/requests/issues/4611/comments
https://api.github.com/repos/psf/requests/issues/4611/events
https://github.com/psf/requests/issues/4611
317,683,867
MDU6SXNzdWUzMTc2ODM4Njc=
4,611
Global timeout?
{ "avatar_url": "https://avatars.githubusercontent.com/u/37349562?v=4", "events_url": "https://api.github.com/users/vuiiscci/events{/privacy}", "followers_url": "https://api.github.com/users/vuiiscci/followers", "following_url": "https://api.github.com/users/vuiiscci/following{/other_user}", "gists_url": "https://api.github.com/users/vuiiscci/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/vuiiscci", "id": 37349562, "login": "vuiiscci", "node_id": "MDQ6VXNlcjM3MzQ5NTYy", "organizations_url": "https://api.github.com/users/vuiiscci/orgs", "received_events_url": "https://api.github.com/users/vuiiscci/received_events", "repos_url": "https://api.github.com/users/vuiiscci/repos", "site_admin": false, "starred_url": "https://api.github.com/users/vuiiscci/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/vuiiscci/subscriptions", "type": "User", "url": "https://api.github.com/users/vuiiscci", "user_view_type": "public" }
[]
closed
true
null
[]
null
1
2018-04-25T15:38:36Z
2021-09-08T02:10:07Z
2018-04-25T22:51:41Z
NONE
resolved
Is there a way to set a global timeout? Googling/stackoverflow resulted in hacky patches. I was wondering if this is a feature now?
{ "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/4611/reactions" }
https://api.github.com/repos/psf/requests/issues/4611/timeline
null
completed
null
null
false
[ "It is not." ]
https://api.github.com/repos/psf/requests/issues/4610
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4610/labels{/name}
https://api.github.com/repos/psf/requests/issues/4610/comments
https://api.github.com/repos/psf/requests/issues/4610/events
https://github.com/psf/requests/issues/4610
317,649,911
MDU6SXNzdWUzMTc2NDk5MTE=
4,610
HTTPSConnectionPool(host='www.google.com', port=443): Read timed out. (read timeout=None)
{ "avatar_url": "https://avatars.githubusercontent.com/u/939594?v=4", "events_url": "https://api.github.com/users/allmoney/events{/privacy}", "followers_url": "https://api.github.com/users/allmoney/followers", "following_url": "https://api.github.com/users/allmoney/following{/other_user}", "gists_url": "https://api.github.com/users/allmoney/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/allmoney", "id": 939594, "login": "allmoney", "node_id": "MDQ6VXNlcjkzOTU5NA==", "organizations_url": "https://api.github.com/users/allmoney/orgs", "received_events_url": "https://api.github.com/users/allmoney/received_events", "repos_url": "https://api.github.com/users/allmoney/repos", "site_admin": false, "starred_url": "https://api.github.com/users/allmoney/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/allmoney/subscriptions", "type": "User", "url": "https://api.github.com/users/allmoney", "user_view_type": "public" }
[]
closed
true
null
[]
null
2
2018-04-25T14:20:16Z
2018-11-08T13:59:22Z
2018-04-25T14:31:35Z
NONE
resolved
See this error in Logs. I have no proxy, VPN. Direct Internet. ## Expected Result No errors ## Actual Result Log Details (ERROR) Wed Apr 25 2018 17:13:39 GMT+0300 (RTZ 2 (зима)) Error doing job: Future exception was never retrieved Traceback (most recent call last): File "/usr/lib/python3.6/site-packages/urllib3/connectionpool.py", line 387, in _make_request six.raise_from(e, None) File "<string>", line 2, in raise_from File "/usr/lib/python3.6/site-packages/urllib3/connectionpool.py", line 383, in _make_request httplib_response = conn.getresponse() File "/usr/lib/python3.6/http/client.py", line 1331, in getresponse response.begin() File "/usr/lib/python3.6/http/client.py", line 297, in begin version, status, reason = self._read_status() File "/usr/lib/python3.6/http/client.py", line 258, in _read_status line = str(self.fp.readline(_MAXLINE + 1), "iso-8859-1") File "/usr/lib/python3.6/socket.py", line 586, in readinto return self._sock.recv_into(b) File "/usr/lib/python3.6/ssl.py", line 1009, in recv_into return self.read(nbytes, buffer) File "/usr/lib/python3.6/ssl.py", line 871, in read return self._sslobj.read(len, buffer) File "/usr/lib/python3.6/ssl.py", line 631, in read v = self._sslobj.read(len, buffer) TimeoutError: [Errno 110] Operation timed out During handling of the above exception, another exception occurred: Traceback (most recent call last): File "/usr/lib/python3.6/site-packages/requests/adapters.py", line 440, in send timeout=timeout File "/usr/lib/python3.6/site-packages/urllib3/connectionpool.py", line 639, in urlopen _stacktrace=sys.exc_info()[2]) File "/usr/lib/python3.6/site-packages/urllib3/util/retry.py", line 357, in increment raise six.reraise(type(error), error, _stacktrace) File "/usr/lib/python3.6/site-packages/urllib3/packages/six.py", line 686, in reraise raise value File "/usr/lib/python3.6/site-packages/urllib3/connectionpool.py", line 601, in urlopen chunked=chunked) File "/usr/lib/python3.6/site-packages/urllib3/connectionpool.py", line 389, in _make_request self._raise_timeout(err=e, url=url, timeout_value=read_timeout) File "/usr/lib/python3.6/site-packages/urllib3/connectionpool.py", line 320, in _raise_timeout raise ReadTimeoutError(self, url, "Read timed out. (read timeout=%s)" % timeout_value) urllib3.exceptions.ReadTimeoutError: HTTPSConnectionPool(host='www.google.com', port=443): Read timed out. (read timeout=None) During handling of the above exception, another exception occurred: Traceback (most recent call last): File "/usr/lib/python3.6/concurrent/futures/thread.py", line 56, in run result = self.fn(*self.args, **self.kwargs) File "/usr/lib/python3.6/site-packages/homeassistant/components/device_tracker/google_maps.py", line 67, in _update_info for person in self.service.get_all_people(): File "/usr/lib/python3.6/site-packages/locationsharinglib/locationsharinglib.py", line 292, in get_all_people return self._get_data() File "/usr/lib/python3.6/site-packages/cachetools/__init__.py", line 46, in wrapper v = func(*args, **kwargs) File "/usr/lib/python3.6/site-packages/locationsharinglib/locationsharinglib.py", line 281, in _get_data response = self._session.get(url, params=payload) File "/usr/lib/python3.6/site-packages/requests/sessions.py", line 521, in get return self.request('GET', url, **kwargs) File "/usr/lib/python3.6/site-packages/requests/sessions.py", line 508, in request resp = self.send(prep, **send_kwargs) File "/usr/lib/python3.6/site-packages/requests/sessions.py", line 618, in send r = adapter.send(request, **kwargs) File "/usr/lib/python3.6/site-packages/requests/adapters.py", line 521, in send raise ReadTimeout(e, request=request) requests.exceptions.ReadTimeout: HTTPSConnectionPool(host='www.google.com', port=443): Read timed out. (read timeout=None) ## Reproduction Steps ```python import requests ``` ## System Information Home Assistant 0.67.1
{ "avatar_url": "https://avatars.githubusercontent.com/u/5271761?v=4", "events_url": "https://api.github.com/users/nateprewitt/events{/privacy}", "followers_url": "https://api.github.com/users/nateprewitt/followers", "following_url": "https://api.github.com/users/nateprewitt/following{/other_user}", "gists_url": "https://api.github.com/users/nateprewitt/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/nateprewitt", "id": 5271761, "login": "nateprewitt", "node_id": "MDQ6VXNlcjUyNzE3NjE=", "organizations_url": "https://api.github.com/users/nateprewitt/orgs", "received_events_url": "https://api.github.com/users/nateprewitt/received_events", "repos_url": "https://api.github.com/users/nateprewitt/repos", "site_admin": false, "starred_url": "https://api.github.com/users/nateprewitt/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/nateprewitt/subscriptions", "type": "User", "url": "https://api.github.com/users/nateprewitt", "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/4610/reactions" }
https://api.github.com/repos/psf/requests/issues/4610/timeline
null
completed
null
null
false
[ "Hi @allmoney, google isn’t responding in time which is why you’re getting a timeout. If you’re positive you’re not behind a vpn or proxy, I’d suggest following up with HomeAssitant first. There isn’t anything here that suggests a defect in Requests.", "I met the question too, can you tell us how to solve this pr...
https://api.github.com/repos/psf/requests/issues/4609
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4609/labels{/name}
https://api.github.com/repos/psf/requests/issues/4609/comments
https://api.github.com/repos/psf/requests/issues/4609/events
https://github.com/psf/requests/pull/4609
317,159,690
MDExOlB1bGxSZXF1ZXN0MTgzNjg2MTY2
4,609
Fix handling of zero-length files
{ "avatar_url": "https://avatars.githubusercontent.com/u/3186654?v=4", "events_url": "https://api.github.com/users/mschmitzer/events{/privacy}", "followers_url": "https://api.github.com/users/mschmitzer/followers", "following_url": "https://api.github.com/users/mschmitzer/following{/other_user}", "gists_url": "https://api.github.com/users/mschmitzer/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/mschmitzer", "id": 3186654, "login": "mschmitzer", "node_id": "MDQ6VXNlcjMxODY2NTQ=", "organizations_url": "https://api.github.com/users/mschmitzer/orgs", "received_events_url": "https://api.github.com/users/mschmitzer/received_events", "repos_url": "https://api.github.com/users/mschmitzer/repos", "site_admin": false, "starred_url": "https://api.github.com/users/mschmitzer/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/mschmitzer/subscriptions", "type": "User", "url": "https://api.github.com/users/mschmitzer", "user_view_type": "public" }
[]
closed
true
null
[]
null
7
2018-04-24T10:13:17Z
2021-09-03T00:11:04Z
2018-04-24T13:59:07Z
NONE
resolved
This was previously fixed in e7c9bbb96 and broken again in 4c82dbab6fc. Add a comment this time to prevent people from breaking it again.
{ "avatar_url": "https://avatars.githubusercontent.com/u/5271761?v=4", "events_url": "https://api.github.com/users/nateprewitt/events{/privacy}", "followers_url": "https://api.github.com/users/nateprewitt/followers", "following_url": "https://api.github.com/users/nateprewitt/following{/other_user}", "gists_url": "https://api.github.com/users/nateprewitt/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/nateprewitt", "id": 5271761, "login": "nateprewitt", "node_id": "MDQ6VXNlcjUyNzE3NjE=", "organizations_url": "https://api.github.com/users/nateprewitt/orgs", "received_events_url": "https://api.github.com/users/nateprewitt/received_events", "repos_url": "https://api.github.com/users/nateprewitt/repos", "site_admin": false, "starred_url": "https://api.github.com/users/nateprewitt/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/nateprewitt/subscriptions", "type": "User", "url": "https://api.github.com/users/nateprewitt", "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/4609/reactions" }
https://api.github.com/repos/psf/requests/issues/4609/timeline
null
null
false
{ "diff_url": "https://github.com/psf/requests/pull/4609.diff", "html_url": "https://github.com/psf/requests/pull/4609", "merged_at": null, "patch_url": "https://github.com/psf/requests/pull/4609.patch", "url": "https://api.github.com/repos/psf/requests/pulls/4609" }
true
[ "Ok, this actually runs afoul of some tests. Interesting.", "Hi @MarcSchmitzer, we use content-length of 0 internally to represent data of indeterminate size. This is sent using `Transfer-Encoding: chunked`. It's advised you don't provide a Content-Length when using Requests, since it should always be handled int...
https://api.github.com/repos/psf/requests/issues/4608
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4608/labels{/name}
https://api.github.com/repos/psf/requests/issues/4608/comments
https://api.github.com/repos/psf/requests/issues/4608/events
https://github.com/psf/requests/issues/4608
316,642,895
MDU6SXNzdWUzMTY2NDI4OTU=
4,608
When POST , A dictionary type data will auto urlencode
{ "avatar_url": "https://avatars.githubusercontent.com/u/18510780?v=4", "events_url": "https://api.github.com/users/FuckTheLife/events{/privacy}", "followers_url": "https://api.github.com/users/FuckTheLife/followers", "following_url": "https://api.github.com/users/FuckTheLife/following{/other_user}", "gists_url": "https://api.github.com/users/FuckTheLife/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/FuckTheLife", "id": 18510780, "login": "FuckTheLife", "node_id": "MDQ6VXNlcjE4NTEwNzgw", "organizations_url": "https://api.github.com/users/FuckTheLife/orgs", "received_events_url": "https://api.github.com/users/FuckTheLife/received_events", "repos_url": "https://api.github.com/users/FuckTheLife/repos", "site_admin": false, "starred_url": "https://api.github.com/users/FuckTheLife/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/FuckTheLife/subscriptions", "type": "User", "url": "https://api.github.com/users/FuckTheLife", "user_view_type": "public" }
[]
closed
true
null
[]
null
2
2018-04-23T02:40:46Z
2021-09-08T02:10:08Z
2018-04-23T06:20:29Z
NONE
resolved
Summary. ## When the POST data is a dictionary type Requests will aoto URLencode it. For example : ``` postdata = { "url" : "https%3A%2f%2fwww.google.com" } ``` ## Actual Result When my post data have URLencoded data what include URL . The actual post data is ``` url=https%253A%252f%252fwww.google.com ``` ## Search source code models.py ```python def _encode_params(data): """Encode parameters in a piece of data. Will successfully encode parameters when passed as a dict or a list of 2-tuples. Order is retained if data is a list of 2-tuples but arbitrary if parameters are supplied as a dict. """ if isinstance(data, (str, bytes)): return data elif hasattr(data, 'read'): return data elif hasattr(data, '__iter__'): result = [] for k, vs in to_key_val_list(data): if isinstance(vs, basestring) or not hasattr(vs, '__iter__'): vs = [vs] for v in vs: if v is not None: result.append( (k.encode('utf-8') if isinstance(k, str) else k, v.encode('utf-8') if isinstance(v, str) else v)) return urlencode(result, doseq=True) else: return data ```
{ "avatar_url": "https://avatars.githubusercontent.com/u/5271761?v=4", "events_url": "https://api.github.com/users/nateprewitt/events{/privacy}", "followers_url": "https://api.github.com/users/nateprewitt/followers", "following_url": "https://api.github.com/users/nateprewitt/following{/other_user}", "gists_url": "https://api.github.com/users/nateprewitt/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/nateprewitt", "id": 5271761, "login": "nateprewitt", "node_id": "MDQ6VXNlcjUyNzE3NjE=", "organizations_url": "https://api.github.com/users/nateprewitt/orgs", "received_events_url": "https://api.github.com/users/nateprewitt/received_events", "repos_url": "https://api.github.com/users/nateprewitt/repos", "site_admin": false, "starred_url": "https://api.github.com/users/nateprewitt/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/nateprewitt/subscriptions", "type": "User", "url": "https://api.github.com/users/nateprewitt", "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/4608/reactions" }
https://api.github.com/repos/psf/requests/issues/4608/timeline
null
completed
null
null
false
[ "Hi @FuckTheLife, the default functionality of Requests is to treat dictionaries passed to the `data` param as multi-part form data which will end up urlencoded. This is what you’re seeing here and what we’d expect. I would suggest either passing strings that aren’t pre-escaped or making a string representation of ...
https://api.github.com/repos/psf/requests/issues/4607
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4607/labels{/name}
https://api.github.com/repos/psf/requests/issues/4607/comments
https://api.github.com/repos/psf/requests/issues/4607/events
https://github.com/psf/requests/issues/4607
316,605,856
MDU6SXNzdWUzMTY2MDU4NTY=
4,607
Unable to install tensorflow
{ "avatar_url": "https://avatars.githubusercontent.com/u/23218848?v=4", "events_url": "https://api.github.com/users/dafinest/events{/privacy}", "followers_url": "https://api.github.com/users/dafinest/followers", "following_url": "https://api.github.com/users/dafinest/following{/other_user}", "gists_url": "https://api.github.com/users/dafinest/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/dafinest", "id": 23218848, "login": "dafinest", "node_id": "MDQ6VXNlcjIzMjE4ODQ4", "organizations_url": "https://api.github.com/users/dafinest/orgs", "received_events_url": "https://api.github.com/users/dafinest/received_events", "repos_url": "https://api.github.com/users/dafinest/repos", "site_admin": false, "starred_url": "https://api.github.com/users/dafinest/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/dafinest/subscriptions", "type": "User", "url": "https://api.github.com/users/dafinest", "user_view_type": "public" }
[ { "color": "f7c6c7", "default": false, "description": null, "id": 167537670, "name": "Propose Close", "node_id": "MDU6TGFiZWwxNjc1Mzc2NzA=", "url": "https://api.github.com/repos/psf/requests/labels/Propose%20Close" } ]
closed
true
null
[]
null
4
2018-04-22T19:25:57Z
2021-09-08T02:10:07Z
2018-04-23T17:06:31Z
NONE
resolved
Summary. ## Expected Result What you expected. ## Actual Result What happened instead. ## Reproduction Steps ```python import requests ``` ## System Information $ python -m requests.help ``` <paste here> ``` This command is only available on Requests v2.16.4 and greater. Otherwise, please provide some basic information about your system (Python version, operating system, &c).
{ "avatar_url": "https://avatars.githubusercontent.com/u/5271761?v=4", "events_url": "https://api.github.com/users/nateprewitt/events{/privacy}", "followers_url": "https://api.github.com/users/nateprewitt/followers", "following_url": "https://api.github.com/users/nateprewitt/following{/other_user}", "gists_url": "https://api.github.com/users/nateprewitt/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/nateprewitt", "id": 5271761, "login": "nateprewitt", "node_id": "MDQ6VXNlcjUyNzE3NjE=", "organizations_url": "https://api.github.com/users/nateprewitt/orgs", "received_events_url": "https://api.github.com/users/nateprewitt/received_events", "repos_url": "https://api.github.com/users/nateprewitt/repos", "site_admin": false, "starred_url": "https://api.github.com/users/nateprewitt/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/nateprewitt/subscriptions", "type": "User", "url": "https://api.github.com/users/nateprewitt", "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/4607/reactions" }
https://api.github.com/repos/psf/requests/issues/4607/timeline
null
completed
null
null
false
[ "pip install tensorflow\r\nCollecting tensorflow\r\n Retrying (Retry(total=4, connect=None, read=None, redirect=None)) after connection broken by 'ProxyError('Cannot connect to proxy.', NewConnectionError('<pip._vendor.requests.packages.urllib3.connection.VerifiedHTTPSConnection object at 0x000001B1FCB5A160>: Fail...
https://api.github.com/repos/psf/requests/issues/4606
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4606/labels{/name}
https://api.github.com/repos/psf/requests/issues/4606/comments
https://api.github.com/repos/psf/requests/issues/4606/events
https://github.com/psf/requests/pull/4606
316,602,922
MDExOlB1bGxSZXF1ZXN0MTgzMjg3Nzc0
4,606
Create requests
{ "avatar_url": "https://avatars.githubusercontent.com/u/38631692?v=4", "events_url": "https://api.github.com/users/nivek444/events{/privacy}", "followers_url": "https://api.github.com/users/nivek444/followers", "following_url": "https://api.github.com/users/nivek444/following{/other_user}", "gists_url": "https://api.github.com/users/nivek444/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/nivek444", "id": 38631692, "login": "nivek444", "node_id": "MDQ6VXNlcjM4NjMxNjky", "organizations_url": "https://api.github.com/users/nivek444/orgs", "received_events_url": "https://api.github.com/users/nivek444/received_events", "repos_url": "https://api.github.com/users/nivek444/repos", "site_admin": false, "starred_url": "https://api.github.com/users/nivek444/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/nivek444/subscriptions", "type": "User", "url": "https://api.github.com/users/nivek444", "user_view_type": "public" }
[]
closed
true
null
[]
null
0
2018-04-22T18:46:28Z
2021-09-03T00:11:04Z
2018-04-22T19:15:35Z
NONE
resolved
asdas
{ "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/4606/reactions" }
https://api.github.com/repos/psf/requests/issues/4606/timeline
null
null
false
{ "diff_url": "https://github.com/psf/requests/pull/4606.diff", "html_url": "https://github.com/psf/requests/pull/4606", "merged_at": null, "patch_url": "https://github.com/psf/requests/pull/4606.patch", "url": "https://api.github.com/repos/psf/requests/pulls/4606" }
true
[]
https://api.github.com/repos/psf/requests/issues/4605
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4605/labels{/name}
https://api.github.com/repos/psf/requests/issues/4605/comments
https://api.github.com/repos/psf/requests/issues/4605/events
https://github.com/psf/requests/issues/4605
316,560,059
MDU6SXNzdWUzMTY1NjAwNTk=
4,605
Request freezes when doing 'r.text'
{ "avatar_url": "https://avatars.githubusercontent.com/u/8395443?v=4", "events_url": "https://api.github.com/users/PuneetKohli/events{/privacy}", "followers_url": "https://api.github.com/users/PuneetKohli/followers", "following_url": "https://api.github.com/users/PuneetKohli/following{/other_user}", "gists_url": "https://api.github.com/users/PuneetKohli/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/PuneetKohli", "id": 8395443, "login": "PuneetKohli", "node_id": "MDQ6VXNlcjgzOTU0NDM=", "organizations_url": "https://api.github.com/users/PuneetKohli/orgs", "received_events_url": "https://api.github.com/users/PuneetKohli/received_events", "repos_url": "https://api.github.com/users/PuneetKohli/repos", "site_admin": false, "starred_url": "https://api.github.com/users/PuneetKohli/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/PuneetKohli/subscriptions", "type": "User", "url": "https://api.github.com/users/PuneetKohli", "user_view_type": "public" }
[ { "color": "fef2c0", "default": false, "description": null, "id": 298537994, "name": "Needs More Information", "node_id": "MDU6TGFiZWwyOTg1Mzc5OTQ=", "url": "https://api.github.com/repos/psf/requests/labels/Needs%20More%20Information" } ]
closed
true
null
[]
null
7
2018-04-22T08:27:27Z
2021-09-08T02:09:59Z
2018-05-13T13:13:20Z
NONE
resolved
Summary. I am trying to use Requests to access a URL. This URL requires certain headers, and values in the cookies. I am able to access the URL fine using Hurl.it/Postman but when using Requests, my laptop freezes up and all my RAM is eaten when I do r.text, r.json() or r.content ## Expected Result Print out the content of the returned HTML page ## Actual Result Laptop Freezes - all RAM used up, need to shutdown Jupyter notebook ## Reproduction Steps ```python import requests url = "http://www.asinlab.com/php/convertfromasin.php?asin_num=B006OC2ANS,B00HWD2OE8,B00J06HWC4,B00CH87HF4,B00B7ERH04&id_type=UPC&bulk=true&x=false" header = {} cookie = {} header["Accept"] = "text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,image/apng,*/*;q=0.8" header["Accept-Encoding"] = "gzip, deflate" header["Accept-Language"] = "en-US,en;q=0.9" cookie["PHPSESSID"] = "7265269b431e4d9d9e4edd079f8da21c" cookie["sc_is_visitor_unique"] = "rx11430932.1524382929.F7A1330878D04FF9DF09539FE782C5B9.1.1.1.1.1.1.1.1.1" header["Referer"] = "http://www.asinlab.com/asin-to-upc-bulk-lookup/" header["User-Agent"] = "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_13_3) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/66.0.3359.117 Safari/537.36" r = requests.get(url=url, headers=header, cookies=cookie, allow_redirects=False) r.text ``` ## System Information $ python -m requests.help ``` { "chardet": { "version": "3.0.4" }, "cryptography": { "version": "" }, "idna": { "version": "2.6" }, "implementation": { "name": "CPython", "version": "2.7.14" }, "platform": { "release": "17.4.0", "system": "Darwin" }, "pyOpenSSL": { "openssl_version": "", "version": null }, "requests": { "version": "2.18.4" }, "system_ssl": { "version": "100020ef" }, "urllib3": { "version": "1.22" }, "using_pyopenssl": false } ```
{ "avatar_url": "https://avatars.githubusercontent.com/u/5271761?v=4", "events_url": "https://api.github.com/users/nateprewitt/events{/privacy}", "followers_url": "https://api.github.com/users/nateprewitt/followers", "following_url": "https://api.github.com/users/nateprewitt/following{/other_user}", "gists_url": "https://api.github.com/users/nateprewitt/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/nateprewitt", "id": 5271761, "login": "nateprewitt", "node_id": "MDQ6VXNlcjUyNzE3NjE=", "organizations_url": "https://api.github.com/users/nateprewitt/orgs", "received_events_url": "https://api.github.com/users/nateprewitt/received_events", "repos_url": "https://api.github.com/users/nateprewitt/repos", "site_admin": false, "starred_url": "https://api.github.com/users/nateprewitt/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/nateprewitt/subscriptions", "type": "User", "url": "https://api.github.com/users/nateprewitt", "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/4605/reactions" }
https://api.github.com/repos/psf/requests/issues/4605/timeline
null
completed
null
null
false
[ "```py\r\n>>> r.status_code\r\n200\r\n>>> r.headers\r\n{'Date': 'Sun, 22 Apr 2018 13:04:55 GMT', 'Server': 'Apache', 'X-Powered-By': 'PHP/7.1.14', 'Expires': 'Thu, 19 Nov 1981 08:52:00 GMT', 'Cache-Control': 'no-store, no-cache, must-revalidate', 'Pragma': 'no-cache', 'Vary': 'Accept-Encoding,User-Agent', 'Content-...
https://api.github.com/repos/psf/requests/issues/4604
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4604/labels{/name}
https://api.github.com/repos/psf/requests/issues/4604/comments
https://api.github.com/repos/psf/requests/issues/4604/events
https://github.com/psf/requests/issues/4604
316,498,988
MDU6SXNzdWUzMTY0OTg5ODg=
4,604
now we support H2?
{ "avatar_url": "https://avatars.githubusercontent.com/u/16604643?v=4", "events_url": "https://api.github.com/users/kmahyyg/events{/privacy}", "followers_url": "https://api.github.com/users/kmahyyg/followers", "following_url": "https://api.github.com/users/kmahyyg/following{/other_user}", "gists_url": "https://api.github.com/users/kmahyyg/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/kmahyyg", "id": 16604643, "login": "kmahyyg", "node_id": "MDQ6VXNlcjE2NjA0NjQz", "organizations_url": "https://api.github.com/users/kmahyyg/orgs", "received_events_url": "https://api.github.com/users/kmahyyg/received_events", "repos_url": "https://api.github.com/users/kmahyyg/repos", "site_admin": false, "starred_url": "https://api.github.com/users/kmahyyg/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/kmahyyg/subscriptions", "type": "User", "url": "https://api.github.com/users/kmahyyg", "user_view_type": "public" }
[]
closed
true
null
[]
null
1
2018-04-21T15:03:27Z
2021-09-05T00:06:49Z
2018-04-21T15:30:34Z
NONE
resolved
- [X] | I checked #2451 #2082 #2584 According to the issue above, does we support HTTP/2 now?
{ "avatar_url": "https://avatars.githubusercontent.com/u/16604643?v=4", "events_url": "https://api.github.com/users/kmahyyg/events{/privacy}", "followers_url": "https://api.github.com/users/kmahyyg/followers", "following_url": "https://api.github.com/users/kmahyyg/following{/other_user}", "gists_url": "https://api.github.com/users/kmahyyg/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/kmahyyg", "id": 16604643, "login": "kmahyyg", "node_id": "MDQ6VXNlcjE2NjA0NjQz", "organizations_url": "https://api.github.com/users/kmahyyg/orgs", "received_events_url": "https://api.github.com/users/kmahyyg/received_events", "repos_url": "https://api.github.com/users/kmahyyg/repos", "site_admin": false, "starred_url": "https://api.github.com/users/kmahyyg/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/kmahyyg/subscriptions", "type": "User", "url": "https://api.github.com/users/kmahyyg", "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/4604/reactions" }
https://api.github.com/repos/psf/requests/issues/4604/timeline
null
completed
null
null
false
[ "I urgently hope to support the http2.0 protocol as soon as possible." ]
https://api.github.com/repos/psf/requests/issues/4603
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4603/labels{/name}
https://api.github.com/repos/psf/requests/issues/4603/comments
https://api.github.com/repos/psf/requests/issues/4603/events
https://github.com/psf/requests/pull/4603
316,469,382
MDExOlB1bGxSZXF1ZXN0MTgzMjEwNTUy
4,603
Nicer URL formatting with lists
{ "avatar_url": "https://avatars.githubusercontent.com/u/11632726?v=4", "events_url": "https://api.github.com/users/sayanarijit/events{/privacy}", "followers_url": "https://api.github.com/users/sayanarijit/followers", "following_url": "https://api.github.com/users/sayanarijit/following{/other_user}", "gists_url": "https://api.github.com/users/sayanarijit/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/sayanarijit", "id": 11632726, "login": "sayanarijit", "node_id": "MDQ6VXNlcjExNjMyNzI2", "organizations_url": "https://api.github.com/users/sayanarijit/orgs", "received_events_url": "https://api.github.com/users/sayanarijit/received_events", "repos_url": "https://api.github.com/users/sayanarijit/repos", "site_admin": false, "starred_url": "https://api.github.com/users/sayanarijit/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/sayanarijit/subscriptions", "type": "User", "url": "https://api.github.com/users/sayanarijit", "user_view_type": "public" }
[]
closed
true
null
[]
null
1
2018-04-21T07:16:59Z
2021-09-03T00:11:04Z
2018-04-21T08:31:20Z
NONE
resolved
# Nicer URL formatting with lists ### Purpose Using `['https://example.com', route1, route2]` as URL parameter as compared to `'https://example.com/{}/{}'.format(route1, route2)` or `'https://example.com/'+route1+'/'+route2` ### Examples ```python import requests slug = 1 r = requests.get(['https://api.jikan.me/anime', slug]) r.url # 'https://api.jikan.me/anime/1' category, item = 'jokes', 'random' r = requests.get(['https://api.chucknorris.io', category, item]) r.url # 'https://api.chucknorris.io/jokes/random' ```
{ "avatar_url": "https://avatars.githubusercontent.com/u/5271761?v=4", "events_url": "https://api.github.com/users/nateprewitt/events{/privacy}", "followers_url": "https://api.github.com/users/nateprewitt/followers", "following_url": "https://api.github.com/users/nateprewitt/following{/other_user}", "gists_url": "https://api.github.com/users/nateprewitt/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/nateprewitt", "id": 5271761, "login": "nateprewitt", "node_id": "MDQ6VXNlcjUyNzE3NjE=", "organizations_url": "https://api.github.com/users/nateprewitt/orgs", "received_events_url": "https://api.github.com/users/nateprewitt/received_events", "repos_url": "https://api.github.com/users/nateprewitt/repos", "site_admin": false, "starred_url": "https://api.github.com/users/nateprewitt/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/nateprewitt/subscriptions", "type": "User", "url": "https://api.github.com/users/nateprewitt", "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/4603/reactions" }
https://api.github.com/repos/psf/requests/issues/4603/timeline
null
null
false
{ "diff_url": "https://github.com/psf/requests/pull/4603.diff", "html_url": "https://github.com/psf/requests/pull/4603", "merged_at": null, "patch_url": "https://github.com/psf/requests/pull/4603.patch", "url": "https://api.github.com/repos/psf/requests/pulls/4603" }
true
[ "Hi @sayanarijit, thanks for the interest in contributing to Requests! Unfortunately, the Requests API is more or less frozen at this point, so I don't believe we'll be able to merge this. It should be easy to accomplish what you're looking for by wrapping the list in a join though, so the additional overhead for u...
https://api.github.com/repos/psf/requests/issues/4602
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4602/labels{/name}
https://api.github.com/repos/psf/requests/issues/4602/comments
https://api.github.com/repos/psf/requests/issues/4602/events
https://github.com/psf/requests/issues/4602
316,241,870
MDU6SXNzdWUzMTYyNDE4NzA=
4,602
Chunk-encoded request doesn't recognize iter_content generator
{ "avatar_url": "https://avatars.githubusercontent.com/u/38559523?v=4", "events_url": "https://api.github.com/users/fmerkel/events{/privacy}", "followers_url": "https://api.github.com/users/fmerkel/followers", "following_url": "https://api.github.com/users/fmerkel/following{/other_user}", "gists_url": "https://api.github.com/users/fmerkel/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/fmerkel", "id": 38559523, "login": "fmerkel", "node_id": "MDQ6VXNlcjM4NTU5NTIz", "organizations_url": "https://api.github.com/users/fmerkel/orgs", "received_events_url": "https://api.github.com/users/fmerkel/received_events", "repos_url": "https://api.github.com/users/fmerkel/repos", "site_admin": false, "starred_url": "https://api.github.com/users/fmerkel/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/fmerkel/subscriptions", "type": "User", "url": "https://api.github.com/users/fmerkel", "user_view_type": "public" }
[]
closed
true
null
[]
null
2
2018-04-20T12:07:16Z
2021-09-08T02:10:08Z
2018-04-21T15:07:02Z
NONE
resolved
Passing a generator created by iter_content() as request data raises "TypeError: sendall() argument 1 must be string or buffer, not generator". ## Expected Result The POST request successfully delives the content from the GET request. ## Actual Result A TypeError is raised: ``` Traceback (most recent call last): File "..\test.py", line 7, in <module> PostForward("http://myhost/img/foo.png", "http://myotherhost/convert") File "..\test.py", line 6, in PostForward return requests.post(url=dst, data=data, headers={'Content-Length': length}) File "C:\Python27\lib\site-packages\requests\api.py", line 112, in post return request('post', url, data=data, json=json, **kwargs) File "C:\Python27\lib\site-packages\requests\api.py", line 58, in request return session.request(method=method, url=url, **kwargs) File "C:\Python27\lib\site-packages\requests\sessions.py", line 508, in request resp = self.send(prep, **send_kwargs) File "C:\Python27\lib\site-packages\requests\sessions.py", line 618, in send r = adapter.send(request, **kwargs) File "C:\Python27\lib\site-packages\requests\adapters.py", line 440, in send timeout=timeout File "C:\Python27\lib\site-packages\urllib3\connectionpool.py", line 601, in urlopen chunked=chunked) File "C:\Python27\lib\site-packages\urllib3\connectionpool.py", line 357, in _make_request conn.request(method, url, **httplib_request_kw) File "C:\Python27\lib\httplib.py", line 1042, in request self._send_request(method, url, body, headers) File "C:\Python27\lib\httplib.py", line 1082, in _send_request self.endheaders(body) File "C:\Python27\lib\httplib.py", line 1038, in endheaders self._send_output(message_body) File "C:\Python27\lib\httplib.py", line 886, in _send_output self.send(message_body) File "C:\Python27\lib\httplib.py", line 858, in send self.sock.sendall(data) File "C:\Python27\lib\socket.py", line 228, in meth return getattr(self._sock,name)(*args) TypeError: sendall() argument 1 must be string or buffer, not generator ``` ## Reproduction Steps ```python import requests def PostForward(src, dst): with requests.get(url=src, stream=True) as srcResponse: length = srcResponse.headers['Content-Length'] data = srcResponse.iter_content(1024) return requests.post(url=dst, data=data, headers={'Content-Length': length}) PostForward("http://myhost/img/foo.png", "http://myotherhost/convert") ``` ## System Information $ python -m requests.help ``` { "chardet": { "version": "3.0.4" }, "cryptography": { "version": "" }, "idna": { "version": "2.6" }, "implementation": { "name": "CPython", "version": "2.7.14" }, "platform": { "release": "10", "system": "Windows" }, "pyOpenSSL": { "openssl_version": "", "version": null }, "requests": { "version": "2.18.4" }, "system_ssl": { "version": "100020bf" }, "urllib3": { "version": "1.22" }, "using_pyopenssl": 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" }
{ "+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/4602/reactions" }
https://api.github.com/repos/psf/requests/issues/4602/timeline
null
completed
null
null
false
[ "P.S.: The error is not raised if the headers param is omitted from the POST request. In that case the request is sent and the server receiving the request responds with 411 Length Required. The server is running Flask 0.12 on mod_wsgi 4.3.0 on Apache 2.4.18.", "`iter_content` returns a generator, which means th...
https://api.github.com/repos/psf/requests/issues/4601
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4601/labels{/name}
https://api.github.com/repos/psf/requests/issues/4601/comments
https://api.github.com/repos/psf/requests/issues/4601/events
https://github.com/psf/requests/issues/4601
316,075,823
MDU6SXNzdWUzMTYwNzU4MjM=
4,601
Requests memory leak
{ "avatar_url": "https://avatars.githubusercontent.com/u/38544207?v=4", "events_url": "https://api.github.com/users/Munroc/events{/privacy}", "followers_url": "https://api.github.com/users/Munroc/followers", "following_url": "https://api.github.com/users/Munroc/following{/other_user}", "gists_url": "https://api.github.com/users/Munroc/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/Munroc", "id": 38544207, "login": "Munroc", "node_id": "MDQ6VXNlcjM4NTQ0MjA3", "organizations_url": "https://api.github.com/users/Munroc/orgs", "received_events_url": "https://api.github.com/users/Munroc/received_events", "repos_url": "https://api.github.com/users/Munroc/repos", "site_admin": false, "starred_url": "https://api.github.com/users/Munroc/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Munroc/subscriptions", "type": "User", "url": "https://api.github.com/users/Munroc", "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": "f7c6c7", "default": false, "description": null, ...
open
false
null
[]
null
25
2018-04-19T23:33:06Z
2023-09-30T20:53:51Z
null
NONE
null
Summary. ## Expected Result Program running normally ## Actual Result Program consuming all ram till stops working ## Reproduction Steps Pseudocode: ```python def function(): proxies = { 'https': proxy } session = requests.Session() session.headers.update({'User-Agent': 'user - agent'}) try: # login = session.get(url, proxies=proxies) # HERE IS WHERE MEMORY LEAKS except: # return -1 # return 0 ``` ## System Information $ python -m requests.help ``` { "chardet": { "version": "3.0.4" }, "cryptography": { "version": "" }, "idna": { "version": "2.6" }, "implementation": { "name": "CPython", "version": "3.6.3" }, "platform": { "release": "10", "system": "Windows" }, "pyOpenSSL": { "openssl_version": "", "version": null }, "requests": { "version": "2.18.4" }, "system_ssl": { "version": "100020bf" }, "urllib3": { "version": "1.22" }, "using_pyopenssl": false } ```
null
{ "+1": 10, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 10, "url": "https://api.github.com/repos/psf/requests/issues/4601/reactions" }
https://api.github.com/repos/psf/requests/issues/4601/timeline
null
null
null
null
false
[ "Please provide us with the output of\r\n\r\n```\r\npython -m requests.help\r\n```\r\n\r\nIf that is unavailable on your version of Requests please provide some basic information about your system (Python version, operating system, etc).", "@sigmavirus24 Done", "Hey @munroc, a couple quick questions about your ...
https://api.github.com/repos/psf/requests/issues/4600
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4600/labels{/name}
https://api.github.com/repos/psf/requests/issues/4600/comments
https://api.github.com/repos/psf/requests/issues/4600/events
https://github.com/psf/requests/issues/4600
316,025,674
MDU6SXNzdWUzMTYwMjU2NzQ=
4,600
Using "no_proxy" by default HTTPAdapter
{ "avatar_url": "https://avatars.githubusercontent.com/u/7704597?v=4", "events_url": "https://api.github.com/users/jejefferson/events{/privacy}", "followers_url": "https://api.github.com/users/jejefferson/followers", "following_url": "https://api.github.com/users/jejefferson/following{/other_user}", "gists_url": "https://api.github.com/users/jejefferson/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jejefferson", "id": 7704597, "login": "jejefferson", "node_id": "MDQ6VXNlcjc3MDQ1OTc=", "organizations_url": "https://api.github.com/users/jejefferson/orgs", "received_events_url": "https://api.github.com/users/jejefferson/received_events", "repos_url": "https://api.github.com/users/jejefferson/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jejefferson/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jejefferson/subscriptions", "type": "User", "url": "https://api.github.com/users/jejefferson", "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" }
2
2018-04-19T20:18:37Z
2024-05-20T14:37:07Z
2024-05-20T14:37:07Z
NONE
null
Although feature with "no_proxy" key are not documented yet there is a validation method `(requests.utils.should_bypass_proxies)` for it. Unfortunately method for matching url in "no_proxy" list is not used by default. This is a bug or a feature? ``` s = requests.Session() r = requests.Request(url='http://127.0.0.2').prepare() s.send(r, proxies={ 'http': 'http://127.0.0.1:8090', 'no_proxy': '127.0.0.2', }, ) ``` ## Expected Result Send method will not use proxy due to url in "no_proxy" list. ## Actual Result Send method will still use proxy and ignore "no_proxy". Reproduction steps above. System info: ``` { "chardet": { "version": "3.0.4" }, "cryptography": { "version": "" }, "idna": { "version": "2.6" }, "implementation": { "name": "CPython", "version": "3.6.2" }, "platform": { "release": "17.2.0", "system": "Darwin" }, "pyOpenSSL": { "openssl_version": "", "version": null }, "requests": { "version": "2.18.4" }, "system_ssl": { "version": "100020ef" }, "urllib3": { "version": "1.22" }, "using_pyopenssl": false } ``` It's possible declare own Adapter and call method for checking no_proxy like this manner: ``` import requests def select_proxy(url, proxies): """Select a proxy for the url, if applicable. :param url: The url being for the request :param proxies: A dictionary of schemes or schemes and hosts to proxy URLs """ proxies = proxies or {} urlparts = requests.utils.urlparse(url) if urlparts.hostname is None: return proxies.get(urlparts.scheme, proxies.get('all')) proxy = None if requests.utils.should_bypass_proxies(url, proxies.get('no_proxy')): return proxy proxy_keys = [ urlparts.scheme + '://' + urlparts.hostname, urlparts.scheme, 'all://' + urlparts.hostname, 'all', ] for proxy_key in proxy_keys: if proxy_key in proxies: proxy = proxies[proxy_key] break return proxy class NoProxyAdapter(requests.adapters.HTTPAdapter): def get_connection(self, url, proxies=None): """Returns a urllib3 connection for the given URL. This should not be called from user code, and is only exposed for use when subclassing the :class:`HTTPAdapter <requests.adapters.HTTPAdapter>`. :param url: The URL to connect to. :param proxies: (optional) A Requests-style dictionary of proxies used on this request. :rtype: urllib3.ConnectionPool """ proxy = select_proxy(url, proxies) if proxy and proxy not in proxies.get('no_proxy', []): proxy = requests.adapters.prepend_scheme_if_needed(proxy, 'http') proxy_manager = self.proxy_manager_for(proxy) conn = proxy_manager.connection_from_url(url) else: # Only scheme should be lower case parsed = requests.adapters.urlparse(url) url = parsed.geturl() conn = self.poolmanager.connection_from_url(url) return conn if __name__ == "__main__": s = requests.Session() s.mount('http://', NoProxyAdapter()) r = requests.Request(url='http://127.0.0.2').prepare() s.send( r, proxies={ 'http': 'http://127.0.0.1:8090', 'no_proxy': '127.0.0.2', }, ) ``` This code works correctly for me and use "no_proxy". All difference is this two lines in function select_proxy: ``` if requests.utils.should_bypass_proxies(url, proxies.get('no_proxy')): return proxy ```
{ "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/4600/reactions" }
https://api.github.com/repos/psf/requests/issues/4600/timeline
null
completed
null
null
false
[ "Hey @jejefferson, thanks for opening this issue. I took a quick look and this functionality was mostly implemented in #3865. The original PR added something similar to what you're asking but it was to `rebuild_proxies`, which means it only runs on redirects. Your first request won't hit this, so that likely explai...
https://api.github.com/repos/psf/requests/issues/4599
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4599/labels{/name}
https://api.github.com/repos/psf/requests/issues/4599/comments
https://api.github.com/repos/psf/requests/issues/4599/events
https://github.com/psf/requests/issues/4599
315,916,180
MDU6SXNzdWUzMTU5MTYxODA=
4,599
proxies in session not taken into account
{ "avatar_url": "https://avatars.githubusercontent.com/u/15017455?v=4", "events_url": "https://api.github.com/users/navidof/events{/privacy}", "followers_url": "https://api.github.com/users/navidof/followers", "following_url": "https://api.github.com/users/navidof/following{/other_user}", "gists_url": "https://api.github.com/users/navidof/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/navidof", "id": 15017455, "login": "navidof", "node_id": "MDQ6VXNlcjE1MDE3NDU1", "organizations_url": "https://api.github.com/users/navidof/orgs", "received_events_url": "https://api.github.com/users/navidof/received_events", "repos_url": "https://api.github.com/users/navidof/repos", "site_admin": false, "starred_url": "https://api.github.com/users/navidof/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/navidof/subscriptions", "type": "User", "url": "https://api.github.com/users/navidof", "user_view_type": "public" }
[ { "color": "fef2c0", "default": false, "description": null, "id": 298537994, "name": "Needs More Information", "node_id": "MDU6TGFiZWwyOTg1Mzc5OTQ=", "url": "https://api.github.com/repos/psf/requests/labels/Needs%20More%20Information" } ]
closed
true
null
[]
null
3
2018-04-19T14:59:15Z
2021-09-08T02:09:56Z
2018-05-20T19:16:31Z
NONE
resolved
When creating a session object, and setting proxies information, the proxy information is not used in subsequent requests: SESS = requests.Session() SESS.auth = (USER, PWD) SESS.verify = False SESS.proxies = {'https': None} ## Expected Result SESS.get(URL + '/' + ENDPOINT) should bypass the proxy and be able to resolve the internal URL. ## Actual Result 502: notresolvable for url But passing the same proxy information to the get works: SESS.get(URL + '/' + ENDPOINT, proxies={'https': None}) works as expected ## Reproduction Steps ```python import requests SESS = requests.Session() SESS.auth = (USER, PWD) SESS.verify = False SESS.proxies = {'https': None} ``` ## System Information requests 2.13.0 python 3.5.2 Fedora 20
{ "avatar_url": "https://avatars.githubusercontent.com/u/5271761?v=4", "events_url": "https://api.github.com/users/nateprewitt/events{/privacy}", "followers_url": "https://api.github.com/users/nateprewitt/followers", "following_url": "https://api.github.com/users/nateprewitt/following{/other_user}", "gists_url": "https://api.github.com/users/nateprewitt/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/nateprewitt", "id": 5271761, "login": "nateprewitt", "node_id": "MDQ6VXNlcjUyNzE3NjE=", "organizations_url": "https://api.github.com/users/nateprewitt/orgs", "received_events_url": "https://api.github.com/users/nateprewitt/received_events", "repos_url": "https://api.github.com/users/nateprewitt/repos", "site_admin": false, "starred_url": "https://api.github.com/users/nateprewitt/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/nateprewitt/subscriptions", "type": "User", "url": "https://api.github.com/users/nateprewitt", "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/4599/reactions" }
https://api.github.com/repos/psf/requests/issues/4599/timeline
null
completed
null
null
false
[ "Hi @navidof, before we dig too far into this, can you confirm this is still an issue in 2.18.4 with urllib3 1.22?\r\n\r\nRequests 2.13 is fairly old now and there’s been some proxy work done since then.", "Hey again @navidof, I'm unable to reproduce this with 2.18.4 and since this hasn't seen an update in the la...
https://api.github.com/repos/psf/requests/issues/4598
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4598/labels{/name}
https://api.github.com/repos/psf/requests/issues/4598/comments
https://api.github.com/repos/psf/requests/issues/4598/events
https://github.com/psf/requests/issues/4598
315,910,053
MDU6SXNzdWUzMTU5MTAwNTM=
4,598
Sessk
{ "avatar_url": "https://avatars.githubusercontent.com/u/7704597?v=4", "events_url": "https://api.github.com/users/jejefferson/events{/privacy}", "followers_url": "https://api.github.com/users/jejefferson/followers", "following_url": "https://api.github.com/users/jejefferson/following{/other_user}", "gists_url": "https://api.github.com/users/jejefferson/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jejefferson", "id": 7704597, "login": "jejefferson", "node_id": "MDQ6VXNlcjc3MDQ1OTc=", "organizations_url": "https://api.github.com/users/jejefferson/orgs", "received_events_url": "https://api.github.com/users/jejefferson/received_events", "repos_url": "https://api.github.com/users/jejefferson/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jejefferson/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jejefferson/subscriptions", "type": "User", "url": "https://api.github.com/users/jejefferson", "user_view_type": "public" }
[]
closed
true
null
[]
null
0
2018-04-19T14:45:07Z
2021-09-08T02:10:09Z
2018-04-19T16:06:08Z
NONE
resolved
Summary. ## Expected Result What you expected. ## Actual Result What happened instead. ## Reproduction Steps ```python import requests ``` ## System Information $ python -m requests.help ``` <paste here> ``` This command is only available on Requests v2.16.4 and greater. Otherwise, please provide some basic information about your system (Python version, operating system, &c).
{ "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/4598/reactions" }
https://api.github.com/repos/psf/requests/issues/4598/timeline
null
completed
null
null
false
[]
https://api.github.com/repos/psf/requests/issues/4597
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4597/labels{/name}
https://api.github.com/repos/psf/requests/issues/4597/comments
https://api.github.com/repos/psf/requests/issues/4597/events
https://github.com/psf/requests/pull/4597
315,729,045
MDExOlB1bGxSZXF1ZXN0MTgyNjY2OTky
4,597
Migrate to new PyPI website
{ "avatar_url": "https://avatars.githubusercontent.com/u/5316833?v=4", "events_url": "https://api.github.com/users/ericwb/events{/privacy}", "followers_url": "https://api.github.com/users/ericwb/followers", "following_url": "https://api.github.com/users/ericwb/following{/other_user}", "gists_url": "https://api.github.com/users/ericwb/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/ericwb", "id": 5316833, "login": "ericwb", "node_id": "MDQ6VXNlcjUzMTY4MzM=", "organizations_url": "https://api.github.com/users/ericwb/orgs", "received_events_url": "https://api.github.com/users/ericwb/received_events", "repos_url": "https://api.github.com/users/ericwb/repos", "site_admin": false, "starred_url": "https://api.github.com/users/ericwb/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/ericwb/subscriptions", "type": "User", "url": "https://api.github.com/users/ericwb", "user_view_type": "public" }
[]
closed
true
null
[]
null
1
2018-04-19T05:05:55Z
2021-09-03T00:11:05Z
2018-04-19T06:19:25Z
CONTRIBUTOR
resolved
According to [1], the PyPI website of pypi.python.org has changed to https://pypi.org. This patch updates all references to the legacy site. [1] https://pythoninsider.blogspot.ca/2018/04/new-pypi-launched-legacy-pypi-shutting.html Signed-off-by: Eric Brown <browne@vmware.com>
{ "avatar_url": "https://avatars.githubusercontent.com/u/5271761?v=4", "events_url": "https://api.github.com/users/nateprewitt/events{/privacy}", "followers_url": "https://api.github.com/users/nateprewitt/followers", "following_url": "https://api.github.com/users/nateprewitt/following{/other_user}", "gists_url": "https://api.github.com/users/nateprewitt/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/nateprewitt", "id": 5271761, "login": "nateprewitt", "node_id": "MDQ6VXNlcjUyNzE3NjE=", "organizations_url": "https://api.github.com/users/nateprewitt/orgs", "received_events_url": "https://api.github.com/users/nateprewitt/received_events", "repos_url": "https://api.github.com/users/nateprewitt/repos", "site_admin": false, "starred_url": "https://api.github.com/users/nateprewitt/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/nateprewitt/subscriptions", "type": "User", "url": "https://api.github.com/users/nateprewitt", "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/4597/reactions" }
https://api.github.com/repos/psf/requests/issues/4597/timeline
null
null
false
{ "diff_url": "https://github.com/psf/requests/pull/4597.diff", "html_url": "https://github.com/psf/requests/pull/4597", "merged_at": null, "patch_url": "https://github.com/psf/requests/pull/4597.patch", "url": "https://api.github.com/repos/psf/requests/pulls/4597" }
true
[ "Hi @ericwb, this is already being addressed in #4596. Thanks for the initiative." ]
https://api.github.com/repos/psf/requests/issues/4596
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4596/labels{/name}
https://api.github.com/repos/psf/requests/issues/4596/comments
https://api.github.com/repos/psf/requests/issues/4596/events
https://github.com/psf/requests/pull/4596
315,715,185
MDExOlB1bGxSZXF1ZXN0MTgyNjU2OTY2
4,596
Update all pypi.python.org URLs to pypi.org
{ "avatar_url": "https://avatars.githubusercontent.com/u/347634?v=4", "events_url": "https://api.github.com/users/jdufresne/events{/privacy}", "followers_url": "https://api.github.com/users/jdufresne/followers", "following_url": "https://api.github.com/users/jdufresne/following{/other_user}", "gists_url": "https://api.github.com/users/jdufresne/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jdufresne", "id": 347634, "login": "jdufresne", "node_id": "MDQ6VXNlcjM0NzYzNA==", "organizations_url": "https://api.github.com/users/jdufresne/orgs", "received_events_url": "https://api.github.com/users/jdufresne/received_events", "repos_url": "https://api.github.com/users/jdufresne/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jdufresne/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jdufresne/subscriptions", "type": "User", "url": "https://api.github.com/users/jdufresne", "user_view_type": "public" }
[]
closed
true
null
[]
null
1
2018-04-19T03:28:52Z
2021-09-02T00:07:50Z
2018-04-19T10:41:37Z
CONTRIBUTOR
resolved
For details on the new PyPI, see the blog post: https://pythoninsider.blogspot.ca/2018/04/new-pypi-launched-legacy-pypi-shutting.html
{ "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/4596/reactions" }
https://api.github.com/repos/psf/requests/issues/4596/timeline
null
null
false
{ "diff_url": "https://github.com/psf/requests/pull/4596.diff", "html_url": "https://github.com/psf/requests/pull/4596", "merged_at": "2018-04-19T10:41:37Z", "patch_url": "https://github.com/psf/requests/pull/4596.patch", "url": "https://api.github.com/repos/psf/requests/pulls/4596" }
true
[ "I think we can merge this without AppVeyor passing." ]
https://api.github.com/repos/psf/requests/issues/4595
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4595/labels{/name}
https://api.github.com/repos/psf/requests/issues/4595/comments
https://api.github.com/repos/psf/requests/issues/4595/events
https://github.com/psf/requests/issues/4595
315,335,238
MDU6SXNzdWUzMTUzMzUyMzg=
4,595
OSError / Image.open(BytesIO(r.content))
{ "avatar_url": "https://avatars.githubusercontent.com/u/14147011?v=4", "events_url": "https://api.github.com/users/Liuzhj/events{/privacy}", "followers_url": "https://api.github.com/users/Liuzhj/followers", "following_url": "https://api.github.com/users/Liuzhj/following{/other_user}", "gists_url": "https://api.github.com/users/Liuzhj/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/Liuzhj", "id": 14147011, "login": "Liuzhj", "node_id": "MDQ6VXNlcjE0MTQ3MDEx", "organizations_url": "https://api.github.com/users/Liuzhj/orgs", "received_events_url": "https://api.github.com/users/Liuzhj/received_events", "repos_url": "https://api.github.com/users/Liuzhj/repos", "site_admin": false, "starred_url": "https://api.github.com/users/Liuzhj/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Liuzhj/subscriptions", "type": "User", "url": "https://api.github.com/users/Liuzhj", "user_view_type": "public" }
[]
closed
true
null
[]
null
4
2018-04-18T05:24:08Z
2021-09-08T02:10:10Z
2018-04-18T05:54:11Z
NONE
resolved
Summary. ## Expected Result http://docs.python-requests.org/en/latest/user/quickstart/?highlight=binary#binary-response-content ```py from PIL import Image from io import BytesIO i = Image.open(BytesIO(r.content)) ``` ``` Traceback (most recent call last): File "X:/study/test.py", line 7, in <module> i = Image.open(BytesIO(r.content)) File "C:\Program Files\Python35\lib\site-packages\PIL\Image.py", line 2590, in open % (filename if filename else fp)) OSError: cannot identify image file <_io.BytesIO object at 0x0000000003471AF0> ``` python : 3.5.1 OS: Windows 7
{ "avatar_url": "https://avatars.githubusercontent.com/u/5271761?v=4", "events_url": "https://api.github.com/users/nateprewitt/events{/privacy}", "followers_url": "https://api.github.com/users/nateprewitt/followers", "following_url": "https://api.github.com/users/nateprewitt/following{/other_user}", "gists_url": "https://api.github.com/users/nateprewitt/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/nateprewitt", "id": 5271761, "login": "nateprewitt", "node_id": "MDQ6VXNlcjUyNzE3NjE=", "organizations_url": "https://api.github.com/users/nateprewitt/orgs", "received_events_url": "https://api.github.com/users/nateprewitt/received_events", "repos_url": "https://api.github.com/users/nateprewitt/repos", "site_admin": false, "starred_url": "https://api.github.com/users/nateprewitt/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/nateprewitt/subscriptions", "type": "User", "url": "https://api.github.com/users/nateprewitt", "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/4595/reactions" }
https://api.github.com/repos/psf/requests/issues/4595/timeline
null
completed
null
null
false
[ "I don't know how to solve it , give me a hand ,Thanks .", "Hi @Liuzhj, this appears to be a request for help rather than a defect report for Requests. We recommend directing usage questions to [StackOverflow](https://stackoverflow.com) for assistance.\r\n\r\nTo help direct your question, it looks like you’re eit...
https://api.github.com/repos/psf/requests/issues/4594
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4594/labels{/name}
https://api.github.com/repos/psf/requests/issues/4594/comments
https://api.github.com/repos/psf/requests/issues/4594/events
https://github.com/psf/requests/issues/4594
315,263,120
MDU6SXNzdWUzMTUyNjMxMjA=
4,594
`Collections.Callable` DeprecationWarning
{ "avatar_url": "https://avatars.githubusercontent.com/u/415926?v=4", "events_url": "https://api.github.com/users/hsolbrig/events{/privacy}", "followers_url": "https://api.github.com/users/hsolbrig/followers", "following_url": "https://api.github.com/users/hsolbrig/following{/other_user}", "gists_url": "https://api.github.com/users/hsolbrig/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/hsolbrig", "id": 415926, "login": "hsolbrig", "node_id": "MDQ6VXNlcjQxNTkyNg==", "organizations_url": "https://api.github.com/users/hsolbrig/orgs", "received_events_url": "https://api.github.com/users/hsolbrig/received_events", "repos_url": "https://api.github.com/users/hsolbrig/repos", "site_admin": false, "starred_url": "https://api.github.com/users/hsolbrig/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/hsolbrig/subscriptions", "type": "User", "url": "https://api.github.com/users/hsolbrig", "user_view_type": "public" }
[]
closed
true
null
[]
null
1
2018-04-17T22:23:04Z
2021-09-08T02:10:10Z
2018-04-17T22:26:58Z
NONE
resolved
Summary. Python 3.7.0b3 has a new warning: ```text .../python3.7/site-packages/requests/models.py:177: DeprecationWarning: Using or importing the ABCs from 'collections' instead of from 'collections.abc' is deprecated, and in 3.8 it will stop working if isinstance(hook, collections.Callable): ``` ## Expected Result Need to change this line (and other references) to `if isinstance(hook, collections.abc.Callable):` What you expected. ## Actual Result What happened instead. ## Reproduction Steps ```python import requests ``` ## System Information $ python -m requests.help ``` { "chardet": { "version": "3.0.4" }, "cryptography": { "version": "" }, "idna": { "version": "2.6" }, "implementation": { "name": "CPython", "version": "3.7.0b3" }, "platform": { "release": "16.7.0", "system": "Darwin" }, "pyOpenSSL": { "openssl_version": "", "version": null }, "requests": { "version": "2.18.4" }, "system_ssl": { "version": "1010007f" }, "urllib3": { "version": "1.22" }, "using_pyopenssl": false } ``` This command is only available on Requests v2.16.4 and greater. Otherwise, please provide some basic information about your system (Python version, operating system, &c).
{ "avatar_url": "https://avatars.githubusercontent.com/u/5271761?v=4", "events_url": "https://api.github.com/users/nateprewitt/events{/privacy}", "followers_url": "https://api.github.com/users/nateprewitt/followers", "following_url": "https://api.github.com/users/nateprewitt/following{/other_user}", "gists_url": "https://api.github.com/users/nateprewitt/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/nateprewitt", "id": 5271761, "login": "nateprewitt", "node_id": "MDQ6VXNlcjUyNzE3NjE=", "organizations_url": "https://api.github.com/users/nateprewitt/orgs", "received_events_url": "https://api.github.com/users/nateprewitt/received_events", "repos_url": "https://api.github.com/users/nateprewitt/repos", "site_admin": false, "starred_url": "https://api.github.com/users/nateprewitt/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/nateprewitt/subscriptions", "type": "User", "url": "https://api.github.com/users/nateprewitt", "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/4594/reactions" }
https://api.github.com/repos/psf/requests/issues/4594/timeline
null
completed
null
null
false
[ "Hey @hsolbrig, this is actually a duplicate of #4494 and we have a PR in the queue to address this. Next time please make sure to check issues and pull requests before opening a new one. Thanks for taking the time to bring this to our attention though!" ]
https://api.github.com/repos/psf/requests/issues/4593
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4593/labels{/name}
https://api.github.com/repos/psf/requests/issues/4593/comments
https://api.github.com/repos/psf/requests/issues/4593/events
https://github.com/psf/requests/issues/4593
315,077,015
MDU6SXNzdWUzMTUwNzcwMTU=
4,593
Allow passing a default json encoder/decoder for all requests
{ "avatar_url": "https://avatars.githubusercontent.com/u/639467?v=4", "events_url": "https://api.github.com/users/brunoais/events{/privacy}", "followers_url": "https://api.github.com/users/brunoais/followers", "following_url": "https://api.github.com/users/brunoais/following{/other_user}", "gists_url": "https://api.github.com/users/brunoais/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/brunoais", "id": 639467, "login": "brunoais", "node_id": "MDQ6VXNlcjYzOTQ2Nw==", "organizations_url": "https://api.github.com/users/brunoais/orgs", "received_events_url": "https://api.github.com/users/brunoais/received_events", "repos_url": "https://api.github.com/users/brunoais/repos", "site_admin": false, "starred_url": "https://api.github.com/users/brunoais/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/brunoais/subscriptions", "type": "User", "url": "https://api.github.com/users/brunoais", "user_view_type": "public" }
[ { "color": "fbca04", "default": false, "description": null, "id": 44501249, "name": "Needs BDFL Input", "node_id": "MDU6TGFiZWw0NDUwMTI0OQ==", "url": "https://api.github.com/repos/psf/requests/labels/Needs%20BDFL%20Input" } ]
closed
true
null
[]
null
5
2018-04-17T14:08:48Z
2021-09-08T02:10:10Z
2018-04-18T13:22:13Z
NONE
resolved
## Summary Add a method onto `requests` so a default json decoder and encoder can be given when calling `json.dumps` and `json.loads()` ## Details Unlike #4097, what I ask here is a way of setting such encoder and decoder which is used in all requests and not just only on an individual one. The basic idea is the same except this is meant to be a global setting and not a by-request setting. In my application's situation, it would mean saving many lines of code and it would also mean more abstraction. Such option would allow having this setup in a dependency where the rest of the application knowing a new class have had a way of being encoded/decoded. Would a global setting be justifiable? Or same stance?
{ "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/4593/reactions" }
https://api.github.com/repos/psf/requests/issues/4593/timeline
null
completed
null
null
false
[ "We don't presently provide any configuration of the `json=` parameter. It's rather simply just `.dumps`\r\n\r\nhttps://github.com/requests/requests/blob/b66908e7b647689793e299edc111bf9910e93ad3/requests/models.py#L458\r\n\r\nWe also don't do any creation of a decoder in the `json` method on a Response\r\n\r\nhttps...
https://api.github.com/repos/psf/requests/issues/4592
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4592/labels{/name}
https://api.github.com/repos/psf/requests/issues/4592/comments
https://api.github.com/repos/psf/requests/issues/4592/events
https://github.com/psf/requests/issues/4592
314,884,513
MDU6SXNzdWUzMTQ4ODQ1MTM=
4,592
Malformed `Set-Cookie` containing CRLF does not cause an error
{ "avatar_url": "https://avatars.githubusercontent.com/u/18148490?v=4", "events_url": "https://api.github.com/users/paultiplady/events{/privacy}", "followers_url": "https://api.github.com/users/paultiplady/followers", "following_url": "https://api.github.com/users/paultiplady/following{/other_user}", "gists_url": "https://api.github.com/users/paultiplady/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/paultiplady", "id": 18148490, "login": "paultiplady", "node_id": "MDQ6VXNlcjE4MTQ4NDkw", "organizations_url": "https://api.github.com/users/paultiplady/orgs", "received_events_url": "https://api.github.com/users/paultiplady/received_events", "repos_url": "https://api.github.com/users/paultiplady/repos", "site_admin": false, "starred_url": "https://api.github.com/users/paultiplady/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/paultiplady/subscriptions", "type": "User", "url": "https://api.github.com/users/paultiplady", "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
false
null
[]
null
7
2018-04-17T02:42:53Z
2024-05-19T19:10:14Z
2024-05-19T19:10:13Z
NONE
null
After receiving a malformed `Set-Cookie` header containing a CRLF, a malformed `Cookie` header is generated (still containing that CRLF). ## Expected Result Per https://github.com/requests/requests/issues/3521, expect an exception to be raised, rather than generating invalid HTTP. ## Actual Result An invalid Cookie header was generated containing a CRLF character. ## Reproduction Steps ... Can't quite figure out a concise repro. Here's the bogus cookie (extracted from the raw HTTP text): ``` ... Set-Cookie: ___utmvbtouVBFmB=gZg XbNOjalT: Lte; path=/; Max-Age=900 ... ``` Gives: ``` Cookie: ___utmvbtouVBFmB=gZg\r\n XbNOjalT: Lte; <other-cookies> ``` ## System Information $ python -m requests.help ``` { "chardet": { "version": "3.0.4" }, "cryptography": { "version": "1.7.1" }, "idna": { "version": "2.6" }, "implementation": { "name": "CPython", "version": "3.5.4" }, "platform": { "release": "15.6.0", "system": "Darwin" }, "pyOpenSSL": { "openssl_version": "100020af", "version": "16.2.0" }, "requests": { "version": "2.18.4" }, "system_ssl": { "version": "100020ef" }, "urllib3": { "version": "1.22" }, "using_pyopenssl": true } ```
{ "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": 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/4592/reactions" }
https://api.github.com/repos/psf/requests/issues/4592/timeline
null
completed
null
null
false
[ "Hey @paultiplady, thanks for bringing this to our attention. The issue you're referring to is about #3366 which was to prevent users from creating requests with headers that contained newlines. While we do prevent that now, we don't validate headers received from servers.\r\n\r\nPutting together a [quick repro](ht...
https://api.github.com/repos/psf/requests/issues/4591
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4591/labels{/name}
https://api.github.com/repos/psf/requests/issues/4591/comments
https://api.github.com/repos/psf/requests/issues/4591/events
https://github.com/psf/requests/pull/4591
314,516,317
MDExOlB1bGxSZXF1ZXN0MTgxNzYzNTc5
4,591
Use pyOpenSSL only when ssl doesn't support SNI
{ "avatar_url": "https://avatars.githubusercontent.com/u/199592?v=4", "events_url": "https://api.github.com/users/methane/events{/privacy}", "followers_url": "https://api.github.com/users/methane/followers", "following_url": "https://api.github.com/users/methane/following{/other_user}", "gists_url": "https://api.github.com/users/methane/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/methane", "id": 199592, "login": "methane", "node_id": "MDQ6VXNlcjE5OTU5Mg==", "organizations_url": "https://api.github.com/users/methane/orgs", "received_events_url": "https://api.github.com/users/methane/received_events", "repos_url": "https://api.github.com/users/methane/repos", "site_admin": false, "starred_url": "https://api.github.com/users/methane/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/methane/subscriptions", "type": "User", "url": "https://api.github.com/users/methane", "user_view_type": "public" }
[]
closed
true
null
[]
null
2
2018-04-16T06:25:06Z
2021-08-28T00:06:23Z
2020-08-18T21:49:52Z
CONTRIBUTOR
resolved
Since recent Python supports SNI, importing pyOpenSSL is avoidable now.
{ "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/4591/reactions" }
https://api.github.com/repos/psf/requests/issues/4591/timeline
null
null
false
{ "diff_url": "https://github.com/psf/requests/pull/4591.diff", "html_url": "https://github.com/psf/requests/pull/4591", "merged_at": null, "patch_url": "https://github.com/psf/requests/pull/4591.patch", "url": "https://api.github.com/repos/psf/requests/pulls/4591" }
true
[ "I don't believe we only use pyOpenSSL to fix up SNI issues anymore. This needs careful review", "This has already been completed in https://github.com/psf/requests/pull/5443" ]
https://api.github.com/repos/psf/requests/issues/4590
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4590/labels{/name}
https://api.github.com/repos/psf/requests/issues/4590/comments
https://api.github.com/repos/psf/requests/issues/4590/events
https://github.com/psf/requests/issues/4590
314,514,389
MDU6SXNzdWUzMTQ1MTQzODk=
4,590
requests treats urllib3's SSL handshake timeout as ReadTimeout
{ "avatar_url": "https://avatars.githubusercontent.com/u/6823542?v=4", "events_url": "https://api.github.com/users/metheoryt/events{/privacy}", "followers_url": "https://api.github.com/users/metheoryt/followers", "following_url": "https://api.github.com/users/metheoryt/following{/other_user}", "gists_url": "https://api.github.com/users/metheoryt/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/metheoryt", "id": 6823542, "login": "metheoryt", "node_id": "MDQ6VXNlcjY4MjM1NDI=", "organizations_url": "https://api.github.com/users/metheoryt/orgs", "received_events_url": "https://api.github.com/users/metheoryt/received_events", "repos_url": "https://api.github.com/users/metheoryt/repos", "site_admin": false, "starred_url": "https://api.github.com/users/metheoryt/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/metheoryt/subscriptions", "type": "User", "url": "https://api.github.com/users/metheoryt", "user_view_type": "public" }
[]
open
false
null
[]
null
15
2018-04-16T06:15:33Z
2021-11-29T17:22:25Z
null
NONE
null
## Expected Result When connecting to a remote machine via SSL/TLS, and SSL handshake timeout happens, I expect to have `SSLError` or `ConnectionError` exception. ## Actual Result `requests` raises `ReadTimeout` ## Reproduction Steps I don't know how to reproduce this, but I have a real stacktrace (most recent call first): ``` timeout: _ssl.c:704: The handshake operation timed out File "urllib3/connectionpool.py", line 346, in _make_request self._validate_conn(conn) File "urllib3/connectionpool.py", line 850, in _validate_conn conn.connect() File "urllib3/connection.py", line 326, in connect ssl_context=context) File "urllib3/util/ssl_.py", line 329, in ssl_wrap_socket return context.wrap_socket(sock, server_hostname=server_hostname) File "python3.5/ssl.py", line 385, in wrap_socket _context=self) File "python3.5/ssl.py", line 760, in __init__ self.do_handshake() File "python3.5/ssl.py", line 996, in do_handshake self._sslobj.do_handshake() File "python3.5/ssl.py", line 641, in do_handshake self._sslobj.do_handshake() ReadTimeoutError: HTTPSConnectionPool(host='somehost.com', port=443): Read timed out. (read timeout=5) File "requests/adapters.py", line 440, in send timeout=timeout File "urllib3/connectionpool.py", line 639, in urlopen _stacktrace=sys.exc_info()[2]) File "urllib3/util/retry.py", line 357, in increment raise six.reraise(type(error), error, _stacktrace) File "urllib3/packages/six.py", line 686, in reraise raise value File "urllib3/connectionpool.py", line 601, in urlopen chunked=chunked) File "urllib3/connectionpool.py", line 349, in _make_request self._raise_timeout(err=e, url=url, timeout_value=conn.timeout) File "urllib3/connectionpool.py", line 309, in _raise_timeout raise ReadTimeoutError(self, url, "Read timed out. (read timeout=%s)" % timeout_value) ReadTimeout: HTTPSConnectionPool(host='somehost.com', port=443): Read timed out. (read timeout=5) File "wsa/external/soap.py", line 234, in call response = command(**params) File "zeep/client.py", line 45, in __call__ self._op_name, args, kwargs) File "zeep/wsdl/bindings/soap.py", line 113, in send options['address'], envelope, http_headers) File "zeep/transports.py", line 95, in post_xml return self.post(address, message, headers) File "wsa/external/soap.py", line 75, in post return super(NonPersistentTransport, self).post(address, message, headers) File "zeep/transports.py", line 67, in post timeout=self.operation_timeout) File "requests/sessions.py", line 555, in post return self.request('POST', url, data=data, json=json, **kwargs) File "requests/sessions.py", line 508, in request resp = self.send(prep, **send_kwargs) File "raven/breadcrumbs.py", line 297, in send resp = real_send(self, request, *args, **kwargs) File "requests/sessions.py", line 618, in send r = adapter.send(request, **kwargs) File "requests/adapters.py", line 521, in send raise ReadTimeout(e, request=request) ``` ## System Information $ python -m requests.help ``` { "chardet": { "version": "3.0.4" }, "cryptography": { "version": "" }, "idna": { "version": "2.6" }, "implementation": { "name": "CPython", "version": "3.5.3" }, "platform": { "release": "3.10.0-693.5.2.el7.x86_64", "system": "Linux" }, "pyOpenSSL": { "openssl_version": "", "version": null }, "requests": { "version": "2.18.4" }, "system_ssl": { "version": "1000105f" }, "urllib3": { "version": "1.22" }, "using_pyopenssl": false } ``` $ openssl version ``` OpenSSL 1.0.2k-fips 26 Jan 2017 ``` $ cat /etc/redhat-release $ uname -spori ``` OS: CentOS Linux release 7.4.1708 (Core), Linux 3.10.0-693.5.2.el7.x86_64 x86_64 x86_64 GNU/Linux ```
null
{ "+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/4590/reactions" }
https://api.github.com/repos/psf/requests/issues/4590/timeline
null
null
null
null
false
[ "Can you share more details about what makes you think there was a handshake error or other TLS issue that happened here?", "<img width=\"521\" alt=\"screen shot 2018-04-16 at 10 45 03 am\" src=\"https://user-images.githubusercontent.com/9362301/38825981-467624cc-4163-11e8-92fe-5df890e9328e.png\">\r\n\r\ncurl pro...
https://api.github.com/repos/psf/requests/issues/4589
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4589/labels{/name}
https://api.github.com/repos/psf/requests/issues/4589/comments
https://api.github.com/repos/psf/requests/issues/4589/events
https://github.com/psf/requests/issues/4589
314,370,654
MDU6SXNzdWUzMTQzNzA2NTQ=
4,589
Making a request with multipart/form-data (file=) should throw an error if the barrier defined in the headers does not match
{ "avatar_url": "https://avatars.githubusercontent.com/u/22382740?v=4", "events_url": "https://api.github.com/users/Radilx/events{/privacy}", "followers_url": "https://api.github.com/users/Radilx/followers", "following_url": "https://api.github.com/users/Radilx/following{/other_user}", "gists_url": "https://api.github.com/users/Radilx/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/Radilx", "id": 22382740, "login": "Radilx", "node_id": "MDQ6VXNlcjIyMzgyNzQw", "organizations_url": "https://api.github.com/users/Radilx/orgs", "received_events_url": "https://api.github.com/users/Radilx/received_events", "repos_url": "https://api.github.com/users/Radilx/repos", "site_admin": false, "starred_url": "https://api.github.com/users/Radilx/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/Radilx/subscriptions", "type": "User", "url": "https://api.github.com/users/Radilx", "user_view_type": "public" }
[]
closed
true
null
[]
null
1
2018-04-14T23:29:46Z
2021-09-08T03:00:20Z
2018-04-15T12:46:21Z
NONE
resolved
I am unable to make a pull request at this time, but I think this should be added. The server will not understand the request if the content-type header's barrier= is not the same as the one generated by requests. At the very least there should be a warning.
{ "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/4589/reactions" }
https://api.github.com/repos/psf/requests/issues/4589/timeline
null
completed
null
null
false
[ "Please provide us with the output of\r\n\r\n```\r\npython -m requests.help\r\n```\r\n\r\nIf that is unavailable on your version of Requests please provide some basic information about your system (Python version, operating system, etc).\r\n\r\nAdditionally, this appears to be a duplicate of several issues. In the ...
https://api.github.com/repos/psf/requests/issues/4588
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4588/labels{/name}
https://api.github.com/repos/psf/requests/issues/4588/comments
https://api.github.com/repos/psf/requests/issues/4588/events
https://github.com/psf/requests/issues/4588
313,968,212
MDU6SXNzdWUzMTM5NjgyMTI=
4,588
response.text is returning with header values.
{ "avatar_url": "https://avatars.githubusercontent.com/u/3342215?v=4", "events_url": "https://api.github.com/users/selvaraju/events{/privacy}", "followers_url": "https://api.github.com/users/selvaraju/followers", "following_url": "https://api.github.com/users/selvaraju/following{/other_user}", "gists_url": "https://api.github.com/users/selvaraju/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/selvaraju", "id": 3342215, "login": "selvaraju", "node_id": "MDQ6VXNlcjMzNDIyMTU=", "organizations_url": "https://api.github.com/users/selvaraju/orgs", "received_events_url": "https://api.github.com/users/selvaraju/received_events", "repos_url": "https://api.github.com/users/selvaraju/repos", "site_admin": false, "starred_url": "https://api.github.com/users/selvaraju/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/selvaraju/subscriptions", "type": "User", "url": "https://api.github.com/users/selvaraju", "user_view_type": "public" }
[]
closed
true
null
[]
null
3
2018-04-13T04:47:44Z
2021-09-08T02:10:08Z
2018-04-21T20:53:59Z
NONE
resolved
Summary. response.text is returning with header values. ## Expected Result We are expecting only response content. but getting with header as well. Could you please help us to solve this issue ? response.text => {"@odata.context":"/redfish/v1/$metadata#ServiceRoot.ServiceRoot"} ## Actual Result Getting response header with response.text like below HTTP/1.1 200 OK Content-Length: 807 OData-Version: 4.0 Content-Type: application/json Date: Fri, 13 Apr 2018 04:38:07 GMT {"@odata.context":"/redfish/v1/$metadata#ServiceRoot.ServiceRoot"} ## Reproduction Steps ```python import requests ``` ## System Information $ python -m requests.help ``` { "chardet": { "version": "3.0.4" }, "cryptography": { "version": "1.7.1" }, "idna": { "version": "2.6" }, "implementation": { "name": "CPython", "version": "2.7.12" }, "platform": { "release": "4.4.0-93-generic", "system": "Linux" }, "pyOpenSSL": { "openssl_version": "1000207f", "version": "16.2.0" }, "requests": { "version": "2.18.4" }, "system_ssl": { "version": "1000207f" }, "urllib3": { "version": "1.22" }, "using_pyopenssl": true } ``` This command is only available on Requests v2.16.4 and greater. Otherwise, please provide some basic information about your system (Python version, operating system, &c).
{ "avatar_url": "https://avatars.githubusercontent.com/u/5271761?v=4", "events_url": "https://api.github.com/users/nateprewitt/events{/privacy}", "followers_url": "https://api.github.com/users/nateprewitt/followers", "following_url": "https://api.github.com/users/nateprewitt/following{/other_user}", "gists_url": "https://api.github.com/users/nateprewitt/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/nateprewitt", "id": 5271761, "login": "nateprewitt", "node_id": "MDQ6VXNlcjUyNzE3NjE=", "organizations_url": "https://api.github.com/users/nateprewitt/orgs", "received_events_url": "https://api.github.com/users/nateprewitt/received_events", "repos_url": "https://api.github.com/users/nateprewitt/repos", "site_admin": false, "starred_url": "https://api.github.com/users/nateprewitt/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/nateprewitt/subscriptions", "type": "User", "url": "https://api.github.com/users/nateprewitt", "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/4588/reactions" }
https://api.github.com/repos/psf/requests/issues/4588/timeline
null
completed
null
null
false
[ "Hi @selvaraju, we don’t modify the body so it’s unlikely Requests is doing anything other than returning what the server sent.\r\n\r\nWe’ll need you to provide a reproduction script in order to investigate. Until then, I don’t know if there’s anything we can do here.", "Hi @selvaraju, since this hasn't received ...
https://api.github.com/repos/psf/requests/issues/4587
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4587/labels{/name}
https://api.github.com/repos/psf/requests/issues/4587/comments
https://api.github.com/repos/psf/requests/issues/4587/events
https://github.com/psf/requests/issues/4587
313,933,682
MDU6SXNzdWUzMTM5MzM2ODI=
4,587
PEM lib SSL error
{ "avatar_url": "https://avatars.githubusercontent.com/u/1672189?v=4", "events_url": "https://api.github.com/users/kevr/events{/privacy}", "followers_url": "https://api.github.com/users/kevr/followers", "following_url": "https://api.github.com/users/kevr/following{/other_user}", "gists_url": "https://api.github.com/users/kevr/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/kevr", "id": 1672189, "login": "kevr", "node_id": "MDQ6VXNlcjE2NzIxODk=", "organizations_url": "https://api.github.com/users/kevr/orgs", "received_events_url": "https://api.github.com/users/kevr/received_events", "repos_url": "https://api.github.com/users/kevr/repos", "site_admin": false, "starred_url": "https://api.github.com/users/kevr/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/kevr/subscriptions", "type": "User", "url": "https://api.github.com/users/kevr", "user_view_type": "public" }
[]
closed
true
null
[]
null
2
2018-04-13T00:48:11Z
2021-09-08T03:00:21Z
2018-04-13T01:50:28Z
NONE
resolved
Summary. See https://github.com/requests/requests/issues/3702 What you expected. A correct connection or failure to verify ssl error What happened instead. SSL library traceback ``` 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) SSLError: [X509] PEM lib (_ssl.c:2831) ``` Reopening this previously closed issue.
{ "avatar_url": "https://avatars.githubusercontent.com/u/5271761?v=4", "events_url": "https://api.github.com/users/nateprewitt/events{/privacy}", "followers_url": "https://api.github.com/users/nateprewitt/followers", "following_url": "https://api.github.com/users/nateprewitt/following{/other_user}", "gists_url": "https://api.github.com/users/nateprewitt/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/nateprewitt", "id": 5271761, "login": "nateprewitt", "node_id": "MDQ6VXNlcjUyNzE3NjE=", "organizations_url": "https://api.github.com/users/nateprewitt/orgs", "received_events_url": "https://api.github.com/users/nateprewitt/received_events", "repos_url": "https://api.github.com/users/nateprewitt/repos", "site_admin": false, "starred_url": "https://api.github.com/users/nateprewitt/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/nateprewitt/subscriptions", "type": "User", "url": "https://api.github.com/users/nateprewitt", "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/4587/reactions" }
https://api.github.com/repos/psf/requests/issues/4587/timeline
null
completed
null
null
false
[ "Hi @kevr, thanks for taking the time to open this. So this error is a cert problem, as stated in the other ticket. We'd need the exact version of Python 2.7 you're using but it's likely coming out of [this function](https://github.com/python/cpython/blob/a61f5da54772b0ea6a7eccf21df08e61585ef712/Modules/_ssl.c#L282...
https://api.github.com/repos/psf/requests/issues/4586
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4586/labels{/name}
https://api.github.com/repos/psf/requests/issues/4586/comments
https://api.github.com/repos/psf/requests/issues/4586/events
https://github.com/psf/requests/pull/4586
313,766,889
MDExOlB1bGxSZXF1ZXN0MTgxMjMzNjM5
4,586
allowing params to get requests on session
{ "avatar_url": "https://avatars.githubusercontent.com/u/16767329?v=4", "events_url": "https://api.github.com/users/ggalves/events{/privacy}", "followers_url": "https://api.github.com/users/ggalves/followers", "following_url": "https://api.github.com/users/ggalves/following{/other_user}", "gists_url": "https://api.github.com/users/ggalves/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/ggalves", "id": 16767329, "login": "ggalves", "node_id": "MDQ6VXNlcjE2NzY3MzI5", "organizations_url": "https://api.github.com/users/ggalves/orgs", "received_events_url": "https://api.github.com/users/ggalves/received_events", "repos_url": "https://api.github.com/users/ggalves/repos", "site_admin": false, "starred_url": "https://api.github.com/users/ggalves/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/ggalves/subscriptions", "type": "User", "url": "https://api.github.com/users/ggalves", "user_view_type": "public" }
[]
closed
true
null
[]
null
2
2018-04-12T15:02:43Z
2021-09-03T00:11:05Z
2018-04-12T17:33:14Z
NONE
resolved
Simple fix to get method of Session class allowing it to receive params, just as requests.get would allow
{ "avatar_url": "https://avatars.githubusercontent.com/u/16767329?v=4", "events_url": "https://api.github.com/users/ggalves/events{/privacy}", "followers_url": "https://api.github.com/users/ggalves/followers", "following_url": "https://api.github.com/users/ggalves/following{/other_user}", "gists_url": "https://api.github.com/users/ggalves/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/ggalves", "id": 16767329, "login": "ggalves", "node_id": "MDQ6VXNlcjE2NzY3MzI5", "organizations_url": "https://api.github.com/users/ggalves/orgs", "received_events_url": "https://api.github.com/users/ggalves/received_events", "repos_url": "https://api.github.com/users/ggalves/repos", "site_admin": false, "starred_url": "https://api.github.com/users/ggalves/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/ggalves/subscriptions", "type": "User", "url": "https://api.github.com/users/ggalves", "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/4586/reactions" }
https://api.github.com/repos/psf/requests/issues/4586/timeline
null
null
false
{ "diff_url": "https://github.com/psf/requests/pull/4586.diff", "html_url": "https://github.com/psf/requests/pull/4586", "merged_at": null, "patch_url": "https://github.com/psf/requests/pull/4586.patch", "url": "https://api.github.com/repos/psf/requests/pulls/4586" }
true
[ "Hi @ggalves Can you share a bit more about what makes this PR necessary? `Session.get` already accepts `params` via `**kwargs` and passes them on appropriately to the best of my knowledge. Is something not behaving as you expect it to?", "Hi @sigmavirus24, I'm sorry, you are right, it's unnecessary.\r\n\r\nI cou...
https://api.github.com/repos/psf/requests/issues/4585
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4585/labels{/name}
https://api.github.com/repos/psf/requests/issues/4585/comments
https://api.github.com/repos/psf/requests/issues/4585/events
https://github.com/psf/requests/issues/4585
313,617,441
MDU6SXNzdWUzMTM2MTc0NDE=
4,585
tbody structure is not detected
{ "avatar_url": "https://avatars.githubusercontent.com/u/19487370?v=4", "events_url": "https://api.github.com/users/corytu/events{/privacy}", "followers_url": "https://api.github.com/users/corytu/followers", "following_url": "https://api.github.com/users/corytu/following{/other_user}", "gists_url": "https://api.github.com/users/corytu/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/corytu", "id": 19487370, "login": "corytu", "node_id": "MDQ6VXNlcjE5NDg3Mzcw", "organizations_url": "https://api.github.com/users/corytu/orgs", "received_events_url": "https://api.github.com/users/corytu/received_events", "repos_url": "https://api.github.com/users/corytu/repos", "site_admin": false, "starred_url": "https://api.github.com/users/corytu/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/corytu/subscriptions", "type": "User", "url": "https://api.github.com/users/corytu", "user_view_type": "public" }
[]
closed
true
null
[]
null
4
2018-04-12T08:02:41Z
2021-09-08T03:00:22Z
2018-04-12T12:04:22Z
NONE
resolved
## Expected Result I am parsing a table on an aspx webpage: https://www.ntuh.gov.tw/labmed/檢驗目錄/Lists/2015/BC.aspx. The `tr` elements are in a `tbody` structure. I expected to find them there. ## Actual Result An empty list is returned as if there's nothing. ## Reproduction Steps ```python import requests from selenium import webdriver from time import sleep from lxml import etree, html url = "https://www.ntuh.gov.tw/labmed/檢驗目錄/Lists/2015/BC.aspx" # With selenium browser = webdriver.Chrome() browser.get(url) # The url is visited with Chrome correctly root = etree.fromstring(browser.page_source, etree.HTMLParser()) root.xpath("//table[@class='ms-listviewtable']/tbody/tr") # It gives me several tr elements for further process # With requests result = "" while result == "": try: # Certificate is not verified to bypass the SSLError # Not secure though result = requests.get(url, verify = False) break except: sleep(5) continue # Transform it into an element tree root = etree.fromstring(result.content, etree.HTMLParser()) # Parse the information with the same XPath root.xpath("//table[@class='ms-listviewtable']/tbody/tr") # It gives me an empty list # However, this following line works: root.xpath("//table[@class='ms-listviewtable']/tr") ``` I've also posted my question on Stack Overflow: [The same xpath yields different extraction results from the same webpage](https://stackoverflow.com/questions/49757013/the-same-xpath-yields-different-extraction-results-from-the-same-webpage). ## System Information ```shell python -m requests.help ``` ``` { "chardet": { "version": "3.0.4" }, "cryptography": { "version": "2.2.1" }, "idna": { "version": "2.6" }, "implementation": { "name": "CPython", "version": "3.6.4" }, "platform": { "release": "17.5.0", "system": "Darwin" }, "pyOpenSSL": { "openssl_version": "100020ef", "version": "17.5.0" }, "requests": { "version": "2.18.4" }, "system_ssl": { "version": "100020ff" }, "urllib3": { "version": "1.22" }, "using_pyopenssl": 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" }
{ "+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/4585/reactions" }
https://api.github.com/repos/psf/requests/issues/4585/timeline
null
completed
null
null
false
[ "Hi there! Thanks for opening this issue. Unfortunately, it seems this is a request for help instead of a report of a defect in the project. Please use [StackOverflow](https://stackoverflow.com) for general usage questions instead and only report defects here.\r\n\r\nIt looks like you also already posted to StackOv...
https://api.github.com/repos/psf/requests/issues/4584
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4584/labels{/name}
https://api.github.com/repos/psf/requests/issues/4584/comments
https://api.github.com/repos/psf/requests/issues/4584/events
https://github.com/psf/requests/issues/4584
313,613,314
MDU6SXNzdWUzMTM2MTMzMTQ=
4,584
requests.get() never timeouted when https proxy connect success but not response data.
{ "avatar_url": "https://avatars.githubusercontent.com/u/10595480?v=4", "events_url": "https://api.github.com/users/jjnetcn/events{/privacy}", "followers_url": "https://api.github.com/users/jjnetcn/followers", "following_url": "https://api.github.com/users/jjnetcn/following{/other_user}", "gists_url": "https://api.github.com/users/jjnetcn/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jjnetcn", "id": 10595480, "login": "jjnetcn", "node_id": "MDQ6VXNlcjEwNTk1NDgw", "organizations_url": "https://api.github.com/users/jjnetcn/orgs", "received_events_url": "https://api.github.com/users/jjnetcn/received_events", "repos_url": "https://api.github.com/users/jjnetcn/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jjnetcn/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jjnetcn/subscriptions", "type": "User", "url": "https://api.github.com/users/jjnetcn", "user_view_type": "public" }
[]
closed
true
null
[]
null
1
2018-04-12T07:49:27Z
2021-09-05T00:07:00Z
2019-02-14T14:56:49Z
NONE
resolved
requests.get() never timeouted when https proxy connect success but not response data. 1: we create the server at port 4444 but not response any data. bash$ nc -l 4444 2:and then call request.get with https proxy bash$ python3 import requests requests.get("https://www.baidu.com", timeout=5, proxies={"http":"http://127.0.0.1:4444", "https":"http://127.0.0.1:4444"}) this command never return in urllib3. it block in HTTPSConnectionPool::urlopen, because HTTPS will call HTTPSConnectionPool::_prepare_conn() to prepare_conn( note http proxy never do this), and send "CONNECT ... HTTP/1.0" and blocked in response. because of socket.create_connection's timeout is None means "never timeouted", backstrace to requests, it new HTTPSConnectionPool() object thought connection_from_url without timeout. so i patched requests/adapters.py and now work --------------------------------------------- del conn = self.get_connection(request.url, proxies) add conn = self.get_connection(request.url, proxies, timeout) del def get_connection(self, url, proxies=None): add def get_connection(self, url, proxies=None, timeout=None): del proxy_manager = self.proxy_manager_for(proxy) add proxy_manager = self.proxy_manager_for(proxy,timeout) i am sorry i am not familiar markdown
{ "avatar_url": "https://avatars.githubusercontent.com/u/6740665?v=4", "events_url": "https://api.github.com/users/lmiguelvargasf/events{/privacy}", "followers_url": "https://api.github.com/users/lmiguelvargasf/followers", "following_url": "https://api.github.com/users/lmiguelvargasf/following{/other_user}", "gists_url": "https://api.github.com/users/lmiguelvargasf/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/lmiguelvargasf", "id": 6740665, "login": "lmiguelvargasf", "node_id": "MDQ6VXNlcjY3NDA2NjU=", "organizations_url": "https://api.github.com/users/lmiguelvargasf/orgs", "received_events_url": "https://api.github.com/users/lmiguelvargasf/received_events", "repos_url": "https://api.github.com/users/lmiguelvargasf/repos", "site_admin": false, "starred_url": "https://api.github.com/users/lmiguelvargasf/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/lmiguelvargasf/subscriptions", "type": "User", "url": "https://api.github.com/users/lmiguelvargasf", "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/4584/reactions" }
https://api.github.com/repos/psf/requests/issues/4584/timeline
null
completed
null
null
false
[ "Closed due to inactivity." ]
https://api.github.com/repos/psf/requests/issues/4583
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4583/labels{/name}
https://api.github.com/repos/psf/requests/issues/4583/comments
https://api.github.com/repos/psf/requests/issues/4583/events
https://github.com/psf/requests/pull/4583
313,516,468
MDExOlB1bGxSZXF1ZXN0MTgxMDUwMTcz
4,583
Add a comment about lowercase env. variables precedence over uppercase
{ "avatar_url": "https://avatars.githubusercontent.com/u/19931768?v=4", "events_url": "https://api.github.com/users/ZuZuD/events{/privacy}", "followers_url": "https://api.github.com/users/ZuZuD/followers", "following_url": "https://api.github.com/users/ZuZuD/following{/other_user}", "gists_url": "https://api.github.com/users/ZuZuD/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/ZuZuD", "id": 19931768, "login": "ZuZuD", "node_id": "MDQ6VXNlcjE5OTMxNzY4", "organizations_url": "https://api.github.com/users/ZuZuD/orgs", "received_events_url": "https://api.github.com/users/ZuZuD/received_events", "repos_url": "https://api.github.com/users/ZuZuD/repos", "site_admin": false, "starred_url": "https://api.github.com/users/ZuZuD/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/ZuZuD/subscriptions", "type": "User", "url": "https://api.github.com/users/ZuZuD", "user_view_type": "public" }
[]
closed
true
null
[]
null
5
2018-04-11T22:59:58Z
2021-09-03T00:11:00Z
2018-05-13T13:15:57Z
NONE
resolved
As suggested by @sigmavirus24 for the follow-up of issue #4579
{ "avatar_url": "https://avatars.githubusercontent.com/u/5271761?v=4", "events_url": "https://api.github.com/users/nateprewitt/events{/privacy}", "followers_url": "https://api.github.com/users/nateprewitt/followers", "following_url": "https://api.github.com/users/nateprewitt/following{/other_user}", "gists_url": "https://api.github.com/users/nateprewitt/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/nateprewitt", "id": 5271761, "login": "nateprewitt", "node_id": "MDQ6VXNlcjUyNzE3NjE=", "organizations_url": "https://api.github.com/users/nateprewitt/orgs", "received_events_url": "https://api.github.com/users/nateprewitt/received_events", "repos_url": "https://api.github.com/users/nateprewitt/repos", "site_admin": false, "starred_url": "https://api.github.com/users/nateprewitt/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/nateprewitt/subscriptions", "type": "User", "url": "https://api.github.com/users/nateprewitt", "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/4583/reactions" }
https://api.github.com/repos/psf/requests/issues/4583/timeline
null
null
false
{ "diff_url": "https://github.com/psf/requests/pull/4583.diff", "html_url": "https://github.com/psf/requests/pull/4583", "merged_at": "2018-05-13T13:15:57Z", "patch_url": "https://github.com/psf/requests/pull/4583.patch", "url": "https://api.github.com/repos/psf/requests/pulls/4583" }
true
[ "Sure @nateprewitt that's updated!", "It also looks like we have a windows failure in the tests but it seems like it may be related to a dependency or pipenv issue. Not really relevant for a comment change but something we’ll want to fix.", "Let's keep it concise then @nateprewitt 👍 ", "Thanks @ZuZud! Kickin...
https://api.github.com/repos/psf/requests/issues/4582
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4582/labels{/name}
https://api.github.com/repos/psf/requests/issues/4582/comments
https://api.github.com/repos/psf/requests/issues/4582/events
https://github.com/psf/requests/issues/4582
312,783,833
MDU6SXNzdWUzMTI3ODM4MzM=
4,582
status_code return 200 in fact , it's should return 302
{ "avatar_url": "https://avatars.githubusercontent.com/u/12119679?v=4", "events_url": "https://api.github.com/users/peibibing/events{/privacy}", "followers_url": "https://api.github.com/users/peibibing/followers", "following_url": "https://api.github.com/users/peibibing/following{/other_user}", "gists_url": "https://api.github.com/users/peibibing/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/peibibing", "id": 12119679, "login": "peibibing", "node_id": "MDQ6VXNlcjEyMTE5Njc5", "organizations_url": "https://api.github.com/users/peibibing/orgs", "received_events_url": "https://api.github.com/users/peibibing/received_events", "repos_url": "https://api.github.com/users/peibibing/repos", "site_admin": false, "starred_url": "https://api.github.com/users/peibibing/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/peibibing/subscriptions", "type": "User", "url": "https://api.github.com/users/peibibing", "user_view_type": "public" }
[]
closed
true
null
[]
null
2
2018-04-10T06:04:21Z
2021-09-08T03:00:23Z
2018-04-10T10:13:50Z
NONE
resolved
Summary. ## Expected Result status_code return 302 ## Actual Result status_code return 200 ## Reproduction Steps ```python In [17]: import requests In [18]: a=requests.get( 'http://spj.anshan.gov.cn/aszwdt/epointzwmhwz/pages/default/legal/wanttodo/') In [19]: a.status_code Out[19]: 200 In [20]: a.url Out[20]: u'http://spj.anshan.gov.cn/aszwdt/epointzwmhwz/pages/default/index;jsessionid=CDF3C67801FB507FBD15B6FC2366244E' ``` ## System Information ``` { "chardet": { "version": "3.0.2" }, "cryptography": { "version": "1.8.1" }, "idna": { "version": "" }, "implementation": { "name": "CPython", "version": "2.7.13" }, "platform": { "release": "16.7.0", "system": "Darwin" }, "pyOpenSSL": { "openssl_version": "1010005f", "version": "17.0.0" }, "requests": { "version": "2.18.4" }, "system_ssl": { "version": "100020ff" }, "urllib3": { "version": "1.22" }, "using_pyopenssl": true } ``` python version: 2.7.14 2.7.5
{ "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/4582/reactions" }
https://api.github.com/repos/psf/requests/issues/4582/timeline
null
completed
null
null
false
[ "The 302 status code is in ```a.history``` because requests had already handled the redirect.", "See also http://docs.python-requests.org/en/master/user/quickstart/?highlight=redirects#redirection-and-history" ]
https://api.github.com/repos/psf/requests/issues/4581
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4581/labels{/name}
https://api.github.com/repos/psf/requests/issues/4581/comments
https://api.github.com/repos/psf/requests/issues/4581/events
https://github.com/psf/requests/pull/4581
312,734,163
MDExOlB1bGxSZXF1ZXN0MTgwNDYyMDc0
4,581
Update to return correct value for multiple_domains().
{ "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" }
[ { "color": "1cff91", "default": false, "description": "", "id": 860696300, "name": "3.0", "node_id": "MDU6TGFiZWw4NjA2OTYzMDA=", "url": "https://api.github.com/repos/psf/requests/labels/3.0" } ]
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" }
14
2018-04-10T00:36:51Z
2024-05-20T14:35:47Z
2024-05-20T14:35:47Z
NONE
null
requests/cookies.py Adjust flow to add domains to list as the first operation in the loop, then convert to a set and check the length of that set is greater than 1. Add tests to pass for a single domain, two cookies with the same domain, and multiple domains. Perhaps not the most efficient method, but it works.
{ "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/4581/reactions" }
https://api.github.com/repos/psf/requests/issues/4581/timeline
null
null
false
{ "diff_url": "https://github.com/psf/requests/pull/4581.diff", "html_url": "https://github.com/psf/requests/pull/4581", "merged_at": null, "patch_url": "https://github.com/psf/requests/pull/4581.patch", "url": "https://api.github.com/repos/psf/requests/pulls/4581" }
true
[ "#4557 ", "@nateprewitt Thank you kindly for the helpful feedback!\r\n\r\nI've adjusted the method to make use of set in place of the domains list. I've also adjusted the structure of the conditional a bit and added an additional test check that null values are handled correctly by the method.", "@nateprewitt ...
https://api.github.com/repos/psf/requests/issues/4580
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4580/labels{/name}
https://api.github.com/repos/psf/requests/issues/4580/comments
https://api.github.com/repos/psf/requests/issues/4580/events
https://github.com/psf/requests/issues/4580
312,526,300
MDU6SXNzdWUzMTI1MjYzMDA=
4,580
Suggest: let json.dumps keeps non-ASCII characters when sending json request
{ "avatar_url": "https://avatars.githubusercontent.com/u/1781999?v=4", "events_url": "https://api.github.com/users/ahuigo/events{/privacy}", "followers_url": "https://api.github.com/users/ahuigo/followers", "following_url": "https://api.github.com/users/ahuigo/following{/other_user}", "gists_url": "https://api.github.com/users/ahuigo/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/ahuigo", "id": 1781999, "login": "ahuigo", "node_id": "MDQ6VXNlcjE3ODE5OTk=", "organizations_url": "https://api.github.com/users/ahuigo/orgs", "received_events_url": "https://api.github.com/users/ahuigo/received_events", "repos_url": "https://api.github.com/users/ahuigo/repos", "site_admin": false, "starred_url": "https://api.github.com/users/ahuigo/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/ahuigo/subscriptions", "type": "User", "url": "https://api.github.com/users/ahuigo", "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": "f7c6c7", "default": false, "description": null, ...
closed
true
{ "avatar_url": "https://avatars.githubusercontent.com/u/1781999?v=4", "events_url": "https://api.github.com/users/ahuigo/events{/privacy}", "followers_url": "https://api.github.com/users/ahuigo/followers", "following_url": "https://api.github.com/users/ahuigo/following{/other_user}", "gists_url": "https://api.github.com/users/ahuigo/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/ahuigo", "id": 1781999, "login": "ahuigo", "node_id": "MDQ6VXNlcjE3ODE5OTk=", "organizations_url": "https://api.github.com/users/ahuigo/orgs", "received_events_url": "https://api.github.com/users/ahuigo/received_events", "repos_url": "https://api.github.com/users/ahuigo/repos", "site_admin": false, "starred_url": "https://api.github.com/users/ahuigo/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/ahuigo/subscriptions", "type": "User", "url": "https://api.github.com/users/ahuigo", "user_view_type": "public" }
[ { "avatar_url": "https://avatars.githubusercontent.com/u/1781999?v=4", "events_url": "https://api.github.com/users/ahuigo/events{/privacy}", "followers_url": "https://api.github.com/users/ahuigo/followers", "following_url": "https://api.github.com/users/ahuigo/following{/other_user}", "gists_url...
null
11
2018-04-09T13:15:44Z
2021-09-08T02:10:07Z
2018-04-24T14:05:30Z
NONE
resolved
## Summary When I send a json request, the json.dumps **does not keeps non-ASCII characters**. ## Reproduction Steps ``` cat <<MM | python3 - & from flask import Flask,request app = Flask('') @app.route('/', methods=['POST', 'GET']) def test(): return(request.data) app.run() MM cat <<MM | python3 - import time import requests as r time.sleep(1) print(r.post('http://localhost:5000/', json={'bar':'程序员'}).text) MM ``` ## Expected Result I expect result keeps *non-ASCII* request: `{"bar": "程序员"}` ## Actual Result `{"bar": "\u7a0b\u5e8f\u5458"}` ## Suggest Modify the models `vim modles.py +458` to keep the non-ASCII characters. For example: `body = complexjson.dumps(json, ensure_ascii=False)` ``` >>> json.dumps('程序员', ensure_ascii=False) '"程序员"' >>> json.dumps('程序员') '"\\u7a0b\\u5e8f\\u5458"' ``` ## System Information $ python -m requests.help ``` { "chardet": { "version": "3.0.4" }, "cryptography": { "version": "" }, "implementation": { "name": "CPython", "version": "3.6.1" }, "platform": { "release": "15.6.0", "system": "Darwin" }, "pyOpenSSL": { "openssl_version": "", "version": null }, "requests": { "version": "2.18.1" }, "system_ssl": { "version": "100020cf" }, "urllib3": { "version": "1.21.1" }, "using_pyopenssl": 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" }
{ "+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/4580/reactions" }
https://api.github.com/repos/psf/requests/issues/4580/timeline
null
completed
null
null
false
[ "Does\r\n\r\n```py\r\n\r\ncat <<MM | python3 -\r\nimport json\r\nimport time\r\nimport requests as r\r\ntime.sleep(1)\r\nprint(r.post('http://localhost:5000/', data=json.dumps({'bar':'程序员'}), headers={'Content-Type': 'application/json'}).text)\r\nMM\r\n```\r\n\r\nDo the right thing?", "Also, looking at our source...
https://api.github.com/repos/psf/requests/issues/4579
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4579/labels{/name}
https://api.github.com/repos/psf/requests/issues/4579/comments
https://api.github.com/repos/psf/requests/issues/4579/events
https://github.com/psf/requests/issues/4579
312,457,919
MDU6SXNzdWUzMTI0NTc5MTk=
4,579
os.environ lowercase takes precedence over uppercase
{ "avatar_url": "https://avatars.githubusercontent.com/u/19931768?v=4", "events_url": "https://api.github.com/users/ZuZuD/events{/privacy}", "followers_url": "https://api.github.com/users/ZuZuD/followers", "following_url": "https://api.github.com/users/ZuZuD/following{/other_user}", "gists_url": "https://api.github.com/users/ZuZuD/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/ZuZuD", "id": 19931768, "login": "ZuZuD", "node_id": "MDQ6VXNlcjE5OTMxNzY4", "organizations_url": "https://api.github.com/users/ZuZuD/orgs", "received_events_url": "https://api.github.com/users/ZuZuD/received_events", "repos_url": "https://api.github.com/users/ZuZuD/repos", "site_admin": false, "starred_url": "https://api.github.com/users/ZuZuD/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/ZuZuD/subscriptions", "type": "User", "url": "https://api.github.com/users/ZuZuD", "user_view_type": "public" }
[]
closed
true
null
[]
null
5
2018-04-09T09:29:40Z
2021-09-08T02:09:57Z
2018-05-20T19:17:16Z
NONE
resolved
I wonder if there is a specific reason for the lowercase http_proxy to take precedence over its uppercase version (same behavior for the other os.environ). The convention is to use uppercase for environment variables and setting both could potentially lead users to unexpected behavior. https://github.com/requests/requests/blob/master/requests/utils.py#L699 Can someone give me the original reason why things have been done like this? Thanks! ## System Information $ python -m requests.help { "chardet": { "version": "3.0.4" }, "cryptography": { "version": "" }, "idna": { "version": "2.6" }, "implementation": { "name": "CPython", "version": "2.7.13" }, "platform": { "release": "4.9.85-38.58.amzn1.x86_64", "system": "Linux" }, "pyOpenSSL": { "openssl_version": "", "version": null }, "requests": { "version": "2.18.4" }, "system_ssl": { "version": "100020bf" }, "urllib3": { "version": "1.22" }, "using_pyopenssl": false }
{ "avatar_url": "https://avatars.githubusercontent.com/u/5271761?v=4", "events_url": "https://api.github.com/users/nateprewitt/events{/privacy}", "followers_url": "https://api.github.com/users/nateprewitt/followers", "following_url": "https://api.github.com/users/nateprewitt/following{/other_user}", "gists_url": "https://api.github.com/users/nateprewitt/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/nateprewitt", "id": 5271761, "login": "nateprewitt", "node_id": "MDQ6VXNlcjUyNzE3NjE=", "organizations_url": "https://api.github.com/users/nateprewitt/orgs", "received_events_url": "https://api.github.com/users/nateprewitt/received_events", "repos_url": "https://api.github.com/users/nateprewitt/repos", "site_admin": false, "starred_url": "https://api.github.com/users/nateprewitt/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/nateprewitt/subscriptions", "type": "User", "url": "https://api.github.com/users/nateprewitt", "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/4579/reactions" }
https://api.github.com/repos/psf/requests/issues/4579/timeline
null
completed
null
null
false
[ "Hi @ZuZuD, to clarify, your concern is about `no_proxy` being given precedence over `NO_PROXY`? I believe the lambda function was designed to give preference to whatever casing it was handed first, and then attempt to find an uppercased version if that did not work.\r\n\r\nThe `no_proxy` check was added later (#94...
https://api.github.com/repos/psf/requests/issues/4578
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4578/labels{/name}
https://api.github.com/repos/psf/requests/issues/4578/comments
https://api.github.com/repos/psf/requests/issues/4578/events
https://github.com/psf/requests/issues/4578
312,412,880
MDU6SXNzdWUzMTI0MTI4ODA=
4,578
docstring inconsistent with requests.api.post
{ "avatar_url": "https://avatars.githubusercontent.com/u/30798866?v=4", "events_url": "https://api.github.com/users/YannLuo/events{/privacy}", "followers_url": "https://api.github.com/users/YannLuo/followers", "following_url": "https://api.github.com/users/YannLuo/following{/other_user}", "gists_url": "https://api.github.com/users/YannLuo/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/YannLuo", "id": 30798866, "login": "YannLuo", "node_id": "MDQ6VXNlcjMwNzk4ODY2", "organizations_url": "https://api.github.com/users/YannLuo/orgs", "received_events_url": "https://api.github.com/users/YannLuo/received_events", "repos_url": "https://api.github.com/users/YannLuo/repos", "site_admin": false, "starred_url": "https://api.github.com/users/YannLuo/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/YannLuo/subscriptions", "type": "User", "url": "https://api.github.com/users/YannLuo", "user_view_type": "public" }
[]
closed
true
null
[]
null
3
2018-04-09T06:46:13Z
2021-09-08T03:00:22Z
2018-04-12T18:41:15Z
NONE
resolved
I run the `pytest tests` and find `requests.api.post` receive `data` whose type is `list_iterator`, which is inconsistent with its docstring. ## Expected Result modify docstring of `requests.api.post` to `:param data: (optional) Dictionary (will be form-encoded), bytes,list_iterator,or file-like object to send in the body of the :class:Request.` ## Actual Result what the docstring shows. ## Reproduction Steps the test case is in `requests/tests/test_lowlevel.py::test_chunked_upload`, which `data` is a `iter` and passed to `requests.api.post`. ```python import requests def test_chunked_upload(): """can safely send generators""" close_server = threading.Event() server = Server.basic_response_server(wait_to_close_event=close_server) data = iter([b'a', b'b', b'c']) with server as (host, port): url = 'http://{0}:{1}/'.format(host, port) r = requests.post(url, data=data, stream=True) close_server.set() # release server block assert r.status_code == 200 assert r.request.headers['Transfer-Encoding'] == 'chunked' ``` ## System Information ``` { "chardet": { "version": "3.0.4" }, "cryptography": { "version": "2.2.2" }, "idna": { "version": "2.6" }, "implementation": { "name": "CPython", "version": "3.6.5" }, "platform": { "release": "17.5.0", "system": "Darwin" }, "pyOpenSSL": { "openssl_version": "1010008f", "version": "17.5.0" }, "requests": { "version": "2.18.4" }, "system_ssl": { "version": "100020ef" }, "urllib3": { "version": "1.22" }, "using_pyopenssl": true } ```
{ "avatar_url": "https://avatars.githubusercontent.com/u/5271761?v=4", "events_url": "https://api.github.com/users/nateprewitt/events{/privacy}", "followers_url": "https://api.github.com/users/nateprewitt/followers", "following_url": "https://api.github.com/users/nateprewitt/following{/other_user}", "gists_url": "https://api.github.com/users/nateprewitt/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/nateprewitt", "id": 5271761, "login": "nateprewitt", "node_id": "MDQ6VXNlcjUyNzE3NjE=", "organizations_url": "https://api.github.com/users/nateprewitt/orgs", "received_events_url": "https://api.github.com/users/nateprewitt/received_events", "repos_url": "https://api.github.com/users/nateprewitt/repos", "site_admin": false, "starred_url": "https://api.github.com/users/nateprewitt/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/nateprewitt/subscriptions", "type": "User", "url": "https://api.github.com/users/nateprewitt", "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/4578/reactions" }
https://api.github.com/repos/psf/requests/issues/4578/timeline
null
completed
null
null
false
[ "Hi @YannLuo,\r\n\r\nRequests will take an iterable object containing bytes for the data param which is noted in [the documentation](http://docs.python-requests.org/en/master/user/advanced/#chunk-encoded-requests). We could specify in the docstring that bytes iterables work here too, but it's a more verbose explana...
https://api.github.com/repos/psf/requests/issues/4577
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4577/labels{/name}
https://api.github.com/repos/psf/requests/issues/4577/comments
https://api.github.com/repos/psf/requests/issues/4577/events
https://github.com/psf/requests/issues/4577
312,288,234
MDU6SXNzdWUzMTIyODgyMzQ=
4,577
r
{ "avatar_url": "https://avatars.githubusercontent.com/u/3155271?v=4", "events_url": "https://api.github.com/users/noamvaza/events{/privacy}", "followers_url": "https://api.github.com/users/noamvaza/followers", "following_url": "https://api.github.com/users/noamvaza/following{/other_user}", "gists_url": "https://api.github.com/users/noamvaza/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/noamvaza", "id": 3155271, "login": "noamvaza", "node_id": "MDQ6VXNlcjMxNTUyNzE=", "organizations_url": "https://api.github.com/users/noamvaza/orgs", "received_events_url": "https://api.github.com/users/noamvaza/received_events", "repos_url": "https://api.github.com/users/noamvaza/repos", "site_admin": false, "starred_url": "https://api.github.com/users/noamvaza/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/noamvaza/subscriptions", "type": "User", "url": "https://api.github.com/users/noamvaza", "user_view_type": "public" }
[]
closed
true
null
[]
null
0
2018-04-08T09:11:05Z
2021-09-08T03:00:24Z
2018-04-08T15:19:31Z
NONE
resolved
Summary. ## Expected Result What you expected. ## Actual Result What happened instead. ## Reproduction Steps ```python import requests ``` ## System Information $ python -m requests.help ``` <paste here> ``` This command is only available on Requests v2.16.4 and greater. Otherwise, please provide some basic information about your system (Python version, operating system, &c).
{ "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/4577/reactions" }
https://api.github.com/repos/psf/requests/issues/4577/timeline
null
completed
null
null
false
[]
https://api.github.com/repos/psf/requests/issues/4576
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4576/labels{/name}
https://api.github.com/repos/psf/requests/issues/4576/comments
https://api.github.com/repos/psf/requests/issues/4576/events
https://github.com/psf/requests/issues/4576
312,268,340
MDU6SXNzdWUzMTIyNjgzNDA=
4,576
POST of urlencoded data breaks HTTPSignatureAuth
{ "avatar_url": "https://avatars.githubusercontent.com/u/5143256?v=4", "events_url": "https://api.github.com/users/hannes-ucsc/events{/privacy}", "followers_url": "https://api.github.com/users/hannes-ucsc/followers", "following_url": "https://api.github.com/users/hannes-ucsc/following{/other_user}", "gists_url": "https://api.github.com/users/hannes-ucsc/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/hannes-ucsc", "id": 5143256, "login": "hannes-ucsc", "node_id": "MDQ6VXNlcjUxNDMyNTY=", "organizations_url": "https://api.github.com/users/hannes-ucsc/orgs", "received_events_url": "https://api.github.com/users/hannes-ucsc/received_events", "repos_url": "https://api.github.com/users/hannes-ucsc/repos", "site_admin": false, "starred_url": "https://api.github.com/users/hannes-ucsc/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/hannes-ucsc/subscriptions", "type": "User", "url": "https://api.github.com/users/hannes-ucsc", "user_view_type": "public" }
[]
closed
true
null
[]
null
1
2018-04-08T03:29:22Z
2021-09-08T03:00:24Z
2018-04-08T06:37:14Z
NONE
resolved
`HTTPSignatureAuth` doesn't work with POST and the `application/x-www-form-urlencoded` content type. https://github.com/requests/requests/blob/e4fc3539b43416f9e9ba6837d73b1b7392d4b242/requests/models.py#L105 The `urlencode()` invocation in the line above returns a `str`, which is then assigned to the `body` attribute of the `PreparedRequest` instance. I think `HTTPSignatureAuth` expects the body to be `bytes`. ## Expected Result Request is made. ## Actual Result ``` Traceback (most recent call last): File "<input>", line 1, in <module> File "/Users/hannes/workspace/hca/data-store/wip/.venv/lib/python3.6/site-packages/requests/api.py", line 112, in post return request('post', url, data=data, json=json, **kwargs) File "/Users/hannes/workspace/hca/data-store/wip/.venv/lib/python3.6/site-packages/requests/api.py", line 58, in request return session.request(method=method, url=url, **kwargs) File "/Users/hannes/workspace/hca/data-store/wip/.venv/lib/python3.6/site-packages/requests/sessions.py", line 494, in request prep = self.prepare_request(req) File "/Users/hannes/workspace/hca/data-store/wip/.venv/lib/python3.6/site-packages/requests/sessions.py", line 437, in prepare_request hooks=merge_hooks(request.hooks, self.hooks), File "/Users/hannes/workspace/hca/data-store/wip/.venv/lib/python3.6/site-packages/requests/models.py", line 309, in prepare self.prepare_auth(auth, url) File "/Users/hannes/workspace/hca/data-store/wip/.venv/lib/python3.6/site-packages/requests/models.py", line 540, in prepare_auth r = auth(self) File "/Users/hannes/workspace/hca/data-store/wip/.venv/lib/python3.6/site-packages/requests_http_signature/__init__.py", line 89, in __call__ self.add_digest(request) File "/Users/hannes/workspace/hca/data-store/wip/.venv/lib/python3.6/site-packages/requests_http_signature/__init__.py", line 69, in add_digest digest = self.hasher_constructor(request.body).digest() TypeError: Unicode-objects must be encoded before hashing ``` ## Reproduction Steps ```python import requests import requests_http_signature auth = requests_http_signature.HTTPSignatureAuth(key=b'123', key_id='foo') requests.post('http://localhost/', data={'foo':'bar'}, auth=auth) ``` ## System Information $ python -m requests.help ``` { "chardet": { "version": "3.0.4" }, "cryptography": { "version": "" }, "idna": { "version": "2.6" }, "implementation": { "name": "CPython", "version": "3.6.4" }, "platform": { "release": "17.4.0", "system": "Darwin" }, "pyOpenSSL": { "openssl_version": "", "version": null }, "requests": { "version": "2.18.4" }, "system_ssl": { "version": "100020ef" }, "urllib3": { "version": "1.22" }, "using_pyopenssl": false } ```
{ "avatar_url": "https://avatars.githubusercontent.com/u/5271761?v=4", "events_url": "https://api.github.com/users/nateprewitt/events{/privacy}", "followers_url": "https://api.github.com/users/nateprewitt/followers", "following_url": "https://api.github.com/users/nateprewitt/following{/other_user}", "gists_url": "https://api.github.com/users/nateprewitt/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/nateprewitt", "id": 5271761, "login": "nateprewitt", "node_id": "MDQ6VXNlcjUyNzE3NjE=", "organizations_url": "https://api.github.com/users/nateprewitt/orgs", "received_events_url": "https://api.github.com/users/nateprewitt/received_events", "repos_url": "https://api.github.com/users/nateprewitt/repos", "site_admin": false, "starred_url": "https://api.github.com/users/nateprewitt/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/nateprewitt/subscriptions", "type": "User", "url": "https://api.github.com/users/nateprewitt", "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/4576/reactions" }
https://api.github.com/repos/psf/requests/issues/4576/timeline
null
completed
null
null
false
[ "Hey @hannes-ucsc, the `urlencode` function in Python 3 returns an ascii string, but I don't believe we have a guarantee to provide data we urlencode as bytes. We currently return the body in the native \"string\" format of your Python version, unless explicitly given something else, which I believe makes sense.\r\...
https://api.github.com/repos/psf/requests/issues/4575
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4575/labels{/name}
https://api.github.com/repos/psf/requests/issues/4575/comments
https://api.github.com/repos/psf/requests/issues/4575/events
https://github.com/psf/requests/issues/4575
312,000,337
MDU6SXNzdWUzMTIwMDAzMzc=
4,575
Too many open files (CLOSE_WAIT connections)
{ "avatar_url": "https://avatars.githubusercontent.com/u/6002677?v=4", "events_url": "https://api.github.com/users/j-frost/events{/privacy}", "followers_url": "https://api.github.com/users/j-frost/followers", "following_url": "https://api.github.com/users/j-frost/following{/other_user}", "gists_url": "https://api.github.com/users/j-frost/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/j-frost", "id": 6002677, "login": "j-frost", "node_id": "MDQ6VXNlcjYwMDI2Nzc=", "organizations_url": "https://api.github.com/users/j-frost/orgs", "received_events_url": "https://api.github.com/users/j-frost/received_events", "repos_url": "https://api.github.com/users/j-frost/repos", "site_admin": false, "starred_url": "https://api.github.com/users/j-frost/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/j-frost/subscriptions", "type": "User", "url": "https://api.github.com/users/j-frost", "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" }
3
2018-04-06T14:36:45Z
2024-05-20T14:37:03Z
2024-05-20T14:37:03Z
NONE
null
I'm importing data from a remote API. It's not the best API, so it requires me to do a lot of requests for any given data point. Since the data isn't time invariant, I need to first get a full set and then import it. Both sides use requests to talk to REST endpoints. The problem is that because I need to import one whole dataset all at once, I have a pretty long running celery task. In our test environment, everything worked great, so I'm ruling out business logic errors, but maybe I or a library provider is using requests wrong -- or this is a bug. ## Problem In my production environment, I get ` HTTPSConnectionPool(host='<redacted>', port=443): Max retries exceeded with url: /rest/api/2/<redacted> (Caused by NewConnectionError('<urllib3.connection.VerifiedHTTPSConnection object at 0x7f05734547b8>: Failed to establish a new connection: [Errno 24] Too many open files',)) ` ## Expected Result New connections can be made while respecting `/etc/security/limits.conf` (which in my case sets nofile to 10240). Requests manages open file descriptors for `CLOSE_WAIT` sockets and recycles them as appropriate. ## Actual Result New connections cannot be made after a certain point. I suspect this might be 1024, because when monitoring `lsof -i | grep CLOSE_WAIT | wc -l`, it never exceeds this number. Calling `gc.collect()` after importing parts of the data does not help. `CLOSE_WAIT` socket file descriptors are only released once the celery task completes and the whole process ends. The next run looks similar, so it seems at least when the process ends, everything is cleaned up properly. ## Reproduction Steps Honestly I don't know what to put here, because I'm just using API wrappers. Please tell me what you need to know. I can tell you this happens independently with both ingress and egress wrappers (which talk to entirely different systems and APIs), and a colleague and I have tried to find any held references and have found none. ## System Information $ python -m requests.help ``` { "chardet": { "version": "3.0.4" }, "cryptography": { "version": "2.0.3" }, "idna": { "version": "2.6" }, "implementation": { "name": "CPython", "version": "3.6.4" }, "platform": { "release": "4.4.0-109-generic", "system": "Linux" }, "pyOpenSSL": { "openssl_version": "1010006f", "version": "17.2.0" }, "requests": { "version": "2.18.4" }, "system_ssl": { "version": "1000207f" }, "urllib3": { "version": "1.22" }, "using_pyopenssl": true } ```
{ "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": 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/4575/reactions" }
https://api.github.com/repos/psf/requests/issues/4575/timeline
null
completed
null
null
false
[ "Maybe help for you:\r\n \" a lot of close/wait usually means that there are a lot of connections being opened and closed rapidly. It takes time for those connections to be cleared on the server even with a proper request to close which is normal TCP operation. I'd suggest you review your code to see if something i...
https://api.github.com/repos/psf/requests/issues/4574
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4574/labels{/name}
https://api.github.com/repos/psf/requests/issues/4574/comments
https://api.github.com/repos/psf/requests/issues/4574/events
https://github.com/psf/requests/issues/4574
311,586,434
MDU6SXNzdWUzMTE1ODY0MzQ=
4,574
Default data should be dict, not list
{ "avatar_url": "https://avatars.githubusercontent.com/u/2925345?v=4", "events_url": "https://api.github.com/users/kalaomer/events{/privacy}", "followers_url": "https://api.github.com/users/kalaomer/followers", "following_url": "https://api.github.com/users/kalaomer/following{/other_user}", "gists_url": "https://api.github.com/users/kalaomer/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/kalaomer", "id": 2925345, "login": "kalaomer", "node_id": "MDQ6VXNlcjI5MjUzNDU=", "organizations_url": "https://api.github.com/users/kalaomer/orgs", "received_events_url": "https://api.github.com/users/kalaomer/received_events", "repos_url": "https://api.github.com/users/kalaomer/repos", "site_admin": false, "starred_url": "https://api.github.com/users/kalaomer/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/kalaomer/subscriptions", "type": "User", "url": "https://api.github.com/users/kalaomer", "user_view_type": "public" }
[ { "color": "f7c6c7", "default": false, "description": null, "id": 167537670, "name": "Propose Close", "node_id": "MDU6TGFiZWwxNjc1Mzc2NzA=", "url": "https://api.github.com/repos/psf/requests/labels/Propose%20Close" } ]
closed
true
null
[]
null
2
2018-04-05T12:17:04Z
2021-09-08T03:00:22Z
2018-04-12T18:43:27Z
NONE
resolved
https://github.com/requests/requests/blob/e4fc3539b43416f9e9ba6837d73b1b7392d4b242/requests/models.py#L223 In request class, empty data should be dict, not list.
{ "avatar_url": "https://avatars.githubusercontent.com/u/5271761?v=4", "events_url": "https://api.github.com/users/nateprewitt/events{/privacy}", "followers_url": "https://api.github.com/users/nateprewitt/followers", "following_url": "https://api.github.com/users/nateprewitt/following{/other_user}", "gists_url": "https://api.github.com/users/nateprewitt/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/nateprewitt", "id": 5271761, "login": "nateprewitt", "node_id": "MDQ6VXNlcjUyNzE3NjE=", "organizations_url": "https://api.github.com/users/nateprewitt/orgs", "received_events_url": "https://api.github.com/users/nateprewitt/received_events", "repos_url": "https://api.github.com/users/nateprewitt/repos", "site_admin": false, "starred_url": "https://api.github.com/users/nateprewitt/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/nateprewitt/subscriptions", "type": "User", "url": "https://api.github.com/users/nateprewitt", "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/4574/reactions" }
https://api.github.com/repos/psf/requests/issues/4574/timeline
null
completed
null
null
false
[ "What makes you think that?", "Since we haven’t had a response and the issue is unclear I’m going to close this for now. @kalaomer feel free to reopen this with more information if you feel there’s still an issue." ]
https://api.github.com/repos/psf/requests/issues/4573
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4573/labels{/name}
https://api.github.com/repos/psf/requests/issues/4573/comments
https://api.github.com/repos/psf/requests/issues/4573/events
https://github.com/psf/requests/pull/4573
311,263,457
MDExOlB1bGxSZXF1ZXN0MTc5NDE2MTAx
4,573
add HTTP 419 to requests.codes
{ "avatar_url": "https://avatars.githubusercontent.com/u/1417779?v=4", "events_url": "https://api.github.com/users/mxmader/events{/privacy}", "followers_url": "https://api.github.com/users/mxmader/followers", "following_url": "https://api.github.com/users/mxmader/following{/other_user}", "gists_url": "https://api.github.com/users/mxmader/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/mxmader", "id": 1417779, "login": "mxmader", "node_id": "MDQ6VXNlcjE0MTc3Nzk=", "organizations_url": "https://api.github.com/users/mxmader/orgs", "received_events_url": "https://api.github.com/users/mxmader/received_events", "repos_url": "https://api.github.com/users/mxmader/repos", "site_admin": false, "starred_url": "https://api.github.com/users/mxmader/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/mxmader/subscriptions", "type": "User", "url": "https://api.github.com/users/mxmader", "user_view_type": "public" }
[]
closed
true
null
[]
null
2
2018-04-04T14:50:14Z
2021-09-03T00:11:06Z
2018-04-04T16:29:54Z
NONE
resolved
via status_codes.py. fixes #4572
{ "avatar_url": "https://avatars.githubusercontent.com/u/1417779?v=4", "events_url": "https://api.github.com/users/mxmader/events{/privacy}", "followers_url": "https://api.github.com/users/mxmader/followers", "following_url": "https://api.github.com/users/mxmader/following{/other_user}", "gists_url": "https://api.github.com/users/mxmader/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/mxmader", "id": 1417779, "login": "mxmader", "node_id": "MDQ6VXNlcjE0MTc3Nzk=", "organizations_url": "https://api.github.com/users/mxmader/orgs", "received_events_url": "https://api.github.com/users/mxmader/received_events", "repos_url": "https://api.github.com/users/mxmader/repos", "site_admin": false, "starred_url": "https://api.github.com/users/mxmader/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/mxmader/subscriptions", "type": "User", "url": "https://api.github.com/users/mxmader", "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/4573/reactions" }
https://api.github.com/repos/psf/requests/issues/4573/timeline
null
null
false
{ "diff_url": "https://github.com/psf/requests/pull/4573.diff", "html_url": "https://github.com/psf/requests/pull/4573", "merged_at": null, "patch_url": "https://github.com/psf/requests/pull/4573.patch", "url": "https://api.github.com/repos/psf/requests/pulls/4573" }
true
[ "Hey @mxmader, thanks for taking the initiative to put this together and start the conversation While there are some uses of 419 on the web, it’s not standardized as you noted in the related issue. I’d personally prefer we avoid introducing things like this (there are a handful of non-standard status codes) into Re...
https://api.github.com/repos/psf/requests/issues/4572
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4572/labels{/name}
https://api.github.com/repos/psf/requests/issues/4572/comments
https://api.github.com/repos/psf/requests/issues/4572/events
https://github.com/psf/requests/issues/4572
311,262,650
MDU6SXNzdWUzMTEyNjI2NTA=
4,572
Add HTTP 419 support to requests.codes
{ "avatar_url": "https://avatars.githubusercontent.com/u/1417779?v=4", "events_url": "https://api.github.com/users/mxmader/events{/privacy}", "followers_url": "https://api.github.com/users/mxmader/followers", "following_url": "https://api.github.com/users/mxmader/following{/other_user}", "gists_url": "https://api.github.com/users/mxmader/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/mxmader", "id": 1417779, "login": "mxmader", "node_id": "MDQ6VXNlcjE0MTc3Nzk=", "organizations_url": "https://api.github.com/users/mxmader/orgs", "received_events_url": "https://api.github.com/users/mxmader/received_events", "repos_url": "https://api.github.com/users/mxmader/repos", "site_admin": false, "starred_url": "https://api.github.com/users/mxmader/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/mxmader/subscriptions", "type": "User", "url": "https://api.github.com/users/mxmader", "user_view_type": "public" }
[]
closed
true
null
[]
null
3
2018-04-04T14:48:18Z
2021-09-08T03:00:25Z
2018-04-04T16:30:42Z
NONE
resolved
Very simply, I would like to have HTTP 419 status code represented as a constant in the `requests.codes` module, perhaps as `requests.codes.AUTHENTICATION_TIMEOUT`. While this code is not officially (to my knowledge) part of an RFC / standard, it seems to have colloquial use / adoption on many Internet-facing web services. Here's another framework who is considering this support (granted, the context is a bit different WRT requests): GetBlimp/django-rest-framework-jwt#158 I'll post a basic PR to illustrate the request; no pressure to merge it as I am unsure what requests' policy on RFCs/standards is (whether or not dogmatic adherence thereto is a tenet/goal of this project).
{ "avatar_url": "https://avatars.githubusercontent.com/u/1417779?v=4", "events_url": "https://api.github.com/users/mxmader/events{/privacy}", "followers_url": "https://api.github.com/users/mxmader/followers", "following_url": "https://api.github.com/users/mxmader/following{/other_user}", "gists_url": "https://api.github.com/users/mxmader/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/mxmader", "id": 1417779, "login": "mxmader", "node_id": "MDQ6VXNlcjE0MTc3Nzk=", "organizations_url": "https://api.github.com/users/mxmader/orgs", "received_events_url": "https://api.github.com/users/mxmader/received_events", "repos_url": "https://api.github.com/users/mxmader/repos", "site_admin": false, "starred_url": "https://api.github.com/users/mxmader/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/mxmader/subscriptions", "type": "User", "url": "https://api.github.com/users/mxmader", "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/4572/reactions" }
https://api.github.com/repos/psf/requests/issues/4572/timeline
null
completed
null
null
false
[ "> whether or not dogmatic adherence thereto is a tenet/goal of this project\r\n\r\n\"dogmatic\" is unnecessarily adversarial in this context and it is setting yourself up for rejection.\r\n\r\n---\r\n\r\nWe adhere to RFCs as best we can, but we also have edges where we allow for behaviour that isn't strictly RFC-c...
https://api.github.com/repos/psf/requests/issues/4571
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4571/labels{/name}
https://api.github.com/repos/psf/requests/issues/4571/comments
https://api.github.com/repos/psf/requests/issues/4571/events
https://github.com/psf/requests/issues/4571
311,066,233
MDU6SXNzdWUzMTEwNjYyMzM=
4,571
Session not pickleable when using DigestAuth and Python3.6
{ "avatar_url": "https://avatars.githubusercontent.com/u/5866405?v=4", "events_url": "https://api.github.com/users/DenverJ/events{/privacy}", "followers_url": "https://api.github.com/users/DenverJ/followers", "following_url": "https://api.github.com/users/DenverJ/following{/other_user}", "gists_url": "https://api.github.com/users/DenverJ/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/DenverJ", "id": 5866405, "login": "DenverJ", "node_id": "MDQ6VXNlcjU4NjY0MDU=", "organizations_url": "https://api.github.com/users/DenverJ/orgs", "received_events_url": "https://api.github.com/users/DenverJ/received_events", "repos_url": "https://api.github.com/users/DenverJ/repos", "site_admin": false, "starred_url": "https://api.github.com/users/DenverJ/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/DenverJ/subscriptions", "type": "User", "url": "https://api.github.com/users/DenverJ", "user_view_type": "public" }
[]
closed
true
null
[]
null
1
2018-04-04T02:46:08Z
2021-09-05T00:07:00Z
2019-02-14T14:58:08Z
NONE
resolved
A requests session cannot be pickled when using DigestAuth and Python3.6 because of this bug with Python3 - https://bugs.python.org/issue28967 and the referenced issue in that issue - https://bugs.python.org/issue22995 (Tested working with Python3.5.4). ## Expected Result Pickle call succeeds. ## Actual Result Exception. ``` C:\Dev\virtual_envs\play_3\Scripts\python.exe C:/Dev/play/requestspickle.py Traceback (most recent call last): File "C:/Dev/play/requestspickle.py", line 7, in <module> session_pickle = pickle.dumps(session) TypeError: can't pickle _thread._local objects ``` ## Reproduction Steps ```python import pickle import requests from requests.auth import HTTPDigestAuth session = requests.Session() session.auth = HTTPDigestAuth('user', 'passwd') pickle.dumps(session) ``` ## System Information $ python -m requests.help ``` { "chardet": { "version": "3.0.4" }, "cryptography": { "version": "" }, "idna": { "version": "2.6" }, "implementation": { "name": "CPython", "version": "3.6.3" }, "platform": { "release": "7", "system": "Windows" }, "pyOpenSSL": { "openssl_version": "", "version": null }, "requests": { "version": "2.18.4" }, "system_ssl": { "version": "100020bf" }, "urllib3": { "version": "1.22" }, "using_pyopenssl": false } ```
{ "avatar_url": "https://avatars.githubusercontent.com/u/6740665?v=4", "events_url": "https://api.github.com/users/lmiguelvargasf/events{/privacy}", "followers_url": "https://api.github.com/users/lmiguelvargasf/followers", "following_url": "https://api.github.com/users/lmiguelvargasf/following{/other_user}", "gists_url": "https://api.github.com/users/lmiguelvargasf/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/lmiguelvargasf", "id": 6740665, "login": "lmiguelvargasf", "node_id": "MDQ6VXNlcjY3NDA2NjU=", "organizations_url": "https://api.github.com/users/lmiguelvargasf/orgs", "received_events_url": "https://api.github.com/users/lmiguelvargasf/received_events", "repos_url": "https://api.github.com/users/lmiguelvargasf/repos", "site_admin": false, "starred_url": "https://api.github.com/users/lmiguelvargasf/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/lmiguelvargasf/subscriptions", "type": "User", "url": "https://api.github.com/users/lmiguelvargasf", "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/4571/reactions" }
https://api.github.com/repos/psf/requests/issues/4571/timeline
null
completed
null
null
false
[ "Closed due to inactivity." ]
https://api.github.com/repos/psf/requests/issues/4570
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4570/labels{/name}
https://api.github.com/repos/psf/requests/issues/4570/comments
https://api.github.com/repos/psf/requests/issues/4570/events
https://github.com/psf/requests/pull/4570
310,809,129
MDExOlB1bGxSZXF1ZXN0MTc5MDc3ODAw
4,570
RequestsCookieJar - fixing the multiple_domains function
{ "avatar_url": "https://avatars.githubusercontent.com/u/10619637?v=4", "events_url": "https://api.github.com/users/e-humbert/events{/privacy}", "followers_url": "https://api.github.com/users/e-humbert/followers", "following_url": "https://api.github.com/users/e-humbert/following{/other_user}", "gists_url": "https://api.github.com/users/e-humbert/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/e-humbert", "id": 10619637, "login": "e-humbert", "node_id": "MDQ6VXNlcjEwNjE5NjM3", "organizations_url": "https://api.github.com/users/e-humbert/orgs", "received_events_url": "https://api.github.com/users/e-humbert/received_events", "repos_url": "https://api.github.com/users/e-humbert/repos", "site_admin": false, "starred_url": "https://api.github.com/users/e-humbert/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/e-humbert/subscriptions", "type": "User", "url": "https://api.github.com/users/e-humbert", "user_view_type": "public" }
[]
closed
true
null
[]
null
0
2018-04-03T12:07:41Z
2021-08-31T00:07:11Z
2019-06-08T13:19:45Z
NONE
resolved
PR resolving the issue : #4557 .
{ "avatar_url": "https://avatars.githubusercontent.com/u/10619637?v=4", "events_url": "https://api.github.com/users/e-humbert/events{/privacy}", "followers_url": "https://api.github.com/users/e-humbert/followers", "following_url": "https://api.github.com/users/e-humbert/following{/other_user}", "gists_url": "https://api.github.com/users/e-humbert/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/e-humbert", "id": 10619637, "login": "e-humbert", "node_id": "MDQ6VXNlcjEwNjE5NjM3", "organizations_url": "https://api.github.com/users/e-humbert/orgs", "received_events_url": "https://api.github.com/users/e-humbert/received_events", "repos_url": "https://api.github.com/users/e-humbert/repos", "site_admin": false, "starred_url": "https://api.github.com/users/e-humbert/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/e-humbert/subscriptions", "type": "User", "url": "https://api.github.com/users/e-humbert", "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/4570/reactions" }
https://api.github.com/repos/psf/requests/issues/4570/timeline
null
null
false
{ "diff_url": "https://github.com/psf/requests/pull/4570.diff", "html_url": "https://github.com/psf/requests/pull/4570", "merged_at": null, "patch_url": "https://github.com/psf/requests/pull/4570.patch", "url": "https://api.github.com/repos/psf/requests/pulls/4570" }
true
[]
https://api.github.com/repos/psf/requests/issues/4569
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4569/labels{/name}
https://api.github.com/repos/psf/requests/issues/4569/comments
https://api.github.com/repos/psf/requests/issues/4569/events
https://github.com/psf/requests/issues/4569
310,330,303
MDU6SXNzdWUzMTAzMzAzMDM=
4,569
IDNAError when trying to GET a working url
{ "avatar_url": "https://avatars.githubusercontent.com/u/731464?v=4", "events_url": "https://api.github.com/users/erezsh/events{/privacy}", "followers_url": "https://api.github.com/users/erezsh/followers", "following_url": "https://api.github.com/users/erezsh/following{/other_user}", "gists_url": "https://api.github.com/users/erezsh/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/erezsh", "id": 731464, "login": "erezsh", "node_id": "MDQ6VXNlcjczMTQ2NA==", "organizations_url": "https://api.github.com/users/erezsh/orgs", "received_events_url": "https://api.github.com/users/erezsh/received_events", "repos_url": "https://api.github.com/users/erezsh/repos", "site_admin": false, "starred_url": "https://api.github.com/users/erezsh/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/erezsh/subscriptions", "type": "User", "url": "https://api.github.com/users/erezsh", "user_view_type": "public" }
[]
closed
true
null
[]
null
10
2018-04-01T15:06:45Z
2021-09-08T01:21:17Z
2018-04-01T15:51:53Z
NONE
resolved
Getting some URLs cause an IDNAError, but they work just fine with curl and other url fetchers. ## Expected Result A successful request ## Actual Result idna.core.IDNAError: The label b'xn--mn8ha4uc' is not a valid A-label The label b'xn--mn8ha4uc' is not a valid A-label ## Reproduction Steps ```python import requests requests.get('https://thegroovecartel.com/feed/') ``` ## System Information $ python -m requests.help ``` { "chardet": { "version": "3.0.4" }, "cryptography": { "version": "2.2.2" }, "idna": { "version": "2.6" }, "implementation": { "name": "CPython", "version": "3.6.4" }, "platform": { "release": "4.15.12-201.fc26.x86_64", "system": "Linux" }, "pyOpenSSL": { "openssl_version": "1010008f", "version": "17.5.0" }, "requests": { "version": "2.18.4" }, "system_ssl": { "version": "1010007f" }, "urllib3": { "version": "1.22" }, "using_pyopenssl": 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" }
{ "+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/4569/reactions" }
https://api.github.com/repos/psf/requests/issues/4569/timeline
null
completed
null
null
false
[ "```\r\n>>> import requests\r\n>>> \r\n>>> requests.get('https://thegroovecartel.com/feed/')\r\n<Response [200]>\r\n>>> import requests.help\r\n>>> requests.help.main()\r\n{\r\n \"chardet\": {\r\n \"version\": \"3.0.4\"\r\n },\r\n \"cryptography\": {\r\n \"version\": \"\"\r\n },\r\n \"idna\": {\r\n \"...
https://api.github.com/repos/psf/requests/issues/4568
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4568/labels{/name}
https://api.github.com/repos/psf/requests/issues/4568/comments
https://api.github.com/repos/psf/requests/issues/4568/events
https://github.com/psf/requests/issues/4568
310,087,159
MDU6SXNzdWUzMTAwODcxNTk=
4,568
Requests session adapter doesn't retry incomplete chunked responses, unlike urllib3
{ "avatar_url": "https://avatars.githubusercontent.com/u/813860?v=4", "events_url": "https://api.github.com/users/a3kov/events{/privacy}", "followers_url": "https://api.github.com/users/a3kov/followers", "following_url": "https://api.github.com/users/a3kov/following{/other_user}", "gists_url": "https://api.github.com/users/a3kov/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/a3kov", "id": 813860, "login": "a3kov", "node_id": "MDQ6VXNlcjgxMzg2MA==", "organizations_url": "https://api.github.com/users/a3kov/orgs", "received_events_url": "https://api.github.com/users/a3kov/received_events", "repos_url": "https://api.github.com/users/a3kov/repos", "site_admin": false, "starred_url": "https://api.github.com/users/a3kov/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/a3kov/subscriptions", "type": "User", "url": "https://api.github.com/users/a3kov", "user_view_type": "public" }
[]
closed
true
null
[]
null
3
2018-03-30T14:58:47Z
2021-09-08T03:00:26Z
2018-04-01T15:57:14Z
NONE
resolved
IncompleteRead error from chunked responses are not retried with requests session and HTTPAdapter using Retry. If I use urllib3 directly, it's retried. ## Expected Result Similar to urllib3, it should be retried. IncompleteRead is a read error and Retry utility specifically states to support retrying of read errors. ## Actual Result It's not retried, raising ChunkedEncodingError instead ## Reproduction Steps ```python import pytest import requests from requests.adapters import HTTPAdapter from requests.exceptions import ChunkedEncodingError from requests.packages.urllib3.util.retry import Retry from urllib3 import PoolManager from urllib3.exceptions import MaxRetryError # This is bad example because it also returns content length header but this is the easiest way I found to reproduce. URL = "https://httpbin.org/response-headers?Content-Type=text%2Fplain%3B+charset%3DUTF-8&Transfer-Encoding=chunked&Server=httpbin" @pytest.fixture def retries(): return Retry(total=2) def test_requests_session_retry(retries): adapter = HTTPAdapter(max_retries=retries) session = requests.Session() session.mount('https://', adapter) with pytest.raises(ChunkedEncodingError): session.get(URL) def test_urllib3_retry(retries): http = PoolManager(retries=retries) with pytest.raises(MaxRetryError): response = http.request('GET', URL) ``` ## System Information ``` $ python -m requests.help { "chardet": { "version": "3.0.4" }, "cryptography": { "version": "2.1.4" }, "idna": { "version": "2.6" }, "implementation": { "name": "CPython", "version": "3.6.0" }, "platform": { "release": "3.13.0-133-generic", "system": "Linux" }, "pyOpenSSL": { "openssl_version": "1010007f", "version": "17.5.0" }, "requests": { "version": "2.18.4" }, "system_ssl": { "version": "1000106f" }, "urllib3": { "version": "1.22" }, "using_pyopenssl": 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" }
{ "+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/4568/reactions" }
https://api.github.com/repos/psf/requests/issues/4568/timeline
null
completed
null
null
false
[ "I believe your urllib3 example is incomplete. Requests does this:\r\n\r\n```py\r\nresponse = http.request('GET', URL, preload_content=False)\r\nfor chunk in response.stream():\r\n # build up requests.Response.content\r\n```\r\n\r\nIf I do that, I get the same problem in urllib3. (Although it's raised as a Proto...
https://api.github.com/repos/psf/requests/issues/4567
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4567/labels{/name}
https://api.github.com/repos/psf/requests/issues/4567/comments
https://api.github.com/repos/psf/requests/issues/4567/events
https://github.com/psf/requests/issues/4567
310,037,926
MDU6SXNzdWUzMTAwMzc5MjY=
4,567
SystemError: error return without exception set
{ "avatar_url": "https://avatars.githubusercontent.com/u/3931761?v=4", "events_url": "https://api.github.com/users/SG5/events{/privacy}", "followers_url": "https://api.github.com/users/SG5/followers", "following_url": "https://api.github.com/users/SG5/following{/other_user}", "gists_url": "https://api.github.com/users/SG5/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/SG5", "id": 3931761, "login": "SG5", "node_id": "MDQ6VXNlcjM5MzE3NjE=", "organizations_url": "https://api.github.com/users/SG5/orgs", "received_events_url": "https://api.github.com/users/SG5/received_events", "repos_url": "https://api.github.com/users/SG5/repos", "site_admin": false, "starred_url": "https://api.github.com/users/SG5/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/SG5/subscriptions", "type": "User", "url": "https://api.github.com/users/SG5", "user_view_type": "public" }
[]
closed
true
null
[]
null
6
2018-03-30T10:53:24Z
2021-09-04T00:06:30Z
2018-04-01T17:55:51Z
NONE
resolved
I have same issue from #4367 ``` Exception ignored in: <generator object urlsplit.<locals>.<genexpr> at 0x1087bdca8> Traceback (most recent call last): File "/usr/local/Cellar/python/3.6.4_4/Frameworks/Python.framework/Versions/3.6/lib/python3.6/urllib/parse.py", line 431, in <genexpr> if not rest or any(c not in '0123456789' for c in rest): SystemError: error return without exception set Exception ignored in: <generator object urlsplit.<locals>.<genexpr> at 0x108788830> Traceback (most recent call last): File "/usr/local/Cellar/python/3.6.4_4/Frameworks/Python.framework/Versions/3.6/lib/python3.6/urllib/parse.py", line 431, in <genexpr> if not rest or any(c not in '0123456789' for c in rest): SystemError: error return without exception set Exception ignored in: <generator object urlsplit.<locals>.<genexpr> at 0x108788360> Traceback (most recent call last): File "/usr/local/Cellar/python/3.6.4_4/Frameworks/Python.framework/Versions/3.6/lib/python3.6/urllib/parse.py", line 431, in <genexpr> if not rest or any(c not in '0123456789' for c in rest): SystemError: error return without exception set Exception ignored in: <generator object iter_slices at 0x108788360> Traceback (most recent call last): File "~/.venv/lib/python3.6/site-packages/requests/utils.py", line 449, in iter_slices def iter_slices(string, slice_length): SystemError: error return without exception set Exception ignored in: <generator object urlsplit.<locals>.<genexpr> at 0x1095fffc0> Traceback (most recent call last): File "/usr/local/Cellar/python/3.6.4_4/Frameworks/Python.framework/Versions/3.6/lib/python3.6/urllib/parse.py", line 431, in <genexpr> if not rest or any(c not in '0123456789' for c in rest): SystemError: error return without exception set Exception ignored in: <generator object iter_slices at 0x1095ffba0> Traceback (most recent call last): File "~/.venv/lib/python3.6/site-packages/requests/utils.py", line 449, in iter_slices def iter_slices(string, slice_length): SystemError: error return without exception set ``` It happens when I make requests in many `threading.Thread`
{ "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/4567/reactions" }
https://api.github.com/repos/psf/requests/issues/4567/timeline
null
completed
null
null
false
[ "As mentioned in #4367, this is not something that Requests controls. This is almost certianly coming from a library used at some point in the execution of the program (e.g., `json`) that has a C dependency and the threading is leading to this issue. There's nothing for Requests to do as far as we can tell with all...
https://api.github.com/repos/psf/requests/issues/4566
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4566/labels{/name}
https://api.github.com/repos/psf/requests/issues/4566/comments
https://api.github.com/repos/psf/requests/issues/4566/events
https://github.com/psf/requests/issues/4566
309,886,122
MDU6SXNzdWUzMDk4ODYxMjI=
4,566
Requests and urllib3 giving "bad handshake: SysCallError(-1, 'Unexpected EOF')" in a proxied environment on a non standard port
{ "avatar_url": "https://avatars.githubusercontent.com/u/12440040?v=4", "events_url": "https://api.github.com/users/tjs24/events{/privacy}", "followers_url": "https://api.github.com/users/tjs24/followers", "following_url": "https://api.github.com/users/tjs24/following{/other_user}", "gists_url": "https://api.github.com/users/tjs24/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/tjs24", "id": 12440040, "login": "tjs24", "node_id": "MDQ6VXNlcjEyNDQwMDQw", "organizations_url": "https://api.github.com/users/tjs24/orgs", "received_events_url": "https://api.github.com/users/tjs24/received_events", "repos_url": "https://api.github.com/users/tjs24/repos", "site_admin": false, "starred_url": "https://api.github.com/users/tjs24/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/tjs24/subscriptions", "type": "User", "url": "https://api.github.com/users/tjs24", "user_view_type": "public" }
[]
closed
true
null
[]
null
2
2018-03-29T20:05:15Z
2021-09-08T03:00:26Z
2018-04-01T15:50:40Z
NONE
resolved
Summary. Are urllib3 and/or requests modules facing problems when it comes to accessing HTTP(S) service(s) on non standard ports? ## Expected Result >python Python 3.5.0 (v3.5.0:374f501f4567, Sep 13 2015, 02:27:37) [MSC v.1900 64 bit (AMD64)] on win32 Type "help", "copyright", "credits" or "license" for more information. >>import requests >>requests.get('https://somehost.com:8443', verify=False) InsecureRequestWarning: Unverified HTTPS request is being made. Adding certificate verification is strongly advised. See: https://urllib3.readthedocs.io/en/latest/advanced-usage.html#ssl-warnings InsecureRequestWarning) <Response [200]> This is what is expected ## Actual Result What happened instead. ![image](https://user-images.githubusercontent.com/12440040/38110490-b96329ce-3350-11e8-803f-9dc3dd4220f9.png) I have referenced these blogs: https://www.bountysource.com/issues/30782175-requests-exceptions-sslerror-eof-occurred-in-violation-of-protocol-_ssl-c-645 https://github.com/requests/requests/issues/4272 >pip freeze asn1crypto==0.24.0 astroid==1.6.2 attrdict==2.0.0 cachetools==2.0.1 certifi==2017.7.27.1 cffi==1.11.5 chardet==3.0.4 colorama==0.3.9 cryptography==2.1.4 future==0.16.0 idna==2.6 isort==4.3.4 lazy-object-proxy==1.3.1 mccabe==0.6.1 ndg-httpsclient==0.4.4 pefile==2017.11.5 pika==0.10.0 prompt-toolkit==1.0.15 protobuf==3.4.0 pyasn1==0.4.2 pycparser==2.18 Pygments==2.2.0 pylint==1.8.3 pyOpenSSL==17.5.0 python-dateutil==2.6.1 PyYAML==3.12 requests==2.18.4 six==1.11.0 urllib3==1.22 wcwidth==0.1.7 wrapt==1.10.11 >openssl version OpenSSL 1.0.2k 26 Jan 2017 >python -c "import ssl; print(ssl.OPENSSL_VERSION)" OpenSSL 1.0.2d 9 Jul 2015 ## System Information > python -m requests.help ``` { "chardet": { "version": "3.0.4" }, "cryptography": { "version": "2.1.4" }, "idna": { "version": "2.6" }, "implementation": { "name": "CPython", "version": "3.5.0" }, "platform": { "release": "", "system": "Windows" }, "pyOpenSSL": { "openssl_version": "1010007f", "version": "17.5.0" }, "requests": { "version": "2.18.4" }, "system_ssl": { "version": "1000204f" }, "urllib3": { "version": "1.22" }, "using_pyopenssl": true } ``` Any help would be appreciated.
{ "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/4566/reactions" }
https://api.github.com/repos/psf/requests/issues/4566/timeline
null
completed
null
null
false
[ "@Lukasa i have tried solutions on your other blogs i mentioned above and none of them worked. I just wanted a bit more guidance.", "Hi there! Thanks for opening this issue. Unfortunately, it seems this is a request for help instead of a report of a defect in the project. Please use [StackOverflow](https://stacko...
https://api.github.com/repos/psf/requests/issues/4565
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4565/labels{/name}
https://api.github.com/repos/psf/requests/issues/4565/comments
https://api.github.com/repos/psf/requests/issues/4565/events
https://github.com/psf/requests/issues/4565
309,802,761
MDU6SXNzdWUzMDk4MDI3NjE=
4,565
Url with vertical bar
{ "avatar_url": "https://avatars.githubusercontent.com/u/6846724?v=4", "events_url": "https://api.github.com/users/jerbluba/events{/privacy}", "followers_url": "https://api.github.com/users/jerbluba/followers", "following_url": "https://api.github.com/users/jerbluba/following{/other_user}", "gists_url": "https://api.github.com/users/jerbluba/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/jerbluba", "id": 6846724, "login": "jerbluba", "node_id": "MDQ6VXNlcjY4NDY3MjQ=", "organizations_url": "https://api.github.com/users/jerbluba/orgs", "received_events_url": "https://api.github.com/users/jerbluba/received_events", "repos_url": "https://api.github.com/users/jerbluba/repos", "site_admin": false, "starred_url": "https://api.github.com/users/jerbluba/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/jerbluba/subscriptions", "type": "User", "url": "https://api.github.com/users/jerbluba", "user_view_type": "public" }
[]
closed
true
null
[]
null
4
2018-03-29T15:34:27Z
2018-03-29T16:48:25Z
2018-03-29T15:40:07Z
NONE
off-topic
I found if we have "|" vertical bar in url will show Expecting value: line 9 column 1 (char 16) The following is my code... req = requests.session() req.get('http://mis.twse.com.tw/stock/index.jsp',headers={'Accept-Language': 'zh-TW'}) response = req.get(self.query_url) print(content) self.query_url is aurl have "|" For example: http://mis.twse.com.tw/stock/api/getStockInfo.jsp?_=1522229112409&json=1&delay=0&ex_ch=tse_3374.tw|tse_2455.tw|tse_8086.tw|tse_3105.tw|tse_4991.tw|tse_2360.tw|tse_4971.tw|tse_6271.tw|tse_2448.tw|tse_2454.tw|tse_3443.tw|tse_3661.tw|tse_3035.tw|tse_2376.tw|tse_2377.tw ## Expected Result I hope I can read url with "vertical bar" ## Actual Result Expecting value: line 9 column 1 (char 16) ## Reproduction Steps ```python import requests req = requests.session() req.get('http://mis.twse.com.tw/stock/index.jsp',headers={'Accept-Language': 'zh-TW'}) response = req.get('http://mis.twse.com.tw/stock/api/getStockInfo.jsp?_=1522229112409&json=1&delay=0&ex_ch=tse_3374.tw|tse_2455.tw|tse_8086.tw|tse_3105.tw|tse_4991.tw|tse_2360.tw|tse_4971.tw|tse_6271.tw|tse_2448.tw|tse_2454.tw|tse_3443.tw|tse_3661.tw|tse_3035.tw|tse_2376.tw|tse_2377.tw' ) content = json.loads(response.text) print(content) ``` ## System Information version python3.6
{ "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/4565/reactions" }
https://api.github.com/repos/psf/requests/issues/4565/timeline
null
completed
null
null
false
[ "I cannot reproduce this locally on Python 3.6 with \r\n\r\n```json\r\n{\r\n \"chardet\": {\r\n \"version\": \"3.0.4\"\r\n },\r\n \"cryptography\": {\r\n \"version\": \"\"\r\n },\r\n \"idna\": {\r\n \"version\": \"2.6\"\r\n },\r\n \"implementation\": {\r\n \"name\": \"CPython\",\r\n \"version\...
https://api.github.com/repos/psf/requests/issues/4564
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4564/labels{/name}
https://api.github.com/repos/psf/requests/issues/4564/comments
https://api.github.com/repos/psf/requests/issues/4564/events
https://github.com/psf/requests/issues/4564
309,430,538
MDU6SXNzdWUzMDk0MzA1Mzg=
4,564
[Python 3] Basic auth relying on utf-8 encoding by default
{ "avatar_url": "https://avatars.githubusercontent.com/u/6583243?v=4", "events_url": "https://api.github.com/users/princess-entrapta/events{/privacy}", "followers_url": "https://api.github.com/users/princess-entrapta/followers", "following_url": "https://api.github.com/users/princess-entrapta/following{/other_user}", "gists_url": "https://api.github.com/users/princess-entrapta/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/princess-entrapta", "id": 6583243, "login": "princess-entrapta", "node_id": "MDQ6VXNlcjY1ODMyNDM=", "organizations_url": "https://api.github.com/users/princess-entrapta/orgs", "received_events_url": "https://api.github.com/users/princess-entrapta/received_events", "repos_url": "https://api.github.com/users/princess-entrapta/repos", "site_admin": false, "starred_url": "https://api.github.com/users/princess-entrapta/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/princess-entrapta/subscriptions", "type": "User", "url": "https://api.github.com/users/princess-entrapta", "user_view_type": "public" }
[]
closed
false
null
[]
null
13
2018-03-28T16:01:08Z
2024-05-19T19:07:07Z
2024-05-19T19:07:06Z
NONE
null
I got deceived by default requests behavior for auth headers. As using a password containing some non-ascii chars, the basic auth method silently encoded in latin1, which caused authentication to fail as it was expected to be utf-8 encoded server side. Utf-8 is default encoding in modern terminals and in python3 strings. As a result, requests behavior for auth is asymmetrical with curl and is odd when being reversed by authentication servers. Requests is expected to fail on non-binary input, or comply to web standards of using utf-8 text strings. As a workaround I encoded the string in utf-8 beforehand authing with requests. ## Reproduction Steps ```python import requests requests.get('https://example.com', auth=('user', 'àéïòù')) ``` ## Expected Result Basic auth header is base64encoded version of "user:àéïòù".encode('utf-8') ## Actual Result Basic auth header is base64encoded version of "user:àéïòù".encode('latin1') ## Workaround requests.get('https://example.com', auth=('user', 'àéïòù'.encode('utf-8')))
{ "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": 13, "-1": 0, "confused": 0, "eyes": 0, "heart": 0, "hooray": 0, "laugh": 0, "rocket": 0, "total_count": 13, "url": "https://api.github.com/repos/psf/requests/issues/4564/reactions" }
https://api.github.com/repos/psf/requests/issues/4564/timeline
null
completed
null
null
false
[ "We could extend https://github.com/requests/requests/blob/b66908e7b647689793e299edc111bf9910e93ad3/requests/auth.py#L79 to accept an encoding and that could pass it through to https://github.com/requests/requests/blob/b66908e7b647689793e299edc111bf9910e93ad3/requests/auth.py#L28 but the extra parameter there would...
https://api.github.com/repos/psf/requests/issues/4563
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4563/labels{/name}
https://api.github.com/repos/psf/requests/issues/4563/comments
https://api.github.com/repos/psf/requests/issues/4563/events
https://github.com/psf/requests/issues/4563
309,278,944
MDU6SXNzdWUzMDkyNzg5NDQ=
4,563
TypeError: request() got an unexpected keyword argument 'file'
{ "avatar_url": "https://avatars.githubusercontent.com/u/814292?v=4", "events_url": "https://api.github.com/users/le9i0nx/events{/privacy}", "followers_url": "https://api.github.com/users/le9i0nx/followers", "following_url": "https://api.github.com/users/le9i0nx/following{/other_user}", "gists_url": "https://api.github.com/users/le9i0nx/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/le9i0nx", "id": 814292, "login": "le9i0nx", "node_id": "MDQ6VXNlcjgxNDI5Mg==", "organizations_url": "https://api.github.com/users/le9i0nx/orgs", "received_events_url": "https://api.github.com/users/le9i0nx/received_events", "repos_url": "https://api.github.com/users/le9i0nx/repos", "site_admin": false, "starred_url": "https://api.github.com/users/le9i0nx/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/le9i0nx/subscriptions", "type": "User", "url": "https://api.github.com/users/le9i0nx", "user_view_type": "public" }
[]
closed
true
null
[]
null
3
2018-03-28T09:02:21Z
2021-09-01T00:11:26Z
2018-03-28T10:45:38Z
NONE
resolved
In the documentation it is written that so it is possible to make a request, but there is an exception. I first tested it on version 2.12.4. And then checked on the latest available (2.18.4). http://docs.python-requests.org/en/stable/user/quickstart/#post-a-multipart-encoded-file ## Expected Result Running the query ## Actual Result TypeError: request() got an unexpected keyword argument 'file' ## Reproduction Steps ```python import requests payload = {"param_1": "value_1", "param_2": "value_2"} files = { 'json': (None, json.dumps(payload), 'application/json'), 'file': ('log', "11" ) } post = requests.post(API_HOST+API_URL, file=files) print(post.content) ``` ## System Information $ python -m requests.help ``` root@5cf05c9a3e78:/app# python3 -m requests.help { "chardet": { "version": "3.0.4" }, "cryptography": { "version": "" }, "idna": { "version": "2.6" }, "implementation": { "name": "CPython", "version": "3.5.3" }, "platform": { "release": "4.9.0-6-amd64", "system": "Linux" }, "pyOpenSSL": { "openssl_version": "", "version": null }, "requests": { "version": "2.18.4" }, "system_ssl": { "version": "1010006f" }, "urllib3": { "version": "1.22" }, "using_pyopenssl": false } ```
{ "avatar_url": "https://avatars.githubusercontent.com/u/814292?v=4", "events_url": "https://api.github.com/users/le9i0nx/events{/privacy}", "followers_url": "https://api.github.com/users/le9i0nx/followers", "following_url": "https://api.github.com/users/le9i0nx/following{/other_user}", "gists_url": "https://api.github.com/users/le9i0nx/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/le9i0nx", "id": 814292, "login": "le9i0nx", "node_id": "MDQ6VXNlcjgxNDI5Mg==", "organizations_url": "https://api.github.com/users/le9i0nx/orgs", "received_events_url": "https://api.github.com/users/le9i0nx/received_events", "repos_url": "https://api.github.com/users/le9i0nx/repos", "site_admin": false, "starred_url": "https://api.github.com/users/le9i0nx/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/le9i0nx/subscriptions", "type": "User", "url": "https://api.github.com/users/le9i0nx", "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/4563/reactions" }
https://api.github.com/repos/psf/requests/issues/4563/timeline
null
completed
null
null
false
[ "excuse me. I was inattentive\r\n", "I ran into the same issue — could you tell, how you worked it out?", "Argh, got it: the keyword is 'files', not 'file'." ]
https://api.github.com/repos/psf/requests/issues/4562
https://api.github.com/repos/psf/requests
https://api.github.com/repos/psf/requests/issues/4562/labels{/name}
https://api.github.com/repos/psf/requests/issues/4562/comments
https://api.github.com/repos/psf/requests/issues/4562/events
https://github.com/psf/requests/pull/4562
309,143,535
MDExOlB1bGxSZXF1ZXN0MTc3ODcyODEx
4,562
respect reply-afer in automatic redirects
{ "avatar_url": "https://avatars.githubusercontent.com/u/1790880?v=4", "events_url": "https://api.github.com/users/kgk/events{/privacy}", "followers_url": "https://api.github.com/users/kgk/followers", "following_url": "https://api.github.com/users/kgk/following{/other_user}", "gists_url": "https://api.github.com/users/kgk/gists{/gist_id}", "gravatar_id": "", "html_url": "https://github.com/kgk", "id": 1790880, "login": "kgk", "node_id": "MDQ6VXNlcjE3OTA4ODA=", "organizations_url": "https://api.github.com/users/kgk/orgs", "received_events_url": "https://api.github.com/users/kgk/received_events", "repos_url": "https://api.github.com/users/kgk/repos", "site_admin": false, "starred_url": "https://api.github.com/users/kgk/starred{/owner}{/repo}", "subscriptions_url": "https://api.github.com/users/kgk/subscriptions", "type": "User", "url": "https://api.github.com/users/kgk", "user_view_type": "public" }
[]
closed
true
null
[]
null
7
2018-03-27T21:38:44Z
2021-08-31T00:07:15Z
2018-03-28T12:03:11Z
NONE
resolved
small patch that respects replay-after only in automatic redirects .. similar to chrome, firefox and others. reply-after is not handled for other status codes such as 503, and 429 as the handling may application specific. https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Retry-After
{ "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/4562/reactions" }
https://api.github.com/repos/psf/requests/issues/4562/timeline
null
null
false
{ "diff_url": "https://github.com/psf/requests/pull/4562.diff", "html_url": "https://github.com/psf/requests/pull/4562", "merged_at": null, "patch_url": "https://github.com/psf/requests/pull/4562.patch", "url": "https://api.github.com/repos/psf/requests/pulls/4562" }
true
[ "There's already logic for respecting the `Retry-After` header within urllib3, one of Requests core modules. You may need to write your own Adapter in order for this logic to be used.", "We did not see it being respected.\n\nwe have seen web-sites returning 30X with retry-after headers and we hit\nmax-redirects ...