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/3860 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3860/labels{/name} | https://api.github.com/repos/psf/requests/issues/3860/comments | https://api.github.com/repos/psf/requests/issues/3860/events | https://github.com/psf/requests/issues/3860 | 206,740,910 | MDU6SXNzdWUyMDY3NDA5MTA= | 3,860 | File names stripped of leading dots | {
"avatar_url": "https://avatars.githubusercontent.com/u/26496?v=4",
"events_url": "https://api.github.com/users/p3lim/events{/privacy}",
"followers_url": "https://api.github.com/users/p3lim/followers",
"following_url": "https://api.github.com/users/p3lim/following{/other_user}",
"gists_url": "https://api.github.com/users/p3lim/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/p3lim",
"id": 26496,
"login": "p3lim",
"node_id": "MDQ6VXNlcjI2NDk2",
"organizations_url": "https://api.github.com/users/p3lim/orgs",
"received_events_url": "https://api.github.com/users/p3lim/received_events",
"repos_url": "https://api.github.com/users/p3lim/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/p3lim/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/p3lim/subscriptions",
"type": "User",
"url": "https://api.github.com/users/p3lim",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 2 | 2017-02-10T08:57:05Z | 2021-09-08T12:00:59Z | 2017-02-10T09:06:40Z | NONE | resolved | Currently using the following to upload a file to a webserver:
```
files = {'files': ('.png', open(file_path, 'rb'))}
res = requests.post(url, files=files)
```
The reason I rename the file to just ".png" is because with an empty base name the server will randomly give the file a name.
However, and I'm not sure if requests is the one to blame here, the file ends up being uploaded with the name "png" instead, as if the leading "." was stripped from the name.
Is this something requests is intentionally doing or should I look elsewhere for the cause? | {
"avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4",
"events_url": "https://api.github.com/users/Lukasa/events{/privacy}",
"followers_url": "https://api.github.com/users/Lukasa/followers",
"following_url": "https://api.github.com/users/Lukasa/following{/other_user}",
"gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Lukasa",
"id": 1382556,
"login": "Lukasa",
"node_id": "MDQ6VXNlcjEzODI1NTY=",
"organizations_url": "https://api.github.com/users/Lukasa/orgs",
"received_events_url": "https://api.github.com/users/Lukasa/received_events",
"repos_url": "https://api.github.com/users/Lukasa/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Lukasa",
"user_view_type": "public"
} | {
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/3860/reactions"
} | https://api.github.com/repos/psf/requests/issues/3860/timeline | null | completed | null | null | false | [
"This is not something requests is doing. A quick Wireshark dump of your sample code against `http://httpbin.org/post` shows that the request looks like this:\r\n\r\n```\r\nPOST /post HTTP/1.1\r\nHost: httpbin.org\r\nConnection: keep-alive\r\nAccept-Encoding: gzip, deflate\r\nAccept: */*\r\nUser-Agent: python-reque... |
https://api.github.com/repos/psf/requests/issues/3859 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3859/labels{/name} | https://api.github.com/repos/psf/requests/issues/3859/comments | https://api.github.com/repos/psf/requests/issues/3859/events | https://github.com/psf/requests/issues/3859 | 206,570,028 | MDU6SXNzdWUyMDY1NzAwMjg= | 3,859 | Certificate failure with Python 2.7.13 and current Requests on virtualized server | {
"avatar_url": "https://avatars.githubusercontent.com/u/25668513?v=4",
"events_url": "https://api.github.com/users/PatrickDChampion/events{/privacy}",
"followers_url": "https://api.github.com/users/PatrickDChampion/followers",
"following_url": "https://api.github.com/users/PatrickDChampion/following{/other_user}",
"gists_url": "https://api.github.com/users/PatrickDChampion/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/PatrickDChampion",
"id": 25668513,
"login": "PatrickDChampion",
"node_id": "MDQ6VXNlcjI1NjY4NTEz",
"organizations_url": "https://api.github.com/users/PatrickDChampion/orgs",
"received_events_url": "https://api.github.com/users/PatrickDChampion/received_events",
"repos_url": "https://api.github.com/users/PatrickDChampion/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/PatrickDChampion/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/PatrickDChampion/subscriptions",
"type": "User",
"url": "https://api.github.com/users/PatrickDChampion",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 24 | 2017-02-09T17:17:17Z | 2021-09-08T05:00:50Z | 2017-06-27T06:01:57Z | NONE | resolved | I use to use Requests and Python 2.7.6 to access a server with a REST interface. After our organization update their servers, I got the "InsecurePlatformWarning: A true SSLContext object is not available" message and then a certificate failure at the bottom of the call stack.
I have now upgraded to Python 2.7.13 and tried. I stopped getting the InsecurePlatformWarning, but I still got the certificate failure at the end. So, then I updated using pip the Requests from version 2.7.0 to the current 2.13.0. I still get the same certificate failure (without the insecure warning). Below is the call stack. If I force the get() to ignore verification "r = s.get(url, params=addr, verify=False)", the transaction works fine, but I would like to maintain security and use the certificates. I am using Windows 7 Enterprise Service Pack 1 (64 bit) and 64bit Python.
Any idea on what is going wrong. Any suggestions?
Starting Session
Sending request
Traceback (most recent call last):
File "S:\FY2015\ChoiceCard\DailyQ\checkSoftAuthOld.py", line 20, in <module>
r = s.get(url,params=addr)
File "C:\Python27\lib\site-packages\requests\sessions.py", line 501, in get
return self.request('GET', url, **kwargs)
File "C:\Python27\lib\site-packages\requests\sessions.py", line 488, in request
resp = self.send(prep, **send_kwargs)
File "C:\Python27\lib\site-packages\requests\sessions.py", line 630, in send
history = [resp for resp in gen] if allow_redirects else []
File "C:\Python27\lib\site-packages\requests\sessions.py", line 190, in resolve_redirects
**adapter_kwargs
File "C:\Python27\lib\site-packages\requests\sessions.py", line 609, in send
r = adapter.send(request, **kwargs)
File "C:\Python27\lib\site-packages\requests\adapters.py", line 497, in send
raise SSLError(e, request=request)
requests.exceptions.SSLError: [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed (_ssl.c:661)
| {
"avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4",
"events_url": "https://api.github.com/users/Lukasa/events{/privacy}",
"followers_url": "https://api.github.com/users/Lukasa/followers",
"following_url": "https://api.github.com/users/Lukasa/following{/other_user}",
"gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Lukasa",
"id": 1382556,
"login": "Lukasa",
"node_id": "MDQ6VXNlcjEzODI1NTY=",
"organizations_url": "https://api.github.com/users/Lukasa/orgs",
"received_events_url": "https://api.github.com/users/Lukasa/received_events",
"repos_url": "https://api.github.com/users/Lukasa/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Lukasa",
"user_view_type": "public"
} | {
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/3859/reactions"
} | https://api.github.com/repos/psf/requests/issues/3859/timeline | null | completed | null | null | false | [
"Assuming the server used to work and now does not, it's most likely that they're serving an invalid certificate or certificate chain. Is the server publicly accessible? If so, can you tell me the host name?",
"Thank you for responding. A closely related link has been working for another application. The server ... |
https://api.github.com/repos/psf/requests/issues/3858 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3858/labels{/name} | https://api.github.com/repos/psf/requests/issues/3858/comments | https://api.github.com/repos/psf/requests/issues/3858/events | https://github.com/psf/requests/issues/3858 | 206,444,445 | MDU6SXNzdWUyMDY0NDQ0NDU= | 3,858 | why I | {
"avatar_url": "https://avatars.githubusercontent.com/u/4971925?v=4",
"events_url": "https://api.github.com/users/xsren/events{/privacy}",
"followers_url": "https://api.github.com/users/xsren/followers",
"following_url": "https://api.github.com/users/xsren/following{/other_user}",
"gists_url": "https://api.github.com/users/xsren/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/xsren",
"id": 4971925,
"login": "xsren",
"node_id": "MDQ6VXNlcjQ5NzE5MjU=",
"organizations_url": "https://api.github.com/users/xsren/orgs",
"received_events_url": "https://api.github.com/users/xsren/received_events",
"repos_url": "https://api.github.com/users/xsren/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/xsren/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/xsren/subscriptions",
"type": "User",
"url": "https://api.github.com/users/xsren",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 2 | 2017-02-09T09:10:22Z | 2021-09-08T12:01:00Z | 2017-02-09T09:23:06Z | NONE | resolved | Hi, execuse me to trouble you!
I want to use requests with gevent to make a concurrent spider. The offical docs says
> If you are concerned about the use of blocking IO, there are lots of projects out there that combine Requests with one of Python's asynchronicity frameworks. Two excellent examples are grequests and requests-futures.
But after read [this question in stackoverflow](http://stackoverflow.com/questions/9501663/how-enable-requests-async-mode), i am confused. Because I run the code in my machine, but it seems requests does better than urllib(python 2.7.10,gevent 1.1.2,requests 2.11.1).
the code:
```
import sys
import gevent
from gevent import monkey
monkey.patch_all()
import requests
import urllib2
def worker(url, use_urllib2=False):
if use_urllib2:
content = urllib2.urlopen(url).read().lower()
else:
content = requests.get(url).content.lower()
title = content.split('<title>')[1].split('</title>')[0].strip()
urls = ['http://www.baidu.com']*15
def by_requests():
jobs = [gevent.spawn(worker, url) for url in urls]
gevent.joinall(jobs)
def by_urllib2():
jobs = [gevent.spawn(worker, url, True) for url in urls]
gevent.joinall(jobs)
if __name__=='__main__':
from timeit import Timer
t = Timer(stmt="by_requests()", setup="from __main__ import by_requests")
print 'by requests: %s seconds'%t.timeit(number=3)
t = Timer(stmt="by_urllib2()", setup="from __main__ import by_urllib2")
print 'by urllib2: %s seconds'%t.timeit(number=3)
sys.exit(0)
```
the result:
```
➜ test_requests python test04.py
by requests: 0.178946971893 seconds
by urllib2: 1.94786500931 seconds
➜ test_requests python test04.py
by requests: 0.233242034912 seconds
by urllib2: 1.55849504471 seconds
➜ test_requests python test04.py
by requests: 0.52639913559 seconds
by urllib2: 3.95958900452 seconds
➜ test_requests python test04.py
by requests: 0.56934094429 seconds
by urllib2: 4.00116705894 seconds
```
My question:
1. The result seems that now gevent + requests is asynchronous. But many people in the website say I should use grequests. Is that right?
2. Why the result I use requests same to I use grequests?
Hope you can answer my question . Thanks very much.
| {
"avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4",
"events_url": "https://api.github.com/users/Lukasa/events{/privacy}",
"followers_url": "https://api.github.com/users/Lukasa/followers",
"following_url": "https://api.github.com/users/Lukasa/following{/other_user}",
"gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Lukasa",
"id": 1382556,
"login": "Lukasa",
"node_id": "MDQ6VXNlcjEzODI1NTY=",
"organizations_url": "https://api.github.com/users/Lukasa/orgs",
"received_events_url": "https://api.github.com/users/Lukasa/received_events",
"repos_url": "https://api.github.com/users/Lukasa/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Lukasa",
"user_view_type": "public"
} | {
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/3858/reactions"
} | https://api.github.com/repos/psf/requests/issues/3858/timeline | null | completed | null | null | false | [
"Requests can work with gevent directly without any trouble: this is the nature of gevent. grequests provides some specific additional utilities for managing Requests with gevent. It's a nice addition, but not required.",
"OK!Thank you very much!"
] |
https://api.github.com/repos/psf/requests/issues/3857 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3857/labels{/name} | https://api.github.com/repos/psf/requests/issues/3857/comments | https://api.github.com/repos/psf/requests/issues/3857/events | https://github.com/psf/requests/pull/3857 | 206,177,352 | MDExOlB1bGxSZXF1ZXN0MTA1MjAyMDk1 | 3,857 | Say that we use a dictionary of strings. | {
"avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4",
"events_url": "https://api.github.com/users/Lukasa/events{/privacy}",
"followers_url": "https://api.github.com/users/Lukasa/followers",
"following_url": "https://api.github.com/users/Lukasa/following{/other_user}",
"gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Lukasa",
"id": 1382556,
"login": "Lukasa",
"node_id": "MDQ6VXNlcjEzODI1NTY=",
"organizations_url": "https://api.github.com/users/Lukasa/orgs",
"received_events_url": "https://api.github.com/users/Lukasa/received_events",
"repos_url": "https://api.github.com/users/Lukasa/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Lukasa",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 1 | 2017-02-08T11:55:27Z | 2021-09-07T00:06:38Z | 2017-02-08T12:05:51Z | MEMBER | resolved | Resolves #3856. | {
"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/3857/reactions"
} | https://api.github.com/repos/psf/requests/issues/3857/timeline | null | null | false | {
"diff_url": "https://github.com/psf/requests/pull/3857.diff",
"html_url": "https://github.com/psf/requests/pull/3857",
"merged_at": "2017-02-08T12:05:51Z",
"patch_url": "https://github.com/psf/requests/pull/3857.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/3857"
} | true | [
"# [Codecov](https://codecov.io/gh/kennethreitz/requests/pull/3857?src=pr&el=h1) Report\n> Merging [#3857](https://codecov.io/gh/kennethreitz/requests/pull/3857?src=pr&el=desc) into [master](https://codecov.io/gh/kennethreitz/requests/commit/5c68b8f2279be82a672b908d0017d60a8ce6efcd?src=pr&el=desc) will **not impact... |
https://api.github.com/repos/psf/requests/issues/3856 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3856/labels{/name} | https://api.github.com/repos/psf/requests/issues/3856/comments | https://api.github.com/repos/psf/requests/issues/3856/events | https://github.com/psf/requests/issues/3856 | 206,161,151 | MDU6SXNzdWUyMDYxNjExNTE= | 3,856 | Can querystring params be non-strings? | {
"avatar_url": "https://avatars.githubusercontent.com/u/3839472?v=4",
"events_url": "https://api.github.com/users/sharmaeklavya2/events{/privacy}",
"followers_url": "https://api.github.com/users/sharmaeklavya2/followers",
"following_url": "https://api.github.com/users/sharmaeklavya2/following{/other_user}",
"gists_url": "https://api.github.com/users/sharmaeklavya2/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/sharmaeklavya2",
"id": 3839472,
"login": "sharmaeklavya2",
"node_id": "MDQ6VXNlcjM4Mzk0NzI=",
"organizations_url": "https://api.github.com/users/sharmaeklavya2/orgs",
"received_events_url": "https://api.github.com/users/sharmaeklavya2/received_events",
"repos_url": "https://api.github.com/users/sharmaeklavya2/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/sharmaeklavya2/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/sharmaeklavya2/subscriptions",
"type": "User",
"url": "https://api.github.com/users/sharmaeklavya2",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 2 | 2017-02-08T10:50:37Z | 2021-09-08T12:01:01Z | 2017-02-08T11:58:29Z | NONE | resolved | Many functions in requests take a parameter named `params`. There we are supposed to pass a mapping which will be used to construct the querystring. Here is the documentation I found about it:
http://docs.python-requests.org/en/master/user/quickstart/#passing-parameters-in-urls
http://docs.python-requests.org/en/master/api/#requests.request
In none of these places there is any mention of whether it's allowed to pass non-string objects. This example shows that even `int`s and `bool`s are accepted.
```
>>> Request(url='http://localhost', params={1: True}).prepare().url
'http://localhost/?1=True'
```
After some experimentation, it seems that requests can accept anything which can be converted to a string. I looked at the source code of [`requests.models._encode_params`](https://github.com/kennethreitz/requests/blob/master/requests/models.py#L82) so I know why it's behaving like this. But is this the intended behavior?
Also, comments in the source code of `requests.models._encode_params` say that a list of 2-tuples is also accepted. Even this isn't mentioned in the documentation links above.
So my point is that I want to know what is the intended way of using the `params` parameter in requests. What can and cannot be passed in as `params`? Is there some existing documentation about this which I haven't been able to find? If no, this information needs to be documented somewhere.
(I'm actually trying to improve [typeshed](https://github.com/python/typeshed) stubs for requests. Whether non-string objects are allowed in `params` or not will determine how to write stubs.) | {
"avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4",
"events_url": "https://api.github.com/users/Lukasa/events{/privacy}",
"followers_url": "https://api.github.com/users/Lukasa/followers",
"following_url": "https://api.github.com/users/Lukasa/following{/other_user}",
"gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Lukasa",
"id": 1382556,
"login": "Lukasa",
"node_id": "MDQ6VXNlcjEzODI1NTY=",
"organizations_url": "https://api.github.com/users/Lukasa/orgs",
"received_events_url": "https://api.github.com/users/Lukasa/received_events",
"repos_url": "https://api.github.com/users/Lukasa/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Lukasa",
"user_view_type": "public"
} | {
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/3856/reactions"
} | https://api.github.com/repos/psf/requests/issues/3856/timeline | null | completed | null | null | false | [
"Oh boy, you are going to get @Lukasa screaming after you soon :) From this email https://lwn.net/Articles/643399/ it is intentional that requests take all sort of types for the \"param\" value. If something needs a fix, that probably would be Requests documentation.\r\n\r\nAlso, if you have not already, read #3855... |
https://api.github.com/repos/psf/requests/issues/3855 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3855/labels{/name} | https://api.github.com/repos/psf/requests/issues/3855/comments | https://api.github.com/repos/psf/requests/issues/3855/events | https://github.com/psf/requests/issues/3855 | 205,744,841 | MDU6SXNzdWUyMDU3NDQ4NDE= | 3,855 | PEP 484 type annotations for Requests | {
"avatar_url": "https://avatars.githubusercontent.com/u/169930?v=4",
"events_url": "https://api.github.com/users/ygingras/events{/privacy}",
"followers_url": "https://api.github.com/users/ygingras/followers",
"following_url": "https://api.github.com/users/ygingras/following{/other_user}",
"gists_url": "https://api.github.com/users/ygingras/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/ygingras",
"id": 169930,
"login": "ygingras",
"node_id": "MDQ6VXNlcjE2OTkzMA==",
"organizations_url": "https://api.github.com/users/ygingras/orgs",
"received_events_url": "https://api.github.com/users/ygingras/received_events",
"repos_url": "https://api.github.com/users/ygingras/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/ygingras/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/ygingras/subscriptions",
"type": "User",
"url": "https://api.github.com/users/ygingras",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 6 | 2017-02-07T00:00:17Z | 2018-07-04T13:31:54Z | 2017-02-07T08:26:25Z | NONE | off-topic | I am considering adding type annotations to Requests to help my team do static analysis of code that depends on it. Would a pull request containing type annotations be merge back?
More info on type annotations:
* PEP 484: https://www.python.org/dev/peps/pep-0484/
* mypy, the type-checker of choice these days: http://mypy-lang.org/
Given the need to support Python 2.x, the preferred format for annotations would be as Type Comments, but I would be open to do .pyi stubs if that makes it easier for everyone. | {
"avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4",
"events_url": "https://api.github.com/users/Lukasa/events{/privacy}",
"followers_url": "https://api.github.com/users/Lukasa/followers",
"following_url": "https://api.github.com/users/Lukasa/following{/other_user}",
"gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Lukasa",
"id": 1382556,
"login": "Lukasa",
"node_id": "MDQ6VXNlcjEzODI1NTY=",
"organizations_url": "https://api.github.com/users/Lukasa/orgs",
"received_events_url": "https://api.github.com/users/Lukasa/received_events",
"repos_url": "https://api.github.com/users/Lukasa/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Lukasa",
"user_view_type": "public"
} | {
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/3855/reactions"
} | https://api.github.com/repos/psf/requests/issues/3855/timeline | null | completed | null | null | false | [
"Thanks for suggesting this!\n\nNo, Requests has no interest in maintaining type annotations in-tree. This has been our policy since PEP 484 was originally discussed on python-dev. PEP 484's type annotations are a poor fit for Requests due to the substantial complexity and flexibility in our API, and so writing a s... |
https://api.github.com/repos/psf/requests/issues/3854 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3854/labels{/name} | https://api.github.com/repos/psf/requests/issues/3854/comments | https://api.github.com/repos/psf/requests/issues/3854/events | https://github.com/psf/requests/issues/3854 | 205,649,184 | MDU6SXNzdWUyMDU2NDkxODQ= | 3,854 | Support urllib3 Retries at Individual Request Level | {
"avatar_url": "https://avatars.githubusercontent.com/u/1214204?v=4",
"events_url": "https://api.github.com/users/TimOrme/events{/privacy}",
"followers_url": "https://api.github.com/users/TimOrme/followers",
"following_url": "https://api.github.com/users/TimOrme/following{/other_user}",
"gists_url": "https://api.github.com/users/TimOrme/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/TimOrme",
"id": 1214204,
"login": "TimOrme",
"node_id": "MDQ6VXNlcjEyMTQyMDQ=",
"organizations_url": "https://api.github.com/users/TimOrme/orgs",
"received_events_url": "https://api.github.com/users/TimOrme/received_events",
"repos_url": "https://api.github.com/users/TimOrme/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/TimOrme/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/TimOrme/subscriptions",
"type": "User",
"url": "https://api.github.com/users/TimOrme",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 1 | 2017-02-06T17:08:49Z | 2021-09-08T12:01:01Z | 2017-02-06T17:14:19Z | NONE | resolved | Right now, requests supports urllib3 retries at the pool level, allowing retries to occur fairly globally. It seems as if urllib3 supports retries at a more granular level as well, for individual requests:
```
>>> r = http.request(
... 'GET',
... 'http://httpbin.org/redirect/3',
... retries=urllib3.Retries(
... redirect=2, raise_on_redirect=False))
>>> r.status
302
```
It would be nice if requests had support for this level of granularity, as some of our cases require retries for only specific endpoints on a single API.
Apologies if this is the wrong place for this, wasn't sure where to place feature requests.
Thanks!
Tim | {
"avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4",
"events_url": "https://api.github.com/users/Lukasa/events{/privacy}",
"followers_url": "https://api.github.com/users/Lukasa/followers",
"following_url": "https://api.github.com/users/Lukasa/following{/other_user}",
"gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Lukasa",
"id": 1382556,
"login": "Lukasa",
"node_id": "MDQ6VXNlcjEzODI1NTY=",
"organizations_url": "https://api.github.com/users/Lukasa/orgs",
"received_events_url": "https://api.github.com/users/Lukasa/received_events",
"repos_url": "https://api.github.com/users/Lukasa/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Lukasa",
"user_view_type": "public"
} | {
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/3854/reactions"
} | https://api.github.com/repos/psf/requests/issues/3854/timeline | null | completed | null | null | false | [
"Thanks for this request!\n\nUnfortunately, we're unlikely to support this: it's fundamentally an additional complexity that we don't think is justified in the API. At this point our top-level API is largely frozen, and we're very unlikely to widen it or add new features.\n\nHowever, it's worth noting that the Tran... |
https://api.github.com/repos/psf/requests/issues/3853 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3853/labels{/name} | https://api.github.com/repos/psf/requests/issues/3853/comments | https://api.github.com/repos/psf/requests/issues/3853/events | https://github.com/psf/requests/pull/3853 | 205,637,955 | MDExOlB1bGxSZXF1ZXN0MTA0ODMyNTA2 | 3,853 | Do not convert /o\ into /O\ | {
"avatar_url": "https://avatars.githubusercontent.com/u/167327?v=4",
"events_url": "https://api.github.com/users/StyXman/events{/privacy}",
"followers_url": "https://api.github.com/users/StyXman/followers",
"following_url": "https://api.github.com/users/StyXman/following{/other_user}",
"gists_url": "https://api.github.com/users/StyXman/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/StyXman",
"id": 167327,
"login": "StyXman",
"node_id": "MDQ6VXNlcjE2NzMyNw==",
"organizations_url": "https://api.github.com/users/StyXman/orgs",
"received_events_url": "https://api.github.com/users/StyXman/received_events",
"repos_url": "https://api.github.com/users/StyXman/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/StyXman/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/StyXman/subscriptions",
"type": "User",
"url": "https://api.github.com/users/StyXman",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 3 | 2017-02-06T16:31:22Z | 2021-09-07T00:06:39Z | 2017-02-07T16:04:25Z | CONTRIBUTOR | resolved | There is code that already check that a guy raising (at least) his right arm does not get big-headed (a.k.a uppercased). Just add the same for the other, poor guy complaining about an error. | {
"avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4",
"events_url": "https://api.github.com/users/Lukasa/events{/privacy}",
"followers_url": "https://api.github.com/users/Lukasa/followers",
"following_url": "https://api.github.com/users/Lukasa/following{/other_user}",
"gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Lukasa",
"id": 1382556,
"login": "Lukasa",
"node_id": "MDQ6VXNlcjEzODI1NTY=",
"organizations_url": "https://api.github.com/users/Lukasa/orgs",
"received_events_url": "https://api.github.com/users/Lukasa/received_events",
"repos_url": "https://api.github.com/users/Lukasa/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Lukasa",
"user_view_type": "public"
} | {
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/3853/reactions"
} | https://api.github.com/repos/psf/requests/issues/3853/timeline | null | null | false | {
"diff_url": "https://github.com/psf/requests/pull/3853.diff",
"html_url": "https://github.com/psf/requests/pull/3853",
"merged_at": "2017-02-07T16:04:25Z",
"patch_url": "https://github.com/psf/requests/pull/3853.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/3853"
} | true | [
"Yes, sorry, I just (w)hacked it in 3 minutes without proper testing. Shame on me. Let me see...",
"Cool, looks good now, thanks! :sparkles:",
"\\o/"
] |
https://api.github.com/repos/psf/requests/issues/3852 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3852/labels{/name} | https://api.github.com/repos/psf/requests/issues/3852/comments | https://api.github.com/repos/psf/requests/issues/3852/events | https://github.com/psf/requests/issues/3852 | 205,373,183 | MDU6SXNzdWUyMDUzNzMxODM= | 3,852 | Missing response headers when malformed header is part of the response | {
"avatar_url": "https://avatars.githubusercontent.com/u/370329?v=4",
"events_url": "https://api.github.com/users/gboudreau/events{/privacy}",
"followers_url": "https://api.github.com/users/gboudreau/followers",
"following_url": "https://api.github.com/users/gboudreau/following{/other_user}",
"gists_url": "https://api.github.com/users/gboudreau/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/gboudreau",
"id": 370329,
"login": "gboudreau",
"node_id": "MDQ6VXNlcjM3MDMyOQ==",
"organizations_url": "https://api.github.com/users/gboudreau/orgs",
"received_events_url": "https://api.github.com/users/gboudreau/received_events",
"repos_url": "https://api.github.com/users/gboudreau/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/gboudreau/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/gboudreau/subscriptions",
"type": "User",
"url": "https://api.github.com/users/gboudreau",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 2 | 2017-02-04T19:58:37Z | 2021-09-08T12:01:02Z | 2017-02-04T21:12:25Z | NONE | resolved | Using Python 3.5, requests 2.13.0
```
>>> import requests
>>> r = requests.get('https://online.chasecanada.ca/ChaseCanada_Consumer/Login.do')
>>> print(r)
<Response [200]>
>>> print(r.headers)
{'Date': 'Sat, 04 Feb 2017 19:52:14 GMT'}
>>>
```
I'm pretty sure the problem is caused by an invalid HTTP header returned by the server:
HTTP/1.1 200 OK
Date: Sat, 04 Feb 2017 19:16:34 GMT
My Param: None
[...]
It directly follows the `Date` response header, which is returned fine, but since no other response headers is returned, I think this broken header is breaking the HTTP response headers parser. | {
"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/3852/reactions"
} | https://api.github.com/repos/psf/requests/issues/3852/timeline | null | completed | null | null | false | [
"Hum. Not sure this is a `requests` issue, since the `headers` dict in the `urllib3.response.HTTPResponse` object also only has the `Date` header...\r\nMaybe there is a workaround somehow..? ",
"As I answered on the urllib3 issue you opened, there is no workaround until urllib3 is no longer reliant on `http.clien... |
https://api.github.com/repos/psf/requests/issues/3851 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3851/labels{/name} | https://api.github.com/repos/psf/requests/issues/3851/comments | https://api.github.com/repos/psf/requests/issues/3851/events | https://github.com/psf/requests/pull/3851 | 205,216,395 | MDExOlB1bGxSZXF1ZXN0MTA0NTc0OTAw | 3,851 | remove pin | {
"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 | 2017-02-03T17:14:31Z | 2021-09-07T00:06:39Z | 2017-02-03T17:21:14Z | MEMBER | resolved | @kennethreitz, it looks like the Pipfile was rebuilt yesterday with the latest version of `pipenv`. We'll need to remove the version we had pinned now that kennethreitz/pipenv#90 is resolved. | {
"avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4",
"events_url": "https://api.github.com/users/Lukasa/events{/privacy}",
"followers_url": "https://api.github.com/users/Lukasa/followers",
"following_url": "https://api.github.com/users/Lukasa/following{/other_user}",
"gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Lukasa",
"id": 1382556,
"login": "Lukasa",
"node_id": "MDQ6VXNlcjEzODI1NTY=",
"organizations_url": "https://api.github.com/users/Lukasa/orgs",
"received_events_url": "https://api.github.com/users/Lukasa/received_events",
"repos_url": "https://api.github.com/users/Lukasa/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Lukasa",
"user_view_type": "public"
} | {
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/3851/reactions"
} | https://api.github.com/repos/psf/requests/issues/3851/timeline | null | null | false | {
"diff_url": "https://github.com/psf/requests/pull/3851.diff",
"html_url": "https://github.com/psf/requests/pull/3851",
"merged_at": "2017-02-03T17:21:14Z",
"patch_url": "https://github.com/psf/requests/pull/3851.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/3851"
} | true | [] |
https://api.github.com/repos/psf/requests/issues/3850 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3850/labels{/name} | https://api.github.com/repos/psf/requests/issues/3850/comments | https://api.github.com/repos/psf/requests/issues/3850/events | https://github.com/psf/requests/issues/3850 | 205,180,611 | MDU6SXNzdWUyMDUxODA2MTE= | 3,850 | Unsupported authorization method | {
"avatar_url": "https://avatars.githubusercontent.com/u/4481867?v=4",
"events_url": "https://api.github.com/users/thewebsitedev/events{/privacy}",
"followers_url": "https://api.github.com/users/thewebsitedev/followers",
"following_url": "https://api.github.com/users/thewebsitedev/following{/other_user}",
"gists_url": "https://api.github.com/users/thewebsitedev/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/thewebsitedev",
"id": 4481867,
"login": "thewebsitedev",
"node_id": "MDQ6VXNlcjQ0ODE4Njc=",
"organizations_url": "https://api.github.com/users/thewebsitedev/orgs",
"received_events_url": "https://api.github.com/users/thewebsitedev/received_events",
"repos_url": "https://api.github.com/users/thewebsitedev/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/thewebsitedev/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/thewebsitedev/subscriptions",
"type": "User",
"url": "https://api.github.com/users/thewebsitedev",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 2 | 2017-02-03T15:03:16Z | 2021-09-08T12:01:03Z | 2017-02-03T15:06:32Z | NONE | resolved | Hello,
My code:
```
headers = {'Authorization': 'Bearer '+access_token}
payload = {'grant_type':'refresh_token','refresh_token':refresh_token,'client_id': client_id, 'client_secret': client_secret}
resp = requests.post(url,headers=headers,data=payload).json()
```
I am trying to get refresh token as mentioned in the [docs](https://build.envato.com/api/#oauth) for Envato API.
When I run this code I get the following response:
**{'error': 'invalid_request', 'error_description': 'Unsupported authorization method: '}**
Can anyone point out as to what I am missing here?
As per the docs I need to make a POST request to get the refresh token.
```
POST https://api.envato.com/token
grant_type=refresh_token&
refresh_token=[REFRESH_TOKEN]&
client_id=[CLIENT_ID]&
client_secret=[CLIENT_SECRET]
```
Requests: v2.13.0
Python: v3.5.3 | {
"avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4",
"events_url": "https://api.github.com/users/Lukasa/events{/privacy}",
"followers_url": "https://api.github.com/users/Lukasa/followers",
"following_url": "https://api.github.com/users/Lukasa/following{/other_user}",
"gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Lukasa",
"id": 1382556,
"login": "Lukasa",
"node_id": "MDQ6VXNlcjEzODI1NTY=",
"organizations_url": "https://api.github.com/users/Lukasa/orgs",
"received_events_url": "https://api.github.com/users/Lukasa/received_events",
"repos_url": "https://api.github.com/users/Lukasa/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Lukasa",
"user_view_type": "public"
} | {
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/3850/reactions"
} | https://api.github.com/repos/psf/requests/issues/3850/timeline | null | completed | null | null | false | [
"So, this is not really a Requests problem: the problem is with the specific data you need to send in the OAuth flow.\r\n\r\nHowever, can I suggest you try removing the `Authorization` header? This uses the `token` endpoint, which some of the other requests do, and none of the others provide an `Authorization` head... |
https://api.github.com/repos/psf/requests/issues/3849 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3849/labels{/name} | https://api.github.com/repos/psf/requests/issues/3849/comments | https://api.github.com/repos/psf/requests/issues/3849/events | https://github.com/psf/requests/issues/3849 | 205,100,797 | MDU6SXNzdWUyMDUxMDA3OTc= | 3,849 | Received response with content-encoding: gzip, but failed to decode it | {
"avatar_url": "https://avatars.githubusercontent.com/u/11490531?v=4",
"events_url": "https://api.github.com/users/wavenator/events{/privacy}",
"followers_url": "https://api.github.com/users/wavenator/followers",
"following_url": "https://api.github.com/users/wavenator/following{/other_user}",
"gists_url": "https://api.github.com/users/wavenator/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/wavenator",
"id": 11490531,
"login": "wavenator",
"node_id": "MDQ6VXNlcjExNDkwNTMx",
"organizations_url": "https://api.github.com/users/wavenator/orgs",
"received_events_url": "https://api.github.com/users/wavenator/received_events",
"repos_url": "https://api.github.com/users/wavenator/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/wavenator/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/wavenator/subscriptions",
"type": "User",
"url": "https://api.github.com/users/wavenator",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 2 | 2017-02-03T08:46:29Z | 2021-09-05T00:07:03Z | 2017-02-03T08:58:17Z | NONE | resolved | ```python
import requests
requests.get('http://gett.bike/')
```
This code raises the following exception:
```python
ContentDecodingError: ('Received response with content-encoding: gzip, but failed to decode it.',
error('Error -3 while decompressing data: incorrect data check',))
```
Arch linux x64
requests==2.13.0
python=3.6.0 | {
"avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4",
"events_url": "https://api.github.com/users/Lukasa/events{/privacy}",
"followers_url": "https://api.github.com/users/Lukasa/followers",
"following_url": "https://api.github.com/users/Lukasa/following{/other_user}",
"gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Lukasa",
"id": 1382556,
"login": "Lukasa",
"node_id": "MDQ6VXNlcjEzODI1NTY=",
"organizations_url": "https://api.github.com/users/Lukasa/orgs",
"received_events_url": "https://api.github.com/users/Lukasa/received_events",
"repos_url": "https://api.github.com/users/Lukasa/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Lukasa",
"user_view_type": "public"
} | {
"+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/3849/reactions"
} | https://api.github.com/repos/psf/requests/issues/3849/timeline | null | completed | null | null | false | [
"This seems like the server is returning data it claims is gzipped, but isn't, or is invalid somehow. curl agrees with this assessment, as you can see by doing `curl -L --compressed http://gett.bike`, which leads to:\r\n\r\n```curl: (23) Error while processing content unencoding: invalid block type```\r\n\r\nYou ca... |
https://api.github.com/repos/psf/requests/issues/3848 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3848/labels{/name} | https://api.github.com/repos/psf/requests/issues/3848/comments | https://api.github.com/repos/psf/requests/issues/3848/events | https://github.com/psf/requests/issues/3848 | 205,099,377 | MDU6SXNzdWUyMDUwOTkzNzc= | 3,848 | A little suggestion about 'LookupDict' in 'requests/requests/structures.py' | {
"avatar_url": "https://avatars.githubusercontent.com/u/22973136?v=4",
"events_url": "https://api.github.com/users/jiazhuamh/events{/privacy}",
"followers_url": "https://api.github.com/users/jiazhuamh/followers",
"following_url": "https://api.github.com/users/jiazhuamh/following{/other_user}",
"gists_url": "https://api.github.com/users/jiazhuamh/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/jiazhuamh",
"id": 22973136,
"login": "jiazhuamh",
"node_id": "MDQ6VXNlcjIyOTczMTM2",
"organizations_url": "https://api.github.com/users/jiazhuamh/orgs",
"received_events_url": "https://api.github.com/users/jiazhuamh/received_events",
"repos_url": "https://api.github.com/users/jiazhuamh/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/jiazhuamh/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/jiazhuamh/subscriptions",
"type": "User",
"url": "https://api.github.com/users/jiazhuamh",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 2 | 2017-02-03T08:37:43Z | 2021-09-08T12:01:03Z | 2017-02-03T09:02:48Z | NONE | resolved | Dear Sir,
I like your 'requests' Python library very much and I'm reading the source code these days. I found a problem that is tricky. The 'LookupDict' class definition is:
`
```
class LookupDict(dict):
def __init__(self, name=None):
self.name = name
super(LookupDict, self).__init__()
def __repr__(self):
return '<lookup \'%s\'>' % (self.name)
def __getitem__(self, key):
# We allow fall-through here, so values default to None
return self.__dict__.get(key, None)
def get(self, key, default=None):
return self.__dict__.get(key, default)
```
`
It inherits the 'dict' object but does not use any of the 'dict' methed. It only use the class's \__dict__ and it is ok to replace the 'dict' with 'object'.
| {
"avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4",
"events_url": "https://api.github.com/users/Lukasa/events{/privacy}",
"followers_url": "https://api.github.com/users/Lukasa/followers",
"following_url": "https://api.github.com/users/Lukasa/following{/other_user}",
"gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Lukasa",
"id": 1382556,
"login": "Lukasa",
"node_id": "MDQ6VXNlcjEzODI1NTY=",
"organizations_url": "https://api.github.com/users/Lukasa/orgs",
"received_events_url": "https://api.github.com/users/Lukasa/received_events",
"repos_url": "https://api.github.com/users/Lukasa/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Lukasa",
"user_view_type": "public"
} | {
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/3848/reactions"
} | https://api.github.com/repos/psf/requests/issues/3848/timeline | null | completed | null | null | false | [
"`LookupDict` absolutely includes all of the dict methods. In particular, it allows the use of `__setitem__` and other things from the dict class. It specifically does only one thing, which is override `__getitem__` to allow returning `None`.\r\n\r\nSo it's not ok to replace the dict with `object` in this case, eve... |
https://api.github.com/repos/psf/requests/issues/3847 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3847/labels{/name} | https://api.github.com/repos/psf/requests/issues/3847/comments | https://api.github.com/repos/psf/requests/issues/3847/events | https://github.com/psf/requests/issues/3847 | 205,083,957 | MDU6SXNzdWUyMDUwODM5NTc= | 3,847 | requests messes up a ZIP stream (?) | {
"avatar_url": "https://avatars.githubusercontent.com/u/3466341?v=4",
"events_url": "https://api.github.com/users/ResidentMario/events{/privacy}",
"followers_url": "https://api.github.com/users/ResidentMario/followers",
"following_url": "https://api.github.com/users/ResidentMario/following{/other_user}",
"gists_url": "https://api.github.com/users/ResidentMario/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/ResidentMario",
"id": 3466341,
"login": "ResidentMario",
"node_id": "MDQ6VXNlcjM0NjYzNDE=",
"organizations_url": "https://api.github.com/users/ResidentMario/orgs",
"received_events_url": "https://api.github.com/users/ResidentMario/received_events",
"repos_url": "https://api.github.com/users/ResidentMario/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/ResidentMario/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/ResidentMario/subscriptions",
"type": "User",
"url": "https://api.github.com/users/ResidentMario",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 3 | 2017-02-03T06:43:04Z | 2021-09-08T12:01:02Z | 2017-02-03T10:11:29Z | NONE | resolved | There's an interesting bug that I've run into involving reading [a zipfile](https://data.cityofnewyork.us/dataset/Broadband-Data-Dig-Datasets/ft4n-yqee) off the web.
The details as in the comments to [this answer on StackOverflow](http://stackoverflow.com/a/42016924/1993206):
This fails with a `BadZipFileError`:
```
z = zipfile.ZipFile(io.BytesIO(requests.get("https://data.cityofnewyork.us/dataset/Broadband-Data-Dig-Datasets/ft4n-yqee").content))
```
But writing `requests.get("https://data.cityofnewyork.us/dataset/Broadband-Data-Dig-Datasets/ft4n-yqee").content` to a file and *then* opening it with `ZipFile` works fine. So this works:
```
with open("temp.zip", "wb") as fp:
fp.write(requests.get("https://data.cityofnewyork.us/dataset/Broadband-Data-Dig-Datasets/ft4n-yqee").content)
with open("temp.zip", "rb") as fp:
zipcontent = zipfile.ZipFile(fp)
```
This is on Python 3.5.2 and Requests 2.12.4. | {
"avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4",
"events_url": "https://api.github.com/users/Lukasa/events{/privacy}",
"followers_url": "https://api.github.com/users/Lukasa/followers",
"following_url": "https://api.github.com/users/Lukasa/following{/other_user}",
"gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Lukasa",
"id": 1382556,
"login": "Lukasa",
"node_id": "MDQ6VXNlcjEzODI1NTY=",
"organizations_url": "https://api.github.com/users/Lukasa/orgs",
"received_events_url": "https://api.github.com/users/Lukasa/received_events",
"repos_url": "https://api.github.com/users/Lukasa/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Lukasa",
"user_view_type": "public"
} | {
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/3847/reactions"
} | https://api.github.com/repos/psf/requests/issues/3847/timeline | null | completed | null | null | false | [
"That doesn't work for me at all. =)\r\n\r\nAn FYI: the response I get from that website is HTML, always. By my reckoning the download link is `https://data.cityofnewyork.us/download/ft4n-yqee/application%2Fzip`, and that link does appear to work correctly in the code sample. =)",
"Yes, my bad for posting the wro... |
https://api.github.com/repos/psf/requests/issues/3846 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3846/labels{/name} | https://api.github.com/repos/psf/requests/issues/3846/comments | https://api.github.com/repos/psf/requests/issues/3846/events | https://github.com/psf/requests/pull/3846 | 204,761,219 | MDExOlB1bGxSZXF1ZXN0MTA0MjYxNDg0 | 3,846 | initial attempt at `get_redirect_target` | {
"avatar_url": "https://avatars.githubusercontent.com/u/204779?v=4",
"events_url": "https://api.github.com/users/jvanasco/events{/privacy}",
"followers_url": "https://api.github.com/users/jvanasco/followers",
"following_url": "https://api.github.com/users/jvanasco/following{/other_user}",
"gists_url": "https://api.github.com/users/jvanasco/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/jvanasco",
"id": 204779,
"login": "jvanasco",
"node_id": "MDQ6VXNlcjIwNDc3OQ==",
"organizations_url": "https://api.github.com/users/jvanasco/orgs",
"received_events_url": "https://api.github.com/users/jvanasco/received_events",
"repos_url": "https://api.github.com/users/jvanasco/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/jvanasco/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/jvanasco/subscriptions",
"type": "User",
"url": "https://api.github.com/users/jvanasco",
"user_view_type": "public"
} | [
{
"color": "d4c5f9",
"default": false,
"description": null,
"id": 536793543,
"name": "needs rebase",
"node_id": "MDU6TGFiZWw1MzY3OTM1NDM=",
"url": "https://api.github.com/repos/psf/requests/labels/needs%20rebase"
}
] | closed | true | null | [] | null | 14 | 2017-02-02T01:52:21Z | 2021-09-07T00:06:35Z | 2017-02-10T21:46:14Z | CONTRIBUTOR | resolved | This is the first attempt at a PR to address my proposal #3837 to support pluggable redirect handling. Feedback is welcome.
This does not break existing tests and adds a new test to for handling malformed 200+location responses using a custom session mixin.
I've been testing it for a day and it seems to be fine.
Thank you for simply considering this, and even more thanks for all the suggestions and advice in the related thread. It has been a long week of little sleep trying to pin down some issues. | {
"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/3846/reactions"
} | https://api.github.com/repos/psf/requests/issues/3846/timeline | null | null | false | {
"diff_url": "https://github.com/psf/requests/pull/3846.diff",
"html_url": "https://github.com/psf/requests/pull/3846",
"merged_at": "2017-02-10T21:46:14Z",
"patch_url": "https://github.com/psf/requests/pull/3846.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/3846"
} | true | [
"# [Codecov](https://codecov.io/gh/kennethreitz/requests/pull/3846?src=pr&el=h1) Report\n> Merging [#3846](https://codecov.io/gh/kennethreitz/requests/pull/3846?src=pr&el=desc) into [master](https://codecov.io/gh/kennethreitz/requests/commit/ad65b0cb19124b5ae4dd01bf19d82c16ffb2485d?src=pr&el=desc) will **increase**... |
https://api.github.com/repos/psf/requests/issues/3845 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3845/labels{/name} | https://api.github.com/repos/psf/requests/issues/3845/comments | https://api.github.com/repos/psf/requests/issues/3845/events | https://github.com/psf/requests/issues/3845 | 204,752,845 | MDU6SXNzdWUyMDQ3NTI4NDU= | 3,845 | Various Intermittent Request Errors | {
"avatar_url": "https://avatars.githubusercontent.com/u/7819023?v=4",
"events_url": "https://api.github.com/users/lukas-gitl/events{/privacy}",
"followers_url": "https://api.github.com/users/lukas-gitl/followers",
"following_url": "https://api.github.com/users/lukas-gitl/following{/other_user}",
"gists_url": "https://api.github.com/users/lukas-gitl/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/lukas-gitl",
"id": 7819023,
"login": "lukas-gitl",
"node_id": "MDQ6VXNlcjc4MTkwMjM=",
"organizations_url": "https://api.github.com/users/lukas-gitl/orgs",
"received_events_url": "https://api.github.com/users/lukas-gitl/received_events",
"repos_url": "https://api.github.com/users/lukas-gitl/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/lukas-gitl/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/lukas-gitl/subscriptions",
"type": "User",
"url": "https://api.github.com/users/lukas-gitl",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 11 | 2017-02-02T00:57:28Z | 2021-09-08T04:00:37Z | 2017-02-02T08:34:42Z | NONE | resolved | When using requests.post (have not tried other methods) I get the following errors **intermittently**.
**Errors**
- ('Connection aborted.', BadStatusLine("''",))
- ('Connection aborted.', error(104, 'Connection reset by peer'))
- ("bad handshake: SysCallError(104, 'ECONNRESET')",)
- EOF occurred in violation of protocol (_ssl.c:661)
- HTTPSConnectionPool(host='...', port=443): Max retries exceeded with url: ... (Caused by NewConnectionError('<requests.packages.urllib3.connection.VerifiedHTTPSConnection object at 0x...>: Failed to establish a new connection: [Errno 110] Operation timed out',))
- Sometimes I just get a 502 or 504 back, but that might be a remote issues
The amount this happens differs, but at least a few times every hour (we are sending a few thousand logs per hour). I wasn't able to reproduce these errors locally or reliably.
I have experienced this will various targets hosts, namely the api provided by: loggly.com, logentries.com, logz.io. Since they all have the issue I don't think it is a server configuration problem.
This issue first appeared about a year ago when we set this up. However it seems to have gotten more problematic since we are sending more requests.
**Setup**
Running Python on Elastic Beanstalk inside a [Single Container Docker Configuration](http://docs.aws.amazon.com/elasticbeanstalk/latest/dg/create_deploy_docker_image.html) behind an Elastic Load Balancer. The outgoing requests happen in various threads (not just in the main thread).
More information that might be useful:
- EC2 Instance OS (`cat /etc/*-release`)
```
NAME="Amazon Linux AMI"
VERSION="2016.09"
ID="amzn"
ID_LIKE="rhel fedora"
VERSION_ID="2016.09"
PRETTY_NAME="Amazon Linux AMI 2016.09"
ANSI_COLOR="0;33"
CPE_NAME="cpe:/o:amazon:linux:2016.09:ga"
HOME_URL="http://aws.amazon.com/amazon-linux-ami/"
Amazon Linux AMI release 2016.09
```
- Docker Version (`docker --version`)
```
Docker version 1.12.6, build 7392c3b/1.12.6
```
- Docker Container OS (`cat /etc/*-release`)
```
3.4.6
NAME="Alpine Linux"
ID=alpine
VERSION_ID=3.4.6
PRETTY_NAME="Alpine Linux v3.4"
HOME_URL="http://alpinelinux.org"
BUG_REPORT_URL="http://bugs.alpinelinux.org"
```
- Python 2.7.13
- `pip freeze --local` results:
_alembic==0.8.10
aniso8601==1.2.0
apns==2.0.1
awsebcli==3.9.0
backports.ssl-match-hostname==3.5.0.1
blessed==1.9.5
boto==2.45.0
botocore==1.5.7
cement==2.8.2
cffi==1.9.1
click==6.7
colorama==0.3.7
contextlib2==0.5.4
coverage==4.3.4
cryptography==1.7.2
docker-py==1.7.2
dockerpty==0.4.1
docopt==0.4.0
docutils==0.13.1
enum34==1.1.6
Faker==0.7.7
Flask==0.12
Flask-Compress==1.4.0
Flask-Limiter==0.9.3
Flask-Migrate==2.0.3
Flask-RESTful==0.3.5
-e flask-restful-swagger==0.15.5
Flask-Script==2.0.5
Flask-SQLAlchemy==2.1
Flask-Testing==0.6.1
funcsigs==1.0.2
GeoAlchemy2==0.4.0
idna==2.2
ipaddress==1.0.18
itsdangerous==0.24
Jinja2==2.9.5
jmespath==0.9.1
limits==1.2.1
Mako==1.0.6
mandrill==1.0.57
MarkupSafe==0.23
mock==2.0.0
nose==1.3.7
pathspec==0.5.0
pbr==1.10.0
pep8==1.7.0
pexpect==4.2.1
psycopg2==2.6.2
ptyprocess==0.5.1
pyasn1==0.1.9
pybars3==0.9.2
pycparser==2.17
pycrypto==2.6.1
pymemcache==1.4.0
PyMeta3==0.5.1
pyOpenSSL==16.2.0
python-dateutil==2.6.0
python-editor==1.0.3
python-gcm==0.1.5
pytz==2016.10
PyYAML==3.12
requests==2.13.0
rollbar==0.13.10
semantic-version==2.5.0
six==1.10.0
SQLAlchemy==1.1.5
tabulate==0.7.5
uWSGI==2.0.14
vcrpy==1.10.5
wcwidth==0.1.7
websocket-client==0.40.0
Werkzeug==0.11.15
wrapt==1.10.8_
**Not working Solutions**
I have found similar issues here, but was not able to fix it with any of the described solutions. I have tried a lot of different approaches, non of which seem to work. Would much appreciate advice and what I should try next.
- Added a small sleep, since I thought this might be related to this [GIL issue](http://stackoverflow.com/questions/383738/104-connection-reset-by-peer-socket-error-or-when-does-closing-a-socket-resu)
- Tried running requests in separate processes instead of a thread, since [GIL issue](http://stackoverflow.com/questions/383738/104-connection-reset-by-peer-socket-error-or-when-does-closing-a-socket-resu) implied this might help
- Tried to use sessions per thread as to not open too many TCP connections, but no difference in error rate
- Tried installing various libraries (pyopenssl, pyasn1, and ndg-httpsclient) as recommended [here](https://github.com/kennethreitz/requests/issues/3391) and [here](https://github.com/kennethreitz/requests/issues/3006).
- Tried injecting `from requests.packages.urllib3.contrib import pyopenssl; pyopenssl.inject_into_urllib3()` like described [here](https://github.com/kennethreitz/requests/issues/3006).
- switched from ubuntu to alpine docker container
- updated everythign to the latest version (including ec2 and docker version)
- Some other stuff that I can't remember at this point
What else should I try? Any idea what might be causing this? What tools should I use to debug this? I'm kind of at a loss here. | {
"avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4",
"events_url": "https://api.github.com/users/Lukasa/events{/privacy}",
"followers_url": "https://api.github.com/users/Lukasa/followers",
"following_url": "https://api.github.com/users/Lukasa/following{/other_user}",
"gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Lukasa",
"id": 1382556,
"login": "Lukasa",
"node_id": "MDQ6VXNlcjEzODI1NTY=",
"organizations_url": "https://api.github.com/users/Lukasa/orgs",
"received_events_url": "https://api.github.com/users/Lukasa/received_events",
"repos_url": "https://api.github.com/users/Lukasa/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Lukasa",
"user_view_type": "public"
} | {
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/3845/reactions"
} | https://api.github.com/repos/psf/requests/issues/3845/timeline | null | completed | null | null | false | [
"So the first four errors all amount to \"the connection was closed by the remote peer at a time we didn't expect\". The fifth one is a standard connection timeout.\r\n\r\nWhile it's possible that some of these reflect underlying problems (for example, a connection closed during a TLS handshake usually indicates th... |
https://api.github.com/repos/psf/requests/issues/3844 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3844/labels{/name} | https://api.github.com/repos/psf/requests/issues/3844/comments | https://api.github.com/repos/psf/requests/issues/3844/events | https://github.com/psf/requests/issues/3844 | 204,655,822 | MDU6SXNzdWUyMDQ2NTU4MjI= | 3,844 | HTTPS proxy connection not initialized if first request is chunked | {
"avatar_url": "https://avatars.githubusercontent.com/u/3267443?v=4",
"events_url": "https://api.github.com/users/bpitman/events{/privacy}",
"followers_url": "https://api.github.com/users/bpitman/followers",
"following_url": "https://api.github.com/users/bpitman/following{/other_user}",
"gists_url": "https://api.github.com/users/bpitman/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/bpitman",
"id": 3267443,
"login": "bpitman",
"node_id": "MDQ6VXNlcjMyNjc0NDM=",
"organizations_url": "https://api.github.com/users/bpitman/orgs",
"received_events_url": "https://api.github.com/users/bpitman/received_events",
"repos_url": "https://api.github.com/users/bpitman/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/bpitman/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/bpitman/subscriptions",
"type": "User",
"url": "https://api.github.com/users/bpitman",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 6 | 2017-02-01T17:50:04Z | 2024-04-23T00:03:48Z | 2023-04-22T23:33:06Z | NONE | resolved | Using code below, will produce 403 error without https_proxy:
```
$ ./test.py
<Response [403]>
```
But ssl error with https_proxy (because CONNECT request is never sent):
```
$ https_proxy=http://10.32.2.100:1080/ ./test.py
Traceback (most recent call last):
File "./test.py", line 11, in <module>
res = session.put("https://github.com/kennethreitz", data=StringIO.StringIO(""))
File "/opt/pepperdata/native/lib/python2.7/site-packages/requests/sessions.py", line 533, in put
return self.request('PUT', url, data=data, **kwargs)
File "/opt/pepperdata/native/lib/python2.7/site-packages/requests/sessions.py", line 475, in request
resp = self.send(prep, **send_kwargs)
File "/opt/pepperdata/native/lib/python2.7/site-packages/requests/sessions.py", line 596, in send
r = adapter.send(request, **kwargs)
File "/opt/pepperdata/native/lib/python2.7/site-packages/requests/adapters.py", line 492, in send
raise ConnectionError(err, request=request)
ConnectionError: [SSL: UNKNOWN_PROTOCOL] unknown protocol (_ssl.c:590)
```
For now, I'm patching my local requests/adaptor.py to init proxy when first conn use is with chunked request:
```
> if hasattr(conn, 'proxy'):
> if conn.proxy is not None and not getattr(low_conn, 'sock', None):
> conn._prepare_proxy(low_conn)
```
```
## test.py ########################################################
import requests
import traceback
import StringIO
import sys
try:
session = requests.session()
res = session.put("https://github.com/kennethreitz", data=StringIO.StringIO(""))
sys.stdout.write(str(res) + "\n")
except Exception:
traceback.print_exc()
session.close()
``` | {
"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/3844/reactions"
} | https://api.github.com/repos/psf/requests/issues/3844/timeline | null | completed | null | null | false | [
"Can you provide some more information please? What requests version are you using. What proxy? What Python version?",
"I work with Brent. I've seen this issue on both Linux and OSX. On Linux I've seen it with python 2.7.11 and requests 2.11.1. On OSX (my laptop) I've seen it with python 2.7.11+requests 2.11.1, p... |
https://api.github.com/repos/psf/requests/issues/3843 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3843/labels{/name} | https://api.github.com/repos/psf/requests/issues/3843/comments | https://api.github.com/repos/psf/requests/issues/3843/events | https://github.com/psf/requests/issues/3843 | 204,565,507 | MDU6SXNzdWUyMDQ1NjU1MDc= | 3,843 | `except` without exception class specified makes IDNA-encoding non-threadsafe. | {
"avatar_url": "https://avatars.githubusercontent.com/u/179961?v=4",
"events_url": "https://api.github.com/users/Crazy-Owl/events{/privacy}",
"followers_url": "https://api.github.com/users/Crazy-Owl/followers",
"following_url": "https://api.github.com/users/Crazy-Owl/following{/other_user}",
"gists_url": "https://api.github.com/users/Crazy-Owl/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Crazy-Owl",
"id": 179961,
"login": "Crazy-Owl",
"node_id": "MDQ6VXNlcjE3OTk2MQ==",
"organizations_url": "https://api.github.com/users/Crazy-Owl/orgs",
"received_events_url": "https://api.github.com/users/Crazy-Owl/received_events",
"repos_url": "https://api.github.com/users/Crazy-Owl/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Crazy-Owl/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Crazy-Owl/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Crazy-Owl",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 3 | 2017-02-01T11:59:56Z | 2021-09-08T12:00:51Z | 2017-02-01T12:05:28Z | NONE | resolved | Hello,
We have a python program with resident process running in separate thread. We make requests in said thread and when master thread spots a timeout, a custom exception is dispatched to child thread via OS signal. We use Requests `2.12.4`.
However, that exception is caught not by our handler (in child thread main loop), but by `except:` directive in `alabel` function deep in `packages/idna/core.py`: https://github.com/kennethreitz/requests/blob/master/requests/packages/idna/core.py#L264 because that handler is an unconditional "catch-all" `except:` directive. That leads to very cryptic behaviour like child thread not stopping and trying to access urls with unnecessary IDNA-encoding (all our URLs are in plain ascii).
Expected behaviour for that handler is not to catch everything, but to expect a specific exception class(es) and work just with them. | {
"avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4",
"events_url": "https://api.github.com/users/Lukasa/events{/privacy}",
"followers_url": "https://api.github.com/users/Lukasa/followers",
"following_url": "https://api.github.com/users/Lukasa/following{/other_user}",
"gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Lukasa",
"id": 1382556,
"login": "Lukasa",
"node_id": "MDQ6VXNlcjEzODI1NTY=",
"organizations_url": "https://api.github.com/users/Lukasa/orgs",
"received_events_url": "https://api.github.com/users/Lukasa/received_events",
"repos_url": "https://api.github.com/users/Lukasa/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Lukasa",
"user_view_type": "public"
} | {
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/3843/reactions"
} | https://api.github.com/repos/psf/requests/issues/3843/timeline | null | completed | null | null | false | [
"Yup, that looks wrong, thanks for reporting it! The `idna` code is vendored, without edits, from [this repo](https://github.com/kjd/idna). I recommend you open an issue there, which when fixed will make its way into Requests.",
"The changes to `idna` repo landed about two weeks ago: https://github.com/kjd/idna/p... |
https://api.github.com/repos/psf/requests/issues/3842 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3842/labels{/name} | https://api.github.com/repos/psf/requests/issues/3842/comments | https://api.github.com/repos/psf/requests/issues/3842/events | https://github.com/psf/requests/issues/3842 | 204,344,671 | MDU6SXNzdWUyMDQzNDQ2NzE= | 3,842 | PUT (requests.put) specifying the source file location for zip file error 10054 | {
"avatar_url": "https://avatars.githubusercontent.com/u/3253973?v=4",
"events_url": "https://api.github.com/users/Twoflower2/events{/privacy}",
"followers_url": "https://api.github.com/users/Twoflower2/followers",
"following_url": "https://api.github.com/users/Twoflower2/following{/other_user}",
"gists_url": "https://api.github.com/users/Twoflower2/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Twoflower2",
"id": 3253973,
"login": "Twoflower2",
"node_id": "MDQ6VXNlcjMyNTM5NzM=",
"organizations_url": "https://api.github.com/users/Twoflower2/orgs",
"received_events_url": "https://api.github.com/users/Twoflower2/received_events",
"repos_url": "https://api.github.com/users/Twoflower2/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Twoflower2/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Twoflower2/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Twoflower2",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 5 | 2017-01-31T16:14:49Z | 2021-09-07T00:06:13Z | 2017-01-31T16:40:24Z | NONE | resolved | With using trying an zip file I get the following, any clues: (requests-2.13.0)
```
with open('default.zip', 'rb') as data:
requests.put(url, data=data)
```
Output:
```
C:\svn\libraries\cpp>python req_put.py default.zip
Traceback (most recent call last):
File "req_put.py", line 102, in <module>
resp = requests.put(uri, headers=headers, data=data) # data=data , params=payload)
File "C:\Python27\lib\site-packages\requests\api.py", line 124, in put
return request('put', url, data=data, **kwargs)
File "C:\Python27\lib\site-packages\requests\api.py", line 56, in request
return session.request(method=method, url=url, **kwargs)
File "C:\Python27\lib\site-packages\requests\sessions.py", line 488, in request
resp = self.send(prep, **send_kwargs)
File "C:\Python27\lib\site-packages\requests\sessions.py", line 609, in send
r = adapter.send(request, **kwargs)
File "C:\Python27\lib\site-packages\requests\adapters.py", line 473, in send
raise ConnectionError(err, request=request)
requests.exceptions.ConnectionError: ('Connection aborted.', error(10054, 'An existing connection was forcibly closed by the remote host'))
```
| {
"avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4",
"events_url": "https://api.github.com/users/Lukasa/events{/privacy}",
"followers_url": "https://api.github.com/users/Lukasa/followers",
"following_url": "https://api.github.com/users/Lukasa/following{/other_user}",
"gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Lukasa",
"id": 1382556,
"login": "Lukasa",
"node_id": "MDQ6VXNlcjEzODI1NTY=",
"organizations_url": "https://api.github.com/users/Lukasa/orgs",
"received_events_url": "https://api.github.com/users/Lukasa/received_events",
"repos_url": "https://api.github.com/users/Lukasa/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Lukasa",
"user_view_type": "public"
} | {
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/3842/reactions"
} | https://api.github.com/repos/psf/requests/issues/3842/timeline | null | completed | null | null | false | [
"The server will have sent a 4XX response, which means it doesn't like your upload. Unfortunately Requests can't handle this yet, because httplib doesn't make it easy. We're working on a substantial refactor to fix this, but it'll be a long time coming. In the meantime, I suggest you try to investigate what format ... |
https://api.github.com/repos/psf/requests/issues/3841 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3841/labels{/name} | https://api.github.com/repos/psf/requests/issues/3841/comments | https://api.github.com/repos/psf/requests/issues/3841/events | https://github.com/psf/requests/pull/3841 | 204,193,292 | MDExOlB1bGxSZXF1ZXN0MTAzODY0Nzk3 | 3,841 | Update Copyright in LICENSE to 2017 | {
"avatar_url": "https://avatars.githubusercontent.com/u/6897645?v=4",
"events_url": "https://api.github.com/users/StewPoll/events{/privacy}",
"followers_url": "https://api.github.com/users/StewPoll/followers",
"following_url": "https://api.github.com/users/StewPoll/following{/other_user}",
"gists_url": "https://api.github.com/users/StewPoll/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/StewPoll",
"id": 6897645,
"login": "StewPoll",
"node_id": "MDQ6VXNlcjY4OTc2NDU=",
"organizations_url": "https://api.github.com/users/StewPoll/orgs",
"received_events_url": "https://api.github.com/users/StewPoll/received_events",
"repos_url": "https://api.github.com/users/StewPoll/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/StewPoll/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/StewPoll/subscriptions",
"type": "User",
"url": "https://api.github.com/users/StewPoll",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 2 | 2017-01-31T03:04:22Z | 2021-09-07T00:06:39Z | 2017-01-31T08:54:28Z | CONTRIBUTOR | resolved | Branch name was meant to be 'Happy New Year' but apparently typing the word 'Year' isn't my strongest skill. | {
"avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4",
"events_url": "https://api.github.com/users/Lukasa/events{/privacy}",
"followers_url": "https://api.github.com/users/Lukasa/followers",
"following_url": "https://api.github.com/users/Lukasa/following{/other_user}",
"gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Lukasa",
"id": 1382556,
"login": "Lukasa",
"node_id": "MDQ6VXNlcjEzODI1NTY=",
"organizations_url": "https://api.github.com/users/Lukasa/orgs",
"received_events_url": "https://api.github.com/users/Lukasa/received_events",
"repos_url": "https://api.github.com/users/Lukasa/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Lukasa",
"user_view_type": "public"
} | {
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/3841/reactions"
} | https://api.github.com/repos/psf/requests/issues/3841/timeline | null | null | false | {
"diff_url": "https://github.com/psf/requests/pull/3841.diff",
"html_url": "https://github.com/psf/requests/pull/3841",
"merged_at": "2017-01-31T08:54:28Z",
"patch_url": "https://github.com/psf/requests/pull/3841.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/3841"
} | true | [
"# [Codecov](https://codecov.io/gh/kennethreitz/requests/pull/3841?src=pr&el=h1) Report\n> Merging [#3841](https://codecov.io/gh/kennethreitz/requests/pull/3841?src=pr&el=desc) into [master](https://codecov.io/gh/kennethreitz/requests/commit/e84086ac86075321aa479a24f6c83dd3ead40212?src=pr&el=desc) will **not impact... |
https://api.github.com/repos/psf/requests/issues/3840 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3840/labels{/name} | https://api.github.com/repos/psf/requests/issues/3840/comments | https://api.github.com/repos/psf/requests/issues/3840/events | https://github.com/psf/requests/issues/3840 | 204,136,883 | MDU6SXNzdWUyMDQxMzY4ODM= | 3,840 | should a malformed non-gzip yet marked gzip response be handled in requests? | {
"avatar_url": "https://avatars.githubusercontent.com/u/204779?v=4",
"events_url": "https://api.github.com/users/jvanasco/events{/privacy}",
"followers_url": "https://api.github.com/users/jvanasco/followers",
"following_url": "https://api.github.com/users/jvanasco/following{/other_user}",
"gists_url": "https://api.github.com/users/jvanasco/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/jvanasco",
"id": 204779,
"login": "jvanasco",
"node_id": "MDQ6VXNlcjIwNDc3OQ==",
"organizations_url": "https://api.github.com/users/jvanasco/orgs",
"received_events_url": "https://api.github.com/users/jvanasco/received_events",
"repos_url": "https://api.github.com/users/jvanasco/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/jvanasco/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/jvanasco/subscriptions",
"type": "User",
"url": "https://api.github.com/users/jvanasco",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 18 | 2017-01-30T21:34:50Z | 2021-09-08T12:00:57Z | 2017-02-09T21:37:02Z | CONTRIBUTOR | resolved | Working on a PR, I discovered that a decently sized CDN will *usually* block the `requests` library via user-agent, but does so with a malformed response that raises an error. (*usually* means hitting the CDN from an ip address using a non-blocked user-string seems to whitelist the IP for 120 seconds -- which is why this took forever to figure out).
Their 403 response is malformed, as the header indicates a gzipped encoding
{'Content-Length': '345', 'Content-Encoding': 'gzip', 'Content-Type': '*/*'}
however the payload is uncompressed plain-text:
<?xml version="1.0" encoding="iso-8859-1"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
<title>403 - Forbidden</title>
</head>
<body>
<h1>403 - Forbidden</h1>
</body>
</html>
This raises a DecodeError/ContentDecodingError in `Response.iter_content`.
I can provide a test case. I just don't want to name the CDN or a client as some project maintainers have (un)official policies on stuff like that.
This is definitely a "bad server". Aside from sending the malformed response, they don't respect 'Accept-Encoding' either.
With this particular CDN, the payload is not chunked and reading the stream with `decode_content=False` will work.
I'm not sure how/if this should be handled. It might be nice to have a fallback where a failure to read compressed data will attempt to read it uncompressed.
| {
"avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4",
"events_url": "https://api.github.com/users/Lukasa/events{/privacy}",
"followers_url": "https://api.github.com/users/Lukasa/followers",
"following_url": "https://api.github.com/users/Lukasa/following{/other_user}",
"gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Lukasa",
"id": 1382556,
"login": "Lukasa",
"node_id": "MDQ6VXNlcjEzODI1NTY=",
"organizations_url": "https://api.github.com/users/Lukasa/orgs",
"received_events_url": "https://api.github.com/users/Lukasa/received_events",
"repos_url": "https://api.github.com/users/Lukasa/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Lukasa",
"user_view_type": "public"
} | {
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/3840/reactions"
} | https://api.github.com/repos/psf/requests/issues/3840/timeline | null | completed | null | null | false | [
"I don't think this should be handled directly. This is strictly an error and the CDN needs to sort out their mess. I have no problems naming names on the Requests issue tracker, but if you'd rather not you should reach out to me directly via email and let me know who it is: the odds are good that either I know som... |
https://api.github.com/repos/psf/requests/issues/3839 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3839/labels{/name} | https://api.github.com/repos/psf/requests/issues/3839/comments | https://api.github.com/repos/psf/requests/issues/3839/events | https://github.com/psf/requests/issues/3839 | 204,121,739 | MDU6SXNzdWUyMDQxMjE3Mzk= | 3,839 | multipart/form-data not encoding correctly on recent versions | {
"avatar_url": "https://avatars.githubusercontent.com/u/6018782?v=4",
"events_url": "https://api.github.com/users/cmanallen/events{/privacy}",
"followers_url": "https://api.github.com/users/cmanallen/followers",
"following_url": "https://api.github.com/users/cmanallen/following{/other_user}",
"gists_url": "https://api.github.com/users/cmanallen/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/cmanallen",
"id": 6018782,
"login": "cmanallen",
"node_id": "MDQ6VXNlcjYwMTg3ODI=",
"organizations_url": "https://api.github.com/users/cmanallen/orgs",
"received_events_url": "https://api.github.com/users/cmanallen/received_events",
"repos_url": "https://api.github.com/users/cmanallen/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/cmanallen/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/cmanallen/subscriptions",
"type": "User",
"url": "https://api.github.com/users/cmanallen",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 2 | 2017-01-30T20:33:23Z | 2021-09-08T12:01:05Z | 2017-01-31T09:45:32Z | NONE | resolved | I have a request that works in older version of the `requests` library but not in more recent versions. The trouble point is the `model` key in the files dictionary. In version `2.11.1`, the model key is correctly recognized by the remote endpoint. In newer versions, the `model` key appears to be omitted or malformed in some way.
I don't believe the API endpoint is the issue. I can execute a `curl` command and it will work as expected.
A sample (functioning) curl request:
```bash
curl -F data_file=@my_file.mp3 -F model=en-US "https://api.speechmatics.com/v1.0/user/1/jobs/?auth_token=ABC"
```
### Request
```python
import requests
files = {
'data_file': open(filename, 'rb'),
'model': ('', 'en-US'),
}
response = requests.post(
'https://api.speechmatics.com/v1.0/user/1/jobs/?auth_token=ABC',
files=files)
print(response.content) # b'{\n "code": 400, \n "error": "No language selected"\n}'
```
### Versions tested:
*All versions installed through `pip` and are being used with `python 3.5`.*
`2.11.1` - Works.
`2.12.4` - **Fails.**
`2.13.0` - **Fails.** | {
"avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4",
"events_url": "https://api.github.com/users/Lukasa/events{/privacy}",
"followers_url": "https://api.github.com/users/Lukasa/followers",
"following_url": "https://api.github.com/users/Lukasa/following{/other_user}",
"gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Lukasa",
"id": 1382556,
"login": "Lukasa",
"node_id": "MDQ6VXNlcjEzODI1NTY=",
"organizations_url": "https://api.github.com/users/Lukasa/orgs",
"received_events_url": "https://api.github.com/users/Lukasa/received_events",
"repos_url": "https://api.github.com/users/Lukasa/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Lukasa",
"user_view_type": "public"
} | {
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/3839/reactions"
} | https://api.github.com/repos/psf/requests/issues/3839/timeline | null | completed | null | null | false | [
"Yeah, this behaviour changed. In particular, the lower-level urllib3 library wanted to allow the possibility of setting an *empty* filename (as opposed to not providing the filename at all). You can get the correct behaviour on all platforms by changing `'model': ('', 'en-US'),` to `'model': (None, 'en-US'),`",
... |
https://api.github.com/repos/psf/requests/issues/3838 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3838/labels{/name} | https://api.github.com/repos/psf/requests/issues/3838/comments | https://api.github.com/repos/psf/requests/issues/3838/events | https://github.com/psf/requests/issues/3838 | 203,864,011 | MDU6SXNzdWUyMDM4NjQwMTE= | 3,838 | ignoring MTU and MSS in TCP handshake | {
"avatar_url": "https://avatars.githubusercontent.com/u/17862972?v=4",
"events_url": "https://api.github.com/users/boogardgodig/events{/privacy}",
"followers_url": "https://api.github.com/users/boogardgodig/followers",
"following_url": "https://api.github.com/users/boogardgodig/following{/other_user}",
"gists_url": "https://api.github.com/users/boogardgodig/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/boogardgodig",
"id": 17862972,
"login": "boogardgodig",
"node_id": "MDQ6VXNlcjE3ODYyOTcy",
"organizations_url": "https://api.github.com/users/boogardgodig/orgs",
"received_events_url": "https://api.github.com/users/boogardgodig/received_events",
"repos_url": "https://api.github.com/users/boogardgodig/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/boogardgodig/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/boogardgodig/subscriptions",
"type": "User",
"url": "https://api.github.com/users/boogardgodig",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 1 | 2017-01-29T11:17:05Z | 2021-09-08T12:01:06Z | 2017-01-29T16:01:58Z | NONE | resolved | Hi
I was using requests flawlessly till yesterday I realised I cannot send large packets to https server getting following error
`requests/adapters.py", line 473, in send
raise ConnectionError(err, request=request)
requests.exceptions.ConnectionError: ('Connection aborted.', BadStatusLine("''",))
`
Turns out my ISP started filtering ICMP fargmentation needed packets and drops large packets. Otherwise packets would have been fragmented and retransmited. Shouldn't requests fragment packets with respenct to MTU or MSS to prevent this from happening?
Is there a work around to this problem? | {
"avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4",
"events_url": "https://api.github.com/users/Lukasa/events{/privacy}",
"followers_url": "https://api.github.com/users/Lukasa/followers",
"following_url": "https://api.github.com/users/Lukasa/following{/other_user}",
"gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Lukasa",
"id": 1382556,
"login": "Lukasa",
"node_id": "MDQ6VXNlcjEzODI1NTY=",
"organizations_url": "https://api.github.com/users/Lukasa/orgs",
"received_events_url": "https://api.github.com/users/Lukasa/received_events",
"repos_url": "https://api.github.com/users/Lukasa/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Lukasa",
"user_view_type": "public"
} | {
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/3838/reactions"
} | https://api.github.com/repos/psf/requests/issues/3838/timeline | null | completed | null | null | false | [
"Requests does not control the way packets are emitted. The socket API for TCP does not expose or allow us to control packet boundaries: the TCP layer in the kernel manages all of this. Any problem you're seeing would be encountered by other programs on your system. \r\n\r\nYou'll need to investigate your system's ... |
https://api.github.com/repos/psf/requests/issues/3837 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3837/labels{/name} | https://api.github.com/repos/psf/requests/issues/3837/comments | https://api.github.com/repos/psf/requests/issues/3837/events | https://github.com/psf/requests/issues/3837 | 203,821,379 | MDU6SXNzdWUyMDM4MjEzNzk= | 3,837 | Proposal: potential way to follow bad url shorteners | {
"avatar_url": "https://avatars.githubusercontent.com/u/204779?v=4",
"events_url": "https://api.github.com/users/jvanasco/events{/privacy}",
"followers_url": "https://api.github.com/users/jvanasco/followers",
"following_url": "https://api.github.com/users/jvanasco/following{/other_user}",
"gists_url": "https://api.github.com/users/jvanasco/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/jvanasco",
"id": 204779,
"login": "jvanasco",
"node_id": "MDQ6VXNlcjIwNDc3OQ==",
"organizations_url": "https://api.github.com/users/jvanasco/orgs",
"received_events_url": "https://api.github.com/users/jvanasco/received_events",
"repos_url": "https://api.github.com/users/jvanasco/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/jvanasco/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/jvanasco/subscriptions",
"type": "User",
"url": "https://api.github.com/users/jvanasco",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 16 | 2017-01-28T18:03:54Z | 2021-09-08T12:00:58Z | 2017-02-10T22:10:22Z | CONTRIBUTOR | resolved | I've ran into an issue that runs tangent to issue #441.
We have a content indexer that is powered by `requests`. Some of the larger URL shorteners exhibit some weird behaviors depending on the user agent string.
* (variant of #441) depending on the user-agent header, a particular shortener will either send a proper 301 response OR a HTTP 200 containing a meta-refresh value of 0.
<head><meta name="referrer" content="always"><noscript><META http-equiv="refresh" content="0;URL={URL}"></noscript><title>{URL}</title></head><script>window.opener = null; location.replace("{URL}")</script>
* (new?) a handful of url shorteners may send a HTTP-200 response with a `location` header to the redirect. (yes I know, it breaks spec and makes no sense.
To handle both of these (and several other scenarios) I have a novel suggestion. The callback hooks could be used to allow developers to catch and follow these types of redirect oddities within a single configured request.
A developer would be able to handle edge cases like the above by with a hook:
def bad_shortener_callback(r):
r_location = r.headers.get('location')
if r.status_code == 200 and r_location!= r.url:
r.is_redirect = True
r.redirect_location_override = r_location
return r
In order to make this work, a slight change would be needed:
The redirect url is pulled via this line:
https://github.com/kennethreitz/requests/blob/f72684e13c5074a671506d29c1b5638156680ea7/requests/sessions.py#L116
url = resp.headers['location']
I propose this change to sessions.py
-url = resp.headers['location']
+url = resp.redirect_location
and then extending models.py accordingly
+ redirect_location_override = None
@property
def redirect_location(self):
if self.redirect_location_override is not None:
return self.redirect_location_override
return self.headers['location']
if this is acceptable, I would be happy to issue a PR that includes tests.
| {
"avatar_url": "https://avatars.githubusercontent.com/u/204779?v=4",
"events_url": "https://api.github.com/users/jvanasco/events{/privacy}",
"followers_url": "https://api.github.com/users/jvanasco/followers",
"following_url": "https://api.github.com/users/jvanasco/following{/other_user}",
"gists_url": "https://api.github.com/users/jvanasco/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/jvanasco",
"id": 204779,
"login": "jvanasco",
"node_id": "MDQ6VXNlcjIwNDc3OQ==",
"organizations_url": "https://api.github.com/users/jvanasco/orgs",
"received_events_url": "https://api.github.com/users/jvanasco/received_events",
"repos_url": "https://api.github.com/users/jvanasco/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/jvanasco/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/jvanasco/subscriptions",
"type": "User",
"url": "https://api.github.com/users/jvanasco",
"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/3837/reactions"
} | https://api.github.com/repos/psf/requests/issues/3837/timeline | null | completed | null | null | false | [
"Thanks for the suggestion!\r\n\r\nSo, I think I don't fully understand why this needs to be a Requests patch. What advantages would you or other users get from having this integrated into Requests?",
"I'm not sure how to interpret your question, so I'm going to answer it a few ways:\r\n\r\nAnd I'll refer to this... |
https://api.github.com/repos/psf/requests/issues/3836 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3836/labels{/name} | https://api.github.com/repos/psf/requests/issues/3836/comments | https://api.github.com/repos/psf/requests/issues/3836/events | https://github.com/psf/requests/pull/3836 | 203,736,052 | MDExOlB1bGxSZXF1ZXN0MTAzNTYzNTE0 | 3,836 | pin pipenv until kennethreitz/pipenv#90 is resolved | {
"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 | 2 | 2017-01-27T20:45:28Z | 2021-09-07T00:06:40Z | 2017-01-27T20:55:07Z | MEMBER | resolved | Fixing build for now until we can properly parse all dependencies in pipenv. | {
"avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4",
"events_url": "https://api.github.com/users/Lukasa/events{/privacy}",
"followers_url": "https://api.github.com/users/Lukasa/followers",
"following_url": "https://api.github.com/users/Lukasa/following{/other_user}",
"gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Lukasa",
"id": 1382556,
"login": "Lukasa",
"node_id": "MDQ6VXNlcjEzODI1NTY=",
"organizations_url": "https://api.github.com/users/Lukasa/orgs",
"received_events_url": "https://api.github.com/users/Lukasa/received_events",
"repos_url": "https://api.github.com/users/Lukasa/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Lukasa",
"user_view_type": "public"
} | {
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/3836/reactions"
} | https://api.github.com/repos/psf/requests/issues/3836/timeline | null | null | false | {
"diff_url": "https://github.com/psf/requests/pull/3836.diff",
"html_url": "https://github.com/psf/requests/pull/3836",
"merged_at": "2017-01-27T20:55:07Z",
"patch_url": "https://github.com/psf/requests/pull/3836.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/3836"
} | true | [
"## [Current coverage](https://codecov.io/gh/kennethreitz/requests/pull/3836?src=pr) is 89.09% (diff: 100%)\n> Merging [#3836](https://codecov.io/gh/kennethreitz/requests/pull/3836?src=pr) into [master](https://codecov.io/gh/kennethreitz/requests/branch/master?src=pr) will increase coverage by **0.05%**\n\n```diff\... |
https://api.github.com/repos/psf/requests/issues/3835 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3835/labels{/name} | https://api.github.com/repos/psf/requests/issues/3835/comments | https://api.github.com/repos/psf/requests/issues/3835/events | https://github.com/psf/requests/pull/3835 | 203,489,835 | MDExOlB1bGxSZXF1ZXN0MTAzMzkwMDY3 | 3,835 | Only send HTTPDigestAuth on 4xx challenges | {
"avatar_url": "https://avatars.githubusercontent.com/u/1574365?v=4",
"events_url": "https://api.github.com/users/mmedal/events{/privacy}",
"followers_url": "https://api.github.com/users/mmedal/followers",
"following_url": "https://api.github.com/users/mmedal/following{/other_user}",
"gists_url": "https://api.github.com/users/mmedal/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/mmedal",
"id": 1574365,
"login": "mmedal",
"node_id": "MDQ6VXNlcjE1NzQzNjU=",
"organizations_url": "https://api.github.com/users/mmedal/orgs",
"received_events_url": "https://api.github.com/users/mmedal/received_events",
"repos_url": "https://api.github.com/users/mmedal/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/mmedal/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/mmedal/subscriptions",
"type": "User",
"url": "https://api.github.com/users/mmedal",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 12 | 2017-01-26T21:10:55Z | 2021-09-07T00:06:40Z | 2017-01-29T08:15:36Z | CONTRIBUTOR | resolved | Resolves: #3772 | {
"avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4",
"events_url": "https://api.github.com/users/Lukasa/events{/privacy}",
"followers_url": "https://api.github.com/users/Lukasa/followers",
"following_url": "https://api.github.com/users/Lukasa/following{/other_user}",
"gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Lukasa",
"id": 1382556,
"login": "Lukasa",
"node_id": "MDQ6VXNlcjEzODI1NTY=",
"organizations_url": "https://api.github.com/users/Lukasa/orgs",
"received_events_url": "https://api.github.com/users/Lukasa/received_events",
"repos_url": "https://api.github.com/users/Lukasa/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Lukasa",
"user_view_type": "public"
} | {
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/3835/reactions"
} | https://api.github.com/repos/psf/requests/issues/3835/timeline | null | null | false | {
"diff_url": "https://github.com/psf/requests/pull/3835.diff",
"html_url": "https://github.com/psf/requests/pull/3835",
"merged_at": "2017-01-29T08:15:36Z",
"patch_url": "https://github.com/psf/requests/pull/3835.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/3835"
} | true | [
"@Lukasa I believe there were issues with ONLY doing 401 as noted in #3772. The related RFCs allow for the WWW-Authenticate header in a non-401 response which the client SHOULD respond to if received. I think the conclusion we came to is to support 4XX response codes.",
"I believe @nateprewitt is correct. It seem... |
https://api.github.com/repos/psf/requests/issues/3834 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3834/labels{/name} | https://api.github.com/repos/psf/requests/issues/3834/comments | https://api.github.com/repos/psf/requests/issues/3834/events | https://github.com/psf/requests/issues/3834 | 203,343,953 | MDU6SXNzdWUyMDMzNDM5NTM= | 3,834 | Strict-Transport-Security Header not complet submittet | {
"avatar_url": "https://avatars.githubusercontent.com/u/10137?v=4",
"events_url": "https://api.github.com/users/ghost/events{/privacy}",
"followers_url": "https://api.github.com/users/ghost/followers",
"following_url": "https://api.github.com/users/ghost/following{/other_user}",
"gists_url": "https://api.github.com/users/ghost/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/ghost",
"id": 10137,
"login": "ghost",
"node_id": "MDQ6VXNlcjEwMTM3",
"organizations_url": "https://api.github.com/users/ghost/orgs",
"received_events_url": "https://api.github.com/users/ghost/received_events",
"repos_url": "https://api.github.com/users/ghost/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/ghost/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/ghost/subscriptions",
"type": "User",
"url": "https://api.github.com/users/ghost",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 1 | 2017-01-26T11:01:53Z | 2021-09-08T12:01:08Z | 2017-01-26T11:12:14Z | NONE | resolved | I'm trying to get the strict-transport-security header in python3 with requests.
My code looks like the following:
`import requests
r = requests.get("https://%s" % domain")
print (r.headers)`
My problem is that the strict-transport-security header does not contain all data. The real Header looks like ```max-age=31536010; includeSubDomains; preload```, but the header by r.headers['strict-transport-security'] only contains ```max-age=31536010; includeSubDomains```, not the preload which is needed by my application.
Tested on FreeBSD 11.0 and Mint Rosa and Arch 4.8.13 | 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/3834/reactions"
} | https://api.github.com/repos/psf/requests/issues/3834/timeline | null | completed | null | null | false | [
"Requests does not amend the headers in any way, so you get what we received. Are there any proxies or other intermediaries which may be amending headers?"
] |
https://api.github.com/repos/psf/requests/issues/3833 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3833/labels{/name} | https://api.github.com/repos/psf/requests/issues/3833/comments | https://api.github.com/repos/psf/requests/issues/3833/events | https://github.com/psf/requests/issues/3833 | 203,325,633 | MDU6SXNzdWUyMDMzMjU2MzM= | 3,833 | bad handshake - requests.exceptions.SSLError | {
"avatar_url": "https://avatars.githubusercontent.com/u/4057835?v=4",
"events_url": "https://api.github.com/users/filipposantovito/events{/privacy}",
"followers_url": "https://api.github.com/users/filipposantovito/followers",
"following_url": "https://api.github.com/users/filipposantovito/following{/other_user}",
"gists_url": "https://api.github.com/users/filipposantovito/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/filipposantovito",
"id": 4057835,
"login": "filipposantovito",
"node_id": "MDQ6VXNlcjQwNTc4MzU=",
"organizations_url": "https://api.github.com/users/filipposantovito/orgs",
"received_events_url": "https://api.github.com/users/filipposantovito/received_events",
"repos_url": "https://api.github.com/users/filipposantovito/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/filipposantovito/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/filipposantovito/subscriptions",
"type": "User",
"url": "https://api.github.com/users/filipposantovito",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 10 | 2017-01-26T09:29:29Z | 2021-09-08T12:01:07Z | 2017-01-26T09:40:36Z | NONE | resolved | Hi,
I read and tried what's in other threads without success. This is the error:
```bash
python -c "import requests; requests.get('https://acciseonline.agenziadogane.it')"
```
```python
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "/home/filippo/src/venvs/test_ssl_sito_dogana/local/lib/python2.7/site-packages/requests/api.py", line 70, in get
return request('get', url, params=params, **kwargs)
File "/home/filippo/src/venvs/test_ssl_sito_dogana/local/lib/python2.7/site-packages/requests/api.py", line 56, in request
return session.request(method=method, url=url, **kwargs)
File "/home/filippo/src/venvs/test_ssl_sito_dogana/local/lib/python2.7/site-packages/requests/sessions.py", line 488, in request
resp = self.send(prep, **send_kwargs)
File "/home/filippo/src/venvs/test_ssl_sito_dogana/local/lib/python2.7/site-packages/requests/sessions.py", line 609, in send
r = adapter.send(request, **kwargs)
File "/home/filippo/src/venvs/test_ssl_sito_dogana/local/lib/python2.7/site-packages/requests/adapters.py", line 497, in send
raise SSLError(e, request=request)
requests.exceptions.SSLError: ("bad handshake: Error([('SSL routines', 'SSL23_GET_SERVER_HELLO', 'sslv3 alert handshake failure')],)",)
```
it runs inside a virtualenv
```bash
(test_ssl_sito_dogana) filippo@savage:~/src/venvs/test_ssl_sito_dogana$ which python
/home/filippo/src/venvs/test_ssl_sito_dogana/bin/python
(test_ssl_sito_dogana) filippo@savage:~/src/venvs/test_ssl_sito_dogana$ pip --version
pip 9.0.1 from /home/filippo/src/venvs/test_ssl_sito_dogana/local/lib/python2.7/site-packages (python 2.7)
```
here the pip freeze output
```bash
(test_ssl_sito_dogana) filippo@savage:~/src/venvs/test_ssl_sito_dogana$ pip freeze | sort
appdirs==1.4.0
backports.shutil-get-terminal-size==1.0.0
cffi==1.9.1
configparser==3.5.0
cryptography==1.7.1
decorator==4.0.11
elpy==1.13.0
enum34==1.1.6
flake8==3.2.1
idna==2.2
importmagic==0.1.7
ipaddress==1.0.18
ipdb==0.10.2
ipython==5.1.0
ipython-genutils==0.1.0
jedi==0.9.0
mccabe==0.5.3
ndg-httpsclient==0.4.2
nose==1.3.7
packaging==16.8
pathlib2==2.2.1
pep8==1.7.0
pexpect==4.2.1
pickleshare==0.7.4
pkg-resources==0.0.0
prompt-toolkit==1.0.9
ptyprocess==0.5.1
pyasn1==0.1.9
pycodestyle==2.2.0
pycparser==2.17
pyflakes==1.5.0
Pygments==2.2.0
pyOpenSSL==16.2.0
pyparsing==2.1.10
requests==2.13.0
scandir==1.4
simplegeneric==0.8.1
six==1.10.0
traitlets==4.3.1
wcwidth==0.1.7
```
and here some openssl info:
```bash
(test_ssl_sito_dogana) filippo@savage:~/src/venvs/test_ssl_sito_dogana$ python -c "import ssl; print ssl.OPENSSL_VERSION"
OpenSSL 1.0.2g 1 Mar 2016
```
```bash
(test_ssl_sito_dogana) filippo@savage:~/src/venvs/test_ssl_sito_dogana$ openssl s_client -connect acciseonline.agenziadogane.it:443
CONNECTED(00000003)
depth=3 C = SE, O = AddTrust AB, OU = AddTrust External TTP Network, CN = AddTrust External CA Root
verify return:1
depth=2 C = GB, ST = Greater Manchester, L = Salford, O = COMODO CA Limited, CN = COMODO RSA Certification Authority
verify return:1
depth=1 C = GB, ST = Greater Manchester, L = Salford, O = COMODO CA Limited, CN = COMODO RSA Domain Validation Secure Server CA
verify return:1
depth=0 OU = Domain Control Validated, OU = SSL, CN = acciseonline.agenziadogane.it
verify return:1
---
Certificate chain
0 s:/OU=Domain Control Validated/OU=SSL/CN=acciseonline.agenziadogane.it
i:/C=GB/ST=Greater Manchester/L=Salford/O=COMODO CA Limited/CN=COMODO RSA Domain Validation Secure Server CA
1 s:/C=GB/ST=Greater Manchester/L=Salford/O=COMODO CA Limited/CN=COMODO RSA Domain Validation Secure Server CA
i:/C=GB/ST=Greater Manchester/L=Salford/O=COMODO CA Limited/CN=COMODO RSA Certification Authority
2 s:/C=GB/ST=Greater Manchester/L=Salford/O=COMODO CA Limited/CN=COMODO RSA Certification Authority
i:/C=SE/O=AddTrust AB/OU=AddTrust External TTP Network/CN=AddTrust External CA Root
3 s:/C=SE/O=AddTrust AB/OU=AddTrust External TTP Network/CN=AddTrust External CA Root
i:/C=SE/O=AddTrust AB/OU=AddTrust External TTP Network/CN=AddTrust External CA Root
---
Server certificate
-----BEGIN CERTIFICATE-----
MIIFczCCBFugAwIBAgIQc2nmdmmY4REjS+9DUxt9NjANBgkqhkiG9w0BAQsFADCB
kDELMAkGA1UEBhMCR0IxGzAZBgNVBAgTEkdyZWF0ZXIgTWFuY2hlc3RlcjEQMA4G
[...]
BFDOspLDTFNZ4/WmvfSS/VGZhbqewlpyD+GCYvdiiOrrhxX7cOXkQrBR0ckEypX2
qWl7dMhwlA==
-----END CERTIFICATE-----
subject=/OU=Domain Control Validated/OU=SSL/CN=acciseonline.agenziadogane.it
issuer=/C=GB/ST=Greater Manchester/L=Salford/O=COMODO CA Limited/CN=COMODO RSA Domain Validation Secure Server CA
---
No client certificate CA names sent
---
SSL handshake has read 5585 bytes and written 619 bytes
---
New, TLSv1/SSLv3, Cipher is RC4-SHA
Server public key is 2048 bit
Secure Renegotiation IS supported
Compression: NONE
Expansion: NONE
No ALPN negotiated
SSL-Session:
Protocol : TLSv1
Cipher : RC4-SHA
Session-ID: FE200000E6B4995A513CC8625648B6F13F32666D5858585812C08958DF770000
Session-ID-ctx:
Master-Key: 35260147D2EEB4B465892E426BBD8504190DDC895FFA894DE0079A40C50247AF1080C1FF792D8E255AF2CD6F2A04087E
Key-Arg : None
PSK identity: None
PSK identity hint: None
SRP username: None
Start Time: 1485422610
Timeout : 300 (sec)
Verify return code: 0 (ok)
---
``` | {
"avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4",
"events_url": "https://api.github.com/users/Lukasa/events{/privacy}",
"followers_url": "https://api.github.com/users/Lukasa/followers",
"following_url": "https://api.github.com/users/Lukasa/following{/other_user}",
"gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Lukasa",
"id": 1382556,
"login": "Lukasa",
"node_id": "MDQ6VXNlcjEzODI1NTY=",
"organizations_url": "https://api.github.com/users/Lukasa/orgs",
"received_events_url": "https://api.github.com/users/Lukasa/received_events",
"repos_url": "https://api.github.com/users/Lukasa/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Lukasa",
"user_view_type": "public"
} | {
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/3833/reactions"
} | https://api.github.com/repos/psf/requests/issues/3833/timeline | null | completed | null | null | false | [
"Hi there!\r\n\r\nThis is not the first time this website has been reported to us as a problem. However, I should note for the future that [this website has quite possibly the worst TLS configuration I have ever seen](https://www.ssllabs.com/ssltest/analyze.html?d=acciseonline.agenziadogane.it&hideResults=on).\r\n\... |
https://api.github.com/repos/psf/requests/issues/3832 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3832/labels{/name} | https://api.github.com/repos/psf/requests/issues/3832/comments | https://api.github.com/repos/psf/requests/issues/3832/events | https://github.com/psf/requests/pull/3832 | 203,135,045 | MDExOlB1bGxSZXF1ZXN0MTAzMTQxODAx | 3,832 | fixing codecov with pipenv | {
"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 | 2 | 2017-01-25T15:32:06Z | 2021-09-07T00:06:41Z | 2017-01-25T15:40:30Z | MEMBER | resolved | codecov broke with the introduction of pipenv because the dependency isn't installed outside of the virtualenv. Running it inside of pipenv fixes this. | {
"avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4",
"events_url": "https://api.github.com/users/Lukasa/events{/privacy}",
"followers_url": "https://api.github.com/users/Lukasa/followers",
"following_url": "https://api.github.com/users/Lukasa/following{/other_user}",
"gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Lukasa",
"id": 1382556,
"login": "Lukasa",
"node_id": "MDQ6VXNlcjEzODI1NTY=",
"organizations_url": "https://api.github.com/users/Lukasa/orgs",
"received_events_url": "https://api.github.com/users/Lukasa/received_events",
"repos_url": "https://api.github.com/users/Lukasa/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Lukasa",
"user_view_type": "public"
} | {
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/3832/reactions"
} | https://api.github.com/repos/psf/requests/issues/3832/timeline | null | null | false | {
"diff_url": "https://github.com/psf/requests/pull/3832.diff",
"html_url": "https://github.com/psf/requests/pull/3832",
"merged_at": "2017-01-25T15:40:30Z",
"patch_url": "https://github.com/psf/requests/pull/3832.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/3832"
} | true | [
"## [Current coverage](https://codecov.io/gh/kennethreitz/requests/pull/3832?src=pr) is 89.03% (diff: 100%)\n\n\n> No coverage report found for **master** at b92058b.\n\n> Powered by [Codecov](https://codecov.io?src=pr). Last update [b92058b...795106c](https://codecov.io/gh/kennethreitz/requests/compare/b92058b6fe6... |
https://api.github.com/repos/psf/requests/issues/3831 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3831/labels{/name} | https://api.github.com/repos/psf/requests/issues/3831/comments | https://api.github.com/repos/psf/requests/issues/3831/events | https://github.com/psf/requests/issues/3831 | 203,021,037 | MDU6SXNzdWUyMDMwMjEwMzc= | 3,831 | AttributeError after gevent.monkey.patch_select() | {
"avatar_url": "https://avatars.githubusercontent.com/u/19982?v=4",
"events_url": "https://api.github.com/users/sublee/events{/privacy}",
"followers_url": "https://api.github.com/users/sublee/followers",
"following_url": "https://api.github.com/users/sublee/following{/other_user}",
"gists_url": "https://api.github.com/users/sublee/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/sublee",
"id": 19982,
"login": "sublee",
"node_id": "MDQ6VXNlcjE5OTgy",
"organizations_url": "https://api.github.com/users/sublee/orgs",
"received_events_url": "https://api.github.com/users/sublee/received_events",
"repos_url": "https://api.github.com/users/sublee/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/sublee/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/sublee/subscriptions",
"type": "User",
"url": "https://api.github.com/users/sublee",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 4 | 2017-01-25T06:12:34Z | 2021-09-08T12:01:04Z | 2017-01-25T10:04:41Z | NONE | resolved | Requests-2.13 fails with `AttributeError` because there's no `select.epoll()` when `gevent` monkey-patched `select`.
This issue is actually a bug from urllib3-1.20. It depends on `select.epoll()` and it doesn't handle `AttributeError`. But `gevent.monkey.patch_select()` removes `epoll`, `kqueue`, `kevent`, and `devpoll` to make some modules non-blocking.
```
Traceback (most recent call last):
...
File "/home/sub/env/local/lib/python2.7/site-packages/requests/sessions.py", line 501, in get
return self.request('GET', url, **kwargs)
File "/home/sub/env/local/lib/python2.7/site-packages/requests/sessions.py", line 488, in request
resp = self.send(prep, **send_kwargs)
File "/home/sub/env/local/lib/python2.7/site-packages/requests/sessions.py", line 609, in send
r = adapter.send(request, **kwargs)
File "/home/sub/env/local/lib/python2.7/site-packages/requests/adapters.py", line 423, in send
timeout=timeout
File "/home/sub/env/local/lib/python2.7/site-packages/requests/packages/urllib3/connectionpool.py", line 588, in urlopen
conn = self._get_conn(timeout=pool_timeout)
File "/home/sub/env/local/lib/python2.7/site-packages/requests/packages/urllib3/connectionpool.py", line 241, in _get_conn
if conn and is_connection_dropped(conn):
File "/home/sub/env/local/lib/python2.7/site-packages/requests/packages/urllib3/util/connection.py", line 27, in is_connection_dropped
return bool(wait_for_read(sock, timeout=0.0))
File "/home/sub/env/local/lib/python2.7/site-packages/requests/packages/urllib3/util/wait.py", line 33, in wait_for_read
return _wait_for_io_events(socks, EVENT_READ, timeout)
File "/home/sub/env/local/lib/python2.7/site-packages/requests/packages/urllib3/util/wait.py", line 22, in _wait_for_io_events
with DefaultSelector() as selector:
File "/home/sub/env/local/lib/python2.7/site-packages/requests/packages/urllib3/util/selectors.py", line 364, in __init__
self._epoll = select.epoll()
AttributeError: 'module' object has no attribute 'epoll'
``` | {
"avatar_url": "https://avatars.githubusercontent.com/u/19982?v=4",
"events_url": "https://api.github.com/users/sublee/events{/privacy}",
"followers_url": "https://api.github.com/users/sublee/followers",
"following_url": "https://api.github.com/users/sublee/following{/other_user}",
"gists_url": "https://api.github.com/users/sublee/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/sublee",
"id": 19982,
"login": "sublee",
"node_id": "MDQ6VXNlcjE5OTgy",
"organizations_url": "https://api.github.com/users/sublee/orgs",
"received_events_url": "https://api.github.com/users/sublee/received_events",
"repos_url": "https://api.github.com/users/sublee/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/sublee/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/sublee/subscriptions",
"type": "User",
"url": "https://api.github.com/users/sublee",
"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/3831/reactions"
} | https://api.github.com/repos/psf/requests/issues/3831/timeline | null | completed | null | null | false | [
"When are you patching with gevent? urllib3 should absolutely tolerate not having an epoll implementation. The epoll implementation is only chosen when `hasattr(select, 'epoll')` is `True`. I suspect you are importing requests before you patch with gevent. When working with gevent you *must* monkey patch before you... |
https://api.github.com/repos/psf/requests/issues/3830 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3830/labels{/name} | https://api.github.com/repos/psf/requests/issues/3830/comments | https://api.github.com/repos/psf/requests/issues/3830/events | https://github.com/psf/requests/pull/3830 | 202,968,271 | MDExOlB1bGxSZXF1ZXN0MTAzMDI0MjMz | 3,830 | Fixing Pipfile source | {
"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 | 2 | 2017-01-24T23:13:07Z | 2021-09-07T00:06:41Z | 2017-01-25T01:58:00Z | MEMBER | resolved | This fixes the issue that was encountered this morning during the 2.13.0 release.
The source specified in the original Pipfile was for an incorrect pypi endpoint. This didn't matter until pipenv 2.6 was released, specifically [cb22a12](https://github.com/kennethreitz/pipenv/commit/cb22a129eae8c8e800e603c38bf1fe04d420fbde), which started using the provided `source` value.
@kennethreitz I used `pipenv lock` with pipenv 3.0.0 to generate the new lock file which I'm assuming is what we want here. | {
"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/3830/reactions"
} | https://api.github.com/repos/psf/requests/issues/3830/timeline | null | null | false | {
"diff_url": "https://github.com/psf/requests/pull/3830.diff",
"html_url": "https://github.com/psf/requests/pull/3830",
"merged_at": "2017-01-25T01:58:00Z",
"patch_url": "https://github.com/psf/requests/pull/3830.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/3830"
} | true | [
"While we're here, it looks like this value is still used in pipenv [here](https://github.com/kennethreitz/pipenv/blob/3fa204b734f67522d7858ab47b1d10263a76dc90/pipenv/_pipfile/api.py#L73) , but I'm not sure if that code is actively being used. I can open a quick PR updating it over there too if needed.",
"ah yes,... |
https://api.github.com/repos/psf/requests/issues/3829 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3829/labels{/name} | https://api.github.com/repos/psf/requests/issues/3829/comments | https://api.github.com/repos/psf/requests/issues/3829/events | https://github.com/psf/requests/issues/3829 | 202,820,492 | MDU6SXNzdWUyMDI4MjA0OTI= | 3,829 | Session.verify=False ignored when REQUESTS_CA_BUNDLE environment variable is set | {
"avatar_url": "https://avatars.githubusercontent.com/u/137616?v=4",
"events_url": "https://api.github.com/users/intgr/events{/privacy}",
"followers_url": "https://api.github.com/users/intgr/followers",
"following_url": "https://api.github.com/users/intgr/following{/other_user}",
"gists_url": "https://api.github.com/users/intgr/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/intgr",
"id": 137616,
"login": "intgr",
"node_id": "MDQ6VXNlcjEzNzYxNg==",
"organizations_url": "https://api.github.com/users/intgr/orgs",
"received_events_url": "https://api.github.com/users/intgr/received_events",
"repos_url": "https://api.github.com/users/intgr/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/intgr/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/intgr/subscriptions",
"type": "User",
"url": "https://api.github.com/users/intgr",
"user_view_type": "public"
} | [
{
"color": "e10c02",
"default": false,
"description": null,
"id": 117744,
"name": "Bug",
"node_id": "MDU6TGFiZWwxMTc3NDQ=",
"url": "https://api.github.com/repos/psf/requests/labels/Bug"
},
{
"color": "e102d8",
"default": false,
"description": null,
"id": 117745,
"... | open | true | null | [] | {
"closed_at": null,
"closed_issues": 29,
"created_at": "2013-11-17T11:29:34Z",
"creator": {
"avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4",
"events_url": "https://api.github.com/users/Lukasa/events{/privacy}",
"followers_url": "https://api.github.com/users/Lukasa/followers",
"following_url": "https://api.github.com/users/Lukasa/following{/other_user}",
"gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Lukasa",
"id": 1382556,
"login": "Lukasa",
"node_id": "MDQ6VXNlcjEzODI1NTY=",
"organizations_url": "https://api.github.com/users/Lukasa/orgs",
"received_events_url": "https://api.github.com/users/Lukasa/received_events",
"repos_url": "https://api.github.com/users/Lukasa/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Lukasa",
"user_view_type": "public"
},
"description": null,
"due_on": null,
"html_url": "https://github.com/psf/requests/milestone/20",
"id": 487518,
"labels_url": "https://api.github.com/repos/psf/requests/milestones/20/labels",
"node_id": "MDk6TWlsZXN0b25lNDg3NTE4",
"number": 20,
"open_issues": 12,
"state": "open",
"title": "3.0.0",
"updated_at": "2024-05-19T18:43:00Z",
"url": "https://api.github.com/repos/psf/requests/milestones/20"
} | 14 | 2017-01-24T13:40:18Z | 2024-02-12T14:04:41Z | null | NONE | null | One would expect that when the caller explicitly asks to make unverified requests, then the `REQUESTS_CA_BUNDLE` environment variable doesn't affect it. The reality is different, however.
```python
import os
import requests
os.environ['REQUESTS_CA_BUNDLE'] = 'asd.pem' # Must be an existing file
r = requests.get('https://self-signed.badssl.com/', verify=False)
print(r)
# Prints: <Response [200]>
session = requests.Session()
session.verify = False
r = session.get('https://self-signed.badssl.com/')
print(r)
# Fails: requests.exceptions.SSLError: [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed (_ssl.c:749)
```
| null | {
"+1": 26,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 26,
"url": "https://api.github.com/repos/psf/requests/issues/3829/reactions"
} | https://api.github.com/repos/psf/requests/issues/3829/timeline | null | null | null | null | false | [
"Thanks for raising this issue! This is a related issue to #2018: specifically, we prefer the environment to the `Session` value assuming the environment specifies an auth value. The fix is easy, but we've unfortunately ossified around this value, so we can't fix it until v3.\r\n\r\nGiven that we fail-closed here (... |
https://api.github.com/repos/psf/requests/issues/3828 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3828/labels{/name} | https://api.github.com/repos/psf/requests/issues/3828/comments | https://api.github.com/repos/psf/requests/issues/3828/events | https://github.com/psf/requests/pull/3828 | 202,810,858 | MDExOlB1bGxSZXF1ZXN0MTAyOTEyODI0 | 3,828 | Blacklist known bad version of pipenv | {
"avatar_url": "https://avatars.githubusercontent.com/u/240830?v=4",
"events_url": "https://api.github.com/users/sigmavirus24/events{/privacy}",
"followers_url": "https://api.github.com/users/sigmavirus24/followers",
"following_url": "https://api.github.com/users/sigmavirus24/following{/other_user}",
"gists_url": "https://api.github.com/users/sigmavirus24/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/sigmavirus24",
"id": 240830,
"login": "sigmavirus24",
"node_id": "MDQ6VXNlcjI0MDgzMA==",
"organizations_url": "https://api.github.com/users/sigmavirus24/orgs",
"received_events_url": "https://api.github.com/users/sigmavirus24/received_events",
"repos_url": "https://api.github.com/users/sigmavirus24/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/sigmavirus24/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/sigmavirus24/subscriptions",
"type": "User",
"url": "https://api.github.com/users/sigmavirus24",
"user_view_type": "public"
} | [] | closed | true | {
"avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4",
"events_url": "https://api.github.com/users/Lukasa/events{/privacy}",
"followers_url": "https://api.github.com/users/Lukasa/followers",
"following_url": "https://api.github.com/users/Lukasa/following{/other_user}",
"gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Lukasa",
"id": 1382556,
"login": "Lukasa",
"node_id": "MDQ6VXNlcjEzODI1NTY=",
"organizations_url": "https://api.github.com/users/Lukasa/orgs",
"received_events_url": "https://api.github.com/users/Lukasa/received_events",
"repos_url": "https://api.github.com/users/Lukasa/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Lukasa",
"user_view_type": "public"
} | [
{
"avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4",
"events_url": "https://api.github.com/users/Lukasa/events{/privacy}",
"followers_url": "https://api.github.com/users/Lukasa/followers",
"following_url": "https://api.github.com/users/Lukasa/following{/other_user}",
"gists_url... | null | 3 | 2017-01-24T12:56:38Z | 2021-09-07T00:06:41Z | 2017-01-24T13:13:52Z | CONTRIBUTOR | resolved | We pinned pipenv to release v2.13.0 but in reality, we could have just
blacklisted the known bad version. For future us, we now blacklist it. | {
"avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4",
"events_url": "https://api.github.com/users/Lukasa/events{/privacy}",
"followers_url": "https://api.github.com/users/Lukasa/followers",
"following_url": "https://api.github.com/users/Lukasa/following{/other_user}",
"gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Lukasa",
"id": 1382556,
"login": "Lukasa",
"node_id": "MDQ6VXNlcjEzODI1NTY=",
"organizations_url": "https://api.github.com/users/Lukasa/orgs",
"received_events_url": "https://api.github.com/users/Lukasa/received_events",
"repos_url": "https://api.github.com/users/Lukasa/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Lukasa",
"user_view_type": "public"
} | {
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/3828/reactions"
} | https://api.github.com/repos/psf/requests/issues/3828/timeline | null | null | false | {
"diff_url": "https://github.com/psf/requests/pull/3828.diff",
"html_url": "https://github.com/psf/requests/pull/3828",
"merged_at": "2017-01-24T13:13:52Z",
"patch_url": "https://github.com/psf/requests/pull/3828.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/3828"
} | true | [
"I think it's more than just 2.8.0, I can't get a working build on travis after 2.5.0. It looks like something happened there that's breaking the build, checking it out now.",
"Odd, 0.2.7 worked just fine locally",
"We can blacklist everything between 0.2.5 and 0.2.8 though"
] |
https://api.github.com/repos/psf/requests/issues/3827 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3827/labels{/name} | https://api.github.com/repos/psf/requests/issues/3827/comments | https://api.github.com/repos/psf/requests/issues/3827/events | https://github.com/psf/requests/pull/3827 | 202,806,189 | MDExOlB1bGxSZXF1ZXN0MTAyOTA5NDY1 | 3,827 | Release v2.13.0 | {
"avatar_url": "https://avatars.githubusercontent.com/u/240830?v=4",
"events_url": "https://api.github.com/users/sigmavirus24/events{/privacy}",
"followers_url": "https://api.github.com/users/sigmavirus24/followers",
"following_url": "https://api.github.com/users/sigmavirus24/following{/other_user}",
"gists_url": "https://api.github.com/users/sigmavirus24/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/sigmavirus24",
"id": 240830,
"login": "sigmavirus24",
"node_id": "MDQ6VXNlcjI0MDgzMA==",
"organizations_url": "https://api.github.com/users/sigmavirus24/orgs",
"received_events_url": "https://api.github.com/users/sigmavirus24/received_events",
"repos_url": "https://api.github.com/users/sigmavirus24/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/sigmavirus24/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/sigmavirus24/subscriptions",
"type": "User",
"url": "https://api.github.com/users/sigmavirus24",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 5 | 2017-01-24T12:34:11Z | 2021-09-07T00:06:42Z | 2017-01-24T12:52:23Z | CONTRIBUTOR | resolved | This includes updates to:
- when we load idna
- urllib3 (updated to version 1.20)
- idna (updated to version 2.2)
- release publishing machinery | {
"avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4",
"events_url": "https://api.github.com/users/Lukasa/events{/privacy}",
"followers_url": "https://api.github.com/users/Lukasa/followers",
"following_url": "https://api.github.com/users/Lukasa/following{/other_user}",
"gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Lukasa",
"id": 1382556,
"login": "Lukasa",
"node_id": "MDQ6VXNlcjEzODI1NTY=",
"organizations_url": "https://api.github.com/users/Lukasa/orgs",
"received_events_url": "https://api.github.com/users/Lukasa/received_events",
"repos_url": "https://api.github.com/users/Lukasa/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Lukasa",
"user_view_type": "public"
} | {
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/3827/reactions"
} | https://api.github.com/repos/psf/requests/issues/3827/timeline | null | null | false | {
"diff_url": "https://github.com/psf/requests/pull/3827.diff",
"html_url": "https://github.com/psf/requests/pull/3827",
"merged_at": "2017-01-24T12:52:23Z",
"patch_url": "https://github.com/psf/requests/pull/3827.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/3827"
} | true | [
"It looks like `init` in the Makefile may need `pipenv shell` run to initialize the virtualenv?",
"Maybe? pipenv 0.1.14 worked, 0.2.9 doesn't. The changelog is not immediately forthcoming as to what the specific problem is.",
"For now we'll just pin it so the builds keep working: @kennethreitz should feel free ... |
https://api.github.com/repos/psf/requests/issues/3826 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3826/labels{/name} | https://api.github.com/repos/psf/requests/issues/3826/comments | https://api.github.com/repos/psf/requests/issues/3826/events | https://github.com/psf/requests/issues/3826 | 202,292,208 | MDU6SXNzdWUyMDIyOTIyMDg= | 3,826 | Access to the server certificate | {
"avatar_url": "https://avatars.githubusercontent.com/u/15989628?v=4",
"events_url": "https://api.github.com/users/Te-k/events{/privacy}",
"followers_url": "https://api.github.com/users/Te-k/followers",
"following_url": "https://api.github.com/users/Te-k/following{/other_user}",
"gists_url": "https://api.github.com/users/Te-k/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Te-k",
"id": 15989628,
"login": "Te-k",
"node_id": "MDQ6VXNlcjE1OTg5NjI4",
"organizations_url": "https://api.github.com/users/Te-k/orgs",
"received_events_url": "https://api.github.com/users/Te-k/received_events",
"repos_url": "https://api.github.com/users/Te-k/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Te-k/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Te-k/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Te-k",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 3 | 2017-01-21T04:49:00Z | 2021-09-08T13:05:26Z | 2017-01-21T10:46:42Z | NONE | resolved | Hi,
I checked documentation and the stackoverflow questions (like [this](https://stackoverflow.com/questions/16903528/how-to-get-response-ssl-certificate-from-requests-in-python)) and from what I see, it is not possible to get the server certificate information with requests.
* Is there any hack to get this info?
* Is there any plan to add this info to the answer? If no, consider this as a feature request :+1: | {
"avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4",
"events_url": "https://api.github.com/users/Lukasa/events{/privacy}",
"followers_url": "https://api.github.com/users/Lukasa/followers",
"following_url": "https://api.github.com/users/Lukasa/following{/other_user}",
"gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Lukasa",
"id": 1382556,
"login": "Lukasa",
"node_id": "MDQ6VXNlcjEzODI1NTY=",
"organizations_url": "https://api.github.com/users/Lukasa/orgs",
"received_events_url": "https://api.github.com/users/Lukasa/received_events",
"repos_url": "https://api.github.com/users/Lukasa/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Lukasa",
"user_view_type": "public"
} | {
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/3826/reactions"
} | https://api.github.com/repos/psf/requests/issues/3826/timeline | null | completed | null | null | false | [
"> Is there any hack to get this info?\r\n\r\nYes. If you stream the response (that is, set `stream=True`), then when you get the response back you can go digging for the socket. Depending on the Python version it'll be in slightly different places: on Python 2 it'll be at `response.raw._fp.fp._sock`, on Python 3 i... |
https://api.github.com/repos/psf/requests/issues/3825 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3825/labels{/name} | https://api.github.com/repos/psf/requests/issues/3825/comments | https://api.github.com/repos/psf/requests/issues/3825/events | https://github.com/psf/requests/issues/3825 | 202,131,592 | MDU6SXNzdWUyMDIxMzE1OTI= | 3,825 | urllib3 connection pool block is not properly implemented | {
"avatar_url": "https://avatars.githubusercontent.com/u/6129283?v=4",
"events_url": "https://api.github.com/users/csala/events{/privacy}",
"followers_url": "https://api.github.com/users/csala/followers",
"following_url": "https://api.github.com/users/csala/following{/other_user}",
"gists_url": "https://api.github.com/users/csala/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/csala",
"id": 6129283,
"login": "csala",
"node_id": "MDQ6VXNlcjYxMjkyODM=",
"organizations_url": "https://api.github.com/users/csala/orgs",
"received_events_url": "https://api.github.com/users/csala/received_events",
"repos_url": "https://api.github.com/users/csala/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/csala/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/csala/subscriptions",
"type": "User",
"url": "https://api.github.com/users/csala",
"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"
} | 12 | 2017-01-20T12:42:36Z | 2024-05-20T14:36:40Z | 2024-05-20T14:36:39Z | NONE | null | Current connection pooling in the urllib3 package is not making a proper use of the `block` parameter, and is not using `pool_timeout` for anything.
In the current implementation of the [`_get_conn` method](https://github.com/kennethreitz/requests/blob/362da46e9a46da6e86e1907f03014384ab210151/requests/packages/urllib3/connectionpool.py#L219), if `block` is `False` and the pool raises an `Empty` indicating that there are no connections left because all are being used, a new connection is created anyway an later on discarded.
Instead of this, the connection attempt should be cancelled with an Exception being raised. Or, at least, there should be the option to indicate that this is the expected behaviour. Otherwise, there is no way to make use of the connection pooling to effectively limit the amount of concurrent outgoing connections without getting the additional ones stuck waiting.
Also, pool_timeout is currently getting the default `None` value and there is no way to change it.
It should be possible to define it when the adapter is created, like the rest of the parameters, to indicate how long a connection attempt can be left waiting in the queue. | {
"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/3825/reactions"
} | https://api.github.com/repos/psf/requests/issues/3825/timeline | null | completed | null | null | false | [
"If the suggested changes are discussed and accepted I can implement them.",
"> Instead of this, the connection attempt should be cancelled with an Exception being raised.\r\n> \r\n> Otherwise, connection pooling provides not benefit.\r\n\r\nThat is not true.\r\n\r\nThe connection pooling strategy requests uses i... |
https://api.github.com/repos/psf/requests/issues/3824 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3824/labels{/name} | https://api.github.com/repos/psf/requests/issues/3824/comments | https://api.github.com/repos/psf/requests/issues/3824/events | https://github.com/psf/requests/issues/3824 | 201,630,562 | MDU6SXNzdWUyMDE2MzA1NjI= | 3,824 | With SSL connection: TypeError: data must be a memoryview, buffer or byte string | {
"avatar_url": "https://avatars.githubusercontent.com/u/10797139?v=4",
"events_url": "https://api.github.com/users/Arno0x/events{/privacy}",
"followers_url": "https://api.github.com/users/Arno0x/followers",
"following_url": "https://api.github.com/users/Arno0x/following{/other_user}",
"gists_url": "https://api.github.com/users/Arno0x/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Arno0x",
"id": 10797139,
"login": "Arno0x",
"node_id": "MDQ6VXNlcjEwNzk3MTM5",
"organizations_url": "https://api.github.com/users/Arno0x/orgs",
"received_events_url": "https://api.github.com/users/Arno0x/received_events",
"repos_url": "https://api.github.com/users/Arno0x/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Arno0x/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Arno0x/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Arno0x",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 7 | 2017-01-18T16:53:53Z | 2021-09-08T13:05:26Z | 2017-01-19T09:34:40Z | NONE | resolved | Hi,
I'm having an exception with my program, probably because of an update in one of the python libs recently, but I don't know how to figure this out.
OS: Linux kali 4.6.0-kali1-amd64 #1 SMP Debian 4.6.4-1kali1 (2016-07-21) x86_64 GNU/Linux
Python: 2.7.13
Requests version:
```
# pip show requests
Name: requests
Version: 2.12.4
Summary: Python HTTP for Humans.
Home-page: http://python-requests.org
Author: Kenneth Reitz
Author-email: me@kennethreitz.com
License: Apache 2.0
Location: /usr/local/lib/python2.7/dist-packages
Requires:
```
Traceback:
```
[...]
File "/root/Tools/DBC2/lib/dropboxHandler.py", line 32, in sendRequest
r = requests.post(url,headers=headers,data=data)
File "/usr/local/lib/python2.7/dist-packages/requests/api.py", line 110, in post
return request('post', url, data=data, json=json, **kwargs)
File "/usr/local/lib/python2.7/dist-packages/requests/api.py", line 56, in request
return session.request(method=method, url=url, **kwargs)
File "/usr/local/lib/python2.7/dist-packages/requests/sessions.py", line 488, in request
resp = self.send(prep, **send_kwargs)
File "/usr/local/lib/python2.7/dist-packages/requests/sessions.py", line 609, in send
r = adapter.send(request, **kwargs)
File "/usr/local/lib/python2.7/dist-packages/requests/adapters.py", line 423, in send
timeout=timeout
File "/usr/local/lib/python2.7/dist-packages/requests/packages/urllib3/connectionpool.py", line 594, in urlopen
chunked=chunked)
File "/usr/local/lib/python2.7/dist-packages/requests/packages/urllib3/connectionpool.py", line 361, in _make_request
conn.request(method, url, **httplib_request_kw)
File "/usr/lib/python2.7/httplib.py", line 1042, in request
self._send_request(method, url, body, headers)
File "/usr/lib/python2.7/httplib.py", line 1082, in _send_request
self.endheaders(body)
File "/usr/lib/python2.7/httplib.py", line 1038, in endheaders
self._send_output(message_body)
File "/usr/lib/python2.7/httplib.py", line 886, in _send_output
self.send(message_body)
File "/usr/lib/python2.7/httplib.py", line 858, in send
self.sock.sendall(data)
File "/usr/local/lib/python2.7/dist-packages/requests/packages/urllib3/contrib/pyopenssl.py", line 292, in sendall
sent = self._send_until_done(data[total_sent:total_sent + SSL_WRITE_BLOCKSIZE])
File "/usr/local/lib/python2.7/dist-packages/requests/packages/urllib3/contrib/pyopenssl.py", line 281, in _send_until_done
return self.connection.send(data)
File "/usr/lib/python2.7/dist-packages/OpenSSL/SSL.py", line 1251, in send
raise TypeError("data must be a memoryview, buffer or byte string")
TypeError: data must be a memoryview, buffer or byte string
```
Other info: The same exact version of my program (pulled from my git repo) works on MacOSX and on Alpine Linux (Docker image).
Any idea what the issue is ?
Thanks,
Arno
The exact | {
"avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4",
"events_url": "https://api.github.com/users/Lukasa/events{/privacy}",
"followers_url": "https://api.github.com/users/Lukasa/followers",
"following_url": "https://api.github.com/users/Lukasa/following{/other_user}",
"gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Lukasa",
"id": 1382556,
"login": "Lukasa",
"node_id": "MDQ6VXNlcjEzODI1NTY=",
"organizations_url": "https://api.github.com/users/Lukasa/orgs",
"received_events_url": "https://api.github.com/users/Lukasa/received_events",
"repos_url": "https://api.github.com/users/Lukasa/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Lukasa",
"user_view_type": "public"
} | {
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/3824/reactions"
} | https://api.github.com/repos/psf/requests/issues/3824/timeline | null | completed | null | null | false | [
"Yes, almost certainly you're sending a unicode string in your `data` keyword argument. You only see it on some platforms because most of the time it can be tolerated. What is your `data` keyword argument?",
"What the app is sending as a `data`argument is always a byte array of AES256 encrypted data, so not real... |
https://api.github.com/repos/psf/requests/issues/3823 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3823/labels{/name} | https://api.github.com/repos/psf/requests/issues/3823/comments | https://api.github.com/repos/psf/requests/issues/3823/events | https://github.com/psf/requests/pull/3823 | 201,560,087 | MDExOlB1bGxSZXF1ZXN0MTAyMDU1MjM5 | 3,823 | Prepare changelog for 2.12.5 | {
"avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4",
"events_url": "https://api.github.com/users/Lukasa/events{/privacy}",
"followers_url": "https://api.github.com/users/Lukasa/followers",
"following_url": "https://api.github.com/users/Lukasa/following{/other_user}",
"gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Lukasa",
"id": 1382556,
"login": "Lukasa",
"node_id": "MDQ6VXNlcjEzODI1NTY=",
"organizations_url": "https://api.github.com/users/Lukasa/orgs",
"received_events_url": "https://api.github.com/users/Lukasa/received_events",
"repos_url": "https://api.github.com/users/Lukasa/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Lukasa",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 1 | 2017-01-18T12:23:34Z | 2021-09-07T00:06:43Z | 2017-01-18T12:41:05Z | MEMBER | resolved | Getting ready to ship the last patch release in the somewhat accursed 2.12 release series. | {
"avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4",
"events_url": "https://api.github.com/users/Lukasa/events{/privacy}",
"followers_url": "https://api.github.com/users/Lukasa/followers",
"following_url": "https://api.github.com/users/Lukasa/following{/other_user}",
"gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Lukasa",
"id": 1382556,
"login": "Lukasa",
"node_id": "MDQ6VXNlcjEzODI1NTY=",
"organizations_url": "https://api.github.com/users/Lukasa/orgs",
"received_events_url": "https://api.github.com/users/Lukasa/received_events",
"repos_url": "https://api.github.com/users/Lukasa/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Lukasa",
"user_view_type": "public"
} | {
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/3823/reactions"
} | https://api.github.com/repos/psf/requests/issues/3823/timeline | null | null | false | {
"diff_url": "https://github.com/psf/requests/pull/3823.diff",
"html_url": "https://github.com/psf/requests/pull/3823",
"merged_at": "2017-01-18T12:41:05Z",
"patch_url": "https://github.com/psf/requests/pull/3823.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/3823"
} | true | [
"## [Current coverage](https://codecov.io/gh/kennethreitz/requests/pull/3823?src=pr) is 89.12% (diff: 100%)\n> Merging [#3823](https://codecov.io/gh/kennethreitz/requests/pull/3823?src=pr) into [master](https://codecov.io/gh/kennethreitz/requests/branch/master?src=pr) will decrease coverage by **0.05%**\n\n```diff\... |
https://api.github.com/repos/psf/requests/issues/3822 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3822/labels{/name} | https://api.github.com/repos/psf/requests/issues/3822/comments | https://api.github.com/repos/psf/requests/issues/3822/events | https://github.com/psf/requests/issues/3822 | 200,831,349 | MDU6SXNzdWUyMDA4MzEzNDk= | 3,822 | "import requests" breaks OpenSSL when used in mod_python | {
"avatar_url": "https://avatars.githubusercontent.com/u/2719629?v=4",
"events_url": "https://api.github.com/users/LarsMichelsen/events{/privacy}",
"followers_url": "https://api.github.com/users/LarsMichelsen/followers",
"following_url": "https://api.github.com/users/LarsMichelsen/following{/other_user}",
"gists_url": "https://api.github.com/users/LarsMichelsen/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/LarsMichelsen",
"id": 2719629,
"login": "LarsMichelsen",
"node_id": "MDQ6VXNlcjI3MTk2Mjk=",
"organizations_url": "https://api.github.com/users/LarsMichelsen/orgs",
"received_events_url": "https://api.github.com/users/LarsMichelsen/received_events",
"repos_url": "https://api.github.com/users/LarsMichelsen/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/LarsMichelsen/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/LarsMichelsen/subscriptions",
"type": "User",
"url": "https://api.github.com/users/LarsMichelsen",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 1 | 2017-01-14T21:35:55Z | 2021-09-08T13:05:27Z | 2017-01-14T21:47:01Z | NONE | resolved | When creating a mod_python (Python 2.7, mod_python 3.3.1) page handler that just imports the requests module (version 2.12.3), it breaks pyOpenSSL (pyOpenSSL-16.2.0, cryptography-1.5.3, idna-2.1 in my case). For example creating certificates like this is not working anymore:
```
from OpenSSL import crypto
pkey = crypto.PKey()
pkey.generate_key(crypto.TYPE_RSA, 2048)
```
An exception like this is raised: Error ([('rsa routines', 'RSA_BUILTIN_KEYGEN', 'BN lib')])
```
File "key_mgmt.py", line 224, in _generate_key
pkey.generate_key(crypto.TYPE_RSA, 2048)
File "lib/python/pyOpenSSL-16.2.0-py2.7.egg/OpenSSL/crypto.py", line 258, in generate_key
_openssl_assert(result == 1)
File "lib/python/pyOpenSSL-16.2.0-py2.7.egg/OpenSSL/_util.py", line 61, in openssl_assert
exception_from_error_queue(error)
File "lib/python/pyOpenSSL-16.2.0-py2.7.egg/OpenSSL/_util.py", line 48, in exception_from_error_queue
raise exception_type(errors)
```
When removing this from requests __init__.py, it works again:
```
try:
from .packages.urllib3.contrib import pyopenssl as pyopenssl
pyopenssl.inject_into_urllib3()
except ImportError:
pass
```
I tried to remove only the `pyopenssl.inject_into_urllib3()` call, but that did not solve the issue. I had to remove the import which then fixed the issue. So it seems that it is somehow related to that module directly or some dependency.
The same code works when running as dedicated python script. Maybe it's related to the mod_python importer or something.
Any ideas? | {
"avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4",
"events_url": "https://api.github.com/users/Lukasa/events{/privacy}",
"followers_url": "https://api.github.com/users/Lukasa/followers",
"following_url": "https://api.github.com/users/Lukasa/following{/other_user}",
"gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Lukasa",
"id": 1382556,
"login": "Lukasa",
"node_id": "MDQ6VXNlcjEzODI1NTY=",
"organizations_url": "https://api.github.com/users/Lukasa/orgs",
"received_events_url": "https://api.github.com/users/Lukasa/received_events",
"repos_url": "https://api.github.com/users/Lukasa/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Lukasa",
"user_view_type": "public"
} | {
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/3822/reactions"
} | https://api.github.com/repos/psf/requests/issues/3822/timeline | null | completed | null | null | false | [
"This is definitely related to mod_python. The cryptography library which PyOpenSSL uses has had problems with mod_python in the past due to mod_python's unusual method of running Python. I suggest you open this issue on the pyca/cryptography repository: they should be best placed to fix this issue."
] |
https://api.github.com/repos/psf/requests/issues/3821 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3821/labels{/name} | https://api.github.com/repos/psf/requests/issues/3821/comments | https://api.github.com/repos/psf/requests/issues/3821/events | https://github.com/psf/requests/issues/3821 | 200,796,456 | MDU6SXNzdWUyMDA3OTY0NTY= | 3,821 | problem with the proxy | {
"avatar_url": "https://avatars.githubusercontent.com/u/8215563?v=4",
"events_url": "https://api.github.com/users/feng-1985/events{/privacy}",
"followers_url": "https://api.github.com/users/feng-1985/followers",
"following_url": "https://api.github.com/users/feng-1985/following{/other_user}",
"gists_url": "https://api.github.com/users/feng-1985/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/feng-1985",
"id": 8215563,
"login": "feng-1985",
"node_id": "MDQ6VXNlcjgyMTU1NjM=",
"organizations_url": "https://api.github.com/users/feng-1985/orgs",
"received_events_url": "https://api.github.com/users/feng-1985/received_events",
"repos_url": "https://api.github.com/users/feng-1985/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/feng-1985/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/feng-1985/subscriptions",
"type": "User",
"url": "https://api.github.com/users/feng-1985",
"user_view_type": "public"
} | [
{
"color": "777777",
"default": false,
"description": null,
"id": 162780722,
"name": "Question/Not a bug",
"node_id": "MDU6TGFiZWwxNjI3ODA3MjI=",
"url": "https://api.github.com/repos/psf/requests/labels/Question/Not%20a%20bug"
}
] | closed | true | null | [] | null | 7 | 2017-01-14T10:54:58Z | 2021-09-08T12:01:10Z | 2017-01-23T16:01:58Z | NONE | resolved | python3 code:
session = requests.session()
r = session.get(url="http://www.google.com",headers=headers,timeout=30,proxies=proxies)
the headers={"User-Agent": random.choice(USER_AGENTS)}
the proxies is like this:
{'http': 'http://117.68.236.155:808', 'https': 'http://117.68.236.155:808'}
I got the following Error Message:
requests.exceptions.ProxyError: HTTPConnectionPool(host='117.68.236.155', port=808): Max retries exceeded with url: http://www.google.com/ (Caused by ProxyError('Cannot connect to proxy.', NewConnectionError('<requests.packages.urllib3.connection.HTTPConnection object at 0x0000007C82F8EBE0>: Failed to establish a new connection: [WinError 10060] 由于连接方在一段时间后没有正确答复或连接的主机没有反应,连接尝试失败。',)))
Requests verison 2.12.4, Python3
I have test the following code, but the return is none:
import requests
print(requests.utils.get_environ_proxies('http://www.google.com'))
Is there any solution? I looking forward to your reply! | {
"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/3821/reactions"
} | https://api.github.com/repos/psf/requests/issues/3821/timeline | null | completed | null | null | false | [
"import requests\r\nsession = requests.session()\r\nr = session.get(url=\"http://www.google.com\")\r\ncookie = session.cookies.get_dict()\r\nprint(cookie)\r\n\r\nget the following error:\r\nrequests.exceptions.ConnectionError: ('Connection aborted.', ConnectionResetError(10054, '远程主机强迫关闭了一个现有的连接。', None, 10054, Non... |
https://api.github.com/repos/psf/requests/issues/3820 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3820/labels{/name} | https://api.github.com/repos/psf/requests/issues/3820/comments | https://api.github.com/repos/psf/requests/issues/3820/events | https://github.com/psf/requests/issues/3820 | 200,791,420 | MDU6SXNzdWUyMDA3OTE0MjA= | 3,820 | requests and urllib2 get different headers when connecting to the same host | {
"avatar_url": "https://avatars.githubusercontent.com/u/440101?v=4",
"events_url": "https://api.github.com/users/dofine/events{/privacy}",
"followers_url": "https://api.github.com/users/dofine/followers",
"following_url": "https://api.github.com/users/dofine/following{/other_user}",
"gists_url": "https://api.github.com/users/dofine/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/dofine",
"id": 440101,
"login": "dofine",
"node_id": "MDQ6VXNlcjQ0MDEwMQ==",
"organizations_url": "https://api.github.com/users/dofine/orgs",
"received_events_url": "https://api.github.com/users/dofine/received_events",
"repos_url": "https://api.github.com/users/dofine/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/dofine/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/dofine/subscriptions",
"type": "User",
"url": "https://api.github.com/users/dofine",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 3 | 2017-01-14T08:54:29Z | 2021-09-08T07:00:34Z | 2017-01-14T09:51:01Z | NONE | resolved | Requests version: 2.11.1
Python: 2.7.12
We've got a server providing .txt files, basically some log files growing over time. When I use `urllib2` to send `GET` to the server `r = urllib2.urlopen('http://example.com')` , the headers of the response would be:
```
Date: XXX
Server: Apache
Last-Modified: XXX
Accept-Ranges: bytes
Content-Length: 12345678
Vary: Accept-Encoding
Connection: close
Content-Type: text/plain
```
While if `r = requests.get('http://example.com')`:
```
Content-Encoding: gzip
Accept-Ranges: bytes
Vary: Accept-Encoding
Keep-alive: timeout=5, max=128
Last-Modified: XXX
Connection: Keep-Alive
ETag: xxxxxxxxx
Content-Type: text/plain
```
The second response is the same with what I get using chrome develop tools. So why the two are different? I need the `Content-Length` header to determine how many bytes I need to download every time, becasue the file could grow really big.
Using `httpbin.org/get` to test:
urllib2 response:
```
{u'args': {},
u'headers': {u'Accept-Encoding': u'identity',
u'Host': u'httpbin.org',
u'User-Agent': u'Python-urllib/2.7'},
u'origin': u'ip',
u'url': u'http://httpbin.org/get'}
```
response headers:
```
Server: nginx
Date: Sat, 14 Jan 2017 07:41:16 GMT
Content-Type: application/json
Content-Length: 207
Connection: close
Access-Control-Allow-Origin: *
Access-Control-Allow-Credentials: true
```
requests response:
```
{u'args': {},
u'headers': {u'Accept': u'*/*',
u'Accept-Encoding': u'gzip, deflate',
u'Host': u'httpbin.org',
u'User-Agent': u'python-requests/2.11.1'},
u'origin': u'ip',
u'url': u'http://httpbin.org/get'}
```
response headers:
```
Server : nginx
Date : Sat, 14 Jan 2017 07:42:39 GMT
Content-Type : application/json
Content-Length : 239
Connection : keep-alive
Access-Control-Allow-Origin : *
Access-Control-Allow-Credentials : true
``` | {
"avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4",
"events_url": "https://api.github.com/users/Lukasa/events{/privacy}",
"followers_url": "https://api.github.com/users/Lukasa/followers",
"following_url": "https://api.github.com/users/Lukasa/following{/other_user}",
"gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Lukasa",
"id": 1382556,
"login": "Lukasa",
"node_id": "MDQ6VXNlcjEzODI1NTY=",
"organizations_url": "https://api.github.com/users/Lukasa/orgs",
"received_events_url": "https://api.github.com/users/Lukasa/received_events",
"repos_url": "https://api.github.com/users/Lukasa/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Lukasa",
"user_view_type": "public"
} | {
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/3820/reactions"
} | https://api.github.com/repos/psf/requests/issues/3820/timeline | null | completed | null | null | false | [
"This is the code:\r\n\r\n```\r\nimport urllib2 \r\nimport requests \r\n\r\nurl = 'exmaple.com' \r\nheaders = { \r\n\"Authorization\": \"Basic xxxx\", \r\n\"Range\": \"bytes=0-\" \r\n} \r\nreq = urllib2.Request(url, headers=headers) \r\nresp = urllib2.urlopen(req) \r\nprint resp.info() \r\n\r\nr = requests.get(url,... |
https://api.github.com/repos/psf/requests/issues/3819 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3819/labels{/name} | https://api.github.com/repos/psf/requests/issues/3819/comments | https://api.github.com/repos/psf/requests/issues/3819/events | https://github.com/psf/requests/pull/3819 | 200,779,099 | MDExOlB1bGxSZXF1ZXN0MTAxNTQ5NTQw | 3,819 | Fix #3818. avoid doing an import inside a method | {
"avatar_url": "https://avatars.githubusercontent.com/u/568181?v=4",
"events_url": "https://api.github.com/users/llazzaro/events{/privacy}",
"followers_url": "https://api.github.com/users/llazzaro/followers",
"following_url": "https://api.github.com/users/llazzaro/following{/other_user}",
"gists_url": "https://api.github.com/users/llazzaro/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/llazzaro",
"id": 568181,
"login": "llazzaro",
"node_id": "MDQ6VXNlcjU2ODE4MQ==",
"organizations_url": "https://api.github.com/users/llazzaro/orgs",
"received_events_url": "https://api.github.com/users/llazzaro/received_events",
"repos_url": "https://api.github.com/users/llazzaro/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/llazzaro/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/llazzaro/subscriptions",
"type": "User",
"url": "https://api.github.com/users/llazzaro",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 2 | 2017-01-14T04:13:04Z | 2021-09-08T01:21:25Z | 2017-01-14T10:01:54Z | NONE | resolved | {
"avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4",
"events_url": "https://api.github.com/users/Lukasa/events{/privacy}",
"followers_url": "https://api.github.com/users/Lukasa/followers",
"following_url": "https://api.github.com/users/Lukasa/following{/other_user}",
"gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Lukasa",
"id": 1382556,
"login": "Lukasa",
"node_id": "MDQ6VXNlcjEzODI1NTY=",
"organizations_url": "https://api.github.com/users/Lukasa/orgs",
"received_events_url": "https://api.github.com/users/Lukasa/received_events",
"repos_url": "https://api.github.com/users/Lukasa/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Lukasa",
"user_view_type": "public"
} | {
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/3819/reactions"
} | https://api.github.com/repos/psf/requests/issues/3819/timeline | null | null | false | {
"diff_url": "https://github.com/psf/requests/pull/3819.diff",
"html_url": "https://github.com/psf/requests/pull/3819",
"merged_at": null,
"patch_url": "https://github.com/psf/requests/pull/3819.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/3819"
} | true | [
"Thanks for this!\r\n\r\nThe idna module is vendored without changes from [here](https://github.com/kjd/idna). We do not carry patches to vendored modules in our own source tree. Please propose this pull request upstream, and we will pull in the changes when a new release is cut.",
"@Lukasa thanks for the commet!... | |
https://api.github.com/repos/psf/requests/issues/3818 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3818/labels{/name} | https://api.github.com/repos/psf/requests/issues/3818/comments | https://api.github.com/repos/psf/requests/issues/3818/events | https://github.com/psf/requests/issues/3818 | 200,778,661 | MDU6SXNzdWUyMDA3Nzg2NjE= | 3,818 | Import error with idna version | {
"avatar_url": "https://avatars.githubusercontent.com/u/568181?v=4",
"events_url": "https://api.github.com/users/llazzaro/events{/privacy}",
"followers_url": "https://api.github.com/users/llazzaro/followers",
"following_url": "https://api.github.com/users/llazzaro/following{/other_user}",
"gists_url": "https://api.github.com/users/llazzaro/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/llazzaro",
"id": 568181,
"login": "llazzaro",
"node_id": "MDQ6VXNlcjU2ODE4MQ==",
"organizations_url": "https://api.github.com/users/llazzaro/orgs",
"received_events_url": "https://api.github.com/users/llazzaro/received_events",
"repos_url": "https://api.github.com/users/llazzaro/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/llazzaro/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/llazzaro/subscriptions",
"type": "User",
"url": "https://api.github.com/users/llazzaro",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 1 | 2017-01-14T04:03:47Z | 2021-09-08T13:05:28Z | 2017-01-14T10:02:06Z | NONE | resolved | Hello,
I recently upgraded to 2.12 and I started to see this import error:
> (Pdb) request('get', url, params=params, **kwargs)
> *** ImportError: No module named uts46data
Looking in the changes I saw that it was recently added idna.
My projects are using import hooks and inside of it the hook use requests.
The code of idna is doing an import inside the method uts46_remap, which is breaking my code.
Moving the import uts46_remap outside fixes this issue.
| {
"avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4",
"events_url": "https://api.github.com/users/Lukasa/events{/privacy}",
"followers_url": "https://api.github.com/users/Lukasa/followers",
"following_url": "https://api.github.com/users/Lukasa/following{/other_user}",
"gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Lukasa",
"id": 1382556,
"login": "Lukasa",
"node_id": "MDQ6VXNlcjEzODI1NTY=",
"organizations_url": "https://api.github.com/users/Lukasa/orgs",
"received_events_url": "https://api.github.com/users/Lukasa/received_events",
"repos_url": "https://api.github.com/users/Lukasa/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Lukasa",
"user_view_type": "public"
} | {
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/3818/reactions"
} | https://api.github.com/repos/psf/requests/issues/3818/timeline | null | completed | null | null | false | [
"Closed for reasons discussed in #3819."
] |
https://api.github.com/repos/psf/requests/issues/3817 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3817/labels{/name} | https://api.github.com/repos/psf/requests/issues/3817/comments | https://api.github.com/repos/psf/requests/issues/3817/events | https://github.com/psf/requests/pull/3817 | 200,727,873 | MDExOlB1bGxSZXF1ZXN0MTAxNTE1MTM2 | 3,817 | Only load .packages.urllib3.contrib.pyopenssl if we have an old version of OpenSSL. | {
"avatar_url": "https://avatars.githubusercontent.com/u/22371?v=4",
"events_url": "https://api.github.com/users/dsully/events{/privacy}",
"followers_url": "https://api.github.com/users/dsully/followers",
"following_url": "https://api.github.com/users/dsully/following{/other_user}",
"gists_url": "https://api.github.com/users/dsully/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/dsully",
"id": 22371,
"login": "dsully",
"node_id": "MDQ6VXNlcjIyMzcx",
"organizations_url": "https://api.github.com/users/dsully/orgs",
"received_events_url": "https://api.github.com/users/dsully/received_events",
"repos_url": "https://api.github.com/users/dsully/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/dsully/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/dsully/subscriptions",
"type": "User",
"url": "https://api.github.com/users/dsully",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 11 | 2017-01-13T20:51:40Z | 2021-09-08T01:21:24Z | 2017-01-16T20:30:14Z | NONE | resolved | See issue #3213 | {
"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/3817/reactions"
} | https://api.github.com/repos/psf/requests/issues/3817/timeline | null | null | false | {
"diff_url": "https://github.com/psf/requests/pull/3817.diff",
"html_url": "https://github.com/psf/requests/pull/3817",
"merged_at": null,
"patch_url": "https://github.com/psf/requests/pull/3817.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/3817"
} | true | [
"Ok, @alex and @reaperhulk really need to sign off on this before I consider merging it. ;)",
"Ok, all commenters, *please* read some of the discussion on #3213 before making further comments here. You'll find it helps you avoid retreading some ground. ;)\r\n\r\n@reaperhulk, my main concern here is that we are fu... |
https://api.github.com/repos/psf/requests/issues/3816 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3816/labels{/name} | https://api.github.com/repos/psf/requests/issues/3816/comments | https://api.github.com/repos/psf/requests/issues/3816/events | https://github.com/psf/requests/issues/3816 | 200,630,475 | MDU6SXNzdWUyMDA2MzA0NzU= | 3,816 | Proxy and SSL : the CONNECT request fails on some proxy (cntlm) as the request is HTTP 1.0 instead of 1.1 | {
"avatar_url": "https://avatars.githubusercontent.com/u/504748?v=4",
"events_url": "https://api.github.com/users/LaurentChardin/events{/privacy}",
"followers_url": "https://api.github.com/users/LaurentChardin/followers",
"following_url": "https://api.github.com/users/LaurentChardin/following{/other_user}",
"gists_url": "https://api.github.com/users/LaurentChardin/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/LaurentChardin",
"id": 504748,
"login": "LaurentChardin",
"node_id": "MDQ6VXNlcjUwNDc0OA==",
"organizations_url": "https://api.github.com/users/LaurentChardin/orgs",
"received_events_url": "https://api.github.com/users/LaurentChardin/received_events",
"repos_url": "https://api.github.com/users/LaurentChardin/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/LaurentChardin/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/LaurentChardin/subscriptions",
"type": "User",
"url": "https://api.github.com/users/LaurentChardin",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 2 | 2017-01-13T13:29:13Z | 2021-09-08T13:05:27Z | 2017-01-13T13:34:08Z | NONE | resolved | It looks like requests (or urllib3 ?) is creating a CONNECT request that fails with some proxies when trying to initiate the SSL tunnel:
INFO:requests.packages.urllib3.connectionpool:Starting new HTTPS connection (1): api.hipchat.com
send: 'CONNECT api.hipchat.com:443 HTTP/1.0\r\n'
send: '\r\n'
as we can, it generates an HTTP/1.0 header which seems to be inaccurate. I could not find any definition of the CONNECT command in the HTTP/1.0 RFC, and seems to have been really defined in HTTP 1.1 RFC.
By manually telneting to my cntlm, i could make the CONNECT work by replacing 1.0 by 1.1.
This makes the requests library fail to work on my side where i have to use CNTLM because our usual proxy is using Kerberos/CNTLM for authentication.
Is there any way to have this reviewed ?
best, | {
"avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4",
"events_url": "https://api.github.com/users/Lukasa/events{/privacy}",
"followers_url": "https://api.github.com/users/Lukasa/followers",
"following_url": "https://api.github.com/users/Lukasa/following{/other_user}",
"gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Lukasa",
"id": 1382556,
"login": "Lukasa",
"node_id": "MDQ6VXNlcjEzODI1NTY=",
"organizations_url": "https://api.github.com/users/Lukasa/orgs",
"received_events_url": "https://api.github.com/users/Lukasa/received_events",
"repos_url": "https://api.github.com/users/Lukasa/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Lukasa",
"user_view_type": "public"
} | {
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/3816/reactions"
} | https://api.github.com/repos/psf/requests/issues/3816/timeline | null | completed | null | null | false | [
"Unfortunately, this is not something we can easily change in urllib3 at the moment, because this CONNECT is actually created by httplib. Simply changing to HTTP/1.1 is not sufficient because that CONNECT request is then not HTTP/1.1 compliant (it has no `Host` header field). We'd need to change both.\r\n\r\nUltima... |
https://api.github.com/repos/psf/requests/issues/3815 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3815/labels{/name} | https://api.github.com/repos/psf/requests/issues/3815/comments | https://api.github.com/repos/psf/requests/issues/3815/events | https://github.com/psf/requests/issues/3815 | 200,610,645 | MDU6SXNzdWUyMDA2MTA2NDU= | 3,815 | Add validation of HTTP URL | {
"avatar_url": "https://avatars.githubusercontent.com/u/4943600?v=4",
"events_url": "https://api.github.com/users/Th30n/events{/privacy}",
"followers_url": "https://api.github.com/users/Th30n/followers",
"following_url": "https://api.github.com/users/Th30n/following{/other_user}",
"gists_url": "https://api.github.com/users/Th30n/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Th30n",
"id": 4943600,
"login": "Th30n",
"node_id": "MDQ6VXNlcjQ5NDM2MDA=",
"organizations_url": "https://api.github.com/users/Th30n/orgs",
"received_events_url": "https://api.github.com/users/Th30n/received_events",
"repos_url": "https://api.github.com/users/Th30n/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Th30n/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Th30n/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Th30n",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 3 | 2017-01-13T11:40:37Z | 2021-09-08T13:05:29Z | 2017-01-13T11:41:55Z | NONE | resolved | I'd like to verify that a URL will be valid for a HTTP request. The main motivation is telling the user in the GUI that the typed URL cannot be used.
Currently, I'm using `requests.models.parse_url`, but this is obviously not enough because `PreparedRequest.prepare_url` performs additional checks (e.g. `host.encode('idna')`). It would be great if the same checks were exposed as a public API. | {
"avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4",
"events_url": "https://api.github.com/users/Lukasa/events{/privacy}",
"followers_url": "https://api.github.com/users/Lukasa/followers",
"following_url": "https://api.github.com/users/Lukasa/following{/other_user}",
"gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Lukasa",
"id": 1382556,
"login": "Lukasa",
"node_id": "MDQ6VXNlcjEzODI1NTY=",
"organizations_url": "https://api.github.com/users/Lukasa/orgs",
"received_events_url": "https://api.github.com/users/Lukasa/received_events",
"repos_url": "https://api.github.com/users/Lukasa/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Lukasa",
"user_view_type": "public"
} | {
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/3815/reactions"
} | https://api.github.com/repos/psf/requests/issues/3815/timeline | null | completed | null | null | false | [
"The simplest thing to do is to use the [PreparedRequest flow](http://docs.python-requests.org/en/master/user/advanced/#prepared-requests): specifically the second example, which goes via a Session.\r\n\r\nYou can catch exceptions raised in this process and use those to determine the validity of the URL.",
"You c... |
https://api.github.com/repos/psf/requests/issues/3814 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3814/labels{/name} | https://api.github.com/repos/psf/requests/issues/3814/comments | https://api.github.com/repos/psf/requests/issues/3814/events | https://github.com/psf/requests/pull/3814 | 200,557,373 | MDExOlB1bGxSZXF1ZXN0MTAxMzk1NzMy | 3,814 | Add ability to load ca bundle from data | {
"avatar_url": "https://avatars.githubusercontent.com/u/88809?v=4",
"events_url": "https://api.github.com/users/Kentzo/events{/privacy}",
"followers_url": "https://api.github.com/users/Kentzo/followers",
"following_url": "https://api.github.com/users/Kentzo/following{/other_user}",
"gists_url": "https://api.github.com/users/Kentzo/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Kentzo",
"id": 88809,
"login": "Kentzo",
"node_id": "MDQ6VXNlcjg4ODA5",
"organizations_url": "https://api.github.com/users/Kentzo/orgs",
"received_events_url": "https://api.github.com/users/Kentzo/received_events",
"repos_url": "https://api.github.com/users/Kentzo/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Kentzo/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Kentzo/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Kentzo",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 7 | 2017-01-13T06:29:28Z | 2021-09-07T00:06:43Z | 2017-01-13T07:19:47Z | NONE | resolved | SSLContext.load_verify_locations allows to specify cadata with 2.7.9+, 3.4+ | {
"avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4",
"events_url": "https://api.github.com/users/Lukasa/events{/privacy}",
"followers_url": "https://api.github.com/users/Lukasa/followers",
"following_url": "https://api.github.com/users/Lukasa/following{/other_user}",
"gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Lukasa",
"id": 1382556,
"login": "Lukasa",
"node_id": "MDQ6VXNlcjEzODI1NTY=",
"organizations_url": "https://api.github.com/users/Lukasa/orgs",
"received_events_url": "https://api.github.com/users/Lukasa/received_events",
"repos_url": "https://api.github.com/users/Lukasa/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Lukasa",
"user_view_type": "public"
} | {
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/3814/reactions"
} | https://api.github.com/repos/psf/requests/issues/3814/timeline | null | null | false | {
"diff_url": "https://github.com/psf/requests/pull/3814.diff",
"html_url": "https://github.com/psf/requests/pull/3814",
"merged_at": null,
"patch_url": "https://github.com/psf/requests/pull/3814.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/3814"
} | true | [
"Thanks for this! Some notes:\r\n\r\n- Firstly, this patch contains changes to the urllib3 project. This is a sub-project vendored in its entirety unchanged into Requests. That means any changes to urllib3 need to be made on that project, and they will then make their way into Requests over time.\r\n- Secondly, I ... |
https://api.github.com/repos/psf/requests/issues/3813 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3813/labels{/name} | https://api.github.com/repos/psf/requests/issues/3813/comments | https://api.github.com/repos/psf/requests/issues/3813/events | https://github.com/psf/requests/issues/3813 | 200,430,233 | MDU6SXNzdWUyMDA0MzAyMzM= | 3,813 | update | {
"avatar_url": "https://avatars.githubusercontent.com/u/1249913?v=4",
"events_url": "https://api.github.com/users/noelmas/events{/privacy}",
"followers_url": "https://api.github.com/users/noelmas/followers",
"following_url": "https://api.github.com/users/noelmas/following{/other_user}",
"gists_url": "https://api.github.com/users/noelmas/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/noelmas",
"id": 1249913,
"login": "noelmas",
"node_id": "MDQ6VXNlcjEyNDk5MTM=",
"organizations_url": "https://api.github.com/users/noelmas/orgs",
"received_events_url": "https://api.github.com/users/noelmas/received_events",
"repos_url": "https://api.github.com/users/noelmas/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/noelmas/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/noelmas/subscriptions",
"type": "User",
"url": "https://api.github.com/users/noelmas",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 0 | 2017-01-12T17:27:56Z | 2021-09-08T13:05:30Z | 2017-01-12T17:28:13Z | NONE | resolved | {
"avatar_url": "https://avatars.githubusercontent.com/u/1249913?v=4",
"events_url": "https://api.github.com/users/noelmas/events{/privacy}",
"followers_url": "https://api.github.com/users/noelmas/followers",
"following_url": "https://api.github.com/users/noelmas/following{/other_user}",
"gists_url": "https://api.github.com/users/noelmas/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/noelmas",
"id": 1249913,
"login": "noelmas",
"node_id": "MDQ6VXNlcjEyNDk5MTM=",
"organizations_url": "https://api.github.com/users/noelmas/orgs",
"received_events_url": "https://api.github.com/users/noelmas/received_events",
"repos_url": "https://api.github.com/users/noelmas/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/noelmas/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/noelmas/subscriptions",
"type": "User",
"url": "https://api.github.com/users/noelmas",
"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/3813/reactions"
} | https://api.github.com/repos/psf/requests/issues/3813/timeline | null | completed | null | null | false | [] | |
https://api.github.com/repos/psf/requests/issues/3812 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3812/labels{/name} | https://api.github.com/repos/psf/requests/issues/3812/comments | https://api.github.com/repos/psf/requests/issues/3812/events | https://github.com/psf/requests/pull/3812 | 200,423,124 | MDExOlB1bGxSZXF1ZXN0MTAxMjk5NTY0 | 3,812 | Add default value of allow_redirects to docs | {
"avatar_url": "https://avatars.githubusercontent.com/u/28734?v=4",
"events_url": "https://api.github.com/users/inglesp/events{/privacy}",
"followers_url": "https://api.github.com/users/inglesp/followers",
"following_url": "https://api.github.com/users/inglesp/following{/other_user}",
"gists_url": "https://api.github.com/users/inglesp/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/inglesp",
"id": 28734,
"login": "inglesp",
"node_id": "MDQ6VXNlcjI4NzM0",
"organizations_url": "https://api.github.com/users/inglesp/orgs",
"received_events_url": "https://api.github.com/users/inglesp/received_events",
"repos_url": "https://api.github.com/users/inglesp/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/inglesp/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/inglesp/subscriptions",
"type": "User",
"url": "https://api.github.com/users/inglesp",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 1 | 2017-01-12T17:00:51Z | 2021-09-08T01:21:25Z | 2017-01-12T17:12:54Z | CONTRIBUTOR | resolved | {
"avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4",
"events_url": "https://api.github.com/users/Lukasa/events{/privacy}",
"followers_url": "https://api.github.com/users/Lukasa/followers",
"following_url": "https://api.github.com/users/Lukasa/following{/other_user}",
"gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Lukasa",
"id": 1382556,
"login": "Lukasa",
"node_id": "MDQ6VXNlcjEzODI1NTY=",
"organizations_url": "https://api.github.com/users/Lukasa/orgs",
"received_events_url": "https://api.github.com/users/Lukasa/received_events",
"repos_url": "https://api.github.com/users/Lukasa/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Lukasa",
"user_view_type": "public"
} | {
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/3812/reactions"
} | https://api.github.com/repos/psf/requests/issues/3812/timeline | null | null | false | {
"diff_url": "https://github.com/psf/requests/pull/3812.diff",
"html_url": "https://github.com/psf/requests/pull/3812",
"merged_at": "2017-01-12T17:12:54Z",
"patch_url": "https://github.com/psf/requests/pull/3812.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/3812"
} | true | [
"Thanks @inglesp!"
] | |
https://api.github.com/repos/psf/requests/issues/3811 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3811/labels{/name} | https://api.github.com/repos/psf/requests/issues/3811/comments | https://api.github.com/repos/psf/requests/issues/3811/events | https://github.com/psf/requests/issues/3811 | 200,199,743 | MDU6SXNzdWUyMDAxOTk3NDM= | 3,811 | Ubuntu 16.04 Python3 SSLV3_ALERT_HANDSHAKE_FAILURE | {
"avatar_url": "https://avatars.githubusercontent.com/u/5175230?v=4",
"events_url": "https://api.github.com/users/2tim/events{/privacy}",
"followers_url": "https://api.github.com/users/2tim/followers",
"following_url": "https://api.github.com/users/2tim/following{/other_user}",
"gists_url": "https://api.github.com/users/2tim/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/2tim",
"id": 5175230,
"login": "2tim",
"node_id": "MDQ6VXNlcjUxNzUyMzA=",
"organizations_url": "https://api.github.com/users/2tim/orgs",
"received_events_url": "https://api.github.com/users/2tim/received_events",
"repos_url": "https://api.github.com/users/2tim/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/2tim/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/2tim/subscriptions",
"type": "User",
"url": "https://api.github.com/users/2tim",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 5 | 2017-01-11T20:32:47Z | 2021-09-08T13:05:31Z | 2017-01-11T20:40:57Z | NONE | resolved | Using:
Python 3.5.2
Ubuntu 16.04.01
OpenSSL 1.0.2g 1 Mar 2016
pip freeze:
alabaster==0.7.9
amqp==2.1.4
antigate==1.4.0
anyjson==0.3.3
Babel==2.3.4
beautifulsoup4==4.5.3
billiard==3.5.0.2
celery==4.0.2
celery-with-redis==3.0
certifi==2016.9.26
cffi==1.9.1
configparser==3.5.0
cryptography==1.7.1
Django==1.10.5
django-docs==0.2.1
djangorestframework==3.5.3
docutils==0.13.1
epydoc==3.0.1
flower==0.9.1
future==0.16.0
gunicorn==19.6.0
idna==2.2
imagesize==0.7.1
Jinja2==2.9.4
kombu==4.0.2
lxml==3.7.2
MarkupSafe==0.23
miette==1.3
ndg-httpsclient==0.4.2
nose==1.3.7
olefile==0.44
ordereddict==1.1
Pillow==4.0.0
probableparsing==0.0.1
psycopg2==2.6.1
pyasn1==0.1.9
pycparser==2.17
Pygments==2.1.3
pyPdf==1.13
python-crfsuite==0.9.1
python-dateutil==2.6.0
pytz==2016.10
redis==2.10.5
reportlab==3.3.0
requests==2.12.4
selenium==2.52.0
six==1.10.0
snowballstemmer==1.2.1
South==1.0.2
Sphinx==1.5.1
tornado==4.2
Unidecode==0.4.20
urllib3==1.19.1
usaddress==0.5.9
vine==1.1.3
xlrd==1.0.0
xmltodict==0.10.2
xvfbwrapper==0.2.9
I tried to track this down from other issues but none of them seemed to answer the problem for my setup. Here is the console steps with error output:
Python 3.5.2 (default, Nov 17 2016, 17:05:23)
[GCC 5.4.0 20160609] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import requests
>>> requests.get("https://webapps.kdads.ks.gov", verify=False)
Traceback (most recent call last):
File "/home/datadev/.envs/scraping/lib/python3.5/site-packages/requests/packages/urllib3/connectionpool.py", line 594, in urlopen
chunked=chunked)
File "/home/datadev/.envs/scraping/lib/python3.5/site-packages/requests/packages/urllib3/connectionpool.py", line 350, in _make_request
self._validate_conn(conn)
File "/home/datadev/.envs/scraping/lib/python3.5/site-packages/requests/packages/urllib3/connectionpool.py", line 835, in _validate_conn
conn.connect()
File "/home/datadev/.envs/scraping/lib/python3.5/site-packages/requests/packages/urllib3/connection.py", line 323, in connect
ssl_context=context)
File "/home/datadev/.envs/scraping/lib/python3.5/site-packages/requests/packages/urllib3/util/ssl_.py", line 324, in ssl_wrap_socket
return context.wrap_socket(sock, server_hostname=server_hostname)
File "/usr/lib/python3.5/ssl.py", line 377, in wrap_socket
_context=self)
File "/usr/lib/python3.5/ssl.py", line 752, in __init__
self.do_handshake()
File "/usr/lib/python3.5/ssl.py", line 988, in do_handshake
self._sslobj.do_handshake()
File "/usr/lib/python3.5/ssl.py", line 633, 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 "/home/datadev/.envs/scraping/lib/python3.5/site-packages/requests/adapters.py", line 423, in send
timeout=timeout
File "/home/datadev/.envs/scraping/lib/python3.5/site-packages/requests/packages/urllib3/connectionpool.py", line 624, in urlopen
raise SSLError(e)
requests.packages.urllib3.exceptions.SSLError: [SSL: SSLV3_ALERT_HANDSHAKE_FAILURE] sslv3 alert handshake failure (_ssl.c:645)
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/home/datadev/.envs/scraping/lib/python3.5/site-packages/requests/api.py", line 70, in get
return request('get', url, params=params, **kwargs)
File "/home/datadev/.envs/scraping/lib/python3.5/site-packages/requests/api.py", line 56, in request
return session.request(method=method, url=url, **kwargs)
File "/home/datadev/.envs/scraping/lib/python3.5/site-packages/requests/sessions.py", line 488, in request
resp = self.send(prep, **send_kwargs)
File "/home/datadev/.envs/scraping/lib/python3.5/site-packages/requests/sessions.py", line 609, in send
r = adapter.send(request, **kwargs)
File "/home/datadev/.envs/scraping/lib/python3.5/site-packages/requests/adapters.py", line 497, in send
raise SSLError(e, request=request)
requests.exceptions.SSLError: [SSL: SSLV3_ALERT_HANDSHAKE_FAILURE] sslv3 alert handshake failure (_ssl.c:645) | {
"avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4",
"events_url": "https://api.github.com/users/Lukasa/events{/privacy}",
"followers_url": "https://api.github.com/users/Lukasa/followers",
"following_url": "https://api.github.com/users/Lukasa/following{/other_user}",
"gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Lukasa",
"id": 1382556,
"login": "Lukasa",
"node_id": "MDQ6VXNlcjEzODI1NTY=",
"organizations_url": "https://api.github.com/users/Lukasa/orgs",
"received_events_url": "https://api.github.com/users/Lukasa/received_events",
"repos_url": "https://api.github.com/users/Lukasa/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Lukasa",
"user_view_type": "public"
} | {
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/3811/reactions"
} | https://api.github.com/repos/psf/requests/issues/3811/timeline | null | completed | null | null | false | [
"I should note we had the same issue with OSX but assumed it was related to our setup with using the built in (outdated) version of OpenSSL. I'm hoping someone will have an easy fix for this that I am just missing.",
"The problem here is that the only cipher suite the server supports is 3DES-based, and newer vers... |
https://api.github.com/repos/psf/requests/issues/3810 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3810/labels{/name} | https://api.github.com/repos/psf/requests/issues/3810/comments | https://api.github.com/repos/psf/requests/issues/3810/events | https://github.com/psf/requests/issues/3810 | 200,116,604 | MDU6SXNzdWUyMDAxMTY2MDQ= | 3,810 | Timeout in stream request closes connection from client side | {
"avatar_url": "https://avatars.githubusercontent.com/u/16137032?v=4",
"events_url": "https://api.github.com/users/tsarvela/events{/privacy}",
"followers_url": "https://api.github.com/users/tsarvela/followers",
"following_url": "https://api.github.com/users/tsarvela/following{/other_user}",
"gists_url": "https://api.github.com/users/tsarvela/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/tsarvela",
"id": 16137032,
"login": "tsarvela",
"node_id": "MDQ6VXNlcjE2MTM3MDMy",
"organizations_url": "https://api.github.com/users/tsarvela/orgs",
"received_events_url": "https://api.github.com/users/tsarvela/received_events",
"repos_url": "https://api.github.com/users/tsarvela/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/tsarvela/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/tsarvela/subscriptions",
"type": "User",
"url": "https://api.github.com/users/tsarvela",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 1 | 2017-01-11T15:03:22Z | 2021-09-08T13:05:32Z | 2017-01-11T15:05:53Z | NONE | resolved | I've hit a problematic behaviour with python3 and requests, stemming from urllib3. Consider the following example usage with tight read timeout.
After getting the first exception, the connection is cleanly shut down from clientside. Serverside gets Broken pipe. I'd expected to be able to continue reading from the stream, without needing to reconnect.
Reading the urllib3 explanation clarifies the issue somewhat, but is this wanted behaviour?
```
#!/usr/bin/env python3
import requests
res = requests.get("http://localhost/stream", stream=True, timeout=(10.0, 1.0))
reason = None
while not reason:
try:
line = res.raw.readline()
print(line)
except Exception as e: print (e)
```
Full traceback is
```
Traceback (most recent call last):
File "/usr/lib/python3.5/site-packages/requests/packages/urllib3/response.py", line 228, in _error_catcher
yield
File "/usr/lib/python3.5/site-packages/requests/packages/urllib3/response.py", line 310, in read
data = self._fp.read(amt)
File "/usr/lib64/python3.5/http/client.py", line 448, in read
n = self.readinto(b)
File "/usr/lib64/python3.5/http/client.py", line 488, in readinto
n = self.fp.readinto(b)
File "/usr/lib64/python3.5/socket.py", line 575, in readinto
return self._sock.recv_into(b)
socket.timeout: timed out
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "example.py", line 8, in <module>
except Exception as e: raise (e)
File "example.py", line 6, in <module>
line = res.raw.readline()
File "/usr/lib/python3.5/site-packages/requests/packages/urllib3/response.py", line 320, in read
flush_decoder = True
File "/usr/lib64/python3.5/contextlib.py", line 77, in __exit__
self.gen.throw(type, value, traceback)
File "/usr/lib/python3.5/site-packages/requests/packages/urllib3/response.py", line 233, in _error_catcher
raise ReadTimeoutError(self._pool, None, 'Read timed out.')
requests.packages.urllib3.exceptions.ReadTimeoutError: HTTPConnectionPool(host='localhost'): Read timed out.
``` | {
"avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4",
"events_url": "https://api.github.com/users/Lukasa/events{/privacy}",
"followers_url": "https://api.github.com/users/Lukasa/followers",
"following_url": "https://api.github.com/users/Lukasa/following{/other_user}",
"gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Lukasa",
"id": 1382556,
"login": "Lukasa",
"node_id": "MDQ6VXNlcjEzODI1NTY=",
"organizations_url": "https://api.github.com/users/Lukasa/orgs",
"received_events_url": "https://api.github.com/users/Lukasa/received_events",
"repos_url": "https://api.github.com/users/Lukasa/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Lukasa",
"user_view_type": "public"
} | {
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/3810/reactions"
} | https://api.github.com/repos/psf/requests/issues/3810/timeline | null | completed | null | null | false | [
"Timeouts are considered error conditions: that is, we assume that if the server takes longer than a timeout to generate a value, you want us to treat that as an error. That means we tear the connection down, because it's now in an indeterminite state: the server may have gone away, or any number of other bad thing... |
https://api.github.com/repos/psf/requests/issues/3809 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3809/labels{/name} | https://api.github.com/repos/psf/requests/issues/3809/comments | https://api.github.com/repos/psf/requests/issues/3809/events | https://github.com/psf/requests/pull/3809 | 200,045,203 | MDExOlB1bGxSZXF1ZXN0MTAxMDMxOTQ2 | 3,809 | Remove unused module from tests | {
"avatar_url": "https://avatars.githubusercontent.com/u/13811604?v=4",
"events_url": "https://api.github.com/users/winterjung/events{/privacy}",
"followers_url": "https://api.github.com/users/winterjung/followers",
"following_url": "https://api.github.com/users/winterjung/following{/other_user}",
"gists_url": "https://api.github.com/users/winterjung/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/winterjung",
"id": 13811604,
"login": "winterjung",
"node_id": "MDQ6VXNlcjEzODExNjA0",
"organizations_url": "https://api.github.com/users/winterjung/orgs",
"received_events_url": "https://api.github.com/users/winterjung/received_events",
"repos_url": "https://api.github.com/users/winterjung/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/winterjung/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/winterjung/subscriptions",
"type": "User",
"url": "https://api.github.com/users/winterjung",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 1 | 2017-01-11T09:41:59Z | 2021-09-08T01:21:26Z | 2017-01-11T09:49:59Z | NONE | resolved | merge_cookies and cookiejar_from_dict functions are already tested by other test functions. | {
"avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4",
"events_url": "https://api.github.com/users/Lukasa/events{/privacy}",
"followers_url": "https://api.github.com/users/Lukasa/followers",
"following_url": "https://api.github.com/users/Lukasa/following{/other_user}",
"gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Lukasa",
"id": 1382556,
"login": "Lukasa",
"node_id": "MDQ6VXNlcjEzODI1NTY=",
"organizations_url": "https://api.github.com/users/Lukasa/orgs",
"received_events_url": "https://api.github.com/users/Lukasa/received_events",
"repos_url": "https://api.github.com/users/Lukasa/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Lukasa",
"user_view_type": "public"
} | {
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/3809/reactions"
} | https://api.github.com/repos/psf/requests/issues/3809/timeline | null | null | false | {
"diff_url": "https://github.com/psf/requests/pull/3809.diff",
"html_url": "https://github.com/psf/requests/pull/3809",
"merged_at": "2017-01-11T09:49:59Z",
"patch_url": "https://github.com/psf/requests/pull/3809.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/3809"
} | true | [
"Thanks for this @JungWinter! :sparkles: :cake: :sparkles:"
] |
https://api.github.com/repos/psf/requests/issues/3808 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3808/labels{/name} | https://api.github.com/repos/psf/requests/issues/3808/comments | https://api.github.com/repos/psf/requests/issues/3808/events | https://github.com/psf/requests/issues/3808 | 200,012,415 | MDU6SXNzdWUyMDAwMTI0MTU= | 3,808 | Connection reset by peer with AWS NAT Gateway and Keep Alive | {
"avatar_url": "https://avatars.githubusercontent.com/u/892861?v=4",
"events_url": "https://api.github.com/users/ediskandarov/events{/privacy}",
"followers_url": "https://api.github.com/users/ediskandarov/followers",
"following_url": "https://api.github.com/users/ediskandarov/following{/other_user}",
"gists_url": "https://api.github.com/users/ediskandarov/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/ediskandarov",
"id": 892861,
"login": "ediskandarov",
"node_id": "MDQ6VXNlcjg5Mjg2MQ==",
"organizations_url": "https://api.github.com/users/ediskandarov/orgs",
"received_events_url": "https://api.github.com/users/ediskandarov/received_events",
"repos_url": "https://api.github.com/users/ediskandarov/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/ediskandarov/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/ediskandarov/subscriptions",
"type": "User",
"url": "https://api.github.com/users/ediskandarov",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 6 | 2017-01-11T06:19:27Z | 2021-09-08T11:00:38Z | 2017-01-11T09:00:30Z | NONE | resolved | Set up following scenario to reproduce the issue:
backend side:
CloudFlare is proxying to AWS ELB.
ELB is proxying to Nginx.
client side:
Create private subnet and attach AWS NAT Gateway to it.
Launch EC2 instance in private subnet and use a script below to reproduce the issue.
Request path is:
EC2 instance(originating) -> AWS NAT Gateway -> CloudFlare -> AWS ELB -> Nginx.
I created a script which reproduces the issue:
```python
import requests
import time
def request_with_timeout(url, minutes):
session = requests.Session()
session.get(url, allow_redirects=False)
time.sleep(minutes * 60)
session.get(url, allow_redirects=False)
request_with_timeout('https://coins.ph', 6)
```
After executing - requests raises an exception:
```
>>> request_with_timeout('https://coins.ph', 6)
/opt/app/accounting/venv/local/lib/python2.7/site-packages/requests/packages/urllib3/util/ssl_.py:315: 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. For more information, see https://urllib3.readthedocs.org/en/latest/security.html#snimissingwarning.
SNIMissingWarning
/opt/app/accounting/venv/local/lib/python2.7/site-packages/requests/packages/urllib3/util/ssl_.py:120: InsecurePlatformWarning: A true SSLContext object is not available. This prevents urllib3 from configuring SSL appropriately and may cause certain SSL connections to fail. For more information, see https://urllib3.readthedocs.org/en/latest/security.html#insecureplatformwarning.
InsecurePlatformWarning
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "<stdin>", line 5, in request_with_timeout
File "/opt/app/accounting/venv/local/lib/python2.7/site-packages/requests/sessions.py", line 480, in get
return self.request('GET', url, **kwargs)
File "/opt/app/accounting/venv/local/lib/python2.7/site-packages/requests/sessions.py", line 468, in request
resp = self.send(prep, **send_kwargs)
File "/opt/app/accounting/venv/local/lib/python2.7/site-packages/requests/sessions.py", line 576, in send
r = adapter.send(request, **kwargs)
File "/opt/app/accounting/venv/local/lib/python2.7/site-packages/requests/adapters.py", line 426, in send
raise ConnectionError(err, request=request)
requests.exceptions.ConnectionError: ('Connection aborted.', error(104, 'Connection reset by peer'))
```
Software versions:
```
Python 2.7.6
requests==2.9.1
```
But also reproduced on Python 2.7.12 and requests 2.12.4 | {
"avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4",
"events_url": "https://api.github.com/users/Lukasa/events{/privacy}",
"followers_url": "https://api.github.com/users/Lukasa/followers",
"following_url": "https://api.github.com/users/Lukasa/following{/other_user}",
"gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Lukasa",
"id": 1382556,
"login": "Lukasa",
"node_id": "MDQ6VXNlcjEzODI1NTY=",
"organizations_url": "https://api.github.com/users/Lukasa/orgs",
"received_events_url": "https://api.github.com/users/Lukasa/received_events",
"repos_url": "https://api.github.com/users/Lukasa/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Lukasa",
"user_view_type": "public"
} | {
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/3808/reactions"
} | https://api.github.com/repos/psf/requests/issues/3808/timeline | null | completed | null | null | false | [
"Attaching tcpdump\r\n\r\n[tcpdump-log.txt](https://github.com/kennethreitz/requests/files/698100/tcpdump-log.txt)\r\n",
"The issue does not appear when URL has `http` scheme.",
"Also everything works fine when there's no AWS NAT Gateway on the traffic path.\r\n\r\nThis can be a result of AWS NAT Gateway behavi... |
https://api.github.com/repos/psf/requests/issues/3807 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3807/labels{/name} | https://api.github.com/repos/psf/requests/issues/3807/comments | https://api.github.com/repos/psf/requests/issues/3807/events | https://github.com/psf/requests/issues/3807 | 199,955,807 | MDU6SXNzdWUxOTk5NTU4MDc= | 3,807 | 'NoneType' object has no attribute 'readline' | {
"avatar_url": "https://avatars.githubusercontent.com/u/9061113?v=4",
"events_url": "https://api.github.com/users/gilessbrown/events{/privacy}",
"followers_url": "https://api.github.com/users/gilessbrown/followers",
"following_url": "https://api.github.com/users/gilessbrown/following{/other_user}",
"gists_url": "https://api.github.com/users/gilessbrown/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/gilessbrown",
"id": 9061113,
"login": "gilessbrown",
"node_id": "MDQ6VXNlcjkwNjExMTM=",
"organizations_url": "https://api.github.com/users/gilessbrown/orgs",
"received_events_url": "https://api.github.com/users/gilessbrown/received_events",
"repos_url": "https://api.github.com/users/gilessbrown/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/gilessbrown/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/gilessbrown/subscriptions",
"type": "User",
"url": "https://api.github.com/users/gilessbrown",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 31 | 2017-01-10T22:48:46Z | 2021-09-02T00:07:16Z | 2017-01-11T17:29:42Z | NONE | resolved | Tried a quick check of open issues, but wasn't sure what to search for on this.
Here's the code to reproduce:
```
import shutil
import requests
import os
session = requests.Session()
# it has something to do with content on the 302 from this url
u = 'http://www.amazon.com/gp/redirect.html/ref=gw_m_b_ir?_encoding=UTF8&location=http%3A%2F%2Fphx.corporate-ir.net%2Fphoenix.zhtml%3Fc%3D97664%26p%3Dirol-irhome&source=standards&token=F9CAD8A11D4336B5E0B3C3B089FA066D0A467C1C'
r0 = session.get(u, stream=True, allow_redirects=False)
redirects = session.resolve_redirects(r0, r0.request, stream=True)
for redirect in redirects:
with open(os.devnull, 'wb') as devnull:
shutil.copyfileobj(redirect.raw, devnull)
```
Gives me the traceback:
```
(tmp-91018d725433cf2c) gsbrown$ python bug.py
Traceback (most recent call last):
File "bug.py", line 11, in <module>
for redirect in redirects:
File "/Users/gsbrown/.virtualenvs/tmp-91018d725433cf2c/lib/python2.7/site-packages/requests/sessions.py", line 106, in resolve_redirects
resp.content # Consume socket so it can be released
File "/Users/gsbrown/.virtualenvs/tmp-91018d725433cf2c/lib/python2.7/site-packages/requests/models.py", line 781, in content
self._content = bytes().join(self.iter_content(CONTENT_CHUNK_SIZE)) or bytes()
File "/Users/gsbrown/.virtualenvs/tmp-91018d725433cf2c/lib/python2.7/site-packages/requests/models.py", line 703, in generate
for chunk in self.raw.stream(chunk_size, decode_content=True):
File "/Users/gsbrown/.virtualenvs/tmp-91018d725433cf2c/lib/python2.7/site-packages/requests/packages/urllib3/response.py", line 428, in stream
for line in self.read_chunked(amt, decode_content=decode_content):
File "/Users/gsbrown/.virtualenvs/tmp-91018d725433cf2c/lib/python2.7/site-packages/requests/packages/urllib3/response.py", line 590, in read_chunked
self._update_chunk_length()
File "/Users/gsbrown/.virtualenvs/tmp-91018d725433cf2c/lib/python2.7/site-packages/requests/packages/urllib3/response.py", line 532, in _update_chunk_length
line = self._fp.fp.readline()
AttributeError: 'NoneType' object has no attribute 'readline'
```
The redirect url is significant. It doesn't happen with the httpbin ones. | {
"avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4",
"events_url": "https://api.github.com/users/Lukasa/events{/privacy}",
"followers_url": "https://api.github.com/users/Lukasa/followers",
"following_url": "https://api.github.com/users/Lukasa/following{/other_user}",
"gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Lukasa",
"id": 1382556,
"login": "Lukasa",
"node_id": "MDQ6VXNlcjEzODI1NTY=",
"organizations_url": "https://api.github.com/users/Lukasa/orgs",
"received_events_url": "https://api.github.com/users/Lukasa/received_events",
"repos_url": "https://api.github.com/users/Lukasa/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Lukasa",
"user_view_type": "public"
} | {
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/3807/reactions"
} | https://api.github.com/repos/psf/requests/issues/3807/timeline | null | completed | null | null | false | [
"FYI: \r\n```\r\n$ pip list\r\npip (1.5.4)\r\nrequests (2.12.4)\r\nsetuptools (2.2)\r\nwsgiref (0.1.2)\r\n```",
"Just a quick note... I can't really help with your issue directly, as it goes beyond my knowledge.\r\n\r\nJust thought I'd mention that pip is up to version 9.0.1... pip 1.5.4 is nearly 3 years old. I'... |
https://api.github.com/repos/psf/requests/issues/3806 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3806/labels{/name} | https://api.github.com/repos/psf/requests/issues/3806/comments | https://api.github.com/repos/psf/requests/issues/3806/events | https://github.com/psf/requests/issues/3806 | 199,827,368 | MDU6SXNzdWUxOTk4MjczNjg= | 3,806 | Problem with proxy + https | {
"avatar_url": "https://avatars.githubusercontent.com/u/1655105?v=4",
"events_url": "https://api.github.com/users/jachymb/events{/privacy}",
"followers_url": "https://api.github.com/users/jachymb/followers",
"following_url": "https://api.github.com/users/jachymb/following{/other_user}",
"gists_url": "https://api.github.com/users/jachymb/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/jachymb",
"id": 1655105,
"login": "jachymb",
"node_id": "MDQ6VXNlcjE2NTUxMDU=",
"organizations_url": "https://api.github.com/users/jachymb/orgs",
"received_events_url": "https://api.github.com/users/jachymb/received_events",
"repos_url": "https://api.github.com/users/jachymb/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/jachymb/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/jachymb/subscriptions",
"type": "User",
"url": "https://api.github.com/users/jachymb",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 3 | 2017-01-10T13:56:11Z | 2021-09-08T13:05:31Z | 2017-01-11T20:39:25Z | NONE | resolved | GET request fails when requesting a https page over a https proxy.
```
>>> import requests
>>> import os
>>> os.getenv("HTTPS_PROXY")
'https://localhost:3130'
>>> requests.get("https://example.org", verify = False)
Traceback (most recent call last):
File "/usr/lib/python3.5/site-packages/requests/packages/urllib3/connectionpool.py", line 588, in urlopen
self._prepare_proxy(conn)
File "/usr/lib/python3.5/site-packages/requests/packages/urllib3/connectionpool.py", line 801, in _prepare_proxy
conn.connect()
File "/usr/lib/python3.5/site-packages/requests/packages/urllib3/connection.py", line 291, in connect
self._tunnel()
File "/usr/lib/python3.5/http/client.py", line 827, in _tunnel
(version, code, message) = response._read_status()
File "/usr/lib/python3.5/http/client.py", line 258, in _read_status
line = str(self.fp.readline(_MAXLINE + 1), "iso-8859-1")
File "/usr/lib/python3.5/socket.py", line 575, in readinto
return self._sock.recv_into(b)
ConnectionResetError: [Errno 104] Connection reset by peer
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/usr/lib/python3.5/site-packages/requests/adapters.py", line 423, in send
timeout=timeout
File "/usr/lib/python3.5/site-packages/requests/packages/urllib3/connectionpool.py", line 643, in urlopen
_stacktrace=sys.exc_info()[2])
File "/usr/lib/python3.5/site-packages/requests/packages/urllib3/util/retry.py", line 363, in increment
raise MaxRetryError(_pool, url, error or ResponseError(cause))
requests.packages.urllib3.exceptions.MaxRetryError: HTTPSConnectionPool(host='example.org', port=443): Max retries exceeded with url: / (Caused by ProxyError('Cannot connect to proxy.', ConnectionResetError(104, 'Connection reset by peer')))
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/usr/lib/python3.5/site-packages/requests/api.py", line 70, in get
return request('get', url, params=params, **kwargs)
File "/usr/lib/python3.5/site-packages/requests/api.py", line 56, in request
return session.request(method=method, url=url, **kwargs)
File "/usr/lib/python3.5/site-packages/requests/sessions.py", line 488, in request
resp = self.send(prep, **send_kwargs)
File "/usr/lib/python3.5/site-packages/requests/sessions.py", line 609, in send
r = adapter.send(request, **kwargs)
File "/usr/lib/python3.5/site-packages/requests/adapters.py", line 485, in send
raise ProxyError(e, request=request)
requests.exceptions.ProxyError: HTTPSConnectionPool(host='example.org', port=443): Max retries exceeded with url: / (Caused by ProxyError('Cannot connect to proxy.', ConnectionResetError(104, 'Connection reset by peer')))
```
The proxy is the squid proxy with this configuration directive:
```
https_port 3130 cert=/etc/sqiud/ssl/squid.pem key=/etc/squid/ssl/squid.key
```
And this works OK:
```
curl --proxy https://localhost:3130 --proxy-insecure https://example.com
```
| {
"avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4",
"events_url": "https://api.github.com/users/Lukasa/events{/privacy}",
"followers_url": "https://api.github.com/users/Lukasa/followers",
"following_url": "https://api.github.com/users/Lukasa/following{/other_user}",
"gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Lukasa",
"id": 1382556,
"login": "Lukasa",
"node_id": "MDQ6VXNlcjEzODI1NTY=",
"organizations_url": "https://api.github.com/users/Lukasa/orgs",
"received_events_url": "https://api.github.com/users/Lukasa/received_events",
"repos_url": "https://api.github.com/users/Lukasa/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Lukasa",
"user_view_type": "public"
} | {
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/3806/reactions"
} | https://api.github.com/repos/psf/requests/issues/3806/timeline | null | completed | null | null | false | [
"Requests does not really support connecting to proxies over HTTPS. In particular, we try to tunnel through them, and that just causes everything to go wrong. I'm afraid that until such time as someone improves httplib's support for this, or until we replace httplib, this is a use-case we simply cannot support.",
... |
https://api.github.com/repos/psf/requests/issues/3805 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3805/labels{/name} | https://api.github.com/repos/psf/requests/issues/3805/comments | https://api.github.com/repos/psf/requests/issues/3805/events | https://github.com/psf/requests/issues/3805 | 199,809,741 | MDU6SXNzdWUxOTk4MDk3NDE= | 3,805 | Cannot clone repo due to bad timezone error | {
"avatar_url": "https://avatars.githubusercontent.com/u/10137?v=4",
"events_url": "https://api.github.com/users/ghost/events{/privacy}",
"followers_url": "https://api.github.com/users/ghost/followers",
"following_url": "https://api.github.com/users/ghost/following{/other_user}",
"gists_url": "https://api.github.com/users/ghost/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/ghost",
"id": 10137,
"login": "ghost",
"node_id": "MDQ6VXNlcjEwMTM3",
"organizations_url": "https://api.github.com/users/ghost/orgs",
"received_events_url": "https://api.github.com/users/ghost/received_events",
"repos_url": "https://api.github.com/users/ghost/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/ghost/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/ghost/subscriptions",
"type": "User",
"url": "https://api.github.com/users/ghost",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 8 | 2017-01-10T12:34:30Z | 2018-09-21T12:35:13Z | 2017-01-10T12:35:52Z | NONE | resolved | ```
nyuszika7h@cadoth ~/src > git clone https://github.com/kennethreitz/requests.git
Cloning into 'requests'...
remote: Counting objects: 18867, done.
remote: Compressing objects: 100% (11/11), done.
error: object 5e6ecdad9f69b1ff789a17733b8edc6fd7091bd8: badTimezone: invalid author/committer line - bad time zone
fatal: Error in object
fatal: index-pack failed
``` | {
"avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4",
"events_url": "https://api.github.com/users/Lukasa/events{/privacy}",
"followers_url": "https://api.github.com/users/Lukasa/followers",
"following_url": "https://api.github.com/users/Lukasa/following{/other_user}",
"gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Lukasa",
"id": 1382556,
"login": "Lukasa",
"node_id": "MDQ6VXNlcjEzODI1NTY=",
"organizations_url": "https://api.github.com/users/Lukasa/orgs",
"received_events_url": "https://api.github.com/users/Lukasa/received_events",
"repos_url": "https://api.github.com/users/Lukasa/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Lukasa",
"user_view_type": "public"
} | {
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/3805/reactions"
} | https://api.github.com/repos/psf/requests/issues/3805/timeline | null | completed | null | null | false | [
"Thanks for raising this issue! In future, please search the issue history before opening new issues on projects, as you'll often find that your issue has been reported before. In this case, this is a duplicate of #3088, #3008, and #2690.",
"Sorry. I did search, but didn't get the right terms.",
"If you have an... |
https://api.github.com/repos/psf/requests/issues/3804 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3804/labels{/name} | https://api.github.com/repos/psf/requests/issues/3804/comments | https://api.github.com/repos/psf/requests/issues/3804/events | https://github.com/psf/requests/pull/3804 | 199,734,872 | MDExOlB1bGxSZXF1ZXN0MTAwODEyMzIy | 3,804 | Improve discoverability of OAuth 2 support | {
"avatar_url": "https://avatars.githubusercontent.com/u/1026649?v=4",
"events_url": "https://api.github.com/users/ncoghlan/events{/privacy}",
"followers_url": "https://api.github.com/users/ncoghlan/followers",
"following_url": "https://api.github.com/users/ncoghlan/following{/other_user}",
"gists_url": "https://api.github.com/users/ncoghlan/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/ncoghlan",
"id": 1026649,
"login": "ncoghlan",
"node_id": "MDQ6VXNlcjEwMjY2NDk=",
"organizations_url": "https://api.github.com/users/ncoghlan/orgs",
"received_events_url": "https://api.github.com/users/ncoghlan/received_events",
"repos_url": "https://api.github.com/users/ncoghlan/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/ncoghlan/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/ncoghlan/subscriptions",
"type": "User",
"url": "https://api.github.com/users/ncoghlan",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 3 | 2017-01-10T05:17:34Z | 2021-09-05T00:07:11Z | 2017-01-10T08:31:59Z | CONTRIBUTOR | resolved | The previous summary gave the impression that requests-oauthlib only supports
OAuth 1.
This updates makes it clear that it also supports OAuth 2, and links directly to the
use case specific authentication flow guides. | {
"avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4",
"events_url": "https://api.github.com/users/Lukasa/events{/privacy}",
"followers_url": "https://api.github.com/users/Lukasa/followers",
"following_url": "https://api.github.com/users/Lukasa/following{/other_user}",
"gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Lukasa",
"id": 1382556,
"login": "Lukasa",
"node_id": "MDQ6VXNlcjEzODI1NTY=",
"organizations_url": "https://api.github.com/users/Lukasa/orgs",
"received_events_url": "https://api.github.com/users/Lukasa/received_events",
"repos_url": "https://api.github.com/users/Lukasa/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Lukasa",
"user_view_type": "public"
} | {
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/3804/reactions"
} | https://api.github.com/repos/psf/requests/issues/3804/timeline | null | null | false | {
"diff_url": "https://github.com/psf/requests/pull/3804.diff",
"html_url": "https://github.com/psf/requests/pull/3804",
"merged_at": "2017-01-10T08:31:59Z",
"patch_url": "https://github.com/psf/requests/pull/3804.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/3804"
} | true | [
"I'm currently working on adding OpenID Connect support to a pre-existing web application (https://github.com/fedora-infra/anitya/issues/329) and found it very hard to find good documentation on writing a full semi-automated integration test where the only manual step is the user authorising a temporary access toke... |
https://api.github.com/repos/psf/requests/issues/3803 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3803/labels{/name} | https://api.github.com/repos/psf/requests/issues/3803/comments | https://api.github.com/repos/psf/requests/issues/3803/events | https://github.com/psf/requests/issues/3803 | 199,635,105 | MDU6SXNzdWUxOTk2MzUxMDU= | 3,803 | AttributeError: 'set' object has no attribute 'items' | {
"avatar_url": "https://avatars.githubusercontent.com/u/911902?v=4",
"events_url": "https://api.github.com/users/codespaced/events{/privacy}",
"followers_url": "https://api.github.com/users/codespaced/followers",
"following_url": "https://api.github.com/users/codespaced/following{/other_user}",
"gists_url": "https://api.github.com/users/codespaced/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/codespaced",
"id": 911902,
"login": "codespaced",
"node_id": "MDQ6VXNlcjkxMTkwMg==",
"organizations_url": "https://api.github.com/users/codespaced/orgs",
"received_events_url": "https://api.github.com/users/codespaced/received_events",
"repos_url": "https://api.github.com/users/codespaced/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/codespaced/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/codespaced/subscriptions",
"type": "User",
"url": "https://api.github.com/users/codespaced",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 5 | 2017-01-09T19:05:36Z | 2021-08-31T00:06:53Z | 2017-01-09T19:41:40Z | NONE | resolved | fresh pip install requests. version 2.12.4. This works in postman.
```
import requests
url = 'https://api.spotify.com/v1/audio-analysis/4JpKVNYnVcJ8tuMKjAj50A'
headers = {'Authorization', 'Bearer TOKEN-HERE'}
r = requests.get(url, headers=headers)
```
```
---------------------------------------------------------------------------
AttributeError Traceback (most recent call last)
<ipython-input-5-0b5138b50602> in <module>()
1 url = 'https://api.spotify.com/v1/audio-analysis/4JpKVNYnVcJ8tuMKjAj50A'
2 headers = {'Authorization', 'Bearer TOKEN-HERE'}
----> 3 r = requests.get(url, headers=headers)
c:\python27\lib\site-packages\requests\api.pyc in get(url, params, **kwargs)
68
69 kwargs.setdefault('allow_redirects', True)
---> 70 return request('get', url, params=params, **kwargs)
71
72
c:\python27\lib\site-packages\requests\api.pyc in request(method, url, **kwargs)
54 # cases, and look like a memory leak in others.
55 with sessions.Session() as session:
---> 56 return session.request(method=method, url=url, **kwargs)
57
58
c:\python27\lib\site-packages\requests\sessions.pyc in request(self, method, url, params, data, headers, cookies, files, auth, timeout, allow_redirects, proxies, hooks, stream, verify, cert, json)
472 hooks = hooks,
473 )
--> 474 prep = self.prepare_request(req)
475
476 proxies = proxies or {}
c:\python27\lib\site-packages\requests\sessions.pyc in prepare_request(self, request)
405 auth=merge_setting(auth, self.auth),
406 cookies=merged_cookies,
--> 407 hooks=merge_hooks(request.hooks, self.hooks),
408 )
409 return p
c:\python27\lib\site-packages\requests\models.pyc in prepare(self, method, url, headers, files, data, params, auth, cookies, hooks, json)
301 self.prepare_method(method)
302 self.prepare_url(url, params)
--> 303 self.prepare_headers(headers)
304 self.prepare_cookies(cookies)
305 self.prepare_body(data, files, json)
c:\python27\lib\site-packages\requests\models.pyc in prepare_headers(self, headers)
423 self.headers = CaseInsensitiveDict()
424 if headers:
--> 425 for header in headers.items():
426 # Raise exception on invalid header value.
427 check_header_validity(header)
AttributeError: 'set' object has no attribute 'items'
```
| {
"avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4",
"events_url": "https://api.github.com/users/Lukasa/events{/privacy}",
"followers_url": "https://api.github.com/users/Lukasa/followers",
"following_url": "https://api.github.com/users/Lukasa/following{/other_user}",
"gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Lukasa",
"id": 1382556,
"login": "Lukasa",
"node_id": "MDQ6VXNlcjEzODI1NTY=",
"organizations_url": "https://api.github.com/users/Lukasa/orgs",
"received_events_url": "https://api.github.com/users/Lukasa/received_events",
"repos_url": "https://api.github.com/users/Lukasa/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Lukasa",
"user_view_type": "public"
} | {
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/3803/reactions"
} | https://api.github.com/repos/psf/requests/issues/3803/timeline | null | completed | null | null | false | [
"Hey @codespaced, thanks for opening this issue. It looks like you used a comma instead of a colon to separate the key and value in your header. This is creating a set object instead of the dictionary we're expecting. Replacing that should solve your issue.",
"Yup, this is strictly a Python syntax problem and not... |
https://api.github.com/repos/psf/requests/issues/3802 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3802/labels{/name} | https://api.github.com/repos/psf/requests/issues/3802/comments | https://api.github.com/repos/psf/requests/issues/3802/events | https://github.com/psf/requests/pull/3802 | 199,472,453 | MDExOlB1bGxSZXF1ZXN0MTAwNjMwOTI2 | 3,802 | Add **kwargs to cookiejar_from_dict | {
"avatar_url": "https://avatars.githubusercontent.com/u/606837?v=4",
"events_url": "https://api.github.com/users/Atterratio/events{/privacy}",
"followers_url": "https://api.github.com/users/Atterratio/followers",
"following_url": "https://api.github.com/users/Atterratio/following{/other_user}",
"gists_url": "https://api.github.com/users/Atterratio/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Atterratio",
"id": 606837,
"login": "Atterratio",
"node_id": "MDQ6VXNlcjYwNjgzNw==",
"organizations_url": "https://api.github.com/users/Atterratio/orgs",
"received_events_url": "https://api.github.com/users/Atterratio/received_events",
"repos_url": "https://api.github.com/users/Atterratio/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Atterratio/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Atterratio/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Atterratio",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 2 | 2017-01-09T03:45:58Z | 2021-09-07T00:06:37Z | 2017-02-10T17:11:56Z | NONE | resolved | It's can be useful for set not default cookies attributes values, for example "domain" or "discard". | {
"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/3802/reactions"
} | https://api.github.com/repos/psf/requests/issues/3802/timeline | null | null | false | {
"diff_url": "https://github.com/psf/requests/pull/3802.diff",
"html_url": "https://github.com/psf/requests/pull/3802",
"merged_at": null,
"patch_url": "https://github.com/psf/requests/pull/3802.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/3802"
} | true | [
"So, while we can do this, are you not likely to be better served by creating a CookieJar yourself at this point? `cookiejar_from_dict` as a utility function is mostly intended for internal use to support the usage of dict in our APIs: we kind of expect that users who want to get more granular control over cookie s... |
https://api.github.com/repos/psf/requests/issues/3801 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3801/labels{/name} | https://api.github.com/repos/psf/requests/issues/3801/comments | https://api.github.com/repos/psf/requests/issues/3801/events | https://github.com/psf/requests/pull/3801 | 199,452,909 | MDExOlB1bGxSZXF1ZXN0MTAwNjE5MzIz | 3,801 | Added python 3.6.0 | {
"avatar_url": "https://avatars.githubusercontent.com/u/1374633?v=4",
"events_url": "https://api.github.com/users/andriisoldatenko/events{/privacy}",
"followers_url": "https://api.github.com/users/andriisoldatenko/followers",
"following_url": "https://api.github.com/users/andriisoldatenko/following{/other_user}",
"gists_url": "https://api.github.com/users/andriisoldatenko/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/andriisoldatenko",
"id": 1374633,
"login": "andriisoldatenko",
"node_id": "MDQ6VXNlcjEzNzQ2MzM=",
"organizations_url": "https://api.github.com/users/andriisoldatenko/orgs",
"received_events_url": "https://api.github.com/users/andriisoldatenko/received_events",
"repos_url": "https://api.github.com/users/andriisoldatenko/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/andriisoldatenko/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/andriisoldatenko/subscriptions",
"type": "User",
"url": "https://api.github.com/users/andriisoldatenko",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 0 | 2017-01-08T22:41:06Z | 2021-09-08T01:21:26Z | 2017-01-09T04:13:04Z | NONE | 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/3801/reactions"
} | https://api.github.com/repos/psf/requests/issues/3801/timeline | null | null | false | {
"diff_url": "https://github.com/psf/requests/pull/3801.diff",
"html_url": "https://github.com/psf/requests/pull/3801",
"merged_at": "2017-01-09T04:13:04Z",
"patch_url": "https://github.com/psf/requests/pull/3801.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/3801"
} | true | [] | |
https://api.github.com/repos/psf/requests/issues/3800 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3800/labels{/name} | https://api.github.com/repos/psf/requests/issues/3800/comments | https://api.github.com/repos/psf/requests/issues/3800/events | https://github.com/psf/requests/issues/3800 | 199,384,061 | MDU6SXNzdWUxOTkzODQwNjE= | 3,800 | Use proxy to hide IP | {
"avatar_url": "https://avatars.githubusercontent.com/u/1591920?v=4",
"events_url": "https://api.github.com/users/Djokx/events{/privacy}",
"followers_url": "https://api.github.com/users/Djokx/followers",
"following_url": "https://api.github.com/users/Djokx/following{/other_user}",
"gists_url": "https://api.github.com/users/Djokx/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Djokx",
"id": 1591920,
"login": "Djokx",
"node_id": "MDQ6VXNlcjE1OTE5MjA=",
"organizations_url": "https://api.github.com/users/Djokx/orgs",
"received_events_url": "https://api.github.com/users/Djokx/received_events",
"repos_url": "https://api.github.com/users/Djokx/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Djokx/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Djokx/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Djokx",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 1 | 2017-01-07T20:45:09Z | 2021-09-08T13:05:33Z | 2017-01-07T21:05:41Z | NONE | resolved | Hi,
I'm trying to use a proxy to hide my IP with my script.
I'm just trying
`requests.get("https://api.ipify.org?format=json", proxies={"http":proxies[0][:-1]}).json()`
But I get my real IP address, no the proxy's one. It that normal ? How is it possible to hide my IP with requests ?
Thanks | {
"avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4",
"events_url": "https://api.github.com/users/Lukasa/events{/privacy}",
"followers_url": "https://api.github.com/users/Lukasa/followers",
"following_url": "https://api.github.com/users/Lukasa/following{/other_user}",
"gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Lukasa",
"id": 1382556,
"login": "Lukasa",
"node_id": "MDQ6VXNlcjEzODI1NTY=",
"organizations_url": "https://api.github.com/users/Lukasa/orgs",
"received_events_url": "https://api.github.com/users/Lukasa/received_events",
"repos_url": "https://api.github.com/users/Lukasa/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Lukasa",
"user_view_type": "public"
} | {
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/3800/reactions"
} | https://api.github.com/repos/psf/requests/issues/3800/timeline | null | completed | null | null | false | [
"The proxy dictionary is keyed on the scheme of the URL you are *requesting*. In your example you are requesting a *https* URL with a proxy dictionary that only has a *http* key. This means Requests thinks you don't want to proxy https requests, and so sends them directly. Add *https* to your proxy dictionary as we... |
https://api.github.com/repos/psf/requests/issues/3799 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3799/labels{/name} | https://api.github.com/repos/psf/requests/issues/3799/comments | https://api.github.com/repos/psf/requests/issues/3799/events | https://github.com/psf/requests/issues/3799 | 199,215,760 | MDU6SXNzdWUxOTkyMTU3NjA= | 3,799 | Why LifoQueue and not simply Queue (or custom LifoQueue)? | {
"avatar_url": "https://avatars.githubusercontent.com/u/56894?v=4",
"events_url": "https://api.github.com/users/Kronuz/events{/privacy}",
"followers_url": "https://api.github.com/users/Kronuz/followers",
"following_url": "https://api.github.com/users/Kronuz/following{/other_user}",
"gists_url": "https://api.github.com/users/Kronuz/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Kronuz",
"id": 56894,
"login": "Kronuz",
"node_id": "MDQ6VXNlcjU2ODk0",
"organizations_url": "https://api.github.com/users/Kronuz/orgs",
"received_events_url": "https://api.github.com/users/Kronuz/received_events",
"repos_url": "https://api.github.com/users/Kronuz/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Kronuz/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Kronuz/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Kronuz",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 2 | 2017-01-06T15:12:38Z | 2021-09-08T13:05:33Z | 2017-01-06T15:24:18Z | NONE | resolved | During some profiling, I found out one slow operation is `self.pool.get()` in `_get_conn()`.
In urllib3, in `connectionpool.ConnectionPool`, requests uses `LifoQueue` (which uses a list instead of a much faster deque):
https://github.com/kennethreitz/requests/blob/master/requests/packages/urllib3/connectionpool.py#L64
My suggestion is one could use a custom LifoQueue as:
```python
class LifoQueue(Queue):
def _get(self):
return self.queue.pop()
```
or simply use a Queue, if Lifo is not really needed.
| {
"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/3799/reactions"
} | https://api.github.com/repos/psf/requests/issues/3799/timeline | null | completed | null | null | false | [
"The LIFO property of the LifoQueue is very much needed: this is to ensure the increased likelihood of using a warm TCP connection, which provides substantial efficiency bonuses. The reason it's a queue, instead of just a deque, is to get the thread-safety guarantees that the queue module provides.\r\n\r\nYou are w... |
https://api.github.com/repos/psf/requests/issues/3798 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3798/labels{/name} | https://api.github.com/repos/psf/requests/issues/3798/comments | https://api.github.com/repos/psf/requests/issues/3798/events | https://github.com/psf/requests/issues/3798 | 199,156,439 | MDU6SXNzdWUxOTkxNTY0Mzk= | 3,798 | Customized proxies seems not work, how can we know the proxies's IP address send to server? | {
"avatar_url": "https://avatars.githubusercontent.com/u/4835229?v=4",
"events_url": "https://api.github.com/users/withr/events{/privacy}",
"followers_url": "https://api.github.com/users/withr/followers",
"following_url": "https://api.github.com/users/withr/following{/other_user}",
"gists_url": "https://api.github.com/users/withr/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/withr",
"id": 4835229,
"login": "withr",
"node_id": "MDQ6VXNlcjQ4MzUyMjk=",
"organizations_url": "https://api.github.com/users/withr/orgs",
"received_events_url": "https://api.github.com/users/withr/received_events",
"repos_url": "https://api.github.com/users/withr/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/withr/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/withr/subscriptions",
"type": "User",
"url": "https://api.github.com/users/withr",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 3 | 2017-01-06T09:27:37Z | 2021-09-08T13:05:34Z | 2017-01-06T09:30:38Z | NONE | resolved | Take this as an example:
```
#!/usr/bin/env python
# -*- coding: utf-8 -*-
import requests
proxies = {"http":"http://111.222.333.444:80"}
r = requests.get("https://www.google.com", proxies=proxies, timeout=5)
r.status_code
r.content
```
Obviously, the proxies "111.222.333.444" is not correct, but why I still got status_code 200??
How can we check the proxies we used to send to server?
| {
"avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4",
"events_url": "https://api.github.com/users/Lukasa/events{/privacy}",
"followers_url": "https://api.github.com/users/Lukasa/followers",
"following_url": "https://api.github.com/users/Lukasa/following{/other_user}",
"gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Lukasa",
"id": 1382556,
"login": "Lukasa",
"node_id": "MDQ6VXNlcjEzODI1NTY=",
"organizations_url": "https://api.github.com/users/Lukasa/orgs",
"received_events_url": "https://api.github.com/users/Lukasa/received_events",
"repos_url": "https://api.github.com/users/Lukasa/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Lukasa",
"user_view_type": "public"
} | {
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/3798/reactions"
} | https://api.github.com/repos/psf/requests/issues/3798/timeline | null | completed | null | null | false | [
"The `proxies` dictionary is defined as having the following form: the keys are the URL schemes for the URLs you are requesting, and the values are the URLs for reaching the proxy.\r\n\r\nThat means when we make a web request, we take the scheme of the URL you're requesting and look for a proxy for it. In your case... |
https://api.github.com/repos/psf/requests/issues/3797 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3797/labels{/name} | https://api.github.com/repos/psf/requests/issues/3797/comments | https://api.github.com/repos/psf/requests/issues/3797/events | https://github.com/psf/requests/issues/3797 | 198,975,576 | MDU6SXNzdWUxOTg5NzU1NzY= | 3,797 | Help: how to upgrade urllib3 for solve "filedescriptor out of range in select()" issue | {
"avatar_url": "https://avatars.githubusercontent.com/u/4769764?v=4",
"events_url": "https://api.github.com/users/abc100m/events{/privacy}",
"followers_url": "https://api.github.com/users/abc100m/followers",
"following_url": "https://api.github.com/users/abc100m/following{/other_user}",
"gists_url": "https://api.github.com/users/abc100m/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/abc100m",
"id": 4769764,
"login": "abc100m",
"node_id": "MDQ6VXNlcjQ3Njk3NjQ=",
"organizations_url": "https://api.github.com/users/abc100m/orgs",
"received_events_url": "https://api.github.com/users/abc100m/received_events",
"repos_url": "https://api.github.com/users/abc100m/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/abc100m/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/abc100m/subscriptions",
"type": "User",
"url": "https://api.github.com/users/abc100m",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 3 | 2017-01-05T15:01:02Z | 2021-09-08T12:01:09Z | 2017-01-05T15:02:47Z | NONE | resolved | requests version: 2.12.4
python version: 2.7.9
platform: linux(CentOS)
issue occured:
```shell
ValueError: filedescriptor out of range in select()
```
detail description : https://github.com/shazow/urllib3/commit/a49bec58fa5f7aca76d1d0b2f1975eb094648eab
and this issue have been fixed :
https://github.com/shazow/urllib3/issues/589
https://github.com/sigmavirus24/urllib3/commit/eb8264f55be9cd6b2d0be2833c5ba48058ce999d
I wonder why requests don't upgrade urllib3? and **how can I upgrade urllib3 for requests?**
| {
"avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4",
"events_url": "https://api.github.com/users/Lukasa/events{/privacy}",
"followers_url": "https://api.github.com/users/Lukasa/followers",
"following_url": "https://api.github.com/users/Lukasa/following{/other_user}",
"gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Lukasa",
"id": 1382556,
"login": "Lukasa",
"node_id": "MDQ6VXNlcjEzODI1NTY=",
"organizations_url": "https://api.github.com/users/Lukasa/orgs",
"received_events_url": "https://api.github.com/users/Lukasa/received_events",
"repos_url": "https://api.github.com/users/Lukasa/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Lukasa",
"user_view_type": "public"
} | {
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/3797/reactions"
} | https://api.github.com/repos/psf/requests/issues/3797/timeline | null | completed | null | null | false | [
"Requests uses a vendored copy of urllib3, so we ship our own updates to it. That means you cannot upgrade urllib3 separately to requests.\r\n\r\nWhile I am here, I should note that there is no released version of urllib3 that contains that fix, you'd have to use urllib3 from master. If that's the case, you are bes... |
https://api.github.com/repos/psf/requests/issues/3796 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3796/labels{/name} | https://api.github.com/repos/psf/requests/issues/3796/comments | https://api.github.com/repos/psf/requests/issues/3796/events | https://github.com/psf/requests/pull/3796 | 198,880,786 | MDExOlB1bGxSZXF1ZXN0MTAwMjM3NjEx | 3,796 | updating https demo urls | {
"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 | 1 | 2017-01-05T05:45:45Z | 2021-09-08T01:21:26Z | 2017-01-05T06:17:23Z | MEMBER | resolved | The doc examples for SSL Cert Verification are pointing at an older url that no longer serves a response which is causing the example to hang indefinitely. This updates the urls to the current, correct domain.
Also removing a swap file that I accidentally snuck in a couple months ago 😅 | {
"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/3796/reactions"
} | https://api.github.com/repos/psf/requests/issues/3796/timeline | null | null | false | {
"diff_url": "https://github.com/psf/requests/pull/3796.diff",
"html_url": "https://github.com/psf/requests/pull/3796",
"merged_at": "2017-01-05T06:17:23Z",
"patch_url": "https://github.com/psf/requests/pull/3796.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/3796"
} | true | [
"✨🍰✨"
] |
https://api.github.com/repos/psf/requests/issues/3795 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3795/labels{/name} | https://api.github.com/repos/psf/requests/issues/3795/comments | https://api.github.com/repos/psf/requests/issues/3795/events | https://github.com/psf/requests/pull/3795 | 198,174,940 | MDExOlB1bGxSZXF1ZXN0OTk3NzAwNzk= | 3,795 | Require pytest-mock for the tests | {
"avatar_url": "https://avatars.githubusercontent.com/u/916551?v=4",
"events_url": "https://api.github.com/users/AdamWill/events{/privacy}",
"followers_url": "https://api.github.com/users/AdamWill/followers",
"following_url": "https://api.github.com/users/AdamWill/following{/other_user}",
"gists_url": "https://api.github.com/users/AdamWill/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/AdamWill",
"id": 916551,
"login": "AdamWill",
"node_id": "MDQ6VXNlcjkxNjU1MQ==",
"organizations_url": "https://api.github.com/users/AdamWill/orgs",
"received_events_url": "https://api.github.com/users/AdamWill/received_events",
"repos_url": "https://api.github.com/users/AdamWill/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/AdamWill/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/AdamWill/subscriptions",
"type": "User",
"url": "https://api.github.com/users/AdamWill",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 4 | 2016-12-30T17:41:19Z | 2021-09-08T01:21:27Z | 2016-12-30T18:15:00Z | CONTRIBUTOR | resolved | test_requests.py `test_session_close_proxy_clear` uses the
`mocker` fixture, which is provided by pytest-mock. | {
"avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4",
"events_url": "https://api.github.com/users/Lukasa/events{/privacy}",
"followers_url": "https://api.github.com/users/Lukasa/followers",
"following_url": "https://api.github.com/users/Lukasa/following{/other_user}",
"gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Lukasa",
"id": 1382556,
"login": "Lukasa",
"node_id": "MDQ6VXNlcjEzODI1NTY=",
"organizations_url": "https://api.github.com/users/Lukasa/orgs",
"received_events_url": "https://api.github.com/users/Lukasa/received_events",
"repos_url": "https://api.github.com/users/Lukasa/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Lukasa",
"user_view_type": "public"
} | {
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/3795/reactions"
} | https://api.github.com/repos/psf/requests/issues/3795/timeline | null | null | false | {
"diff_url": "https://github.com/psf/requests/pull/3795.diff",
"html_url": "https://github.com/psf/requests/pull/3795",
"merged_at": "2016-12-30T18:15:00Z",
"patch_url": "https://github.com/psf/requests/pull/3795.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/3795"
} | true | [
"Now I look at it, the pytest-httpbin required version also differs between setup.py and requirements.txt (as a downstream distributor I also much prefer `>=` to `==`, but...:>)",
"Perhaps it would be worth reducing test_requirements to a non-versioned list like [urllib3 does](https://github.com/shazow/urllib3/bl... |
https://api.github.com/repos/psf/requests/issues/3794 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3794/labels{/name} | https://api.github.com/repos/psf/requests/issues/3794/comments | https://api.github.com/repos/psf/requests/issues/3794/events | https://github.com/psf/requests/issues/3794 | 198,011,364 | MDU6SXNzdWUxOTgwMTEzNjQ= | 3,794 | When a response with status code 204 is received the package still tries to parser its bytes and get an exception | {
"avatar_url": "https://avatars.githubusercontent.com/u/14309774?v=4",
"events_url": "https://api.github.com/users/elasti-georgeg/events{/privacy}",
"followers_url": "https://api.github.com/users/elasti-georgeg/followers",
"following_url": "https://api.github.com/users/elasti-georgeg/following{/other_user}",
"gists_url": "https://api.github.com/users/elasti-georgeg/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/elasti-georgeg",
"id": 14309774,
"login": "elasti-georgeg",
"node_id": "MDQ6VXNlcjE0MzA5Nzc0",
"organizations_url": "https://api.github.com/users/elasti-georgeg/orgs",
"received_events_url": "https://api.github.com/users/elasti-georgeg/received_events",
"repos_url": "https://api.github.com/users/elasti-georgeg/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/elasti-georgeg/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/elasti-georgeg/subscriptions",
"type": "User",
"url": "https://api.github.com/users/elasti-georgeg",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 8 | 2016-12-29T13:59:09Z | 2021-09-08T13:05:28Z | 2017-01-14T12:42:39Z | NONE | resolved | our rails server send status_code 204 for some logout requests (a delete with some cookies), and hence the message has no body
however in a code I catch the following exception:
/usr/local/lib/python2.7/dist-packages/requests/api.pyc in request(method, url, **kwargs)
54 # cases, and look like a memory leak in others.
55 with sessions.Session() as session:
---> 56 return session.request(method=method, url=url, **kwargs)
57
58
/usr/local/lib/python2.7/dist-packages/requests/sessions.pyc in request(self, method, url, params, data, headers, cookies, files, auth, timeout, allow_redirects, proxies, hooks, stream, verify, cert, json)
486 }
487 send_kwargs.update(settings)
--> 488 resp = self.send(prep, **send_kwargs)
489
490 return resp
/usr/local/lib/python2.7/dist-packages/requests/sessions.pyc in send(self, request, **kwargs)
639
640 if not stream:
--> 641 r.content
642
643 return r
/usr/local/lib/python2.7/dist-packages/requests/models.pyc in content(self)
779 self._content = None
780 else:
--> 781 self._content = bytes().join(self.iter_content(CONTENT_CHUNK_SIZE)) or bytes()
782
783 self._content_consumed = True
/usr/local/lib/python2.7/dist-packages/requests/models.pyc in generate()
704 yield chunk
705 except ProtocolError as e:
--> 706 raise ChunkedEncodingError(e)
707 except DecodeError as e:
708 raise ContentDecodingError(e)
The problem is here: https://github.com/kennethreitz/requests/blob/master/requests/models.py#L778
for some reason the status code checks itself agains 0, and raw requests checks agains None
while raw request does contain all the headers it has no body and thus an iterator fails to iterate on an empty chunk.
| {
"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/3794/reactions"
} | https://api.github.com/repos/psf/requests/issues/3794/timeline | null | completed | null | null | false | [
"Hey @elasti-georgeg, thanks for opening this issue. I am able to reproduce the issue you've listed but only with a 204 response containing a \"Transfer-Encoding: chunked\" header.\r\n\r\n[RFC 7230 § 3.3.1](https://tools.ietf.org/html/rfc7230#section-3.3.1) states:\r\n\r\n>A server MUST NOT send a Transfer-Encoding... |
https://api.github.com/repos/psf/requests/issues/3793 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3793/labels{/name} | https://api.github.com/repos/psf/requests/issues/3793/comments | https://api.github.com/repos/psf/requests/issues/3793/events | https://github.com/psf/requests/issues/3793 | 198,000,030 | MDU6SXNzdWUxOTgwMDAwMzA= | 3,793 | Pyinstaller error with requests version > 2.11.1 | {
"avatar_url": "https://avatars.githubusercontent.com/u/12796536?v=4",
"events_url": "https://api.github.com/users/Sattar1/events{/privacy}",
"followers_url": "https://api.github.com/users/Sattar1/followers",
"following_url": "https://api.github.com/users/Sattar1/following{/other_user}",
"gists_url": "https://api.github.com/users/Sattar1/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Sattar1",
"id": 12796536,
"login": "Sattar1",
"node_id": "MDQ6VXNlcjEyNzk2NTM2",
"organizations_url": "https://api.github.com/users/Sattar1/orgs",
"received_events_url": "https://api.github.com/users/Sattar1/received_events",
"repos_url": "https://api.github.com/users/Sattar1/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Sattar1/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Sattar1/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Sattar1",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 2 | 2016-12-29T12:27:55Z | 2021-09-08T12:01:04Z | 2016-12-29T13:17:10Z | NONE | resolved | Hi
I am developing an application with python, using _requests_ library in it.
I make executable file with _pyinstaller_ library.
My application works with newest version of _requests_ when I run it through python commands or inside IDLE. But when I get EXE output with _pyinstaller_, It doesn't run correctly. Here is the message:
"
... (trace files)
ImportError: No module named 'queue'
During handling of the above exception, another exception occurred:
... (trace files)
ImportError: No module named 'urllib3'
Failed to execute script.
"
So I figured out that there is something wrong with _**urllib3**_ library. Then I downgraded _requests_ to "2.11.1" version (One before updating bundled urllib3 to 1.19) and created another EXE file. Rerun it, and worked!
Now I know that there is something wrong with newer versions of _requests_ (> 2.11.1) and _pyinstaller_. But don't know how to fix it. Could you plz help me?
Thanks. | {
"avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4",
"events_url": "https://api.github.com/users/Lukasa/events{/privacy}",
"followers_url": "https://api.github.com/users/Lukasa/followers",
"following_url": "https://api.github.com/users/Lukasa/following{/other_user}",
"gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Lukasa",
"id": 1382556,
"login": "Lukasa",
"node_id": "MDQ6VXNlcjEzODI1NTY=",
"organizations_url": "https://api.github.com/users/Lukasa/orgs",
"received_events_url": "https://api.github.com/users/Lukasa/received_events",
"repos_url": "https://api.github.com/users/Lukasa/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Lukasa",
"user_view_type": "public"
} | {
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/3793/reactions"
} | https://api.github.com/repos/psf/requests/issues/3793/timeline | null | completed | null | null | false | [
"This is strictly a PyInstaller issue. Requests works fine, and vendors all of its dependencies. Clearly PyInstaller is having trouble locating the dependent module, even though it is entirely within the Requests package. That problem is PyInstaller's, and you'll need to take it up with them.",
"This is caused by... |
https://api.github.com/repos/psf/requests/issues/3792 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3792/labels{/name} | https://api.github.com/repos/psf/requests/issues/3792/comments | https://api.github.com/repos/psf/requests/issues/3792/events | https://github.com/psf/requests/issues/3792 | 197,950,441 | MDU6SXNzdWUxOTc5NTA0NDE= | 3,792 | Invalid detection of utf-32-be | {
"avatar_url": "https://avatars.githubusercontent.com/u/5925982?v=4",
"events_url": "https://api.github.com/users/evgen231/events{/privacy}",
"followers_url": "https://api.github.com/users/evgen231/followers",
"following_url": "https://api.github.com/users/evgen231/following{/other_user}",
"gists_url": "https://api.github.com/users/evgen231/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/evgen231",
"id": 5925982,
"login": "evgen231",
"node_id": "MDQ6VXNlcjU5MjU5ODI=",
"organizations_url": "https://api.github.com/users/evgen231/orgs",
"received_events_url": "https://api.github.com/users/evgen231/received_events",
"repos_url": "https://api.github.com/users/evgen231/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/evgen231/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/evgen231/subscriptions",
"type": "User",
"url": "https://api.github.com/users/evgen231",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 0 | 2016-12-29T04:03:23Z | 2021-09-08T13:05:35Z | 2016-12-29T13:28:08Z | CONTRIBUTOR | resolved | ```python
import requests
requests.get('http://localhost/example.json').json()
```
```
Traceback (most recent call last):
File "example.py", line 3, in <module>
requests.get('http://localhost/example.json').json()
File "/usr/lib/python3.6/site-packages/requests/models.py", line 850, in json
return complexjson.loads(self.text, **kwargs)
File "/usr/lib/python3.6/json/__init__.py", line 344, in loads
s, 0)
json.decoder.JSONDecodeError: Unexpected UTF-8 BOM (decode using utf-8-sig): line 1 column 1 (char 0)
```
```
# wget --server-response http://localhost/example.json
--2016-12-29 10:49:23-- http://localhost/example.json
Resolving localhost (localhost)... 127.0.0.1
Connecting to localhost (localhost)|127.0.0.1|:80... connected.
HTTP request sent, awaiting response...
HTTP/1.1 200 OK
Date: Thu, 29 Dec 2016 03:51:03 GMT
Server: Apache/2.4.10 (Debian)
Last-Modified: Thu, 29 Dec 2016 03:42:32 GMT
ETag: "c-544c3e019ba33"
Accept-Ranges: bytes
Content-Length: 12
Keep-Alive: timeout=5, max=100
Connection: Keep-Alive
Content-Type: application/json
Length: 12 [application/json]
```
http://localhost/example.json is file encoded with utf-32-be.
```json
{}
```
Fix #3791 | {
"avatar_url": "https://avatars.githubusercontent.com/u/5925982?v=4",
"events_url": "https://api.github.com/users/evgen231/events{/privacy}",
"followers_url": "https://api.github.com/users/evgen231/followers",
"following_url": "https://api.github.com/users/evgen231/following{/other_user}",
"gists_url": "https://api.github.com/users/evgen231/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/evgen231",
"id": 5925982,
"login": "evgen231",
"node_id": "MDQ6VXNlcjU5MjU5ODI=",
"organizations_url": "https://api.github.com/users/evgen231/orgs",
"received_events_url": "https://api.github.com/users/evgen231/received_events",
"repos_url": "https://api.github.com/users/evgen231/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/evgen231/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/evgen231/subscriptions",
"type": "User",
"url": "https://api.github.com/users/evgen231",
"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/3792/reactions"
} | https://api.github.com/repos/psf/requests/issues/3792/timeline | null | completed | null | null | false | [] |
https://api.github.com/repos/psf/requests/issues/3791 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3791/labels{/name} | https://api.github.com/repos/psf/requests/issues/3791/comments | https://api.github.com/repos/psf/requests/issues/3791/events | https://github.com/psf/requests/pull/3791 | 197,947,895 | MDExOlB1bGxSZXF1ZXN0OTk2MTQ4NzQ= | 3,791 | Fixed detection of utf-32-be by BOM. | {
"avatar_url": "https://avatars.githubusercontent.com/u/5925982?v=4",
"events_url": "https://api.github.com/users/evgen231/events{/privacy}",
"followers_url": "https://api.github.com/users/evgen231/followers",
"following_url": "https://api.github.com/users/evgen231/following{/other_user}",
"gists_url": "https://api.github.com/users/evgen231/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/evgen231",
"id": 5925982,
"login": "evgen231",
"node_id": "MDQ6VXNlcjU5MjU5ODI=",
"organizations_url": "https://api.github.com/users/evgen231/orgs",
"received_events_url": "https://api.github.com/users/evgen231/received_events",
"repos_url": "https://api.github.com/users/evgen231/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/evgen231/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/evgen231/subscriptions",
"type": "User",
"url": "https://api.github.com/users/evgen231",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 1 | 2016-12-29T03:24:28Z | 2021-09-08T01:21:28Z | 2016-12-29T09:41:24Z | CONTRIBUTOR | resolved | {
"avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4",
"events_url": "https://api.github.com/users/Lukasa/events{/privacy}",
"followers_url": "https://api.github.com/users/Lukasa/followers",
"following_url": "https://api.github.com/users/Lukasa/following{/other_user}",
"gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Lukasa",
"id": 1382556,
"login": "Lukasa",
"node_id": "MDQ6VXNlcjEzODI1NTY=",
"organizations_url": "https://api.github.com/users/Lukasa/orgs",
"received_events_url": "https://api.github.com/users/Lukasa/received_events",
"repos_url": "https://api.github.com/users/Lukasa/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Lukasa",
"user_view_type": "public"
} | {
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/3791/reactions"
} | https://api.github.com/repos/psf/requests/issues/3791/timeline | null | null | false | {
"diff_url": "https://github.com/psf/requests/pull/3791.diff",
"html_url": "https://github.com/psf/requests/pull/3791",
"merged_at": "2016-12-29T09:41:24Z",
"patch_url": "https://github.com/psf/requests/pull/3791.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/3791"
} | true | [
"Thanks so much!"
] | |
https://api.github.com/repos/psf/requests/issues/3790 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3790/labels{/name} | https://api.github.com/repos/psf/requests/issues/3790/comments | https://api.github.com/repos/psf/requests/issues/3790/events | https://github.com/psf/requests/issues/3790 | 197,942,525 | MDU6SXNzdWUxOTc5NDI1MjU= | 3,790 | Module boot extremely slow (2-3 seconds) | {
"avatar_url": "https://avatars.githubusercontent.com/u/1411897?v=4",
"events_url": "https://api.github.com/users/djbaldey/events{/privacy}",
"followers_url": "https://api.github.com/users/djbaldey/followers",
"following_url": "https://api.github.com/users/djbaldey/following{/other_user}",
"gists_url": "https://api.github.com/users/djbaldey/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/djbaldey",
"id": 1411897,
"login": "djbaldey",
"node_id": "MDQ6VXNlcjE0MTE4OTc=",
"organizations_url": "https://api.github.com/users/djbaldey/orgs",
"received_events_url": "https://api.github.com/users/djbaldey/received_events",
"repos_url": "https://api.github.com/users/djbaldey/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/djbaldey/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/djbaldey/subscriptions",
"type": "User",
"url": "https://api.github.com/users/djbaldey",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 12 | 2016-12-29T02:02:35Z | 2021-09-08T13:05:34Z | 2017-01-04T04:57:09Z | NONE | resolved | On GNU/Debian 8, AMD Phenom 9550 Quad-Core Processor, 8Gb DDR2, Python 2.7.9/3.4.2
requests version 2.12.4 from PyPi
This is due to the following code in the `__init__.py` file:
```
# Attempt to enable urllib3's SNI support, if possible
try:
from .packages.urllib3.contrib import pyopenssl
pyopenssl.inject_into_urllib3()
except ImportError:
pass
```
After I commented out this code, the time was reduced to 0.05 seconds.
Whether this test is necessary for all users?
You may want to remove the code?
| {
"avatar_url": "https://avatars.githubusercontent.com/u/1411897?v=4",
"events_url": "https://api.github.com/users/djbaldey/events{/privacy}",
"followers_url": "https://api.github.com/users/djbaldey/followers",
"following_url": "https://api.github.com/users/djbaldey/following{/other_user}",
"gists_url": "https://api.github.com/users/djbaldey/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/djbaldey",
"id": 1411897,
"login": "djbaldey",
"node_id": "MDQ6VXNlcjE0MTE4OTc=",
"organizations_url": "https://api.github.com/users/djbaldey/orgs",
"received_events_url": "https://api.github.com/users/djbaldey/received_events",
"repos_url": "https://api.github.com/users/djbaldey/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/djbaldey/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/djbaldey/subscriptions",
"type": "User",
"url": "https://api.github.com/users/djbaldey",
"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/3790/reactions"
} | https://api.github.com/repos/psf/requests/issues/3790/timeline | null | completed | null | null | false | [
"@djbaldey This code optionally injects the PyOpenSSL based TLS backend into Requests. It's extremely useful because in many cases it enables support of advanced features that the standard library TLS module does not support. For this reason, we always attempt to inject it, as this is the most reliably way to detec... |
https://api.github.com/repos/psf/requests/issues/3789 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3789/labels{/name} | https://api.github.com/repos/psf/requests/issues/3789/comments | https://api.github.com/repos/psf/requests/issues/3789/events | https://github.com/psf/requests/pull/3789 | 197,403,344 | MDExOlB1bGxSZXF1ZXN0OTkyNjUxMzM= | 3,789 | 3780: Lazy load idna library | {
"avatar_url": "https://avatars.githubusercontent.com/u/5230880?v=4",
"events_url": "https://api.github.com/users/moin18/events{/privacy}",
"followers_url": "https://api.github.com/users/moin18/followers",
"following_url": "https://api.github.com/users/moin18/following{/other_user}",
"gists_url": "https://api.github.com/users/moin18/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/moin18",
"id": 5230880,
"login": "moin18",
"node_id": "MDQ6VXNlcjUyMzA4ODA=",
"organizations_url": "https://api.github.com/users/moin18/orgs",
"received_events_url": "https://api.github.com/users/moin18/received_events",
"repos_url": "https://api.github.com/users/moin18/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/moin18/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/moin18/subscriptions",
"type": "User",
"url": "https://api.github.com/users/moin18",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 7 | 2016-12-23T17:21:43Z | 2021-09-07T00:06:42Z | 2017-01-19T09:19:00Z | CONTRIBUTOR | resolved | Changes based on comment from previous Pull Request: https://github.com/kennethreitz/requests/pull/3787
Fix for issue: https://github.com/kennethreitz/requests/issues/3780
| {
"avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4",
"events_url": "https://api.github.com/users/Lukasa/events{/privacy}",
"followers_url": "https://api.github.com/users/Lukasa/followers",
"following_url": "https://api.github.com/users/Lukasa/following{/other_user}",
"gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Lukasa",
"id": 1382556,
"login": "Lukasa",
"node_id": "MDQ6VXNlcjEzODI1NTY=",
"organizations_url": "https://api.github.com/users/Lukasa/orgs",
"received_events_url": "https://api.github.com/users/Lukasa/received_events",
"repos_url": "https://api.github.com/users/Lukasa/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Lukasa",
"user_view_type": "public"
} | {
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/3789/reactions"
} | https://api.github.com/repos/psf/requests/issues/3789/timeline | null | null | false | {
"diff_url": "https://github.com/psf/requests/pull/3789.diff",
"html_url": "https://github.com/psf/requests/pull/3789",
"merged_at": "2017-01-19T09:19:00Z",
"patch_url": "https://github.com/psf/requests/pull/3789.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/3789"
} | true | [
"@Lukasa Please let me know your thought on this. I think it should address your concern in my previous Pull Request.",
"@sigmavirus24 Not sure why it is showing the status as \"Changes requested\" even though they are fixed in commit: https://github.com/kennethreitz/requests/pull/3789/commits/965eb3d1525e3d3846... |
https://api.github.com/repos/psf/requests/issues/3788 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3788/labels{/name} | https://api.github.com/repos/psf/requests/issues/3788/comments | https://api.github.com/repos/psf/requests/issues/3788/events | https://github.com/psf/requests/issues/3788 | 197,376,970 | MDU6SXNzdWUxOTczNzY5NzA= | 3,788 | Exceptions having references to urllib3 exceptions in "message" field | {
"avatar_url": "https://avatars.githubusercontent.com/u/290258?v=4",
"events_url": "https://api.github.com/users/rabbbit/events{/privacy}",
"followers_url": "https://api.github.com/users/rabbbit/followers",
"following_url": "https://api.github.com/users/rabbbit/following{/other_user}",
"gists_url": "https://api.github.com/users/rabbbit/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/rabbbit",
"id": 290258,
"login": "rabbbit",
"node_id": "MDQ6VXNlcjI5MDI1OA==",
"organizations_url": "https://api.github.com/users/rabbbit/orgs",
"received_events_url": "https://api.github.com/users/rabbbit/received_events",
"repos_url": "https://api.github.com/users/rabbbit/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/rabbbit/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/rabbbit/subscriptions",
"type": "User",
"url": "https://api.github.com/users/rabbbit",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 13 | 2016-12-23T14:20:05Z | 2021-11-26T05:00:32Z | 2021-08-28T04:20:47Z | NONE | resolved | Hey,
tldr; is exceptions keeping references to urllib3 exceptions a design choice?
I ran an issue when trying to automatically serialise `TimeoutError.message`. It appears it contains a reference to urllib3 exceptions:
```python
>>> try:
... requests.get('http://google.com', timeout=0.05)
... except Exception as e:
pass
>>> e.message
ReadTimeoutError("HTTPConnectionPool(host='www.google.pl', port=80): Read timed out. (read timeout=0.05)",)
>>> e.message.__class__
<class 'requests.packages.urllib3.exceptions.ReadTimeoutError'>
```
Which is inline with I see in [in the source](https://github.com/kennethreitz/requests/blob/master/requests/adapters.py#L499)
```python
elif isinstance(e, ReadTimeoutError):
raise ReadTimeout(e, request=request)
```
but I wasn't expecting this.
[Python docs](https://docs.python.org/2/library/exceptions.html#exceptions.BaseException) say:
> The tuple of arguments given to the exception constructor. Some built-in exceptions (like IOError) expect a certain number of arguments and assign a special meaning to the elements of this tuple, while others are usually called only with a single string giving an error message.
Given the above I was expecting either:
1. `message` to be a string ( per typical use case )
2. `message` to be `None` and `errno` and `strerror` being set: ( because [Request exceptions extend IOError](https://github.com/kennethreitz/requests/blob/master/requests/exceptions.py#L12) and [IOError having a specific constructor defined](https://docs.python.org/2/library/exceptions.html#exceptions.EnvironmentError) )
Was the current implementation a conscious decision? If not, what would be your preference, option (1) or (2) from the above?
(2) seems more correct, (1) seems simpler.
Happy to try to PR.
Thanks! | {
"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/3788/reactions"
} | https://api.github.com/repos/psf/requests/issues/3788/timeline | null | completed | null | null | false | [
"Yes, keeping references to urllib3 exceptions is a deliberate design decision. It ensures that low-level causes of high-level problems can be accurately diagnosed without relying on Python 3 exception chaining, which has not historically existed and continues to not exist on Python 2.\r\n\r\nI am pretty disincline... |
https://api.github.com/repos/psf/requests/issues/3787 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3787/labels{/name} | https://api.github.com/repos/psf/requests/issues/3787/comments | https://api.github.com/repos/psf/requests/issues/3787/events | https://github.com/psf/requests/pull/3787 | 197,285,230 | MDExOlB1bGxSZXF1ZXN0OTkxODM3MTc= | 3,787 | Lazy load idna to free memory | {
"avatar_url": "https://avatars.githubusercontent.com/u/5230880?v=4",
"events_url": "https://api.github.com/users/moin18/events{/privacy}",
"followers_url": "https://api.github.com/users/moin18/followers",
"following_url": "https://api.github.com/users/moin18/following{/other_user}",
"gists_url": "https://api.github.com/users/moin18/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/moin18",
"id": 5230880,
"login": "moin18",
"node_id": "MDQ6VXNlcjUyMzA4ODA=",
"organizations_url": "https://api.github.com/users/moin18/orgs",
"received_events_url": "https://api.github.com/users/moin18/received_events",
"repos_url": "https://api.github.com/users/moin18/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/moin18/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/moin18/subscriptions",
"type": "User",
"url": "https://api.github.com/users/moin18",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 5 | 2016-12-22T23:07:33Z | 2021-09-08T01:21:29Z | 2016-12-23T13:52:43Z | CONTRIBUTOR | resolved | Fix for issue: https://github.com/kennethreitz/requests/issues/3780
Lazily loading `idna`. This CR includes utilities to:
* lazily load idna package
* And, delete module from sys.modules after use
Changes looks to work fine for me. Now, None of the reference to `idna` is getting used directly. GC will release the memory when required. | {
"avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4",
"events_url": "https://api.github.com/users/Lukasa/events{/privacy}",
"followers_url": "https://api.github.com/users/Lukasa/followers",
"following_url": "https://api.github.com/users/Lukasa/following{/other_user}",
"gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Lukasa",
"id": 1382556,
"login": "Lukasa",
"node_id": "MDQ6VXNlcjEzODI1NTY=",
"organizations_url": "https://api.github.com/users/Lukasa/orgs",
"received_events_url": "https://api.github.com/users/Lukasa/received_events",
"repos_url": "https://api.github.com/users/Lukasa/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Lukasa",
"user_view_type": "public"
} | {
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/3787/reactions"
} | https://api.github.com/repos/psf/requests/issues/3787/timeline | null | null | false | {
"diff_url": "https://github.com/psf/requests/pull/3787.diff",
"html_url": "https://github.com/psf/requests/pull/3787",
"merged_at": null,
"patch_url": "https://github.com/psf/requests/pull/3787.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/3787"
} | true | [
"I think it will be a better idea to create a separate package to lazy load module and add that package as the part of both `urllib3` and `requests` package",
"urllib3 does not vendor idna, so such a package cannot really be easily shared. ",
"Additionally, Requests does not carry patches to urllib3: it vendors... |
https://api.github.com/repos/psf/requests/issues/3786 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3786/labels{/name} | https://api.github.com/repos/psf/requests/issues/3786/comments | https://api.github.com/repos/psf/requests/issues/3786/events | https://github.com/psf/requests/issues/3786 | 197,231,914 | MDU6SXNzdWUxOTcyMzE5MTQ= | 3,786 | plus character in url not working | {
"avatar_url": "https://avatars.githubusercontent.com/u/24253794?v=4",
"events_url": "https://api.github.com/users/Andriuskislas/events{/privacy}",
"followers_url": "https://api.github.com/users/Andriuskislas/followers",
"following_url": "https://api.github.com/users/Andriuskislas/following{/other_user}",
"gists_url": "https://api.github.com/users/Andriuskislas/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Andriuskislas",
"id": 24253794,
"login": "Andriuskislas",
"node_id": "MDQ6VXNlcjI0MjUzNzk0",
"organizations_url": "https://api.github.com/users/Andriuskislas/orgs",
"received_events_url": "https://api.github.com/users/Andriuskislas/received_events",
"repos_url": "https://api.github.com/users/Andriuskislas/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Andriuskislas/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Andriuskislas/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Andriuskislas",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 5 | 2016-12-22T18:02:12Z | 2021-09-08T13:05:36Z | 2016-12-23T01:36:34Z | NONE | resolved | My url is like this
` http://api.example.com/user/jhon+doe?field=full&key=somestring `
After I making request, when I print the url , I only get `http://api.example.com/user/jhon` which is incorrect and it's return error from api.
How can I request url with plus character? | {
"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/3786/reactions"
} | https://api.github.com/repos/psf/requests/issues/3786/timeline | null | completed | null | null | false | [
"My guess is that the issue is not with the library but your api. Your api is not able to translate `+` into valid user",
"Hey @Andriuskislas, thanks for opening this ticket. I can't seem to reproduce the path dropping in 2.12.4 with the information supplied above. However, I think I have an idea of what you're h... |
https://api.github.com/repos/psf/requests/issues/3785 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3785/labels{/name} | https://api.github.com/repos/psf/requests/issues/3785/comments | https://api.github.com/repos/psf/requests/issues/3785/events | https://github.com/psf/requests/pull/3785 | 196,993,536 | MDExOlB1bGxSZXF1ZXN0OTg5NzY0NTE= | 3,785 | fix urllib3 documentation link | {
"avatar_url": "https://avatars.githubusercontent.com/u/3793595?v=4",
"events_url": "https://api.github.com/users/Adusei/events{/privacy}",
"followers_url": "https://api.github.com/users/Adusei/followers",
"following_url": "https://api.github.com/users/Adusei/following{/other_user}",
"gists_url": "https://api.github.com/users/Adusei/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Adusei",
"id": 3793595,
"login": "Adusei",
"node_id": "MDQ6VXNlcjM3OTM1OTU=",
"organizations_url": "https://api.github.com/users/Adusei/orgs",
"received_events_url": "https://api.github.com/users/Adusei/received_events",
"repos_url": "https://api.github.com/users/Adusei/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Adusei/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Adusei/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Adusei",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 6 | 2016-12-21T17:48:57Z | 2021-09-08T01:21:28Z | 2016-12-21T18:08:46Z | CONTRIBUTOR | resolved | The link to urllib3 documentation in the appengine warning message shows " SORRY This page does not exist yet."
This PR fixes the documentation link. | {
"avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4",
"events_url": "https://api.github.com/users/Lukasa/events{/privacy}",
"followers_url": "https://api.github.com/users/Lukasa/followers",
"following_url": "https://api.github.com/users/Lukasa/following{/other_user}",
"gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Lukasa",
"id": 1382556,
"login": "Lukasa",
"node_id": "MDQ6VXNlcjEzODI1NTY=",
"organizations_url": "https://api.github.com/users/Lukasa/orgs",
"received_events_url": "https://api.github.com/users/Lukasa/received_events",
"repos_url": "https://api.github.com/users/Lukasa/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Lukasa",
"user_view_type": "public"
} | {
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/3785/reactions"
} | https://api.github.com/repos/psf/requests/issues/3785/timeline | null | null | false | {
"diff_url": "https://github.com/psf/requests/pull/3785.diff",
"html_url": "https://github.com/psf/requests/pull/3785",
"merged_at": "2016-12-21T18:08:46Z",
"patch_url": "https://github.com/psf/requests/pull/3785.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/3785"
} | true | [
"Thanks for the patch!",
"@Lukasa it looks like this is a modification in the appengine module in urllib3. The warning update may need to go over there, otherwise we'll overwrite it the next time we update urllib3.",
"Agh good spot, I missed that. Can we open a new patch on urllib3 that DTRT?",
"@Adusei would... |
https://api.github.com/repos/psf/requests/issues/3784 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3784/labels{/name} | https://api.github.com/repos/psf/requests/issues/3784/comments | https://api.github.com/repos/psf/requests/issues/3784/events | https://github.com/psf/requests/issues/3784 | 196,981,015 | MDU6SXNzdWUxOTY5ODEwMTU= | 3,784 | SSL context | {
"avatar_url": "https://avatars.githubusercontent.com/u/12953712?v=4",
"events_url": "https://api.github.com/users/AlmightyOatmeal/events{/privacy}",
"followers_url": "https://api.github.com/users/AlmightyOatmeal/followers",
"following_url": "https://api.github.com/users/AlmightyOatmeal/following{/other_user}",
"gists_url": "https://api.github.com/users/AlmightyOatmeal/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/AlmightyOatmeal",
"id": 12953712,
"login": "AlmightyOatmeal",
"node_id": "MDQ6VXNlcjEyOTUzNzEy",
"organizations_url": "https://api.github.com/users/AlmightyOatmeal/orgs",
"received_events_url": "https://api.github.com/users/AlmightyOatmeal/received_events",
"repos_url": "https://api.github.com/users/AlmightyOatmeal/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/AlmightyOatmeal/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/AlmightyOatmeal/subscriptions",
"type": "User",
"url": "https://api.github.com/users/AlmightyOatmeal",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 3 | 2016-12-21T16:52:08Z | 2021-09-08T13:05:37Z | 2016-12-21T17:11:58Z | NONE | resolved | In some instances, requests is used to access services via SSL that disable TLS v1.0 for security reasons but there is no way to configure what SSL/TLS versions are acceptable nor pass in a SSL context. This is very disappointing.
For example, I *need* to be able to create this context and use it, but I can't...
```
import ssl
context = ssl.SSLContext(ssl.PROTOCOL_SSLv23)
context.options |= ssl.OP_NO_TLSv1
``` | {
"avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4",
"events_url": "https://api.github.com/users/Lukasa/events{/privacy}",
"followers_url": "https://api.github.com/users/Lukasa/followers",
"following_url": "https://api.github.com/users/Lukasa/following{/other_user}",
"gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Lukasa",
"id": 1382556,
"login": "Lukasa",
"node_id": "MDQ6VXNlcjEzODI1NTY=",
"organizations_url": "https://api.github.com/users/Lukasa/orgs",
"received_events_url": "https://api.github.com/users/Lukasa/received_events",
"repos_url": "https://api.github.com/users/Lukasa/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Lukasa",
"user_view_type": "public"
} | {
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/3784/reactions"
} | https://api.github.com/repos/psf/requests/issues/3784/timeline | null | completed | null | null | false | [
"Thanks for this report!\r\n\r\nFirstly, services that disable TLSv1 should still be compatible with Requests. Requests advertises support for all TLS versions higher than SSLv3 in the default configuration, so services should simply choose TLSv1.2. Requests will happily do that. \r\n\r\nSecondly, you absolutely ca... |
https://api.github.com/repos/psf/requests/issues/3783 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3783/labels{/name} | https://api.github.com/repos/psf/requests/issues/3783/comments | https://api.github.com/repos/psf/requests/issues/3783/events | https://github.com/psf/requests/pull/3783 | 196,939,612 | MDExOlB1bGxSZXF1ZXN0OTg5Mzc0MTk= | 3,783 | Closes #3780 High memory usage due to idma import | {
"avatar_url": "https://avatars.githubusercontent.com/u/5230880?v=4",
"events_url": "https://api.github.com/users/moin18/events{/privacy}",
"followers_url": "https://api.github.com/users/moin18/followers",
"following_url": "https://api.github.com/users/moin18/following{/other_user}",
"gists_url": "https://api.github.com/users/moin18/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/moin18",
"id": 5230880,
"login": "moin18",
"node_id": "MDQ6VXNlcjUyMzA4ODA=",
"organizations_url": "https://api.github.com/users/moin18/orgs",
"received_events_url": "https://api.github.com/users/moin18/received_events",
"repos_url": "https://api.github.com/users/moin18/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/moin18/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/moin18/subscriptions",
"type": "User",
"url": "https://api.github.com/users/moin18",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 5 | 2016-12-21T14:00:00Z | 2021-09-08T01:21:29Z | 2016-12-21T14:06:29Z | CONTRIBUTOR | resolved | {
"avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4",
"events_url": "https://api.github.com/users/Lukasa/events{/privacy}",
"followers_url": "https://api.github.com/users/Lukasa/followers",
"following_url": "https://api.github.com/users/Lukasa/following{/other_user}",
"gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Lukasa",
"id": 1382556,
"login": "Lukasa",
"node_id": "MDQ6VXNlcjEzODI1NTY=",
"organizations_url": "https://api.github.com/users/Lukasa/orgs",
"received_events_url": "https://api.github.com/users/Lukasa/received_events",
"repos_url": "https://api.github.com/users/Lukasa/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Lukasa",
"user_view_type": "public"
} | {
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/3783/reactions"
} | https://api.github.com/repos/psf/requests/issues/3783/timeline | null | null | false | {
"diff_url": "https://github.com/psf/requests/pull/3783.diff",
"html_url": "https://github.com/psf/requests/pull/3783",
"merged_at": null,
"patch_url": "https://github.com/psf/requests/pull/3783.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/3783"
} | true | [
"Because of how Python imports work, this also will not have any effect. Specifically, `from x import y` is approximately the same as `import x; y = x.y`. I'm afraid we need a better solution than even this. \r\n\r\nSorry!",
"By better solution do you mean the changes in: `idna/core.py` that is imported by `__ini... | |
https://api.github.com/repos/psf/requests/issues/3782 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3782/labels{/name} | https://api.github.com/repos/psf/requests/issues/3782/comments | https://api.github.com/repos/psf/requests/issues/3782/events | https://github.com/psf/requests/pull/3782 | 196,925,645 | MDExOlB1bGxSZXF1ZXN0OTg5Mjc0Mzk= | 3,782 | Closes ##3780 High memory usage due to idma import | {
"avatar_url": "https://avatars.githubusercontent.com/u/5230880?v=4",
"events_url": "https://api.github.com/users/moin18/events{/privacy}",
"followers_url": "https://api.github.com/users/moin18/followers",
"following_url": "https://api.github.com/users/moin18/following{/other_user}",
"gists_url": "https://api.github.com/users/moin18/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/moin18",
"id": 5230880,
"login": "moin18",
"node_id": "MDQ6VXNlcjUyMzA4ODA=",
"organizations_url": "https://api.github.com/users/moin18/orgs",
"received_events_url": "https://api.github.com/users/moin18/received_events",
"repos_url": "https://api.github.com/users/moin18/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/moin18/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/moin18/subscriptions",
"type": "User",
"url": "https://api.github.com/users/moin18",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 2 | 2016-12-21T12:51:52Z | 2021-09-08T01:21:30Z | 2016-12-21T13:41:20Z | CONTRIBUTOR | resolved | Fix related to bug: https://github.com/kennethreitz/requests/issues/3780
`idma` package will now be imported within the function | {
"avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4",
"events_url": "https://api.github.com/users/Lukasa/events{/privacy}",
"followers_url": "https://api.github.com/users/Lukasa/followers",
"following_url": "https://api.github.com/users/Lukasa/following{/other_user}",
"gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Lukasa",
"id": 1382556,
"login": "Lukasa",
"node_id": "MDQ6VXNlcjEzODI1NTY=",
"organizations_url": "https://api.github.com/users/Lukasa/orgs",
"received_events_url": "https://api.github.com/users/Lukasa/received_events",
"repos_url": "https://api.github.com/users/Lukasa/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Lukasa",
"user_view_type": "public"
} | {
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/3782/reactions"
} | https://api.github.com/repos/psf/requests/issues/3782/timeline | null | null | false | {
"diff_url": "https://github.com/psf/requests/pull/3782.diff",
"html_url": "https://github.com/psf/requests/pull/3782",
"merged_at": null,
"patch_url": "https://github.com/psf/requests/pull/3782.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/3782"
} | true | [
"Thanks for this!\r\n\r\nHowever, this patch does not meaningfully reduce the memory usage. Any use of Requests will encounter this branch immediately and unconditionally, meaning that in practice all that we have done is delay the loading of the module. I think we need a better solution than this one.",
"How abo... |
https://api.github.com/repos/psf/requests/issues/3781 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3781/labels{/name} | https://api.github.com/repos/psf/requests/issues/3781/comments | https://api.github.com/repos/psf/requests/issues/3781/events | https://github.com/psf/requests/pull/3781 | 196,854,401 | MDExOlB1bGxSZXF1ZXN0OTg4Nzc1Njc= | 3,781 | updating idna.uts46data from upstream project | {
"avatar_url": "https://avatars.githubusercontent.com/u/1094627?v=4",
"events_url": "https://api.github.com/users/mplonka/events{/privacy}",
"followers_url": "https://api.github.com/users/mplonka/followers",
"following_url": "https://api.github.com/users/mplonka/following{/other_user}",
"gists_url": "https://api.github.com/users/mplonka/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/mplonka",
"id": 1094627,
"login": "mplonka",
"node_id": "MDQ6VXNlcjEwOTQ2Mjc=",
"organizations_url": "https://api.github.com/users/mplonka/orgs",
"received_events_url": "https://api.github.com/users/mplonka/received_events",
"repos_url": "https://api.github.com/users/mplonka/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/mplonka/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/mplonka/subscriptions",
"type": "User",
"url": "https://api.github.com/users/mplonka",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 8 | 2016-12-21T06:10:53Z | 2021-09-07T00:06:42Z | 2016-12-21T15:59:35Z | CONTRIBUTOR | resolved | {
"avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4",
"events_url": "https://api.github.com/users/Lukasa/events{/privacy}",
"followers_url": "https://api.github.com/users/Lukasa/followers",
"following_url": "https://api.github.com/users/Lukasa/following{/other_user}",
"gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Lukasa",
"id": 1382556,
"login": "Lukasa",
"node_id": "MDQ6VXNlcjEzODI1NTY=",
"organizations_url": "https://api.github.com/users/Lukasa/orgs",
"received_events_url": "https://api.github.com/users/Lukasa/received_events",
"repos_url": "https://api.github.com/users/Lukasa/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Lukasa",
"user_view_type": "public"
} | {
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/3781/reactions"
} | https://api.github.com/repos/psf/requests/issues/3781/timeline | null | null | false | {
"diff_url": "https://github.com/psf/requests/pull/3781.diff",
"html_url": "https://github.com/psf/requests/pull/3781",
"merged_at": "2016-12-21T15:59:35Z",
"patch_url": "https://github.com/psf/requests/pull/3781.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/3781"
} | true | [
"This is meant to include https://github.com/kjd/idna/pull/33 which will fix https://github.com/kennethreitz/requests/issues/3711.\r\n\r\nThe patch was done by running `make idna`. Also patching Makefile itself, removing `sed` invocation, which isn't necessary anymore.",
"Thanks for this patch @mplonka. However, ... | |
https://api.github.com/repos/psf/requests/issues/3780 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3780/labels{/name} | https://api.github.com/repos/psf/requests/issues/3780/comments | https://api.github.com/repos/psf/requests/issues/3780/events | https://github.com/psf/requests/issues/3780 | 196,773,876 | MDU6SXNzdWUxOTY3NzM4NzY= | 3,780 | idna package increases memory usage by ~20MB | {
"avatar_url": "https://avatars.githubusercontent.com/u/2750246?v=4",
"events_url": "https://api.github.com/users/DanielGibbsNZ/events{/privacy}",
"followers_url": "https://api.github.com/users/DanielGibbsNZ/followers",
"following_url": "https://api.github.com/users/DanielGibbsNZ/following{/other_user}",
"gists_url": "https://api.github.com/users/DanielGibbsNZ/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/DanielGibbsNZ",
"id": 2750246,
"login": "DanielGibbsNZ",
"node_id": "MDQ6VXNlcjI3NTAyNDY=",
"organizations_url": "https://api.github.com/users/DanielGibbsNZ/orgs",
"received_events_url": "https://api.github.com/users/DanielGibbsNZ/received_events",
"repos_url": "https://api.github.com/users/DanielGibbsNZ/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/DanielGibbsNZ/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/DanielGibbsNZ/subscriptions",
"type": "User",
"url": "https://api.github.com/users/DanielGibbsNZ",
"user_view_type": "public"
} | [
{
"color": "0b02e1",
"default": false,
"description": null,
"id": 191274,
"name": "Contributor Friendly",
"node_id": "MDU6TGFiZWwxOTEyNzQ=",
"url": "https://api.github.com/repos/psf/requests/labels/Contributor%20Friendly"
}
] | closed | true | null | [] | null | 10 | 2016-12-20T20:32:35Z | 2021-09-08T12:01:09Z | 2017-01-24T12:25:00Z | NONE | resolved | I am running an Ubuntu 16.04.1 LTS machine with Python 3.5.2 which has about 40 Python scripts loaded, each one of which uses Requests. I recently updated Requests and suddenly found I was running out of memory.
Upon further investigation I discovered that as of version 2.12.0, the `idna` package has been included in requests and this has caused the memory consumption for each script to increase by about 20MB.
This can be observed with the following steps:
1. Install Requests version 2.11.1
2. Run `python3 -c "import requests; import time; time.sleep(60)" &`.
3. While the previous command is running, run `top` or `htop` and observe the resident memory usage of the command.
4. Install Requests version 2.12.0.
5. Repeat steps 2 and 3.
Is there any way that Requests could lazily load the idna library so that this extra 20MB of memory is only used when actually working with IDNA domains? | {
"avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4",
"events_url": "https://api.github.com/users/Lukasa/events{/privacy}",
"followers_url": "https://api.github.com/users/Lukasa/followers",
"following_url": "https://api.github.com/users/Lukasa/following{/other_user}",
"gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Lukasa",
"id": 1382556,
"login": "Lukasa",
"node_id": "MDQ6VXNlcjEzODI1NTY=",
"organizations_url": "https://api.github.com/users/Lukasa/orgs",
"received_events_url": "https://api.github.com/users/Lukasa/received_events",
"repos_url": "https://api.github.com/users/Lukasa/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Lukasa",
"user_view_type": "public"
} | {
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/3780/reactions"
} | https://api.github.com/repos/psf/requests/issues/3780/timeline | null | completed | null | null | false | [
"Yeah, requests could absolutely lazily import idna. Anyone who would like to can work on a patch to defer this import. =)",
"Just had a look at where `idna` is used (https://github.com/kennethreitz/requests/blob/7d2dfa86841fae49fa82f4f59098d5be862d1ba0/requests/models.py#L371) and it seems it's being used for ev... |
https://api.github.com/repos/psf/requests/issues/3779 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3779/labels{/name} | https://api.github.com/repos/psf/requests/issues/3779/comments | https://api.github.com/repos/psf/requests/issues/3779/events | https://github.com/psf/requests/issues/3779 | 196,734,596 | MDU6SXNzdWUxOTY3MzQ1OTY= | 3,779 | Move to travis | {
"avatar_url": "https://avatars.githubusercontent.com/u/119893?v=4",
"events_url": "https://api.github.com/users/kennethreitz/events{/privacy}",
"followers_url": "https://api.github.com/users/kennethreitz/followers",
"following_url": "https://api.github.com/users/kennethreitz/following{/other_user}",
"gists_url": "https://api.github.com/users/kennethreitz/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/kennethreitz",
"id": 119893,
"login": "kennethreitz",
"node_id": "MDQ6VXNlcjExOTg5Mw==",
"organizations_url": "https://api.github.com/users/kennethreitz/orgs",
"received_events_url": "https://api.github.com/users/kennethreitz/received_events",
"repos_url": "https://api.github.com/users/kennethreitz/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/kennethreitz/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/kennethreitz/subscriptions",
"type": "User",
"url": "https://api.github.com/users/kennethreitz",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 0 | 2016-12-20T17:39:38Z | 2021-09-08T13:05:38Z | 2016-12-21T07:07:03Z | CONTRIBUTOR | resolved | jenkins is enough of a headache to deal with, let's do this. | {
"avatar_url": "https://avatars.githubusercontent.com/u/119893?v=4",
"events_url": "https://api.github.com/users/kennethreitz/events{/privacy}",
"followers_url": "https://api.github.com/users/kennethreitz/followers",
"following_url": "https://api.github.com/users/kennethreitz/following{/other_user}",
"gists_url": "https://api.github.com/users/kennethreitz/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/kennethreitz",
"id": 119893,
"login": "kennethreitz",
"node_id": "MDQ6VXNlcjExOTg5Mw==",
"organizations_url": "https://api.github.com/users/kennethreitz/orgs",
"received_events_url": "https://api.github.com/users/kennethreitz/received_events",
"repos_url": "https://api.github.com/users/kennethreitz/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/kennethreitz/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/kennethreitz/subscriptions",
"type": "User",
"url": "https://api.github.com/users/kennethreitz",
"user_view_type": "public"
} | {
"+1": 1,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 1,
"laugh": 0,
"rocket": 0,
"total_count": 2,
"url": "https://api.github.com/repos/psf/requests/issues/3779/reactions"
} | https://api.github.com/repos/psf/requests/issues/3779/timeline | null | completed | null | null | false | [] |
https://api.github.com/repos/psf/requests/issues/3778 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3778/labels{/name} | https://api.github.com/repos/psf/requests/issues/3778/comments | https://api.github.com/repos/psf/requests/issues/3778/events | https://github.com/psf/requests/issues/3778 | 196,427,245 | MDU6SXNzdWUxOTY0MjcyNDU= | 3,778 | Handle Content in new tab | {
"avatar_url": "https://avatars.githubusercontent.com/u/18625267?v=4",
"events_url": "https://api.github.com/users/arunchandramouli/events{/privacy}",
"followers_url": "https://api.github.com/users/arunchandramouli/followers",
"following_url": "https://api.github.com/users/arunchandramouli/following{/other_user}",
"gists_url": "https://api.github.com/users/arunchandramouli/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/arunchandramouli",
"id": 18625267,
"login": "arunchandramouli",
"node_id": "MDQ6VXNlcjE4NjI1MjY3",
"organizations_url": "https://api.github.com/users/arunchandramouli/orgs",
"received_events_url": "https://api.github.com/users/arunchandramouli/received_events",
"repos_url": "https://api.github.com/users/arunchandramouli/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/arunchandramouli/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/arunchandramouli/subscriptions",
"type": "User",
"url": "https://api.github.com/users/arunchandramouli",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 3 | 2016-12-19T14:31:49Z | 2016-12-19T15:00:22Z | 2016-12-19T14:54:11Z | NONE | null | I tried to scrap report from https://www.theice.com/marketdata/reports/datawarehouse/ConsolidatedDailyVolumeOIReport.shtml?selectionForm=
We can find Report Date, Asset Class and a Submit button
When we hit submit it actually opens in a new Tab as
https://www.theice.com/marketdata/reports/datawarehouse/ConsolidatedDailyVolumeOIReport.shtm
I tried simulating POST, but it always says Session Time Out.
On Contrast if you could see
https://www.theice.com/marketdata/reports/175.
When you enter dates and hit submit, it opens but not in a new tab, in this case requests is able to get the data.
Is there any solution for this? Please suggest. | {
"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/3778/reactions"
} | https://api.github.com/repos/psf/requests/issues/3778/timeline | null | completed | null | null | false | [
"Questions belong on [StackOverflow](https://stackoverflow.com) using the [python-requests tag](http://stackoverflow.com/questions/tagged/python-requests) not in the defect/bug tracker.",
"But it's not working?",
"@arunchandramouli taking a quick look at those websites, it looks as if they require JavaScript in... |
https://api.github.com/repos/psf/requests/issues/3777 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3777/labels{/name} | https://api.github.com/repos/psf/requests/issues/3777/comments | https://api.github.com/repos/psf/requests/issues/3777/events | https://github.com/psf/requests/issues/3777 | 196,416,685 | MDU6SXNzdWUxOTY0MTY2ODU= | 3,777 | EOF occurred in violation of protocol | {
"avatar_url": "https://avatars.githubusercontent.com/u/961966?v=4",
"events_url": "https://api.github.com/users/ernestoalejo/events{/privacy}",
"followers_url": "https://api.github.com/users/ernestoalejo/followers",
"following_url": "https://api.github.com/users/ernestoalejo/following{/other_user}",
"gists_url": "https://api.github.com/users/ernestoalejo/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/ernestoalejo",
"id": 961966,
"login": "ernestoalejo",
"node_id": "MDQ6VXNlcjk2MTk2Ng==",
"organizations_url": "https://api.github.com/users/ernestoalejo/orgs",
"received_events_url": "https://api.github.com/users/ernestoalejo/received_events",
"repos_url": "https://api.github.com/users/ernestoalejo/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/ernestoalejo/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/ernestoalejo/subscriptions",
"type": "User",
"url": "https://api.github.com/users/ernestoalejo",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 8 | 2016-12-19T13:44:06Z | 2021-09-08T13:05:38Z | 2016-12-19T14:47:13Z | NONE | resolved | Related to issue #3774, but I preferred to open a new one just in case it's different.
The code:
```python
import requests
from requests.adapters import HTTPAdapter
from requests.packages.urllib3.util.ssl_ import create_urllib3_context
# This is the 2.11 Requests cipher string.
CIPHERS = (
'ECDH+AESGCM:DH+AESGCM:ECDH+AES256:DH+AES256:ECDH+AES128:DH+AES:ECDH+HIGH:'
'DH+HIGH:ECDH+3DES:DH+3DES:RSA+AESGCM:RSA+AES:RSA+HIGH:RSA+3DES:!aNULL:'
'!eNULL:!MD5'
)
class DESAdapter(HTTPAdapter):
def init_poolmanager(self, *args, **kwargs):
context = create_urllib3_context(ciphers=CIPHERS)
kwargs['ssl_context'] = context
return super(DESAdapter, self).init_poolmanager(*args, **kwargs)
s = requests.Session()
s.mount('https://XXX:25000/YYY', DESAdapter())
print s.post('https://XXX:25000/YYY', verify=False, timeout=10)
```
The exception:
```
Traceback (most recent call last):
File "test.py", line 22, in <module>
print s.post('https://XXX:25000/YYY', verify=False, timeout=10)
File "/home/ernesto/projects/test2/local/lib/python2.7/site-packages/requests/sessions.py", line 535, in post
return self.request('POST', url, data=data, json=json, **kwargs)
File "/home/ernesto/projects/test2/local/lib/python2.7/site-packages/requests/sessions.py", line 488, in request
resp = self.send(prep, **send_kwargs)
File "/home/ernesto/projects/test2/local/lib/python2.7/site-packages/requests/sessions.py", line 609, in send
r = adapter.send(request, **kwargs)
File "/home/ernesto/projects/test2/local/lib/python2.7/site-packages/requests/adapters.py", line 497, in send
raise SSLError(e, request=request)
requests.exceptions.SSLError: EOF occurred in violation of protocol (_ssl.c:590)
```
The issue seems related to #3774 because `curl` connects correctly but outputs this in verbose mode:
```
* SSL connection using TLS1.0 / RSA_3DES_EDE_CBC_SHA1
* server certificate verification SKIPPED
* server certificate status verification SKIPPED
```
Output of `pip freeze`:
```
pkg-resources==0.0.0
requests==2.12.4
```
Inside the Docker production container requests v2.11.1 is working right now and v2.12.0 not. I wanted to pinpoint exactly the commit to fill the issue but in my local virtualenv outside Docker every single version I'm trying raises the error and I can't start the git blame. I'll try to make a custom simplified container.
I wanted to confirm the issue is the 3DES cypher before asking the server operator to change it.
-----
If I install `requests[security]` the error changes to:
```
Traceback (most recent call last):
File "test.py", line 22, in <module>
print s.post('https://rol.othello.es:25000/BookingEngine', verify=False, timeout=10)
File "/home/ernesto/projects/test2/local/lib/python2.7/site-packages/requests/sessions.py", line 535, in post
return self.request('POST', url, data=data, json=json, **kwargs)
File "/home/ernesto/projects/test2/local/lib/python2.7/site-packages/requests/sessions.py", line 488, in request
resp = self.send(prep, **send_kwargs)
File "/home/ernesto/projects/test2/local/lib/python2.7/site-packages/requests/sessions.py", line 609, in send
r = adapter.send(request, **kwargs)
File "/home/ernesto/projects/test2/local/lib/python2.7/site-packages/requests/adapters.py", line 497, in send
raise SSLError(e, request=request)
requests.exceptions.SSLError: ("bad handshake: SysCallError(-1, 'Unexpected EOF')",)
```
and `pip freeze` changes to:
```
cffi==1.9.1
cryptography==1.7.1
enum34==1.1.6
idna==2.1
ipaddress==1.0.17
pkg-resources==0.0.0
pyasn1==0.1.9
pycparser==2.17
pyOpenSSL==16.2.0
requests==2.12.4
six==1.10.0
``` | {
"avatar_url": "https://avatars.githubusercontent.com/u/961966?v=4",
"events_url": "https://api.github.com/users/ernestoalejo/events{/privacy}",
"followers_url": "https://api.github.com/users/ernestoalejo/followers",
"following_url": "https://api.github.com/users/ernestoalejo/following{/other_user}",
"gists_url": "https://api.github.com/users/ernestoalejo/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/ernestoalejo",
"id": 961966,
"login": "ernestoalejo",
"node_id": "MDQ6VXNlcjk2MTk2Ng==",
"organizations_url": "https://api.github.com/users/ernestoalejo/orgs",
"received_events_url": "https://api.github.com/users/ernestoalejo/received_events",
"repos_url": "https://api.github.com/users/ernestoalejo/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/ernestoalejo/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/ernestoalejo/subscriptions",
"type": "User",
"url": "https://api.github.com/users/ernestoalejo",
"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/3777/reactions"
} | https://api.github.com/repos/psf/requests/issues/3777/timeline | null | completed | null | null | false | [
"I can now reproduce the issue correctly inside a simple Docker container, but after `git bisect` of course the commit introducing the error was this one: 99fa7becf263473c7bfc1998b41c2c6c80a0f499",
"It's extremely likely that 3DES is the problem, but I haven't been able to debug the DESAdapter I wrote because I'm... |
https://api.github.com/repos/psf/requests/issues/3776 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3776/labels{/name} | https://api.github.com/repos/psf/requests/issues/3776/comments | https://api.github.com/repos/psf/requests/issues/3776/events | https://github.com/psf/requests/issues/3776 | 196,354,090 | MDU6SXNzdWUxOTYzNTQwOTA= | 3,776 | Non-ASCII characters in `requests/cacerts.pem` file cause errors in Jython / IBM JVM | {
"avatar_url": "https://avatars.githubusercontent.com/u/1094627?v=4",
"events_url": "https://api.github.com/users/mplonka/events{/privacy}",
"followers_url": "https://api.github.com/users/mplonka/followers",
"following_url": "https://api.github.com/users/mplonka/following{/other_user}",
"gists_url": "https://api.github.com/users/mplonka/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/mplonka",
"id": 1094627,
"login": "mplonka",
"node_id": "MDQ6VXNlcjEwOTQ2Mjc=",
"organizations_url": "https://api.github.com/users/mplonka/orgs",
"received_events_url": "https://api.github.com/users/mplonka/received_events",
"repos_url": "https://api.github.com/users/mplonka/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/mplonka/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/mplonka/subscriptions",
"type": "User",
"url": "https://api.github.com/users/mplonka",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 3 | 2016-12-19T08:13:48Z | 2021-09-08T13:05:36Z | 2016-12-19T12:15:51Z | CONTRIBUTOR | resolved | When using requests with Jython running on of IBM JVM, accessing HTTPS endpoints fails with:
```
java.security.cert.CertificateException: Fail to parse input stream
```
Example code:
```python
import requests
r = requests.get('https://www.google.com/')
```
The problem occurs only with Jython and only when running on IBM JVMs. The exception is being thrown by IBM's implementation of `java.security.cert.CertificateFactory`:
```
certs = list(cf.generateCertificates(ByteArrayInputStream(f.read())))
at com.ibm.crypto.provider.X509Factory.b(Unknown Source)
at com.ibm.crypto.provider.X509Factory.engineGenerateCertificates(Unknown Source)
at java.security.cert.CertificateFactory.generateCertificates(CertificateFactory.java:448)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:95)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:55)
at java.lang.reflect.Method.invoke(Method.java:508)
```
It turns out that CertificateFactory in IBM JVMs is very strict when parsing PEM files and it does not allow non-ASCII characters at all, even in comments. After removing the following lines, everything works without issues:
```
[ 1949]: # Issuer: CN=TÜBİTAK UEKAE Kök Sertifika Hizmet Sağlayıcısı - Sürüm 3 O=Türkiye Bilimsel ve Teknolojik Araştırma Kurumu - TÜBİTAK OU=Ulusal Elektronik ve Kriptoloji Araştırma Enstitüsü - UEKAE/Kamu Sertifikasyon Merkezi
[ 1950]: # Subject: CN=TÜBİTAK UEKAE Kök Sertifika Hizmet Sağlayıcısı - Sürüm 3 O=Türkiye Bilimsel ve Teknolojik Araştırma Kurumu - TÜBİTAK OU=Ulusal Elektronik ve Kriptoloji Araştırma Enstitüsü - UEKAE/Kamu Sertifikasyon Merkezi
[ 2280]: # Issuer: CN=NetLock Arany (Class Gold) Főtanúsítvány O=NetLock Kft. OU=Tanúsítványkiadók (Certification Services)
[ 2281]: # Subject: CN=NetLock Arany (Class Gold) Főtanúsítvány O=NetLock Kft. OU=Tanúsítványkiadók (Certification Services)
[ 2282]: # Label: "NetLock Arany (Class Gold) Főtanúsítvány"
[ 2936]: # Issuer: CN=Certinomis - Autorité Racine O=Certinomis OU=0002 433998903
[ 2937]: # Subject: CN=Certinomis - Autorité Racine O=Certinomis OU=0002 433998903
[ 2938]: # Label: "Certinomis - Autorité Racine"
[ 3413]: # Issuer: CN=TÜRKTRUST Elektronik Sertifika Hizmet Sağlayıcısı O=TÜRKTRUST Bilgi İletişim ve Bilişim Güvenliği Hizmetleri A.Ş. (c) Aralık 2007
[ 3414]: # Subject: CN=TÜRKTRUST Elektronik Sertifika Hizmet Sağlayıcısı O=TÜRKTRUST Bilgi İletişim ve Bilişim Güvenliği Hizmetleri A.Ş. (c) Aralık 2007
[ 3896]: # Issuer: CN=E-Tugra Certification Authority O=E-Tuğra EBG Bilişim Teknolojileri ve Hizmetleri A.Ş. OU=E-Tugra Sertifikasyon Merkezi
[ 3897]: # Subject: CN=E-Tugra Certification Authority O=E-Tuğra EBG Bilişim Teknolojileri ve Hizmetleri A.Ş. OU=E-Tugra Sertifikasyon Merkezi
[ 4303]: # Issuer: CN=CA 沃通根证书 O=WoSign CA Limited
[ 4304]: # Subject: CN=CA 沃通根证书 O=WoSign CA Limited
[ 4750]: # Issuer: CN=TÜRKTRUST Elektronik Sertifika Hizmet Sağlayıcısı H5 O=TÜRKTRUST Bilgi İletişim ve Bilişim Güvenliği Hizmetleri A.Ş.
[ 4751]: # Subject: CN=TÜRKTRUST Elektronik Sertifika Hizmet Sağlayıcısı H5 O=TÜRKTRUST Bilgi İletişim ve Bilişim Güvenliği Hizmetleri A.Ş.
[ 4752]: # Label: "TÜRKTRUST Elektronik Sertifika Hizmet Sağlayıcısı H5"
[ 4783]: # Issuer: CN=TÜRKTRUST Elektronik Sertifika Hizmet Sağlayıcısı H6 O=TÜRKTRUST Bilgi İletişim ve Bilişim Güvenliği Hizmetleri A.Ş.
[ 4784]: # Subject: CN=TÜRKTRUST Elektronik Sertifika Hizmet Sağlayıcısı H6 O=TÜRKTRUST Bilgi İletişim ve Bilişim Güvenliği Hizmetleri A.Ş.
[ 4785]: # Label: "TÜRKTRUST Elektronik Sertifika Hizmet Sağlayıcısı H6"
```
A temporary workaround is to remove all comments from `cacerts.pem` file and set `REQUESTS_CA_BUNDLE` variable:
```bash
grep -v '^\s*\(#.*\)\?$' requests/cacert.pem > /tmp/cacert.pem
export REQUESTS_CA_BUNDLE=/tmp/cacert.pem
```
From what I can see in the [Makefile](https://github.com/kennethreitz/requests/blob/v2.12.4/Makefile#L17-L18), the `requests/cacert.pem` file is being downloaded from <http://ci.kennethreitz.org/job/ca-bundle/lastSuccessfulBuild/artifact/cacerts.pem>, which means that the patch should be either applied to that Jenkins job or the `Makefile`. Not sure which one is best?
My suggested solution (but not necessarily the implementation) is to encode those special characters with 'backslashreplace'. Piping the pem file through this script does exactly that:
```python
import sys
for l in sys.stdin.readlines():
print unicode(l, 'utf8').strip().encode('ascii', errors='backslashreplace')
```
| {
"avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4",
"events_url": "https://api.github.com/users/Lukasa/events{/privacy}",
"followers_url": "https://api.github.com/users/Lukasa/followers",
"following_url": "https://api.github.com/users/Lukasa/following{/other_user}",
"gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Lukasa",
"id": 1382556,
"login": "Lukasa",
"node_id": "MDQ6VXNlcjEzODI1NTY=",
"organizations_url": "https://api.github.com/users/Lukasa/orgs",
"received_events_url": "https://api.github.com/users/Lukasa/received_events",
"repos_url": "https://api.github.com/users/Lukasa/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Lukasa",
"user_view_type": "public"
} | {
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/3776/reactions"
} | https://api.github.com/repos/psf/requests/issues/3776/timeline | null | completed | null | null | false | [
"The PEM file actually comes from https://mkcert.org/generate/. I see no reason to remove the comments on the source side, given that every other tool is happy to ignore them. But I also see no reason we shouldn't fix up the build process for certifi to strip them.\r\n\r\nI consider this an issue on certifi more th... |
https://api.github.com/repos/psf/requests/issues/3775 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3775/labels{/name} | https://api.github.com/repos/psf/requests/issues/3775/comments | https://api.github.com/repos/psf/requests/issues/3775/events | https://github.com/psf/requests/issues/3775 | 196,320,655 | MDU6SXNzdWUxOTYzMjA2NTU= | 3,775 | Problem running PyInstaller 3.2 compiled executable using requests v2.12.x | {
"avatar_url": "https://avatars.githubusercontent.com/u/16149848?v=4",
"events_url": "https://api.github.com/users/sureshk75/events{/privacy}",
"followers_url": "https://api.github.com/users/sureshk75/followers",
"following_url": "https://api.github.com/users/sureshk75/following{/other_user}",
"gists_url": "https://api.github.com/users/sureshk75/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/sureshk75",
"id": 16149848,
"login": "sureshk75",
"node_id": "MDQ6VXNlcjE2MTQ5ODQ4",
"organizations_url": "https://api.github.com/users/sureshk75/orgs",
"received_events_url": "https://api.github.com/users/sureshk75/received_events",
"repos_url": "https://api.github.com/users/sureshk75/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/sureshk75/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/sureshk75/subscriptions",
"type": "User",
"url": "https://api.github.com/users/sureshk75",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 5 | 2016-12-19T02:49:41Z | 2021-09-08T10:00:38Z | 2016-12-19T03:08:19Z | NONE | resolved | Hi, firstly thank you for the awesome module that you have here. I've been using Python 3.4.4 on an app I created about 2 months ago and recently ran into some issues with requests. The following is the traceback displayed when attempting to run it after compiling it into a windows executable using PyInstaller 3.2 using requests v2.12.x (all patches). I have downgraded to requests v2.11.1 as that version compiles and runs without errors. I thought I'd give you the heads up as I couldn't find a similar issue and solution anywhere.
Thanks
> Traceback (most recent call last):
> File "site-packages\requests\packages\__init__.py", line 27, in <module>
> File "C:\Python34\lib\site-packages\PyInstaller\loader\pyimod03_importers.py", line 389, in load_module
> exec(bytecode, module.__dict__)
> File "site-packages\requests\packages\urllib3\__init__.py", line 8, in <module>
> File "C:\Python34\lib\site-packages\PyInstaller\loader\pyimod03_importers.py", line 389, in load_module
> exec(bytecode, module.__dict__)
> File "site-packages\requests\packages\urllib3\connectionpool.py", line 28, in <module>
> File "site-packages\requests\packages\urllib3\packages\six.py", line 203, in load_module
> File "site-packages\requests\packages\urllib3\packages\six.py", line 115, in _resolve
> File "site-packages\requests\packages\urllib3\packages\six.py", line 82, in _import_module
> ImportError: No module named 'queue'
>
> During handling of the above exception, another exception occurred:
>
> Traceback (most recent call last):
> File "dt3.py", line 13, in <module>
> File "C:\Python34\lib\site-packages\PyInstaller\loader\pyimod03_importers.py", line 389, in load_module
> exec(bytecode, module.__dict__)
> File "site-packages\requests\__init__.py", line 63, in <module>
> File "C:\Python34\lib\site-packages\PyInstaller\loader\pyimod03_importers.py", line 389, in load_module
> exec(bytecode, module.__dict__)
> File "site-packages\requests\utils.py", line 24, in <module>
> File "C:\Python34\lib\site-packages\PyInstaller\loader\pyimod03_importers.py", line 389, in load_module
> exec(bytecode, module.__dict__)
> File "site-packages\requests\_internal_utils.py", line 11, in <module>
> File "C:\Python34\lib\site-packages\PyInstaller\loader\pyimod03_importers.py", line 389, in load_module
> exec(bytecode, module.__dict__)
> File "site-packages\requests\compat.py", line 11, in <module>
> File "C:\Python34\lib\site-packages\PyInstaller\loader\pyimod03_importers.py", line 389, in load_module
> exec(bytecode, module.__dict__)
> File "site-packages\requests\packages\__init__.py", line 29, in <module>
> ImportError: No module named 'urllib3' | {
"avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4",
"events_url": "https://api.github.com/users/Lukasa/events{/privacy}",
"followers_url": "https://api.github.com/users/Lukasa/followers",
"following_url": "https://api.github.com/users/Lukasa/following{/other_user}",
"gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Lukasa",
"id": 1382556,
"login": "Lukasa",
"node_id": "MDQ6VXNlcjEzODI1NTY=",
"organizations_url": "https://api.github.com/users/Lukasa/orgs",
"received_events_url": "https://api.github.com/users/Lukasa/received_events",
"repos_url": "https://api.github.com/users/Lukasa/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Lukasa",
"user_view_type": "public"
} | {
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/3775/reactions"
} | https://api.github.com/repos/psf/requests/issues/3775/timeline | null | completed | null | null | false | [
"This seems like a pyinstaller problem: our import of the queue module via `six` isn't being detected. You should ensure that your packaging includes that standard library module. ",
"@Lukasa We hit this problem today. Can you explain what you mean by:\r\n> You should ensure that your packaging includes that stan... |
https://api.github.com/repos/psf/requests/issues/3774 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3774/labels{/name} | https://api.github.com/repos/psf/requests/issues/3774/comments | https://api.github.com/repos/psf/requests/issues/3774/events | https://github.com/psf/requests/issues/3774 | 196,314,842 | MDU6SXNzdWUxOTYzMTQ4NDI= | 3,774 | bad handshake error with ssl3 | {
"avatar_url": "https://avatars.githubusercontent.com/u/1667227?v=4",
"events_url": "https://api.github.com/users/bigbagboom/events{/privacy}",
"followers_url": "https://api.github.com/users/bigbagboom/followers",
"following_url": "https://api.github.com/users/bigbagboom/following{/other_user}",
"gists_url": "https://api.github.com/users/bigbagboom/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/bigbagboom",
"id": 1667227,
"login": "bigbagboom",
"node_id": "MDQ6VXNlcjE2NjcyMjc=",
"organizations_url": "https://api.github.com/users/bigbagboom/orgs",
"received_events_url": "https://api.github.com/users/bigbagboom/received_events",
"repos_url": "https://api.github.com/users/bigbagboom/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/bigbagboom/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/bigbagboom/subscriptions",
"type": "User",
"url": "https://api.github.com/users/bigbagboom",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 14 | 2016-12-19T01:40:11Z | 2019-02-01T18:00:10Z | 2016-12-19T01:57:19Z | NONE | resolved | I have an inhouse IIS server with ssl3 but an expired certificate, so I used requests without certificate verification and it was working fine with requests 2.11.1. But after I upgrade requests to 2.12.0, there was an error occured.
the code is:
...
requests.get('https://10.192.8.89:8080/yps_report', verify=False)
...
error message:
Traceback (most recent call last):
File "c:\python35\lib\site-packages\requests\packages\urllib3\contrib\pyopenssl.py", line 417, in wrap_socket
cnx.do_handshake()
File "c:\python35\lib\site-packages\OpenSSL\SSL.py", line 1426, in do_handshake
self._raise_ssl_error(self._ssl, result)
File "c:\python35\lib\site-packages\OpenSSL\SSL.py", line 1167, 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:\python35\lib\site-packages\requests\packages\urllib3\connectionpool.py", line 594, in urlopen
chunked=chunked)
File "c:\python35\lib\site-packages\requests\packages\urllib3\connectionpool.py", line 350, in _make_request
self._validate_conn(conn)
File "c:\python35\lib\site-packages\requests\packages\urllib3\connectionpool.py", line 835, in _validate_conn
conn.connect()
File "c:\python35\lib\site-packages\requests\packages\urllib3\connection.py", line 323, in connect
ssl_context=context)
File "c:\python35\lib\site-packages\requests\packages\urllib3\util\ssl_.py", line 324, in ssl_wrap_socket
return context.wrap_socket(sock, server_hostname=server_hostname)
File "c:\python35\lib\site-packages\requests\packages\urllib3\contrib\pyopenssl.py", line 424, in wrap_socket
raise ssl.SSLError('bad handshake: %r' % e)
ssl.SSLError: ("bad handshake: SysCallError(-1, 'Unexpected EOF')",)
...
I tried to downgrade requests to 2.11.1 and the error was gone. I have no idea how to fix this.
| {
"avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4",
"events_url": "https://api.github.com/users/Lukasa/events{/privacy}",
"followers_url": "https://api.github.com/users/Lukasa/followers",
"following_url": "https://api.github.com/users/Lukasa/following{/other_user}",
"gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Lukasa",
"id": 1382556,
"login": "Lukasa",
"node_id": "MDQ6VXNlcjEzODI1NTY=",
"organizations_url": "https://api.github.com/users/Lukasa/orgs",
"received_events_url": "https://api.github.com/users/Lukasa/received_events",
"repos_url": "https://api.github.com/users/Lukasa/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Lukasa",
"user_view_type": "public"
} | {
"+1": 1,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 1,
"url": "https://api.github.com/repos/psf/requests/issues/3774/reactions"
} | https://api.github.com/repos/psf/requests/issues/3774/timeline | null | completed | null | null | false | [
"This is almost certainly because the server in question only supports 3DES as a cipher, which we dropped from our default cipher list because it's insecure. If you operate the server I strongly encourage you to upgrade its cipher suite configuration to support something secure. ",
"I think you are right. But I d... |
https://api.github.com/repos/psf/requests/issues/3773 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3773/labels{/name} | https://api.github.com/repos/psf/requests/issues/3773/comments | https://api.github.com/repos/psf/requests/issues/3773/events | https://github.com/psf/requests/pull/3773 | 196,167,951 | MDExOlB1bGxSZXF1ZXN0OTg0MTMyNzk= | 3,773 | remove HTTPProxyAuth in favor of the proxies parameter | {
"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 | 2016-12-16T22:26:37Z | 2021-09-08T01:21:30Z | 2016-12-17T14:23:33Z | MEMBER | resolved | Minor tweak for 3.0.0 to cross off #2003 by removing the HTTPProxyAuth class in favor of the `proxies` param. | {
"avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4",
"events_url": "https://api.github.com/users/Lukasa/events{/privacy}",
"followers_url": "https://api.github.com/users/Lukasa/followers",
"following_url": "https://api.github.com/users/Lukasa/following{/other_user}",
"gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Lukasa",
"id": 1382556,
"login": "Lukasa",
"node_id": "MDQ6VXNlcjEzODI1NTY=",
"organizations_url": "https://api.github.com/users/Lukasa/orgs",
"received_events_url": "https://api.github.com/users/Lukasa/received_events",
"repos_url": "https://api.github.com/users/Lukasa/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Lukasa",
"user_view_type": "public"
} | {
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/3773/reactions"
} | https://api.github.com/repos/psf/requests/issues/3773/timeline | null | null | false | {
"diff_url": "https://github.com/psf/requests/pull/3773.diff",
"html_url": "https://github.com/psf/requests/pull/3773",
"merged_at": "2016-12-17T14:23:33Z",
"patch_url": "https://github.com/psf/requests/pull/3773.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/3773"
} | true | [] |
https://api.github.com/repos/psf/requests/issues/3772 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3772/labels{/name} | https://api.github.com/repos/psf/requests/issues/3772/comments | https://api.github.com/repos/psf/requests/issues/3772/events | https://github.com/psf/requests/issues/3772 | 196,051,679 | MDU6SXNzdWUxOTYwNTE2Nzk= | 3,772 | Digest Auth will auth regardless of status code | {
"avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4",
"events_url": "https://api.github.com/users/Lukasa/events{/privacy}",
"followers_url": "https://api.github.com/users/Lukasa/followers",
"following_url": "https://api.github.com/users/Lukasa/following{/other_user}",
"gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Lukasa",
"id": 1382556,
"login": "Lukasa",
"node_id": "MDQ6VXNlcjEzODI1NTY=",
"organizations_url": "https://api.github.com/users/Lukasa/orgs",
"received_events_url": "https://api.github.com/users/Lukasa/received_events",
"repos_url": "https://api.github.com/users/Lukasa/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Lukasa",
"user_view_type": "public"
} | [
{
"color": "0b02e1",
"default": false,
"description": null,
"id": 191274,
"name": "Contributor Friendly",
"node_id": "MDU6TGFiZWwxOTEyNzQ=",
"url": "https://api.github.com/repos/psf/requests/labels/Contributor%20Friendly"
}
] | closed | true | null | [] | {
"closed_at": null,
"closed_issues": 29,
"created_at": "2013-11-17T11:29:34Z",
"creator": {
"avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4",
"events_url": "https://api.github.com/users/Lukasa/events{/privacy}",
"followers_url": "https://api.github.com/users/Lukasa/followers",
"following_url": "https://api.github.com/users/Lukasa/following{/other_user}",
"gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Lukasa",
"id": 1382556,
"login": "Lukasa",
"node_id": "MDQ6VXNlcjEzODI1NTY=",
"organizations_url": "https://api.github.com/users/Lukasa/orgs",
"received_events_url": "https://api.github.com/users/Lukasa/received_events",
"repos_url": "https://api.github.com/users/Lukasa/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Lukasa",
"user_view_type": "public"
},
"description": null,
"due_on": null,
"html_url": "https://github.com/psf/requests/milestone/20",
"id": 487518,
"labels_url": "https://api.github.com/repos/psf/requests/milestones/20/labels",
"node_id": "MDk6TWlsZXN0b25lNDg3NTE4",
"number": 20,
"open_issues": 12,
"state": "open",
"title": "3.0.0",
"updated_at": "2024-05-19T18:43:00Z",
"url": "https://api.github.com/repos/psf/requests/milestones/20"
} | 10 | 2016-12-16T12:45:03Z | 2021-09-08T12:01:06Z | 2017-01-29T08:15:36Z | MEMBER | resolved | Discovered on IRC.
The digest auth handler in Requests' codebase doesn't ever actually check that it is responding to a 401: it just looks for an Authorization header. That's pretty dumb, so we should add a check to only actually do the execution for 401s.
This is a contributor friendly change. | {
"avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4",
"events_url": "https://api.github.com/users/Lukasa/events{/privacy}",
"followers_url": "https://api.github.com/users/Lukasa/followers",
"following_url": "https://api.github.com/users/Lukasa/following{/other_user}",
"gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Lukasa",
"id": 1382556,
"login": "Lukasa",
"node_id": "MDQ6VXNlcjEzODI1NTY=",
"organizations_url": "https://api.github.com/users/Lukasa/orgs",
"received_events_url": "https://api.github.com/users/Lukasa/received_events",
"repos_url": "https://api.github.com/users/Lukasa/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Lukasa",
"user_view_type": "public"
} | {
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/3772/reactions"
} | https://api.github.com/repos/psf/requests/issues/3772/timeline | null | completed | null | null | false | [
"Are we sure that tightening this check is what we want to do? It looks like [RFC 7235](https://tools.ietf.org/html/rfc7235#section-4.1) suggests that it's acceptable to send a WWW-Authenticate challenge with a non-401 status code. I'm not sure `handle_401` is the most apt name for the hook, but the functionality s... |
https://api.github.com/repos/psf/requests/issues/3771 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3771/labels{/name} | https://api.github.com/repos/psf/requests/issues/3771/comments | https://api.github.com/repos/psf/requests/issues/3771/events | https://github.com/psf/requests/pull/3771 | 195,860,796 | MDExOlB1bGxSZXF1ZXN0OTgxOTE0MzI= | 3,771 | Reuse all connections | {
"avatar_url": "https://avatars.githubusercontent.com/u/3725538?v=4",
"events_url": "https://api.github.com/users/agalera/events{/privacy}",
"followers_url": "https://api.github.com/users/agalera/followers",
"following_url": "https://api.github.com/users/agalera/following{/other_user}",
"gists_url": "https://api.github.com/users/agalera/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/agalera",
"id": 3725538,
"login": "agalera",
"node_id": "MDQ6VXNlcjM3MjU1Mzg=",
"organizations_url": "https://api.github.com/users/agalera/orgs",
"received_events_url": "https://api.github.com/users/agalera/received_events",
"repos_url": "https://api.github.com/users/agalera/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/agalera/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/agalera/subscriptions",
"type": "User",
"url": "https://api.github.com/users/agalera",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 3 | 2016-12-15T17:06:55Z | 2021-09-08T01:21:31Z | 2016-12-15T17:47:15Z | NONE | resolved | When testing, every time I make a request, the message appears:
`` `Starting a new HTTP connection (1): www. *****. With
I have seen one session per application. He tried to reuse the "session" for all requests and seems to work properly, even with connections that have been closed.
What implications would this change have?
``` python
In [9]: requests.get("https://github.com")
Starting new HTTPS connection (1): github.com
Out[9]: <Response [200]>
In [10]: requests.get("https://github.com")
Out[10]: <Response [200]>
In [11]: requests.get("https://stackoverflow.com")
Starting new HTTPS connection (1): stackoverflow.com
Out[11]: <Response [200]>
In [12]: requests.get("https://stackoverflow.com")
Out[12]: <Response [200]>
In [13]: requests.get("https://github.com")
Out[13]: <Response [200]>
In [14]: requests.get("https://github.com")
Out[14]: <Response [200]>
``` | {
"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/3771/reactions"
} | https://api.github.com/repos/psf/requests/issues/3771/timeline | null | null | false | {
"diff_url": "https://github.com/psf/requests/pull/3771.diff",
"html_url": "https://github.com/psf/requests/pull/3771",
"merged_at": null,
"patch_url": "https://github.com/psf/requests/pull/3771.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/3771"
} | true | [
"Hey @kianxineki, I skimmed through your question and responded a bit too quickly. The implications of this change is we would now use a single `Session` object across ALL connections with `requests.request` which may not be what the user wants. The api methods are intended to be single connections that are cleaned... |
https://api.github.com/repos/psf/requests/issues/3770 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3770/labels{/name} | https://api.github.com/repos/psf/requests/issues/3770/comments | https://api.github.com/repos/psf/requests/issues/3770/events | https://github.com/psf/requests/issues/3770 | 195,690,075 | MDU6SXNzdWUxOTU2OTAwNzU= | 3,770 | Revoked SSL Certificates not causing SSL error? | {
"avatar_url": "https://avatars.githubusercontent.com/u/12736585?v=4",
"events_url": "https://api.github.com/users/mendaxi/events{/privacy}",
"followers_url": "https://api.github.com/users/mendaxi/followers",
"following_url": "https://api.github.com/users/mendaxi/following{/other_user}",
"gists_url": "https://api.github.com/users/mendaxi/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/mendaxi",
"id": 12736585,
"login": "mendaxi",
"node_id": "MDQ6VXNlcjEyNzM2NTg1",
"organizations_url": "https://api.github.com/users/mendaxi/orgs",
"received_events_url": "https://api.github.com/users/mendaxi/received_events",
"repos_url": "https://api.github.com/users/mendaxi/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/mendaxi/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/mendaxi/subscriptions",
"type": "User",
"url": "https://api.github.com/users/mendaxi",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 4 | 2016-12-15T01:08:43Z | 2021-09-08T13:05:35Z | 2016-12-15T08:30:32Z | NONE | resolved | eyo this is my first time submitting a bug report of value (i think)
so a day or so ago I discovered that when you don't get an SSL error when you do:
```requests.get("revoked.badssl.com")```
which isn't very good
the problem isn't with OpenSSL, opening the following fails because of the bad certificate.
```openssl s_client -connect revoked.badssl.com:443```
I did some digging, as I'm working with SSL in my personal project, and _I think_ know what the issue is.
when you use the regular old' ```ssl.wrap_socket()```, you get the same behavior, where the module flat out ignores the bad certificate. It seems the correct way to do this is to do something similar to the following:
```
default_context = ssl.create_default_context(purpose=ssl.Purpose.CLIENT_AUTH)
default_context.verify_mode = ssl.CERT_REQUIRED
wrapped_socket = default_context.wrap_socket(your_socket_here)
```
This will then create an error when you try to get the webpage.
It seems that the issue stems from [here](https://github.com/kennethreitz/requests/blame/362da46e9a46da6e86e1907f03014384ab210151/requests/packages/urllib3/util/ssl_.py#L98), and was somewhat referenced [here](
https://github.com/kennethreitz/requests/issues/1786#issuecomment-167593081)
running python 3.5.2 on debian stretch with requests version 2.12.3, if that helps at all
tl;dr it seems that revoked ssl certs aren't being rejected, which could be an issue
I also wanted to thank y'all for making such an amazing python HTTP(S) module. I don't know what I would do without you guys. | {
"avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4",
"events_url": "https://api.github.com/users/Lukasa/events{/privacy}",
"followers_url": "https://api.github.com/users/Lukasa/followers",
"following_url": "https://api.github.com/users/Lukasa/following{/other_user}",
"gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Lukasa",
"id": 1382556,
"login": "Lukasa",
"node_id": "MDQ6VXNlcjEzODI1NTY=",
"organizations_url": "https://api.github.com/users/Lukasa/orgs",
"received_events_url": "https://api.github.com/users/Lukasa/received_events",
"repos_url": "https://api.github.com/users/Lukasa/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Lukasa",
"user_view_type": "public"
} | {
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/3770/reactions"
} | https://api.github.com/repos/psf/requests/issues/3770/timeline | null | completed | null | null | false | [
"So we are not doing client auth here.\r\n\r\nAnd the openssl client fails for me because there's no local certificate in my bundle for the issuer of that revoked certificate:\r\n\r\n```\r\nCONNECTED(00000003)\r\ndepth=0 /C=US/ST=California/L=San Francisco/O=BadSSL Fallback. Unknown subdomain or no SNI./CN=badssl-f... |
https://api.github.com/repos/psf/requests/issues/3769 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3769/labels{/name} | https://api.github.com/repos/psf/requests/issues/3769/comments | https://api.github.com/repos/psf/requests/issues/3769/events | https://github.com/psf/requests/issues/3769 | 195,564,579 | MDU6SXNzdWUxOTU1NjQ1Nzk= | 3,769 | Failure to install on Jython since 2.12.0 | {
"avatar_url": "https://avatars.githubusercontent.com/u/726553?v=4",
"events_url": "https://api.github.com/users/ppolewicz/events{/privacy}",
"followers_url": "https://api.github.com/users/ppolewicz/followers",
"following_url": "https://api.github.com/users/ppolewicz/following{/other_user}",
"gists_url": "https://api.github.com/users/ppolewicz/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/ppolewicz",
"id": 726553,
"login": "ppolewicz",
"node_id": "MDQ6VXNlcjcyNjU1Mw==",
"organizations_url": "https://api.github.com/users/ppolewicz/orgs",
"received_events_url": "https://api.github.com/users/ppolewicz/received_events",
"repos_url": "https://api.github.com/users/ppolewicz/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/ppolewicz/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/ppolewicz/subscriptions",
"type": "User",
"url": "https://api.github.com/users/ppolewicz",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 4 | 2016-12-14T15:39:42Z | 2021-09-08T13:05:39Z | 2016-12-14T15:42:20Z | NONE | resolved | ```
(jython) r@r-V ~ $ python --version
Jython 2.7.1b3
(jython) r@r-V ~ $ pip install requests==2.11.1
Collecting requests==2.11.1
Using cached requests-2.11.1-py2.py3-none-any.whl
Installing collected packages: requests
Found existing installation: requests 2.11.0
Uninstalling requests-2.11.0:
Successfully uninstalled requests-2.11.0
Successfully installed requests-2.11.1
(jython) r@r-V ~ $ pip install requests==2.12.0
Collecting requests==2.12.0
Using cached requests-2.12.0-py2.py3-none-any.whl
Installing collected packages: requests
Found existing installation: requests 2.11.1
Uninstalling requests-2.11.1:
Successfully uninstalled requests-2.11.1
Rolling back uninstall of requests
Exception:
Traceback (most recent call last):
File "/home/r/.virtualenvs/jython/Lib/site-packages/pip/basecommand.py", line 215, in main
status = self.run(options, args)
File "/home/r/.virtualenvs/jython/Lib/site-packages/pip/commands/install.py", line 338, in run
requirement_set.install(
File "/home/r/.virtualenvs/jython/Lib/site-packages/pip/commands/install.py", line 338, in run
requirement_set.install(
File "/home/r/.virtualenvs/jython/Lib/site-packages/pip/req/req_set.py", line 780, in install
requirement.install(
File "/home/r/.virtualenvs/jython/Lib/site-packages/pip/req/req_install.py", line 851, in install
self.move_wheel_files(self.source_dir, root=root, prefix=prefix)
File "/home/r/.virtualenvs/jython/Lib/site-packages/pip/req/req_install.py", line 1057, in move_wheel_files
move_wheel_files(
File "/home/r/.virtualenvs/jython/Lib/site-packages/pip/wheel.py", line 272, in move_wheel_files
compileall.compile_dir(source, force=True, quiet=True)
File "/home/r/jython/Lib/compileall.py", line 56, in compile_dir
if not compile_dir(fullname, maxlevels - 1, dfile, force, rx,
File "/home/r/jython/Lib/compileall.py", line 56, in compile_dir
if not compile_dir(fullname, maxlevels - 1, dfile, force, rx,
File "/home/r/jython/Lib/compileall.py", line 56, in compile_dir
if not compile_dir(fullname, maxlevels - 1, dfile, force, rx,
File "/home/r/jython/Lib/compileall.py", line 50, in compile_dir
if not compile_file(fullname, ddir, force, rx, quiet):
File "/home/r/jython/Lib/compileall.py", line 99, in compile_file
ok = py_compile.compile(fullname, None, dfile, True)
File "/home/r/jython/Lib/compileall.py", line 99, in compile_file
ok = py_compile.compile(fullname, None, dfile, True)
File "/home/r/jython/Lib/py_compile.py", line 96, in compile
_py_compile.compile(file, cfile, dfile)
File "/home/r/jython/Lib/py_compile.py", line 96, in compile
_py_compile.compile(file, cfile, dfile)
RuntimeException: java.lang.RuntimeException: Method code too large!
(jython) r@r-V ~ $
```
This might not be a bug in `requests`, but perhaps it is workaroundable? Has any change been done in 2.12.0 that caused a very big method to be created? | {
"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/3769/reactions"
} | https://api.github.com/repos/psf/requests/issues/3769/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\nThis is a duplicate of the **open** #3711 ",
"I found that issue, but it did not contain \"RuntimeException: java.lang.RuntimeException: Method code too large!\" and it mentioned usage, not installation, ... |
https://api.github.com/repos/psf/requests/issues/3768 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3768/labels{/name} | https://api.github.com/repos/psf/requests/issues/3768/comments | https://api.github.com/repos/psf/requests/issues/3768/events | https://github.com/psf/requests/issues/3768 | 195,443,880 | MDU6SXNzdWUxOTU0NDM4ODA= | 3,768 | Proxy socks windows | {
"avatar_url": "https://avatars.githubusercontent.com/u/17412555?v=4",
"events_url": "https://api.github.com/users/kityamoto/events{/privacy}",
"followers_url": "https://api.github.com/users/kityamoto/followers",
"following_url": "https://api.github.com/users/kityamoto/following{/other_user}",
"gists_url": "https://api.github.com/users/kityamoto/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/kityamoto",
"id": 17412555,
"login": "kityamoto",
"node_id": "MDQ6VXNlcjE3NDEyNTU1",
"organizations_url": "https://api.github.com/users/kityamoto/orgs",
"received_events_url": "https://api.github.com/users/kityamoto/received_events",
"repos_url": "https://api.github.com/users/kityamoto/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/kityamoto/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/kityamoto/subscriptions",
"type": "User",
"url": "https://api.github.com/users/kityamoto",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 4 | 2016-12-14T05:29:56Z | 2021-09-08T11:00:29Z | 2017-04-27T19:38:29Z | NONE | resolved | `$ pip install requests[socks]`
`>>>import requests`
`>>>proxies = {'http': 'socks5://127.0.0.1:9150','https': 'socks5://127.0.0.1:9150'}`
`>>>r = requests.get('https://api.github.com', proxies=proxies)`
`Traceback (most recent call last):`
`...`
` raise InvalidSchema("Missing dependencies for SOCKS support.")`
`requests.exceptions.InvalidSchema: Missing dependencies for SOCKS support.`
Package is installed win_inet_pton with pysocks automatically.
`$ pip install win_inet_pton` | {
"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/3768/reactions"
} | https://api.github.com/repos/psf/requests/issues/3768/timeline | null | completed | null | null | false | [
"Can you provide the output of `pip freeze`, and confirm that when you type `import socks` that that works?",
"I confirm for him ;)\r\n\r\n```\r\n>> pip freeze\r\nfuture==0.16.0\r\npsutil==5.0.0\r\nPySocks==1.6.5\r\nrequests==2.12.4\r\nsix==1.10.0\r\nwin-inet-pton==1.0.1\r\n```\r\n\r\n\r\n```\r\n>> python\r\nPyth... |
https://api.github.com/repos/psf/requests/issues/3767 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3767/labels{/name} | https://api.github.com/repos/psf/requests/issues/3767/comments | https://api.github.com/repos/psf/requests/issues/3767/events | https://github.com/psf/requests/issues/3767 | 195,441,238 | MDU6SXNzdWUxOTU0NDEyMzg= | 3,767 | Expected a bytes-like object in prepare_auth | {
"avatar_url": "https://avatars.githubusercontent.com/u/910895?v=4",
"events_url": "https://api.github.com/users/raphaeltm/events{/privacy}",
"followers_url": "https://api.github.com/users/raphaeltm/followers",
"following_url": "https://api.github.com/users/raphaeltm/following{/other_user}",
"gists_url": "https://api.github.com/users/raphaeltm/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/raphaeltm",
"id": 910895,
"login": "raphaeltm",
"node_id": "MDQ6VXNlcjkxMDg5NQ==",
"organizations_url": "https://api.github.com/users/raphaeltm/orgs",
"received_events_url": "https://api.github.com/users/raphaeltm/received_events",
"repos_url": "https://api.github.com/users/raphaeltm/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/raphaeltm/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/raphaeltm/subscriptions",
"type": "User",
"url": "https://api.github.com/users/raphaeltm",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 2 | 2016-12-14T05:03:02Z | 2021-09-08T13:05:40Z | 2016-12-14T08:48:40Z | NONE | resolved | I'm using [python-intercom](https://github.com/jkeyes/python-intercom) which requires requests 2.6.0. I have been using requests outside of that as well, and recently upgraded from 2.11.1 to 2.12.3.
python-intercom then stopped working (but works when I revert to requests 2.11.1). I haven't dug through the python-intercom code yet to figure out exactly what is going on. I'm happy to stick to 2.11.1, but since the requests website suggests that there should be no breaking changes with minor releases, I figured I'd post here.
Stack trace:
```
Traceback (most recent call last):
File "/tmp/Potato/lib/python3.5/site-packages/django/core/handlers/exception.py", line 39, in inner
response = get_response(request)
File "/tmp/Potato/lib/python3.5/site-packages/django/core/handlers/base.py", line 187, in _get_response
response = self.process_exception_by_middleware(e, request)
File "/tmp/Potato/lib/python3.5/site-packages/django/core/handlers/base.py", line 185, in _get_response
response = wrapped_callback(request, *callback_args, **callback_kwargs)
File "/vagrant/PotatoMain/views/user.py", line 39, in auth_callback
login(request, user)
File "/tmp/Potato/lib/python3.5/site-packages/django/contrib/auth/__init__.py", line 130, in login
user_logged_in.send(sender=user.__class__, request=request, user=user)
File "/tmp/Potato/lib/python3.5/site-packages/django/dispatch/dispatcher.py", line 191, in send
response = receiver(signal=self, sender=sender, **named)
File "/tmp/Potato/lib/python3.5/site-packages/django/contrib/auth/models.py", line 25, in update_last_login
user.save(update_fields=['last_login'])
File "/tmp/Potato/lib/python3.5/site-packages/django/contrib/auth/base_user.py", line 80, in save
super(AbstractBaseUser, self).save(*args, **kwargs)
File "/tmp/Potato/lib/python3.5/site-packages/django/db/models/base.py", line 796, in save
force_update=force_update, update_fields=update_fields)
File "/tmp/Potato/lib/python3.5/site-packages/django/db/models/base.py", line 833, in save_base
update_fields=update_fields, raw=raw, using=using)
File "/tmp/Potato/lib/python3.5/site-packages/django/dispatch/dispatcher.py", line 191, in send
response = receiver(signal=self, sender=sender, **named)
File "/vagrant/PotatoMain/signals.py", line 14, in feed_post_save
intercom.User.create(email=instance.email)
File "/tmp/Potato/lib/python3.5/site-packages/intercom/api_operations/save.py", line 12, in create
response = Intercom.post("/%s/" % (collection), **params)
File "/tmp/Potato/lib/python3.5/site-packages/intercom/__init__.py", line 171, in post
return cls.request('POST', path, params)
File "/tmp/Potato/lib/python3.5/site-packages/intercom/__init__.py", line 163, in request
method, cls.get_url(path), cls._auth, params)
File "/tmp/Potato/lib/python3.5/site-packages/intercom/request.py", line 47, in send_request_to_path
auth=auth, verify=certifi.where(), **req_params)
File "/tmp/Potato/lib/python3.5/site-packages/requests/api.py", line 56, in request
return session.request(method=method, url=url, **kwargs)
File "/tmp/Potato/lib/python3.5/site-packages/requests/sessions.py", line 474, in request
prep = self.prepare_request(req)
File "/tmp/Potato/lib/python3.5/site-packages/requests/sessions.py", line 407, in prepare_request
hooks=merge_hooks(request.hooks, self.hooks),
File "/tmp/Potato/lib/python3.5/site-packages/requests/models.py", line 306, in prepare
self.prepare_auth(auth, url)
File "/tmp/Potato/lib/python3.5/site-packages/requests/models.py", line 527, in prepare_auth
r = auth(self)
File "/tmp/Potato/lib/python3.5/site-packages/requests/auth.py", line 68, in __call__
r.headers['Authorization'] = _basic_auth_str(self.username, self.password)
File "/tmp/Potato/lib/python3.5/site-packages/requests/auth.py", line 38, in _basic_auth_str
b64encode(b':'.join((username, password))).strip()
TypeError: sequence item 1: expected a bytes-like object, NoneType found
``` | {
"avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4",
"events_url": "https://api.github.com/users/Lukasa/events{/privacy}",
"followers_url": "https://api.github.com/users/Lukasa/followers",
"following_url": "https://api.github.com/users/Lukasa/following{/other_user}",
"gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Lukasa",
"id": 1382556,
"login": "Lukasa",
"node_id": "MDQ6VXNlcjEzODI1NTY=",
"organizations_url": "https://api.github.com/users/Lukasa/orgs",
"received_events_url": "https://api.github.com/users/Lukasa/received_events",
"repos_url": "https://api.github.com/users/Lukasa/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Lukasa",
"user_view_type": "public"
} | {
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/3767/reactions"
} | https://api.github.com/repos/psf/requests/issues/3767/timeline | null | completed | null | null | false | [
"Hey @raphaeltm, thanks for opening a ticket. This has been addressed in #3758 and is working on master. It should be fixed when the next release ships.",
"Yup. In the meantime, python-intercom can resolve the issue by not passing objects that aren't strings as auth objects."
] |
https://api.github.com/repos/psf/requests/issues/3766 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3766/labels{/name} | https://api.github.com/repos/psf/requests/issues/3766/comments | https://api.github.com/repos/psf/requests/issues/3766/events | https://github.com/psf/requests/pull/3766 | 195,037,095 | MDExOlB1bGxSZXF1ZXN0OTc1OTgxMjI= | 3,766 | testing HTTPDigestAuth hooks | {
"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 | 9 | 2016-12-12T17:35:13Z | 2021-09-08T01:21:31Z | 2016-12-14T09:41:11Z | MEMBER | resolved | #1979 is still opened as "unresolved" but it looks like a patch (#2253) was merged to address it in 2014. There wasn't a testing framework at the time, so no tests were included to verify things actually worked. I haven't been able to concoct a end-to-end test with httpbin for this, but the individual pieces work as intended. I can work on devising a socket test if needed. | {
"avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4",
"events_url": "https://api.github.com/users/Lukasa/events{/privacy}",
"followers_url": "https://api.github.com/users/Lukasa/followers",
"following_url": "https://api.github.com/users/Lukasa/following{/other_user}",
"gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Lukasa",
"id": 1382556,
"login": "Lukasa",
"node_id": "MDQ6VXNlcjEzODI1NTY=",
"organizations_url": "https://api.github.com/users/Lukasa/orgs",
"received_events_url": "https://api.github.com/users/Lukasa/received_events",
"repos_url": "https://api.github.com/users/Lukasa/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Lukasa",
"user_view_type": "public"
} | {
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/3766/reactions"
} | https://api.github.com/repos/psf/requests/issues/3766/timeline | null | null | false | {
"diff_url": "https://github.com/psf/requests/pull/3766.diff",
"html_url": "https://github.com/psf/requests/pull/3766",
"merged_at": "2016-12-14T09:41:11Z",
"patch_url": "https://github.com/psf/requests/pull/3766.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/3766"
} | true | [
"I think I'd be much happier seeing a socket test than the httpbin ones: they just end up testing implementation details more than actual behaviour.",
"I don't think either of these are testing anything specific to httpbin's implementation, they should work the same regardless of which server they hit as long as ... |
https://api.github.com/repos/psf/requests/issues/3765 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3765/labels{/name} | https://api.github.com/repos/psf/requests/issues/3765/comments | https://api.github.com/repos/psf/requests/issues/3765/events | https://github.com/psf/requests/pull/3765 | 194,852,241 | MDExOlB1bGxSZXF1ZXN0OTc0NzAzNjY= | 3,765 | Make code match behavior as defined in RFC 2818 and RFC 6125 and documented behavior | {
"avatar_url": "https://avatars.githubusercontent.com/u/302525?v=4",
"events_url": "https://api.github.com/users/noxxi/events{/privacy}",
"followers_url": "https://api.github.com/users/noxxi/followers",
"following_url": "https://api.github.com/users/noxxi/following{/other_user}",
"gists_url": "https://api.github.com/users/noxxi/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/noxxi",
"id": 302525,
"login": "noxxi",
"node_id": "MDQ6VXNlcjMwMjUyNQ==",
"organizations_url": "https://api.github.com/users/noxxi/orgs",
"received_events_url": "https://api.github.com/users/noxxi/received_events",
"repos_url": "https://api.github.com/users/noxxi/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/noxxi/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/noxxi/subscriptions",
"type": "User",
"url": "https://api.github.com/users/noxxi",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 1 | 2016-12-11T19:59:01Z | 2021-09-08T01:21:33Z | 2016-12-11T20:57:13Z | NONE | resolved | The CN should be checked if no dNSName exist in subjectAltNames. The code treated a IP address as DNS name by appending it to dnsnames. This way CN was not checked in a certificate which contained the hostname as CN but only IP addresses as SAN.
See also http://stackoverflow.com/questions/41089539/authentication-issue-with-ssl-certificate-using-python-requests-lib | {
"avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4",
"events_url": "https://api.github.com/users/Lukasa/events{/privacy}",
"followers_url": "https://api.github.com/users/Lukasa/followers",
"following_url": "https://api.github.com/users/Lukasa/following{/other_user}",
"gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Lukasa",
"id": 1382556,
"login": "Lukasa",
"node_id": "MDQ6VXNlcjEzODI1NTY=",
"organizations_url": "https://api.github.com/users/Lukasa/orgs",
"received_events_url": "https://api.github.com/users/Lukasa/received_events",
"repos_url": "https://api.github.com/users/Lukasa/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Lukasa",
"user_view_type": "public"
} | {
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/3765/reactions"
} | https://api.github.com/repos/psf/requests/issues/3765/timeline | null | null | false | {
"diff_url": "https://github.com/psf/requests/pull/3765.diff",
"html_url": "https://github.com/psf/requests/pull/3765",
"merged_at": null,
"patch_url": "https://github.com/psf/requests/pull/3765.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/3765"
} | true | [
"Thanks for this! For the moment, I'm not going to merge this, for the following reasons.\r\n\r\n1. This patch affects urllib3, which we vendor without changes. It would need to be proposed to that project. \r\n2. The inclusion of match_hostname is currently intended to behave the same way on all platforms. Thus, i... |
https://api.github.com/repos/psf/requests/issues/3764 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3764/labels{/name} | https://api.github.com/repos/psf/requests/issues/3764/comments | https://api.github.com/repos/psf/requests/issues/3764/events | https://github.com/psf/requests/pull/3764 | 194,783,012 | MDExOlB1bGxSZXF1ZXN0OTc0MzI5Njk= | 3,764 | Proposed/3.0.0 | {
"avatar_url": "https://avatars.githubusercontent.com/u/20820116?v=4",
"events_url": "https://api.github.com/users/ihiro100/events{/privacy}",
"followers_url": "https://api.github.com/users/ihiro100/followers",
"following_url": "https://api.github.com/users/ihiro100/following{/other_user}",
"gists_url": "https://api.github.com/users/ihiro100/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/ihiro100",
"id": 20820116,
"login": "ihiro100",
"node_id": "MDQ6VXNlcjIwODIwMTE2",
"organizations_url": "https://api.github.com/users/ihiro100/orgs",
"received_events_url": "https://api.github.com/users/ihiro100/received_events",
"repos_url": "https://api.github.com/users/ihiro100/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/ihiro100/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/ihiro100/subscriptions",
"type": "User",
"url": "https://api.github.com/users/ihiro100",
"user_view_type": "public"
} | [] | closed | true | null | [] | null | 0 | 2016-12-10T18:12:26Z | 2021-09-08T01:21:33Z | 2016-12-10T18:43:37Z | NONE | resolved | {
"avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4",
"events_url": "https://api.github.com/users/Lukasa/events{/privacy}",
"followers_url": "https://api.github.com/users/Lukasa/followers",
"following_url": "https://api.github.com/users/Lukasa/following{/other_user}",
"gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Lukasa",
"id": 1382556,
"login": "Lukasa",
"node_id": "MDQ6VXNlcjEzODI1NTY=",
"organizations_url": "https://api.github.com/users/Lukasa/orgs",
"received_events_url": "https://api.github.com/users/Lukasa/received_events",
"repos_url": "https://api.github.com/users/Lukasa/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Lukasa",
"user_view_type": "public"
} | {
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/3764/reactions"
} | https://api.github.com/repos/psf/requests/issues/3764/timeline | null | null | false | {
"diff_url": "https://github.com/psf/requests/pull/3764.diff",
"html_url": "https://github.com/psf/requests/pull/3764",
"merged_at": null,
"patch_url": "https://github.com/psf/requests/pull/3764.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/3764"
} | true | [] | |
https://api.github.com/repos/psf/requests/issues/3763 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3763/labels{/name} | https://api.github.com/repos/psf/requests/issues/3763/comments | https://api.github.com/repos/psf/requests/issues/3763/events | https://github.com/psf/requests/pull/3763 | 194,676,872 | MDExOlB1bGxSZXF1ZXN0OTczNjU3ODY= | 3,763 | Revert "use enforce_content_length in Requests" | {
"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 | 1 | 2016-12-09T19:27:16Z | 2021-09-08T01:21:34Z | 2016-12-09T21:16:30Z | MEMBER | resolved | This is more of a TODO reminder. Given the upcoming work for urllib3 2.0, which I'm assuming will be used in a Requests 3.0.0, this won't work. We don't need to remove this immediately, but I'll leave this here for when we're sure 2.0 is happening. | {
"avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4",
"events_url": "https://api.github.com/users/Lukasa/events{/privacy}",
"followers_url": "https://api.github.com/users/Lukasa/followers",
"following_url": "https://api.github.com/users/Lukasa/following{/other_user}",
"gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Lukasa",
"id": 1382556,
"login": "Lukasa",
"node_id": "MDQ6VXNlcjEzODI1NTY=",
"organizations_url": "https://api.github.com/users/Lukasa/orgs",
"received_events_url": "https://api.github.com/users/Lukasa/received_events",
"repos_url": "https://api.github.com/users/Lukasa/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Lukasa",
"user_view_type": "public"
} | {
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/3763/reactions"
} | https://api.github.com/repos/psf/requests/issues/3763/timeline | null | null | false | {
"diff_url": "https://github.com/psf/requests/pull/3763.diff",
"html_url": "https://github.com/psf/requests/pull/3763",
"merged_at": null,
"patch_url": "https://github.com/psf/requests/pull/3763.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/3763"
} | true | [
"Heh, we won't forget: we'll run immediately into errors because I removed the kwarg entirely. Let's not queue up a whole bunch of PRs: let's focus on doing 2.0 first. :wink:"
] |
https://api.github.com/repos/psf/requests/issues/3762 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3762/labels{/name} | https://api.github.com/repos/psf/requests/issues/3762/comments | https://api.github.com/repos/psf/requests/issues/3762/events | https://github.com/psf/requests/pull/3762 | 194,676,129 | MDExOlB1bGxSZXF1ZXN0OTczNjUyNTc= | 3,762 | updating 3.0 history | {
"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 | 1 | 2016-12-09T19:23:35Z | 2021-09-08T01:21:32Z | 2016-12-10T13:57:44Z | MEMBER | resolved | Catching up the 3.0-HISTORY.rst file for the most of 2016's changes. | {
"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/3762/reactions"
} | https://api.github.com/repos/psf/requests/issues/3762/timeline | null | null | false | {
"diff_url": "https://github.com/psf/requests/pull/3762.diff",
"html_url": "https://github.com/psf/requests/pull/3762",
"merged_at": "2016-12-10T13:57:44Z",
"patch_url": "https://github.com/psf/requests/pull/3762.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/3762"
} | true | [
"✨ 🍰 ✨ "
] |
https://api.github.com/repos/psf/requests/issues/3761 | https://api.github.com/repos/psf/requests | https://api.github.com/repos/psf/requests/issues/3761/labels{/name} | https://api.github.com/repos/psf/requests/issues/3761/comments | https://api.github.com/repos/psf/requests/issues/3761/events | https://github.com/psf/requests/pull/3761 | 194,618,007 | MDExOlB1bGxSZXF1ZXN0OTczMjQxODE= | 3,761 | re-restrict params for _basic_auth_str in 3.0.0 | {
"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 | 1 | 2016-12-09T15:06:13Z | 2021-09-08T01:21:34Z | 2016-12-09T15:29:17Z | MEMBER | resolved | Bon voyage ⛵! | {
"avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4",
"events_url": "https://api.github.com/users/Lukasa/events{/privacy}",
"followers_url": "https://api.github.com/users/Lukasa/followers",
"following_url": "https://api.github.com/users/Lukasa/following{/other_user}",
"gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Lukasa",
"id": 1382556,
"login": "Lukasa",
"node_id": "MDQ6VXNlcjEzODI1NTY=",
"organizations_url": "https://api.github.com/users/Lukasa/orgs",
"received_events_url": "https://api.github.com/users/Lukasa/received_events",
"repos_url": "https://api.github.com/users/Lukasa/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Lukasa",
"user_view_type": "public"
} | {
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/3761/reactions"
} | https://api.github.com/repos/psf/requests/issues/3761/timeline | null | null | false | {
"diff_url": "https://github.com/psf/requests/pull/3761.diff",
"html_url": "https://github.com/psf/requests/pull/3761",
"merged_at": "2016-12-09T15:29:17Z",
"patch_url": "https://github.com/psf/requests/pull/3761.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/3761"
} | true | [
"@Lukasa I should have learned by now that when I feel the need for emojis, my changes are overzealous. Ready for another peek :)"
] |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.