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/628
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/628/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/628/comments
|
https://api.github.com/repos/psf/requests/issues/628/events
|
https://github.com/psf/requests/issues/628
| 4,699,862 |
MDU6SXNzdWU0Njk5ODYy
| 628 |
Retry does not occur during timeout
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/519545?v=4",
"events_url": "https://api.github.com/users/stantonk/events{/privacy}",
"followers_url": "https://api.github.com/users/stantonk/followers",
"following_url": "https://api.github.com/users/stantonk/following{/other_user}",
"gists_url": "https://api.github.com/users/stantonk/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/stantonk",
"id": 519545,
"login": "stantonk",
"node_id": "MDQ6VXNlcjUxOTU0NQ==",
"organizations_url": "https://api.github.com/users/stantonk/orgs",
"received_events_url": "https://api.github.com/users/stantonk/received_events",
"repos_url": "https://api.github.com/users/stantonk/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/stantonk/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/stantonk/subscriptions",
"type": "User",
"url": "https://api.github.com/users/stantonk",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 2 |
2012-05-22T21:09:47Z
|
2021-09-09T07:05:28Z
|
2012-07-27T05:54:15Z
|
NONE
|
resolved
|
Why does this not retry 3 times?
```
import time
import logging
import requests
from requests.exceptions import Timeout
logging.basicConfig(**{
'format': '%(asctime)s - %(name)s - %(levelname)s - %(message)s',
'level': logging.DEBUG
})
logger = logging.getLogger()
TIMEOUT = 2
RETRY = 3
start = time.time()
try:
r = requests.get(
'http://httpbin.org/delay/5',
timeout=TIMEOUT,
config={'max_retries': RETRY}
)
except Timeout:
print 'Timed out, sad trombone.'
stop = time.time()
print 'took: {}s'.format(stop - start)
```
$ python test.py
2012-05-22 16:07:34,023 - requests.packages.urllib3.connectionpool - INFO - Starting new HTTP connection (1): httpbin.org
Timed out, sad trombone.
took: 2.0639898777s
|
{
"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/628/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/628/timeline
| null |
completed
| null | null | false |
[
"Will the timeout setting cause requests to time out when it can't **connect** to the server within the specified time, or does it time out when it can't finish reading the response within the specified time. Based on my example it seems that it is the former, not the latter.\n\nIf this is the case, then would it be imprudent to set the timeout to something rather low and attempt to retry if there is a Timeout raised? I am trying to make my code as robust as possible, and on occasion the 3rd party API I'm accessing via HTTPS raises a Timeout or SSLError exception (something like read timed out). I want to fail as fast as possible if it's going to timeout, then retry a few times before giving up.\n",
"timeout is for connects. \n"
] |
https://api.github.com/repos/psf/requests/issues/627
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/627/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/627/comments
|
https://api.github.com/repos/psf/requests/issues/627/events
|
https://github.com/psf/requests/issues/627
| 4,690,960 |
MDU6SXNzdWU0NjkwOTYw
| 627 |
Failure to get through digest page which redirects to temporary AWS url
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/635911?v=4",
"events_url": "https://api.github.com/users/vlcinsky/events{/privacy}",
"followers_url": "https://api.github.com/users/vlcinsky/followers",
"following_url": "https://api.github.com/users/vlcinsky/following{/other_user}",
"gists_url": "https://api.github.com/users/vlcinsky/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/vlcinsky",
"id": 635911,
"login": "vlcinsky",
"node_id": "MDQ6VXNlcjYzNTkxMQ==",
"organizations_url": "https://api.github.com/users/vlcinsky/orgs",
"received_events_url": "https://api.github.com/users/vlcinsky/received_events",
"repos_url": "https://api.github.com/users/vlcinsky/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/vlcinsky/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/vlcinsky/subscriptions",
"type": "User",
"url": "https://api.github.com/users/vlcinsky",
"user_view_type": "public"
}
|
[
{
"color": "e10c02",
"default": false,
"description": null,
"id": 117744,
"name": "Bug",
"node_id": "MDU6TGFiZWwxMTc3NDQ=",
"url": "https://api.github.com/repos/psf/requests/labels/Bug"
},
{
"color": "0b02e1",
"default": false,
"description": null,
"id": 191274,
"name": "Contributor Friendly",
"node_id": "MDU6TGFiZWwxOTEyNzQ=",
"url": "https://api.github.com/repos/psf/requests/labels/Contributor%20Friendly"
}
] |
closed
| true | null |
[] | null | 31 |
2012-05-22T13:57:29Z
|
2021-09-09T05:30:44Z
|
2012-11-27T18:36:34Z
|
NONE
|
resolved
|
-- edit --
This relates to finding of @Lukas, who found, that **hooks are not passed to a new request on redirect**, which is not described elsewhere (yet?).
As soon as this hook related problem is resolved, there seem to be solution using hook, removing problem making header Authorization from final redirecting request (as sigmavirus24 has found).
-- end of edit --
I use web app, which first asks user to authenticate (usign digest auth) and then redirects him to temporarily valid url at AWS s3 storage.
Using requests fails to handle this correctly, it reports 401.
Asking for easy pages does not make these problems.
Using the app over web browser works well.
I created test utility::
``` python
import requests
from requests.auth import HTTPDigestAuth
def test_redirect_to_easypage():
url = 'http://localhost:8080/feed'
auth = HTTPDigestAuth("user", "password")
params = {"key": "easypage"}
r = requests.get(url, auth = auth, params = params)
assert r.status_code == 200
assert len(r.history) == 2
assert r.history[1].status_code == 401
assert r.history[0].status_code == 302
return
def test_redirect_to_awspage():
url = 'http://localhost:8080/feed'
auth = HTTPDigestAuth("user", "password")
params = {"key": "awsredir"}
r = requests.get(url, auth = auth, params = params)
assert r.status_code == 200
assert len(r.history) == 2
assert r.history[1].status_code == 401
assert r.history[0].status_code == 302
return
```
test_redirect_to_awspage fails by 401.
And here is simple web app, written in cherrypy::
``` python
"""Test cherrypy web server for "requests" test redirection to AWS S3 temporary url.
2012-05-22 by [email protected]
"""
import cherrypy
from cherrypy.lib import auth_digest
class DigestForwarder(object):
"""Server, serving only authorized users ("user", "password") by redirecting to some secret destination url
Home page (gives you instructions and links to use)
http://localhost:8080/
Easy page redirection:
http://localhost:8080/feed?key=easypage
Redirection to tmp AWS page (valid till end 2012):
http://localhost:8080/feed?key=awsredir
"""
targets=dict(
easypage= "http://docs.python-requests.org/en/latest/index.html",
awsredir= "http://janvlcinsky.s3.amazonaws.com/files.basex.org/xml/xmark.xml?AWSAccessKeyId=AKIAJBXTB3W6TPH7OEQA&Expires=1356908390&Signature=t6HE4oEdTVx4Mi9Q7TrDbe6%2FQxs%3D"
)
@cherrypy.expose
def index(self):
login = cherrypy.request.login
lines = ""
for key, value in self.targets.items():
request_url = "/feed?key=" + key
lines += """<li>Key: %(key)s: <a href="%(request_url)s">%(request_url)s</a></li>""" % locals()
return """\
<html>
<body>
<h1>Digest based redirector</h1>
<p>Your user account <b>%(login)s</b> has access to following feeds:</p>
<ul>
%(lines)s
</ul>
</body>
</html>""" % locals()
@cherrypy.expose
def feed(self, key):
if key in self.targets.keys():
url = self.targets[key]
raise cherrypy.HTTPRedirect(url, 302)
else:
raise cherrypy.HTTPError(400, "Unexpected value of feed key: %s." % key)
return "You asked for key %(key)s and are redirected to %(ulr)s" % locals()
conf = {"/": {
"log.error_file": "digestforwarder.error.log",
"log.access_file": "digestforwarder.logaccess.log",
"tools.auth_digest.on": True,
"tools.auth_digest.realm": 'localhost',
"tools.auth_digest.get_ha1": cherrypy.lib.auth_digest.get_ha1_dict_plain({'user': 'password'}),
"tools.auth_digest.key": 'abcd12345efgh',
"tools.auth_digest.debug": True
}
}
controller = DigestForwarder()
print controller.__doc__
cherrypy.quickstart(controller, config = conf)
```
Assuming you have cherrypy installed, just run the script which will provide what is needed for testing locally.
|
{
"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/627/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/627/timeline
| null |
completed
| null | null | false |
[
"@vlcinsky does this still exist in 0.14.2?\n",
"I will review this issue in following days, at last within two weeks (so till 10th of December 2012).\n",
"@vlcinsky in my impatience I installed cherrypy in a virtualenv and ran your script. If you instead return the response for the awspage function instead of calling assertions, I get \n\n```\n>>> resp = test_redirect_to_awspage()\n>>> resp\n<Response [400]>\n>>> resp.reason\n'Bad Request'\n>>> resp.history\n[<Response [302]>, <Response [401]>]\n>>> resp.history[0]\n<Response [302]>\n>>> resp.history[1]\n<Response [401]>\n>>> resp.history[1].reason\n'Unauthorized'\n>>> resp.history[1].request\n<Request [GET]>\n>>> resp.history[1].request.auth\n<requests.auth.HTTPDigestAuth object at 0x...>\n>>> resp.history[0].request \n>>> resp.request.auth\n<requests.auth.HTTPDigestAuth object at 0x..>\n>>> resp.request.auth is resp.history[1].request.auth\nTrue\n>>> resp.content\n'<?xml version=\"1.0\" encoding=\"UTF-8\"?>\\n<Error><Code>InvalidArgument</Code><Message>Either the Signature query string parameter or the Authorization header should be specified, not both</Message><ArgumentValue>Digest username=\"user\", realm=\"localhost\", nonce=\"1353967118:71f8dba5f51e2a56cee9bbfd7d7b4f2a\", uri=\"/files.basex.org/xml/xmark.xml?AWSAccessKeyId=AKIAJBXTB3W6TPH7OEQA&Expires=1356908390&Signature=t6HE4oEdTVx4Mi9Q7TrDbe6%2FQxs%3D\", response=\"68b0a0f7ce7428b25c850bb11a45f7c4\", qop=auth, nc=00000003, cnonce=\"8612fd9ebd12e180\"</ArgumentValue><ArgumentName>Authorization</ArgumentName><RequestId>20D399DFBB080D7B</RequestId><HostId>MyWasdwbty/IODTWvp6UxF7B8uDWd/H4GDlHEXtJyuOVqthmyLdvvhpI58gAz5Ca</HostId></Error>'\n```\n\nWhat's interesting is that both the Signature query string and Authorization header can not both be specified. There-in lies your problem.\n\nYou can probably fix this with a hook that will remove the auth header on redirect. @kennethreitz @Lukasa @piotr-dobrogost would any of you be able to help him write the hook?\n",
"Also, this gist has my updated files: https://gist.github.com/a39953b468000fb5515a\n",
"Yeah, pulling off the Auth header should be fine. I'll see if I can whip up a quick hook that works.\n",
":heart: @Lukasa \n",
"Oh, this has been interesting. Turns out that hooks are _not_ passed to a new request on redirect, as you can see [here](https://github.com/kennethreitz/requests/blob/develop/requests/models.py#L294). In the meantime, I can hack around this. @kennethreitz, is this a bug?\n",
"I have to assume it's a bug. If it isn't, there's effectively no way to intercept a redirect and put a hook on it beyond interrupting the normal redirect path entirely, like Digest Auth does with HTTP 401s. I monkeypatched my version of Requests to pass hooks onwards, and was able to resolve this problem.\n\nI'll give Kenneth some time to get back on the bug front. If this is intentional behaviour (it might be), I'll come up with a more complicated hook to do the same job. =)\n",
"Yeah, I'm fairly certain this is a bug too. It should be fairly trivial to send on the existing hooks to the next request though.\n\n-- EDIT -- \n\nIt might be that hooks were added after the `_build_response` method was written and no one really noticed this before. In that case, I can easily see this being an accidental omission.\n",
"Yup, it's a one-line change, just want to make sure there isn't a good reason behind it. =)\n",
"@Lukasa \nNice find. Generally there's asymmetry between the first request and all subsequent ones. Notice history is not passed, either.\n",
"What does your one-line change look like? Adding `hook=self.hooks,` and using the `post_response` hook aren't working unless I'm miswriting my callback function.\n",
"@piotr-dobrogost, history can't be passed to even the first request, but it isn't exactly important.\n",
"The one line change is `hook=self.hooks`.\n\nIn my mental picture the correct type of hook to use here is a `pre_send` hook, because this is actually enforcing a specific AWS requirement. This means it should take effect only on requests that violate the requirement, namely those that have both an `Authorization` header and a `Signature` query string. If you add `hook=self.hooks` and then register the following hook as a `pre_send` hook, you should get a 404:\n\n``` python\ndef strip_auth_hook(request):\n url = request.url\n\n if \"signature=\" in url.lower():\n # Remove the Authorization header.\n try:\n request.headers.pop('Authorization')\n except KeyError:\n pass\n\n return\n```\n\nObviously, this is just a demo hook, a real hook should be more specific about the content of the URL, e.g. it should enforce that it is an AWS URL.\n",
"Ah, and this is why I asked you guys for help with the hook writing. I'm not as experienced with writing callbacks and am too distracted with measure theory to have thought this through as you did. Also, I'm sure you have it written correctly locally but you need to return `request` (more for @vlcinsky's benefit).\n",
"@sigmavirus24, @Lukasa , @piotr-dobrogost, you are awesome.\nNow I see, it was worth to write the test code.\n\nI found that the file, I was using for testing, got removed from my AWS bucket (I forgot about testing purpose of it).\n\nThe file is back, so it shall return some content as soon as this solution comes into effect.\n\nI will have to study your hooks and this stuff, which I am not so familiar with yet, but probably not today, as we have here deep night 00:44 a.m CET.\n\nThanks for your effort.\n",
"You're very welcome.\n",
"@sigmavirus24: Actually you don't always have to return the `Request`, as I didn't do it locally. =) The docs aren't super clear on this, but my reading of them is that if you don't return anything from the hook then the variable passed into the hook is used. Because Python is primarily pass-by-reference, when I pop the item from the dict it affects the version of the dict in the original `Request`. Admittedly it's not super explicit and so returning the `Request` is better form, but it does work.\n\n@vlcinsky: Please note that there is probably a bug in Requests that will prevent that hook from functioning as written. When we resolve that, I will post some sample code that functions correctly. =)\n",
"-- edit note--\nThis description was modified to include more general observation about web browser behaviour, so not only Firefox, but also Chromium and IE\n-- end of edit note\n\n@all\nAPI of request is nice in it's simplicity. Using hook is a solution, but is it really necessary?\n\n## Findings from my short investigation\n\n### How are browsers behaving - using Authorization header only if redirecting into the same domain\n\nUsing Wireshark I looked at how Firefox, Chromium and partially also IE are behaving in regard to use of header Authorization in redirected requests after previous 302 (redirect) using obtained address from Location.\n\nIf redirect points into the same domain, it does reuse existing Authorization header in the request.\n\nIf redirect points out of current domain, header Authorization is never reused.\n\nNote, that if the same IP has different domain name, then it is considered different domain. I used one domain \"localhost\" and another \"zen\" (name of my computer), both having IP 127.0.0.1.\n\nNote about IE test: On MS Windows I had problem to track network traffic with Wireshark on localhost, which is typically invisible to Wireshark. I could only prove, that leaving to external domain from localhost was not including Authorization header. However, it is very likely, it behaves exactly the same way as was observed with Firefox and Chromium.\n\n### RFC2617: Authorization header allowed even without preceding 401\n\nhttp://tools.ietf.org/html/rfc2617#page-4 tells:\n\n> A user agent that wishes to authenticate itself with an origin\n> server--usually, but not necessarily, after receiving a 401\n> (Unauthorized)--MAY do so by including an Authorization header field\n> with the request. A client that wishes to authenticate itself with a\n> proxy--usually, but not necessarily, after receiving a 407 (Proxy\n> Authentication Required)--MAY do so by including a Proxy-\n> Authorization header field with the request. Both the Authorization\n> field value and the Proxy-Authorization field value consist of\n> credentials containing the authentication information of the client\n> for the realm of the resource being requested. The user agent MUST\n> choose to use one of the challenges with the strongest auth-scheme it\n> understands and request credentials from the user based upon that\n> challenge.\n\nSo it seems, there is no strict rule, defining, if agent (browser) shall first get challenge via 401, and then be allowed to provide Authorization header.\n\n### Developers often expect, redirection will be able to reuse Authorization\n\nAs redirect goes often within the same domain, it is natural, one expects, it will be able to authorize even on the redirected url.\n\nI found some links about Android and iOS related bugs and implementations, which finally allowed to redirect and authorize using the same credentials. I lost the links to these pages, but it seem to follow the pattern observed in Firefox, Chromium and IE on desktop.\n\n## Proposed solutions\n\n### NoAutoAuthorization: Do not automatically use Authorization on first redirect, only if challenged\n\n**Do not use this**\n\nIf there is request to be redirected, go there, but do not automatically include Authorization header.\n\nIf there comes response, challenging for authentication, do so, but not sooner.\n\nDrawback: this generates one request more in cases, where Authorization is really requested for target url.\n\n### HomeAutoAuthorization: Do use Authorization for redirects within the same domain\n\n**Use this one, as it follows behaviour seen on desktop browsers**\n\nIf there is redirection, use Authorization header with first request to new url if Location aims into the same domain as original request, otherwise do not use it.\n\nThis is sort of optimized NoAutoAuthorization solution and this one I would prefer.\n\n### FailOverAuthorization: Always use Authorization, retry without it if failed\n\n**Do not use this**, desktop browser never attempted to reuse known credentials (could this be even sort of security risk?)\n\nAlways use Authorization header with first request to new location, but if it fails, try once more without header Authorization.\n\nThis seems a bit messy approach.\n\n### HooksWhereNeeded: Add/Remove Authorization case by case\n\n**Do not use this**, try to follow behaviour of desktop browsers.\n\nIn fact, this is solution, which extends any of previous ones.\n\nThe best is to avoid this, as it makes use more complex. But it is fixture which comes handy when needed.\n\n## Final thoughts\n- Existing behaviour is not simply wrong, as RFC2617 does allow Authorization header to be placed even without challenge\n- However, **behaviour observed with desktop browsers Firefox, Chromium and IE shows use of _HomeAutoAuthorization_ approach. Following the same pattern with Requests would be very intuitive and would also make use quite simple** even in the case, reported originally with this bug report.\n\nQuestion: shall anybody file a bug report for currently discovered problem with hooks being sometime ignored? \n",
"Very nice summary.\n\n> Question: shall anybody file a bug report for currently discovered problem with hooks being sometime ignored?\n\nYes. It could be the most interested person here - you :)\n",
"I love it when people quote RFC's so thank you for doing your research and giving us the necessary information. The problem is your use case seems to be in the 10% and knowing what little I do about Kenneth's design philosophy means that your proposed solutions are likely to not be implemented. As you said, requests is technically correct in how it behaves since the specification is permissive in its language. \n\nFurthermore, I think treating this issue as the hooks issue is the better option to avoid creating more issues than needed. We're just waiting on @kennethreitz to affirm that the exclusion of hooks from the redirected requests is not intentional.\n",
"@piotr-dobrogost :-)\nMy question regarding filing a bug has two sides:\n\n#### Shall it be filed at all?\n\nIn case, the problem is almost fixed and about to be committed and adopted into code, then fileing a new issue is not worth to do.\n\n#### Who is the best person to write such a bug report\n\nI do my best to describe things, I am at least familiar with or where I can provide good quality description.\n\nBut with hook being ignored - I did not even try to use one so far and I would be talking about completely new topic to me.\n\nI agree with @sigmavirus24 we could keep this issue as discussed bug report **hooks are not passed to a new request on redirect**\n\nI will edit my original description to point to this aspect, if anyone is interested in detailing, do it.\n\n@all this is my first experience with Github issue cooperation incorporating more then two persons - I love it. So fast, so effective. It is like chatting while being quite productive.\n",
"@vlcinsky: It's probably not worth filing a bug report, I'll just open a pull request with the fix when I get home from work this evening. =)\n",
"Also, @Lukasa TIL\n",
"Agreed, I think the hooks is the way to go here. =)\n",
"Maybe I'm missing something here but do we know how major browsers behave in various scenarios described by @vlcinsky in this thread? I think we don't and as long as we don't find out and make Requests follow their behavior the issue of sending authorization data at right moment still exists.\n\n@sigmavirus24 \n\n> history can't be passed to even the first request, but it isn't exactly important.\n\nIt should be passed to the first request (being empty at this moment of course) and all subsequent requests. Every request should have knowledge about history as this could be needed to make decisions in hooks for example.\nI did not imply it's important in this particular issue but it's logical to note that here, as this is yet another missing piece of data not propagated to subsequent requests similarly to hooks.\nIf you agree I'd like to open issue for this.\n",
"@piotr-dobrogost I fully agree, that perfect solution should follow, how browsers are doing redirection.\n\nTo move this on, I have spent couple of hours, sniffing **Firefox, Chromium and IE** and have found, they do **follow Home AutoAuthorization pattern** as described in my longest text above.\n\nFollowing the same pattern by Requests would follow current \"beauty of simple and intuitive API by design\" approach, which I like a lot. \n\nIt is also possible, current behaviour is sort of security risk - the Authorization header is \"reporting\" sensitive information to another server. However, I cannot claim, it could be really misused, I am not expert on this topic and there could be some sort of protection against record - reply attack.\n\n**Could someone reopen this issue?**\n\nFor history not being passed, I would ask someone like @piotr-dobrogost to file separate issue, as it is not really affecting resolution of this one, but deserves some attention.\n",
"I agree, the Auth handler is doing the wrong thing here. However, for the moment, I'm leaving this issue closed because of the refactor (see #970). The whole mechanism of how we do Auth is going to change (probably), so we'll have to rewrite the Auth handlers. That will be the right time to fix this issue. =)\n",
"@Lukasa I see, you prefer issues being closed :-).\n\nBut: you agree, the Auth handler is doing things wrong - and you prefer to keep the issue closed.\n\nIsn't this sort of issue maintainance anti-pattern?\n\nIs anyone supposed to review closed issues after 1.0.0 is completed? Are we hoping, someone will just remember it?\n\nTo me, milestone \"later\" being assigned to this issue seems natural. And as 1.0.0 is on the table, it is quite likely, it would be closed even before 1.0.0 is completed.\n\nYou and others put some effort on analysing and resolving current problem (so there is some temporary solution in devel branch now), I put some effort on providing bug report and proposal for handling authorization. I think, having this issue open and living under \"later\" milestone would ensure, this effort will not be forgotten and is more likely to contribute to higher usability and quality of Requests in future.\n\nOther option would be to extract remaining issues from this bug (handling Authorization header with redirect and History not being kept over border of redirect), assign them to \"later\" milestone and close this bug, as there is temporary solution available.\n",
"Oh, sorry, I just reread my message and I didn't adequately explain what I wanted to do.\n\n_This_ issue, the one originally raised, is fixed. The Auth handler is neither broken nor bugged, but in an unusual subset of cases it can leak information. That is a new issue.\n\nWe need a new issue that clearly indicates what our actual problem is.\n\n(NB: For the record, I'm way more likely to remember closing the issue than I am to _ever_ look at the milestones. I don't think anyone on this project does that. =D )\n"
] |
https://api.github.com/repos/psf/requests/issues/626
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/626/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/626/comments
|
https://api.github.com/repos/psf/requests/issues/626/events
|
https://github.com/psf/requests/pull/626
| 4,684,285 |
MDExOlB1bGxSZXF1ZXN0MTM5ODgyMw==
| 626 |
Improvements to RequestsCookieJar
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/1443719?v=4",
"events_url": "https://api.github.com/users/joshimhoff/events{/privacy}",
"followers_url": "https://api.github.com/users/joshimhoff/followers",
"following_url": "https://api.github.com/users/joshimhoff/following{/other_user}",
"gists_url": "https://api.github.com/users/joshimhoff/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/joshimhoff",
"id": 1443719,
"login": "joshimhoff",
"node_id": "MDQ6VXNlcjE0NDM3MTk=",
"organizations_url": "https://api.github.com/users/joshimhoff/orgs",
"received_events_url": "https://api.github.com/users/joshimhoff/received_events",
"repos_url": "https://api.github.com/users/joshimhoff/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/joshimhoff/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/joshimhoff/subscriptions",
"type": "User",
"url": "https://api.github.com/users/joshimhoff",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 6 |
2012-05-22T04:39:22Z
|
2021-09-08T23:01:13Z
|
2012-05-22T04:45:44Z
|
NONE
|
resolved
|
- Docstrings for all methods in RequestsCookieJar
- Defined keys(), values(), and items() in order to let user convert RequestsCookieJar to a plain Pyton dict
- If there are multiple cookies with the same information, we now throw CookieConflictError
- Defined a couple of small utility functions
Discussion here: #578
I decided to only throw CookieConflictError if there are actually are conflicting cookies (it is fine to have multiple domains in jar), in order to not break any existing client code.
|
{
"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/626/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/626/timeline
| null | null | false |
{
"diff_url": "https://github.com/psf/requests/pull/626.diff",
"html_url": "https://github.com/psf/requests/pull/626",
"merged_at": "2012-05-22T04:45:44Z",
"patch_url": "https://github.com/psf/requests/pull/626.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/626"
}
| true |
[
"Beautiful! We'll see what @travisbot says :)\n",
"This pull request [fails](http://travis-ci.org/kennethreitz/requests/builds/1396842) (merged 96cd8e9c into 2d974662).\n",
"Looks like it breaks on Python 3 :(\n",
"I left a print statement in there from when I was debugging. Nice catch, travisbot.\n",
"This pull request [passes](http://travis-ci.org/kennethreitz/requests/builds/1396868) (merged 0eb0b894 into 2d974662).\n",
":cake:\n\nThanks for this. Excellent improvements all around :)\n"
] |
https://api.github.com/repos/psf/requests/issues/625
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/625/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/625/comments
|
https://api.github.com/repos/psf/requests/issues/625/events
|
https://github.com/psf/requests/issues/625
| 4,672,611 |
MDU6SXNzdWU0NjcyNjEx
| 625 |
SSLError error raise for https urls (SSL23_Get_Server_Hello:unknown protocol)
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/335567?v=4",
"events_url": "https://api.github.com/users/Carreau/events{/privacy}",
"followers_url": "https://api.github.com/users/Carreau/followers",
"following_url": "https://api.github.com/users/Carreau/following{/other_user}",
"gists_url": "https://api.github.com/users/Carreau/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Carreau",
"id": 335567,
"login": "Carreau",
"node_id": "MDQ6VXNlcjMzNTU2Nw==",
"organizations_url": "https://api.github.com/users/Carreau/orgs",
"received_events_url": "https://api.github.com/users/Carreau/received_events",
"repos_url": "https://api.github.com/users/Carreau/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Carreau/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Carreau/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Carreau",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 4 |
2012-05-21T15:01:27Z
|
2021-09-09T00:00:59Z
|
2012-07-27T05:56:28Z
|
NONE
|
resolved
|
Hi,
I'm trying to acces github api v3 through requests, but I get the attached traceback when trying to connect to any https urls.
As I'm behind a proxy, I tried setting the proxy as shown in another issue, but proxy respond to me that it can't get the URL.
I also tried `verify=False`, which raise Timeout
I'm surely dooing something wrong, so if I can get some clues of what...
Thanks.
( OS X 10.7.3 , http(s)_proxy exported in bash)
Without setting proxies
``` python
In [43]: requests.__version__
Out[43]: '0.12.1'
In [32]: c = requests.get('https://api.github.com/')
---------------------------------------------------------------------------
SSLError Traceback (most recent call last)
/Users/matthiasbussonnier/ipython/<ipython-input-32-f476e1ab2b17> in <module>()
----> 1 c = requests.get('https://api.github.com/')
/usr/local/Cellar/python/2.7.2/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/requests-0.12.1-py2.7.egg/requests/api.pyc in get(url, **kwargs)
51 kwargs.setdefault('allow_redirects', True)
---> 52 return request('get', url, **kwargs)
/usr/.../requests/api.pyc in request(method, url, **kwargs)
39 s = kwargs.pop('session') if 'session' in kwargs else sessions.session()
---> 40 return s.request(method=method, url=url, **kwargs)
/usr/.../requests/sessions.pyc in request(self, method, url, params, data, headers, cookies, files, auth, timeout, allow_redirects, proxies, hooks, return_response, config, prefetch, verify, cert)
228 # Send the HTTP Request.
--> 229 r.send(prefetch=prefetch)
/usr/.../requests/models.pyc in send(self, anyway, prefetch)
607 except (_SSLError, _HTTPError) as e:
608 if self.verify and isinstance(e, _SSLError):
--> 609 raise SSLError(e)
SSLError: [Errno 1] _ssl.c:503: error:140770FC:SSL routines:SSL23_GET_SERVER_HELLO:unknown protocol
```
with setting proxy
``` python
In [33]: PROXY_LIST = {
'https':'www-cache:3128'
}
In [36]: c = requests.get('https://api.github.com/pulls',proxies=PROXY_LIST)
In [37]: print c.content # translated by me from french
[...]
Error :
Don't support this combinaison of methods and protocol for following URL
https://api.github.com/pulls
Squid does not allow all methods for all URLs, for example, you can't use POST in a GOPHER request.
[...]
```
|
{
"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/625/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/625/timeline
| null |
completed
| null | null | false |
[
"What version of openssl do you have installed?\n\n`openssl version` in a terminal\n",
"OpenSSL 0.9.8r 8 Feb 2011.\n\nI thought of upgrading (to 1.0.1c) with homewbrew but it says not to :\n\n```\nThis formula is keg-only.\nMac OS X already provides this program and installing another version in\nparallel can cause all kinds of trouble.\n```\n\nMaybe there is a way to tell requests to use a specific version ...\n\nDon't know it it helps, but, it works with curl...\n\nThanks.\n",
"This might be related with #606\n",
"Closing for #606\n"
] |
https://api.github.com/repos/psf/requests/issues/624
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/624/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/624/comments
|
https://api.github.com/repos/psf/requests/issues/624/events
|
https://github.com/psf/requests/issues/624
| 4,654,818 |
MDU6SXNzdWU0NjU0ODE4
| 624 |
Documentation Translation Guide
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/119893?v=4",
"events_url": "https://api.github.com/users/kennethreitz/events{/privacy}",
"followers_url": "https://api.github.com/users/kennethreitz/followers",
"following_url": "https://api.github.com/users/kennethreitz/following{/other_user}",
"gists_url": "https://api.github.com/users/kennethreitz/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/kennethreitz",
"id": 119893,
"login": "kennethreitz",
"node_id": "MDQ6VXNlcjExOTg5Mw==",
"organizations_url": "https://api.github.com/users/kennethreitz/orgs",
"received_events_url": "https://api.github.com/users/kennethreitz/received_events",
"repos_url": "https://api.github.com/users/kennethreitz/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/kennethreitz/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/kennethreitz/subscriptions",
"type": "User",
"url": "https://api.github.com/users/kennethreitz",
"user_view_type": "public"
}
|
[
{
"color": "e102d8",
"default": false,
"description": null,
"id": 117745,
"name": "Planned",
"node_id": "MDU6TGFiZWwxMTc3NDU=",
"url": "https://api.github.com/repos/psf/requests/labels/Planned"
},
{
"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 |
{
"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"
}
|
[
{
"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"
}
] | null | 59 |
2012-05-19T14:53:39Z
|
2022-02-26T06:00:22Z
|
2021-11-28T05:43:39Z
|
CONTRIBUTOR
|
resolved
|
{
"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/624/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/624/timeline
| null |
completed
| null | null | false |
[
"Yes we need it because I might translate the documentation to arabic sometime\n",
"@toutouastro that would be fantastic!\n",
"Japanese is underway: http://ja.python-requests.org\n",
"The summer break is coming and I'll hack on this project a lot this summer !\n",
"How popular is `requests` among the Hispanic community?\n",
"Awesome! I cannot wait :)\n",
"Any advise on how I should start?\n",
"I'd be willing to do a Danish translation.\n",
"Thanks for the all the help, guys! \n\nI created a bunch of repos here: https://github.com/requests\n\nI've created a new 'Translations Team', and added all of you to it. You should be able to push to any of the translation repositories. :)\n\n:sparkles: :cake: :sparkles:\n",
"Am I doing it right?\nWhat do I need to do to have the Spanish version published like the Japanese one? (http://ja.python-requests.org)\n\nThanks\n",
"@kennethreitz any chance for a Portuguese repository? :)\n",
"@duailibe are you volunteering? :)\n",
"@kennethreitz yes! :)\n",
"I'm on it!\n",
"@duailibe thanks so much! Just push here :) https://github.com/requests/requests-docs-pt\n",
"That's funny. A lot of translating going on, but the translating guide never got written. \nI'm basically translating anything under docs/ \n",
"@kennethreitz awesome! Thanks! :cake: \n",
"@serpulga I'd like to contribute to the Spanish translation too. I see you're doing it now, but I think some things have to be changed, and I'd also like to help you finish the entire translation if you haven't. What should be the procedure?\n",
"Hi @omederos. I think regular git-flow / pull requests would be the way to go.\nI think I pushed the one document that was left, and I honestly don't know\nwhat's next. Let's see if we can get some pointers from @kennethreitz for the\nother translators.\n\nThanks,\n\nSergio\n",
"I’d love to help out with Polish. Requests is awesome and it needs more docs translations.\n",
"@Kwpolska all set! Let me know when you have an update so I can make it official :)\n\nhttps://github.com/requests/requests-docs-pl\n\nThanks so much :)\n",
"Can I volunteer to translate the docs to Indonesian, please?\n",
"Can I ask what does it need to put the spanish documentation online, @kennethreitz ? \n(Besides some update, it has 9 months old, as I see here: https://github.com/requests/requests-docs-es)\n",
"I can translate to Turkish. How do i start?\n",
"@deusExCore start a fork and start translating the documentation in place. When we can grab his attention, we'll have @kennethreitz add you to the requests organization and help you move your fork to github.com/requests/requests-docs-tr and then he, or I will have to set up DNS to resolve that for you\n",
"Hi guys, here you have a candidate for translating the docs to Italian!\n@kennethreitz @sigmavirus24 if it's a good thing, I can start working on that on a fork\n",
"@csparpa go for it!\n",
"yep :)\n",
"@kennethreitz would you setup a specific repo under https://github.com/requests for the IT translation? I'll wait for that if you're going to create it\n",
"@csparpa please start translating and as soon as it's mostly done is when we usually import your fork into the @requests org\n"
] |
|
https://api.github.com/repos/psf/requests/issues/623
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/623/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/623/comments
|
https://api.github.com/repos/psf/requests/issues/623/events
|
https://github.com/psf/requests/issues/623
| 4,639,094 |
MDU6SXNzdWU0NjM5MDk0
| 623 |
fetching small part of data instead of whole file
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/642195?v=4",
"events_url": "https://api.github.com/users/oczkers/events{/privacy}",
"followers_url": "https://api.github.com/users/oczkers/followers",
"following_url": "https://api.github.com/users/oczkers/following{/other_user}",
"gists_url": "https://api.github.com/users/oczkers/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/oczkers",
"id": 642195,
"login": "oczkers",
"node_id": "MDQ6VXNlcjY0MjE5NQ==",
"organizations_url": "https://api.github.com/users/oczkers/orgs",
"received_events_url": "https://api.github.com/users/oczkers/received_events",
"repos_url": "https://api.github.com/users/oczkers/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/oczkers/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/oczkers/subscriptions",
"type": "User",
"url": "https://api.github.com/users/oczkers",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 1 |
2012-05-18T09:42:28Z
|
2021-09-09T08:00:42Z
|
2012-05-18T18:10:37Z
|
CONTRIBUTOR
|
resolved
|
Correct me if i`m wrong but it`s not able to fetch only small part of data instead whole file.
for example if i want to download large file and save to hdd, whole file have to be first buffered in ram:
<pre>open.write('large_file', 'wb').requests.get('http://large_file').content)</pre>
it should be like that:
<pre>file = open('large_file', 'wb')
connection = requests.get('http://large_file')
while True:
buffer = connection.fetch(1024) # fetch only 1024 B
if not buffer:
break
file.write(buffer)
file.close()
</pre>
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/642195?v=4",
"events_url": "https://api.github.com/users/oczkers/events{/privacy}",
"followers_url": "https://api.github.com/users/oczkers/followers",
"following_url": "https://api.github.com/users/oczkers/following{/other_user}",
"gists_url": "https://api.github.com/users/oczkers/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/oczkers",
"id": 642195,
"login": "oczkers",
"node_id": "MDQ6VXNlcjY0MjE5NQ==",
"organizations_url": "https://api.github.com/users/oczkers/orgs",
"received_events_url": "https://api.github.com/users/oczkers/received_events",
"repos_url": "https://api.github.com/users/oczkers/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/oczkers/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/oczkers/subscriptions",
"type": "User",
"url": "https://api.github.com/users/oczkers",
"user_view_type": "public"
}
|
{
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/623/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/623/timeline
| null |
completed
| null | null | false |
[
"You should take a look at `response.iter_content`\n"
] |
https://api.github.com/repos/psf/requests/issues/622
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/622/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/622/comments
|
https://api.github.com/repos/psf/requests/issues/622/events
|
https://github.com/psf/requests/pull/622
| 4,629,799 |
MDExOlB1bGxSZXF1ZXN0MTM3NTYwMw==
| 622 |
Changed the store_cookie configuration to be part of the config dict, instead of being a new argument
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/65202?v=4",
"events_url": "https://api.github.com/users/amalakar/events{/privacy}",
"followers_url": "https://api.github.com/users/amalakar/followers",
"following_url": "https://api.github.com/users/amalakar/following{/other_user}",
"gists_url": "https://api.github.com/users/amalakar/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/amalakar",
"id": 65202,
"login": "amalakar",
"node_id": "MDQ6VXNlcjY1MjAy",
"organizations_url": "https://api.github.com/users/amalakar/orgs",
"received_events_url": "https://api.github.com/users/amalakar/received_events",
"repos_url": "https://api.github.com/users/amalakar/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/amalakar/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/amalakar/subscriptions",
"type": "User",
"url": "https://api.github.com/users/amalakar",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 2 |
2012-05-17T19:00:55Z
|
2021-09-09T00:01:13Z
|
2012-05-20T01:42:57Z
|
CONTRIBUTOR
|
resolved
|
Hi kennethreitz,
I have changed the code to make the configuration part of the config object instead of being a parameter.
This is the actual commit:
https://github.com/amalakar/requests/commit/ae3b13920875c3068a19f04c3bc8f7d4cbdfd76f
Git issue: After realizing you had issue merging yesterday I did some 'rebase' and this pull request now has 17 other commits :( I am not sure if this can be merged. If not I will try something else. I come from svn world and looks like I need to learn git. My way of learning via trial and error is not working well here.
Thanks,
Arup
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/65202?v=4",
"events_url": "https://api.github.com/users/amalakar/events{/privacy}",
"followers_url": "https://api.github.com/users/amalakar/followers",
"following_url": "https://api.github.com/users/amalakar/following{/other_user}",
"gists_url": "https://api.github.com/users/amalakar/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/amalakar",
"id": 65202,
"login": "amalakar",
"node_id": "MDQ6VXNlcjY1MjAy",
"organizations_url": "https://api.github.com/users/amalakar/orgs",
"received_events_url": "https://api.github.com/users/amalakar/received_events",
"repos_url": "https://api.github.com/users/amalakar/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/amalakar/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/amalakar/subscriptions",
"type": "User",
"url": "https://api.github.com/users/amalakar",
"user_view_type": "public"
}
|
{
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/622/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/622/timeline
| null | null | false |
{
"diff_url": "https://github.com/psf/requests/pull/622.diff",
"html_url": "https://github.com/psf/requests/pull/622",
"merged_at": null,
"patch_url": "https://github.com/psf/requests/pull/622.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/622"
}
| true |
[
"Hmm, looks like you aren't based off the current develop branch.\n",
"Let me close this and send another pull request. \n"
] |
https://api.github.com/repos/psf/requests/issues/621
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/621/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/621/comments
|
https://api.github.com/repos/psf/requests/issues/621/events
|
https://github.com/psf/requests/issues/621
| 4,629,164 |
MDU6SXNzdWU0NjI5MTY0
| 621 |
Getting HTTP 400 errors when trying to POST data and files
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/1234335?v=4",
"events_url": "https://api.github.com/users/rdodev/events{/privacy}",
"followers_url": "https://api.github.com/users/rdodev/followers",
"following_url": "https://api.github.com/users/rdodev/following{/other_user}",
"gists_url": "https://api.github.com/users/rdodev/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/rdodev",
"id": 1234335,
"login": "rdodev",
"node_id": "MDQ6VXNlcjEyMzQzMzU=",
"organizations_url": "https://api.github.com/users/rdodev/orgs",
"received_events_url": "https://api.github.com/users/rdodev/received_events",
"repos_url": "https://api.github.com/users/rdodev/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/rdodev/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/rdodev/subscriptions",
"type": "User",
"url": "https://api.github.com/users/rdodev",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 4 |
2012-05-17T18:25:23Z
|
2021-09-09T07:05:29Z
|
2012-07-27T05:53:14Z
|
NONE
|
resolved
|
Whenever I try to POST a form with data and files, I get HTTP 400 (Bad request) errors. I can post same data and to same URL w/o problems through a web browser.
|
{
"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/621/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/621/timeline
| null |
completed
| null | null | false |
[
"is the web browser doing multipart?\n",
"I believe so. Here's the gist https://gist.github.com/2720779\n",
"I think I see the potential issue: if you look at the browser headers above, you see that the Content-Type is set to multipart/form-data when I do the request through requests, the headers show Content-Type 'application/x-www-form-urlencoded' which might be causing the server to refuse that content type? \n",
"I had a similar problem trying to post json strings. The problem went away when I set Content-Type to 'application/json'.\n\nIt seems that this problem happens because post defaults to x-www-form-urlencoded even though the input param is a string (I checked using httplib2 with no headers, and the same server was able to accept).\n"
] |
https://api.github.com/repos/psf/requests/issues/620
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/620/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/620/comments
|
https://api.github.com/repos/psf/requests/issues/620/events
|
https://github.com/psf/requests/pull/620
| 4,628,599 |
MDExOlB1bGxSZXF1ZXN0MTM3NTAyNw==
| 620 |
Do not send cookies marked with secure flag over insecure HTTP connection
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/359029?v=4",
"events_url": "https://api.github.com/users/mwielgoszewski/events{/privacy}",
"followers_url": "https://api.github.com/users/mwielgoszewski/followers",
"following_url": "https://api.github.com/users/mwielgoszewski/following{/other_user}",
"gists_url": "https://api.github.com/users/mwielgoszewski/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/mwielgoszewski",
"id": 359029,
"login": "mwielgoszewski",
"node_id": "MDQ6VXNlcjM1OTAyOQ==",
"organizations_url": "https://api.github.com/users/mwielgoszewski/orgs",
"received_events_url": "https://api.github.com/users/mwielgoszewski/received_events",
"repos_url": "https://api.github.com/users/mwielgoszewski/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/mwielgoszewski/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/mwielgoszewski/subscriptions",
"type": "User",
"url": "https://api.github.com/users/mwielgoszewski",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 3 |
2012-05-17T17:53:47Z
|
2021-09-08T15:01:10Z
|
2012-05-17T18:17:44Z
|
CONTRIBUTOR
|
resolved
|
By default, the cookielib.CookieJar used by requests does not honor standard accept/reject rules for Netscape and RFC295 cookies. This behavior could result in the inadvertent exposure of sensitive cookies that have been set with the 'secure' flag (i.e., they are only to be sent to HTTPS resources) when requesting non-HTTPS connection.
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/359029?v=4",
"events_url": "https://api.github.com/users/mwielgoszewski/events{/privacy}",
"followers_url": "https://api.github.com/users/mwielgoszewski/followers",
"following_url": "https://api.github.com/users/mwielgoszewski/following{/other_user}",
"gists_url": "https://api.github.com/users/mwielgoszewski/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/mwielgoszewski",
"id": 359029,
"login": "mwielgoszewski",
"node_id": "MDQ6VXNlcjM1OTAyOQ==",
"organizations_url": "https://api.github.com/users/mwielgoszewski/orgs",
"received_events_url": "https://api.github.com/users/mwielgoszewski/received_events",
"repos_url": "https://api.github.com/users/mwielgoszewski/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/mwielgoszewski/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/mwielgoszewski/subscriptions",
"type": "User",
"url": "https://api.github.com/users/mwielgoszewski",
"user_view_type": "public"
}
|
{
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/620/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/620/timeline
| null | null | false |
{
"diff_url": "https://github.com/psf/requests/pull/620.diff",
"html_url": "https://github.com/psf/requests/pull/620",
"merged_at": null,
"patch_url": "https://github.com/psf/requests/pull/620.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/620"
}
| true |
[
"This pull request [passes](http://travis-ci.org/kennethreitz/requests/builds/1358411) (merged 3f99dfd2 into 2d974662).\n",
"Woops, my apologies. The version of requests that I had tested against was not using cookielib.CookieJar.\n",
"For the record, this is tested by `test_secure_cookies` here: https://github.com/kennethreitz/requests/blob/develop/tests/test_cookies.py\n"
] |
https://api.github.com/repos/psf/requests/issues/619
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/619/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/619/comments
|
https://api.github.com/repos/psf/requests/issues/619/events
|
https://github.com/psf/requests/pull/619
| 4,621,127 |
MDExOlB1bGxSZXF1ZXN0MTM3MTY2MQ==
| 619 |
Rewrite quickstart docs.
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/1382556?v=4",
"events_url": "https://api.github.com/users/Lukasa/events{/privacy}",
"followers_url": "https://api.github.com/users/Lukasa/followers",
"following_url": "https://api.github.com/users/Lukasa/following{/other_user}",
"gists_url": "https://api.github.com/users/Lukasa/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Lukasa",
"id": 1382556,
"login": "Lukasa",
"node_id": "MDQ6VXNlcjEzODI1NTY=",
"organizations_url": "https://api.github.com/users/Lukasa/orgs",
"received_events_url": "https://api.github.com/users/Lukasa/received_events",
"repos_url": "https://api.github.com/users/Lukasa/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Lukasa/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Lukasa/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Lukasa",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 6 |
2012-05-17T09:22:55Z
|
2021-09-08T15:01:09Z
|
2012-05-29T23:49:51Z
|
MEMBER
|
resolved
|
Issue #503 raised a few problems with the lack of clarity in the quickstart documentation. This pull request rewrites that documentation, to cover the issues raised in #503, and for general clarity.
If there are other docs rewrites you'd like, or changes to this one, I'd be happy to update this pull request with further commits.
|
{
"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/619/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/619/timeline
| null | null | false |
{
"diff_url": "https://github.com/psf/requests/pull/619.diff",
"html_url": "https://github.com/psf/requests/pull/619",
"merged_at": "2012-05-29T23:49:51Z",
"patch_url": "https://github.com/psf/requests/pull/619.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/619"
}
| true |
[
"This pull request [passes](http://travis-ci.org/kennethreitz/requests/builds/1354039) (merged 45506d1f into 2d974662).\n",
"This pull request [passes](http://travis-ci.org/kennethreitz/requests/builds/1358709) (merged 36fd8da1 into 2d974662).\n",
"This pull request now also addresses issue #504.\n",
"This pull request [passes](http://travis-ci.org/kennethreitz/requests/builds/1376845) (merged 2b8e01bf into 2d974662).\n",
"@kennethreitz: How do you feel about that last commit as a first draft of a solution to #482?\n",
"Thanks for this! I'm :-1: in a few things in here, but I can tweak later :)\n"
] |
https://api.github.com/repos/psf/requests/issues/618
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/618/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/618/comments
|
https://api.github.com/repos/psf/requests/issues/618/events
|
https://github.com/psf/requests/pull/618
| 4,615,482 |
MDExOlB1bGxSZXF1ZXN0MTM2OTI2MQ==
| 618 |
Issue #505: Allow disabling of cookie persistence/sending
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/65202?v=4",
"events_url": "https://api.github.com/users/amalakar/events{/privacy}",
"followers_url": "https://api.github.com/users/amalakar/followers",
"following_url": "https://api.github.com/users/amalakar/following{/other_user}",
"gists_url": "https://api.github.com/users/amalakar/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/amalakar",
"id": 65202,
"login": "amalakar",
"node_id": "MDQ6VXNlcjY1MjAy",
"organizations_url": "https://api.github.com/users/amalakar/orgs",
"received_events_url": "https://api.github.com/users/amalakar/received_events",
"repos_url": "https://api.github.com/users/amalakar/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/amalakar/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/amalakar/subscriptions",
"type": "User",
"url": "https://api.github.com/users/amalakar",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 7 |
2012-05-16T22:35:54Z
|
2021-09-08T15:01:09Z
|
2012-05-17T00:10:31Z
|
CONTRIBUTOR
|
resolved
|
I tried to add the feature as requested in issue #505. When store_cookies is set to False, all the cookies sent by the server would be just ignored. The user can still provide cookies using the cookie param though and they would be passed to the server as well. Just that the ones sent by the server are ignored.
Thanks,
Arup
|
{
"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/618/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/618/timeline
| null | null | false |
{
"diff_url": "https://github.com/psf/requests/pull/618.diff",
"html_url": "https://github.com/psf/requests/pull/618",
"merged_at": "2012-05-17T00:10:31Z",
"patch_url": "https://github.com/psf/requests/pull/618.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/618"
}
| true |
[
"Hmm, was this pull request against latest? Looks like GitHub thinks that it can't automatically be merged.\n",
"I am new to github and I am lost what is missing here :( Shall I repeat the process?\n",
"Hmm, I'm not sure, honestly. Everything looks good to me.\n",
"Excellent, thanks for the change :)\n",
"Actually, I should have looked a bit closer at this. cookies should be added to config, not added as a new argument.\n",
"Well it was my mistake I now realize that you mentioned as \"The second one (with config) is definitely best\". Let me fix the to use the config object. Then I will send a new pull request. Does it work?\n",
"Perfect!\n"
] |
https://api.github.com/repos/psf/requests/issues/617
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/617/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/617/comments
|
https://api.github.com/repos/psf/requests/issues/617/events
|
https://github.com/psf/requests/pull/617
| 4,609,921 |
MDExOlB1bGxSZXF1ZXN0MTM2NjYyNg==
| 617 |
Expose case-insensitive key access when deleting a key from CaseInsensitveDict
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/359029?v=4",
"events_url": "https://api.github.com/users/mwielgoszewski/events{/privacy}",
"followers_url": "https://api.github.com/users/mwielgoszewski/followers",
"following_url": "https://api.github.com/users/mwielgoszewski/following{/other_user}",
"gists_url": "https://api.github.com/users/mwielgoszewski/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/mwielgoszewski",
"id": 359029,
"login": "mwielgoszewski",
"node_id": "MDQ6VXNlcjM1OTAyOQ==",
"organizations_url": "https://api.github.com/users/mwielgoszewski/orgs",
"received_events_url": "https://api.github.com/users/mwielgoszewski/received_events",
"repos_url": "https://api.github.com/users/mwielgoszewski/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/mwielgoszewski/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/mwielgoszewski/subscriptions",
"type": "User",
"url": "https://api.github.com/users/mwielgoszewski",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 2 |
2012-05-16T18:02:15Z
|
2021-09-08T15:01:09Z
|
2012-05-17T00:34:03Z
|
CONTRIBUTOR
|
resolved
|
Previously, when attempting to call del on a dictionary key that did not exist, a KeyError was raised. This commit changes the default behavior to be case-insensitive.
|
{
"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/617/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/617/timeline
| null | null | false |
{
"diff_url": "https://github.com/psf/requests/pull/617.diff",
"html_url": "https://github.com/psf/requests/pull/617",
"merged_at": "2012-05-17T00:34:03Z",
"patch_url": "https://github.com/psf/requests/pull/617.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/617"
}
| true |
[
"This pull request [passes](http://travis-ci.org/kennethreitz/requests/builds/1348101) (merged 4b7c5dab into c477f6eb).\n",
"Awesome, thanks!\n"
] |
https://api.github.com/repos/psf/requests/issues/616
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/616/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/616/comments
|
https://api.github.com/repos/psf/requests/issues/616/events
|
https://github.com/psf/requests/pull/616
| 4,595,777 |
MDExOlB1bGxSZXF1ZXN0MTM2MDQxNQ==
| 616 |
draft pull request for eager release of sockets
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/376448?v=4",
"events_url": "https://api.github.com/users/slingamn/events{/privacy}",
"followers_url": "https://api.github.com/users/slingamn/followers",
"following_url": "https://api.github.com/users/slingamn/following{/other_user}",
"gists_url": "https://api.github.com/users/slingamn/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/slingamn",
"id": 376448,
"login": "slingamn",
"node_id": "MDQ6VXNlcjM3NjQ0OA==",
"organizations_url": "https://api.github.com/users/slingamn/orgs",
"received_events_url": "https://api.github.com/users/slingamn/received_events",
"repos_url": "https://api.github.com/users/slingamn/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/slingamn/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/slingamn/subscriptions",
"type": "User",
"url": "https://api.github.com/users/slingamn",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 4 |
2012-05-15T23:59:16Z
|
2021-09-08T23:08:22Z
|
2012-07-18T03:39:34Z
|
CONTRIBUTOR
|
resolved
|
Please do not merge this! This is intended as a "design review" :-) It needs more comments and tests before it is production ready.
This implements explicit disposal of sockets in urllib3 and Requests that does not rely on instantaneous garbage collection via reference counts (e.g., for PyPy). It should fix #520 without removing the `Response.request` member, or otherwise breaking the API (or the reference cycle, depending on whether you're a glass-half-full or glass-half-empty person).
It's split into three commits: one is a test case, one adds explicit disposal, one defaults `prefetch=True` and changes the tests to match.
@shazow maybe you could take a look at the urllib3 changes?
Thanks everyone.
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/376448?v=4",
"events_url": "https://api.github.com/users/slingamn/events{/privacy}",
"followers_url": "https://api.github.com/users/slingamn/followers",
"following_url": "https://api.github.com/users/slingamn/following{/other_user}",
"gists_url": "https://api.github.com/users/slingamn/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/slingamn",
"id": 376448,
"login": "slingamn",
"node_id": "MDQ6VXNlcjM3NjQ0OA==",
"organizations_url": "https://api.github.com/users/slingamn/orgs",
"received_events_url": "https://api.github.com/users/slingamn/received_events",
"repos_url": "https://api.github.com/users/slingamn/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/slingamn/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/slingamn/subscriptions",
"type": "User",
"url": "https://api.github.com/users/slingamn",
"user_view_type": "public"
}
|
{
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/616/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/616/timeline
| null | null | false |
{
"diff_url": "https://github.com/psf/requests/pull/616.diff",
"html_url": "https://github.com/psf/requests/pull/616",
"merged_at": null,
"patch_url": "https://github.com/psf/requests/pull/616.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/616"
}
| true |
[
"This pull request [passes](http://travis-ci.org/kennethreitz/requests/builds/1341277) (merged e490a2f9 into 355003b4).\n",
"This pull request [passes](http://travis-ci.org/kennethreitz/requests/builds/1343119) (merged b4556066 into 355003b4).\n",
"Could you make a separate pull requests just for urllib3? I'll take a closer look at it there.\n",
"I'm closing this in favor of discussion at shazow/urllib3#87.\n"
] |
https://api.github.com/repos/psf/requests/issues/615
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/615/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/615/comments
|
https://api.github.com/repos/psf/requests/issues/615/events
|
https://github.com/psf/requests/issues/615
| 4,588,692 |
MDU6SXNzdWU0NTg4Njky
| 615 |
Documentation is wrong: Response has no attribute 'text'
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/217980?v=4",
"events_url": "https://api.github.com/users/willi-mueller/events{/privacy}",
"followers_url": "https://api.github.com/users/willi-mueller/followers",
"following_url": "https://api.github.com/users/willi-mueller/following{/other_user}",
"gists_url": "https://api.github.com/users/willi-mueller/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/willi-mueller",
"id": 217980,
"login": "willi-mueller",
"node_id": "MDQ6VXNlcjIxNzk4MA==",
"organizations_url": "https://api.github.com/users/willi-mueller/orgs",
"received_events_url": "https://api.github.com/users/willi-mueller/received_events",
"repos_url": "https://api.github.com/users/willi-mueller/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/willi-mueller/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/willi-mueller/subscriptions",
"type": "User",
"url": "https://api.github.com/users/willi-mueller",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 3 |
2012-05-15T17:35:06Z
|
2021-09-09T08:00:41Z
|
2012-05-15T20:06:13Z
|
NONE
|
resolved
|
The very first example on the Website and in the README.md produces an error because Response has no attribute 'text'. Maybe you meant 'content'?
But there is another mistake in that example – the github API call returns nothing. See http://developer.github.com/v3/#authentication.
What could be a better example? If someone makes up a good example I'll fix the documentation.
Great work so far, I really love requests!
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/217980?v=4",
"events_url": "https://api.github.com/users/willi-mueller/events{/privacy}",
"followers_url": "https://api.github.com/users/willi-mueller/followers",
"following_url": "https://api.github.com/users/willi-mueller/following{/other_user}",
"gists_url": "https://api.github.com/users/willi-mueller/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/willi-mueller",
"id": 217980,
"login": "willi-mueller",
"node_id": "MDQ6VXNlcjIxNzk4MA==",
"organizations_url": "https://api.github.com/users/willi-mueller/orgs",
"received_events_url": "https://api.github.com/users/willi-mueller/received_events",
"repos_url": "https://api.github.com/users/willi-mueller/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/willi-mueller/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/willi-mueller/subscriptions",
"type": "User",
"url": "https://api.github.com/users/willi-mueller",
"user_view_type": "public"
}
|
{
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/615/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/615/timeline
| null |
completed
| null | null | false |
[
"Are you using an old release?\n",
"Oh, sorry. I had 0.7 and now upgraded to 0.12.1 and it works. Thanks.\n",
"Yes, I had same error. Using \"pip install requests --upgrade\" worked for me.\n"
] |
https://api.github.com/repos/psf/requests/issues/614
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/614/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/614/comments
|
https://api.github.com/repos/psf/requests/issues/614/events
|
https://github.com/psf/requests/pull/614
| 4,586,141 |
MDExOlB1bGxSZXF1ZXN0MTM1NTkyNw==
| 614 |
Better content-type detection and unicode fix
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/1165819?v=4",
"events_url": "https://api.github.com/users/ib-lundgren/events{/privacy}",
"followers_url": "https://api.github.com/users/ib-lundgren/followers",
"following_url": "https://api.github.com/users/ib-lundgren/following{/other_user}",
"gists_url": "https://api.github.com/users/ib-lundgren/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/ib-lundgren",
"id": 1165819,
"login": "ib-lundgren",
"node_id": "MDQ6VXNlcjExNjU4MTk=",
"organizations_url": "https://api.github.com/users/ib-lundgren/orgs",
"received_events_url": "https://api.github.com/users/ib-lundgren/received_events",
"repos_url": "https://api.github.com/users/ib-lundgren/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/ib-lundgren/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/ib-lundgren/subscriptions",
"type": "User",
"url": "https://api.github.com/users/ib-lundgren",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 8 |
2012-05-15T15:29:13Z
|
2021-09-08T15:01:08Z
|
2012-05-15T15:39:20Z
|
CONTRIBUTOR
|
resolved
|
Better content-type detection for request.auth.OAuth1, fixes [OAuthLib #38](https://github.com/idangazit/oauthlib/issues/38). All requests with files are now treated as multipart and r.data is not included in the signature creation.
Small fix to a UnicodeDecodeError during httplibs concatenation of the unicode Authorization header and file data.
|
{
"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/614/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/614/timeline
| null | null | false |
{
"diff_url": "https://github.com/psf/requests/pull/614.diff",
"html_url": "https://github.com/psf/requests/pull/614",
"merged_at": "2012-05-15T15:39:20Z",
"patch_url": "https://github.com/psf/requests/pull/614.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/614"
}
| true |
[
"This pull request [fails](http://travis-ci.org/kennethreitz/requests/builds/1336709) (merged c24665b5 into 763393f7).\n",
"Looks like this breaks Python 3.1.\n",
"Yea sorry about that. Only use 2.7 myself and forgot that 3 does not allow u''. Nice work @travisbot =) \n\nbrb updating...\n",
"@idangazit, any comments on this?\n",
"This pull request [passes](http://travis-ci.org/kennethreitz/requests/builds/1336823) (merged 6a9d59ea into 763393f7).\n",
"Thank you sir :)\n",
"Yes! Thanks :heart:\n",
"@ib-lundgren \n\n3.3 will [support](http://docs.python.org/dev/whatsnew/3.3.html#pep-414-explicit-unicode-literals) explicit unicode literals. \n"
] |
https://api.github.com/repos/psf/requests/issues/613
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/613/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/613/comments
|
https://api.github.com/repos/psf/requests/issues/613/events
|
https://github.com/psf/requests/pull/613
| 4,584,666 |
MDExOlB1bGxSZXF1ZXN0MTM1NTIxMA==
| 613 |
Remove sharing of base_headers config between sessions.
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/1241310?v=4",
"events_url": "https://api.github.com/users/surajbarkale/events{/privacy}",
"followers_url": "https://api.github.com/users/surajbarkale/followers",
"following_url": "https://api.github.com/users/surajbarkale/following{/other_user}",
"gists_url": "https://api.github.com/users/surajbarkale/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/surajbarkale",
"id": 1241310,
"login": "surajbarkale",
"node_id": "MDQ6VXNlcjEyNDEzMTA=",
"organizations_url": "https://api.github.com/users/surajbarkale/orgs",
"received_events_url": "https://api.github.com/users/surajbarkale/received_events",
"repos_url": "https://api.github.com/users/surajbarkale/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/surajbarkale/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/surajbarkale/subscriptions",
"type": "User",
"url": "https://api.github.com/users/surajbarkale",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 2 |
2012-05-15T14:18:16Z
|
2021-09-08T15:01:08Z
|
2012-05-15T15:31:43Z
|
CONTRIBUTOR
|
resolved
|
Since base_headers is a dictionary, it's reference was shared with all instances of Session objects. This patch deep copies all config options. Using deepcopy here should not incur a large performance penalty.
|
{
"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/613/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/613/timeline
| null | null | false |
{
"diff_url": "https://github.com/psf/requests/pull/613.diff",
"html_url": "https://github.com/psf/requests/pull/613",
"merged_at": "2012-05-15T15:31:43Z",
"patch_url": "https://github.com/psf/requests/pull/613.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/613"
}
| true |
[
"This pull request [passes](http://travis-ci.org/kennethreitz/requests/builds/1336193) (merged 973e9cb5 into 763393f7).\n",
"Thanks!\n"
] |
https://api.github.com/repos/psf/requests/issues/612
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/612/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/612/comments
|
https://api.github.com/repos/psf/requests/issues/612/events
|
https://github.com/psf/requests/issues/612
| 4,578,465 |
MDU6SXNzdWU0NTc4NDY1
| 612 |
exception in requests.models.Request.cookies.items()
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/90568?v=4",
"events_url": "https://api.github.com/users/arteme/events{/privacy}",
"followers_url": "https://api.github.com/users/arteme/followers",
"following_url": "https://api.github.com/users/arteme/following{/other_user}",
"gists_url": "https://api.github.com/users/arteme/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/arteme",
"id": 90568,
"login": "arteme",
"node_id": "MDQ6VXNlcjkwNTY4",
"organizations_url": "https://api.github.com/users/arteme/orgs",
"received_events_url": "https://api.github.com/users/arteme/received_events",
"repos_url": "https://api.github.com/users/arteme/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/arteme/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/arteme/subscriptions",
"type": "User",
"url": "https://api.github.com/users/arteme",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 1 |
2012-05-15T06:53:13Z
|
2021-09-09T07:05:25Z
|
2012-07-27T06:01:48Z
|
NONE
|
resolved
|
It seems like the keys in the cookie jar are not names, but the actual cookie objects, so callings req.cookies.items() fails with an exception:
``` ipython
In [19]: requests.__version__
Out[19]: '0.12.1'
In [20]: r.request.cookies.keys()
Out[20]: [Cookie(version=0, name='csrftoken', value='65cab054cf10a7c14785ad7b254e44c4', port=None, port_specified=False, domain='192.168.230.1', domain_specified=False, domain_initial_dot=False, path='/', path_specified=True, secure=False, expires=1368513530, discard=False, comment=None, comment_url=None, rest={}, rfc2109=False)]
In [21]: r.request.cookies.items()
---------------------------------------------------------------------------
KeyError Traceback (most recent call last)
/home/arteme/http-tester/<ipython-input-21-93b115547bb8> in <module>()
----> 1 r.request.cookies.items()
/usr/lib/python2.6/_abcoll.pyc in items(self)
348
349 def items(self):
--> 350 return [(key, self[key]) for key in self]
351
352 def values(self):
/home/arteme/http-tester/requests/cookies.pyc in __getitem__(self, name)
161
162 def __getitem__(self, name):
--> 163 return self._find(name)
164
165 def __setitem__(self, name, value):
/home/arteme/http-tester/requests/cookies.pyc in _find(self, name, domain, path)
176 return cookie.value
177
--> 178 raise KeyError('name=%r, domain=%r, path=%r' % (name, domain, path))
179
180 def __getstate__(self):
KeyError: "name=Cookie(version=0, name='csrftoken', value='65cab054cf10a7c14785ad7b254e44c4', port=None, port_specified=False, domain='192.168.230.1', domain_specified=False, domain_initial_dot=False, path='/', path_specified=True, secure=False, expires=1368513530, discard=False, comment=None, comment_url=None, rest={}, rfc2109=False), domain=None, path=None"
```
|
{
"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/612/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/612/timeline
| null |
completed
| null | null | false |
[
"@arteme Check out #578. There are plans to implements keys(), values(), and items(), so that a user of Requests can call dict(resp.cookies) and get a name value dict.\n"
] |
https://api.github.com/repos/psf/requests/issues/611
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/611/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/611/comments
|
https://api.github.com/repos/psf/requests/issues/611/events
|
https://github.com/psf/requests/pull/611
| 4,555,738 |
MDExOlB1bGxSZXF1ZXN0MTM0MjgzNQ==
| 611 |
Improve developer documentation.
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/13798?v=4",
"events_url": "https://api.github.com/users/pnasrat/events{/privacy}",
"followers_url": "https://api.github.com/users/pnasrat/followers",
"following_url": "https://api.github.com/users/pnasrat/following{/other_user}",
"gists_url": "https://api.github.com/users/pnasrat/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/pnasrat",
"id": 13798,
"login": "pnasrat",
"node_id": "MDQ6VXNlcjEzNzk4",
"organizations_url": "https://api.github.com/users/pnasrat/orgs",
"received_events_url": "https://api.github.com/users/pnasrat/received_events",
"repos_url": "https://api.github.com/users/pnasrat/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/pnasrat/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/pnasrat/subscriptions",
"type": "User",
"url": "https://api.github.com/users/pnasrat",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 6 |
2012-05-13T23:11:47Z
|
2021-09-08T15:01:07Z
|
2012-05-14T02:47:19Z
|
CONTRIBUTOR
|
resolved
|
I cloned, followed the todo and had failures as no certifi or chardet.
Fixed up so easy to get started.
|
{
"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/611/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/611/timeline
| null | null | false |
{
"diff_url": "https://github.com/psf/requests/pull/611.diff",
"html_url": "https://github.com/psf/requests/pull/611",
"merged_at": "2012-05-14T02:47:19Z",
"patch_url": "https://github.com/psf/requests/pull/611.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/611"
}
| true |
[
"This pull request [passes](http://travis-ci.org/kennethreitz/requests/builds/1322966) (merged 2c114738 into 40d32536).\n",
"May be related to Issue #601 \n",
"I was going to argue against teaching virtualenv in here, but I can definitely see it being useful to new developers.\n\nThanks!\n",
"Is the documentaion incomplete ?\n",
"@toutouastro always a work in progress :)\n",
"in and after july (summer break) I'am planing to work on some open source projects and I liked requests and I think I'll participate in this project !\n"
] |
https://api.github.com/repos/psf/requests/issues/610
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/610/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/610/comments
|
https://api.github.com/repos/psf/requests/issues/610/events
|
https://github.com/psf/requests/pull/610
| 4,551,868 |
MDExOlB1bGxSZXF1ZXN0MTM0MTcwMw==
| 610 |
Removed extra whitespace
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/7339?v=4",
"events_url": "https://api.github.com/users/medwards/events{/privacy}",
"followers_url": "https://api.github.com/users/medwards/followers",
"following_url": "https://api.github.com/users/medwards/following{/other_user}",
"gists_url": "https://api.github.com/users/medwards/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/medwards",
"id": 7339,
"login": "medwards",
"node_id": "MDQ6VXNlcjczMzk=",
"organizations_url": "https://api.github.com/users/medwards/orgs",
"received_events_url": "https://api.github.com/users/medwards/received_events",
"repos_url": "https://api.github.com/users/medwards/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/medwards/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/medwards/subscriptions",
"type": "User",
"url": "https://api.github.com/users/medwards",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 3 |
2012-05-13T10:02:05Z
|
2021-09-08T15:01:07Z
|
2012-05-13T18:01:22Z
|
CONTRIBUTOR
|
resolved
|
Just removing something I saw while browsing the code.
|
{
"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/610/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/610/timeline
| null | null | false |
{
"diff_url": "https://github.com/psf/requests/pull/610.diff",
"html_url": "https://github.com/psf/requests/pull/610",
"merged_at": "2012-05-13T18:01:22Z",
"patch_url": "https://github.com/psf/requests/pull/610.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/610"
}
| true |
[
"This pull request [passes](http://travis-ci.org/kennethreitz/requests/builds/1319174) (merged 51f76280 into 4161a7ec).\n",
"Erp... how did that newline bit slip in... does that matter?\n",
"thanks :)\n"
] |
https://api.github.com/repos/psf/requests/issues/609
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/609/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/609/comments
|
https://api.github.com/repos/psf/requests/issues/609/events
|
https://github.com/psf/requests/issues/609
| 4,551,729 |
MDU6SXNzdWU0NTUxNzI5
| 609 |
async.py doesn't have code
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/311929?v=4",
"events_url": "https://api.github.com/users/kracekumar/events{/privacy}",
"followers_url": "https://api.github.com/users/kracekumar/followers",
"following_url": "https://api.github.com/users/kracekumar/following{/other_user}",
"gists_url": "https://api.github.com/users/kracekumar/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/kracekumar",
"id": 311929,
"login": "kracekumar",
"node_id": "MDQ6VXNlcjMxMTkyOQ==",
"organizations_url": "https://api.github.com/users/kracekumar/orgs",
"received_events_url": "https://api.github.com/users/kracekumar/received_events",
"repos_url": "https://api.github.com/users/kracekumar/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/kracekumar/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/kracekumar/subscriptions",
"type": "User",
"url": "https://api.github.com/users/kracekumar",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 3 |
2012-05-13T09:23:31Z
|
2021-09-09T08:00:43Z
|
2012-05-14T16:34:01Z
|
CONTRIBUTOR
|
resolved
|
Seems async.py file doesn't have any code. So async will not be supported from requests?
|
{
"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/609/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/609/timeline
| null |
completed
| null | null | false |
[
"close this issue it's duplicated #608\n",
"Sorry, some how I clicked button twice\n",
"No problem !\n"
] |
https://api.github.com/repos/psf/requests/issues/608
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/608/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/608/comments
|
https://api.github.com/repos/psf/requests/issues/608/events
|
https://github.com/psf/requests/issues/608
| 4,551,728 |
MDU6SXNzdWU0NTUxNzI4
| 608 |
async.py doesn't have code
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/311929?v=4",
"events_url": "https://api.github.com/users/kracekumar/events{/privacy}",
"followers_url": "https://api.github.com/users/kracekumar/followers",
"following_url": "https://api.github.com/users/kracekumar/following{/other_user}",
"gists_url": "https://api.github.com/users/kracekumar/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/kracekumar",
"id": 311929,
"login": "kracekumar",
"node_id": "MDQ6VXNlcjMxMTkyOQ==",
"organizations_url": "https://api.github.com/users/kracekumar/orgs",
"received_events_url": "https://api.github.com/users/kracekumar/received_events",
"repos_url": "https://api.github.com/users/kracekumar/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/kracekumar/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/kracekumar/subscriptions",
"type": "User",
"url": "https://api.github.com/users/kracekumar",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 6 |
2012-05-13T09:23:30Z
|
2021-09-09T08:00:43Z
|
2012-05-14T16:33:48Z
|
CONTRIBUTOR
|
resolved
|
Seems async.py file doesn't have any code. So async will not be supported from requests?
|
{
"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/608/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/608/timeline
| null |
completed
| null | null | false |
[
"It's now a separate project: https://github.com/kennethreitz/grequests\n",
"yep, I am aware of it, if upgrade requests and code which consumes async will break, is there any plan to support async.py by internally importing GRequests ?\n",
"@kracekumar no, this is a backwards incompatible change.\n",
" :( \n`from request.__past__ import async` isn't possible ?\n",
"It's possible, but it's not a good idea. I'm removing it for a reason.\n",
"For reference: http://semver.org/ :)\n"
] |
https://api.github.com/repos/psf/requests/issues/607
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/607/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/607/comments
|
https://api.github.com/repos/psf/requests/issues/607/events
|
https://github.com/psf/requests/pull/607
| 4,548,233 |
MDExOlB1bGxSZXF1ZXN0MTM0MDQ3MQ==
| 607 |
Fix a docstring typo (of -> if).
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/10137?v=4",
"events_url": "https://api.github.com/users/ghost/events{/privacy}",
"followers_url": "https://api.github.com/users/ghost/followers",
"following_url": "https://api.github.com/users/ghost/following{/other_user}",
"gists_url": "https://api.github.com/users/ghost/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/ghost",
"id": 10137,
"login": "ghost",
"node_id": "MDQ6VXNlcjEwMTM3",
"organizations_url": "https://api.github.com/users/ghost/orgs",
"received_events_url": "https://api.github.com/users/ghost/received_events",
"repos_url": "https://api.github.com/users/ghost/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/ghost/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/ghost/subscriptions",
"type": "User",
"url": "https://api.github.com/users/ghost",
"user_view_type": "public"
}
|
[] |
closed
| false | null |
[] | null | 2 |
2012-05-12T17:24:14Z
|
2014-07-20T01:35:43Z
|
2012-05-12T21:23:04Z
|
NONE
| null |
A minor typo fix in the send docstring.
|
{
"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/607/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/607/timeline
| null | null | false |
{
"diff_url": "https://github.com/psf/requests/pull/607.diff",
"html_url": "https://github.com/psf/requests/pull/607",
"merged_at": "2012-05-12T21:23:04Z",
"patch_url": "https://github.com/psf/requests/pull/607.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/607"
}
| true |
[
"This pull request [passes](http://travis-ci.org/kennethreitz/requests/builds/1314955) (merged ed767cb7 into 0442122d).\n",
"Oops, thanks :)\n"
] |
https://api.github.com/repos/psf/requests/issues/606
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/606/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/606/comments
|
https://api.github.com/repos/psf/requests/issues/606/events
|
https://github.com/psf/requests/issues/606
| 4,537,873 |
MDU6SXNzdWU0NTM3ODcz
| 606 |
Allow specifying the ssl protocol version to use
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/245297?v=4",
"events_url": "https://api.github.com/users/mvantellingen/events{/privacy}",
"followers_url": "https://api.github.com/users/mvantellingen/followers",
"following_url": "https://api.github.com/users/mvantellingen/following{/other_user}",
"gists_url": "https://api.github.com/users/mvantellingen/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/mvantellingen",
"id": 245297,
"login": "mvantellingen",
"node_id": "MDQ6VXNlcjI0NTI5Nw==",
"organizations_url": "https://api.github.com/users/mvantellingen/orgs",
"received_events_url": "https://api.github.com/users/mvantellingen/received_events",
"repos_url": "https://api.github.com/users/mvantellingen/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/mvantellingen/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/mvantellingen/subscriptions",
"type": "User",
"url": "https://api.github.com/users/mvantellingen",
"user_view_type": "public"
}
|
[
{
"color": "e10c02",
"default": false,
"description": null,
"id": 117744,
"name": "Bug",
"node_id": "MDU6TGFiZWwxMTc3NDQ=",
"url": "https://api.github.com/repos/psf/requests/labels/Bug"
}
] |
closed
| true | null |
[] | null | 20 |
2012-05-11T17:32:54Z
|
2018-11-04T13:36:35Z
|
2012-07-27T06:10:49Z
|
NONE
|
resolved
|
Allow specifying the ssh protocol version (sslv2 or sslv3). This should fix problems connecting to various https sites (e.g. *.sharepoint.com)
See http://bugs.python.org/issue11220 for more information
|
{
"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/606/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/606/timeline
| null |
completed
| null | null | false |
[
"Wouldn't it make more sense for the library to just handle whichever ssl protocol version is in use by the server? Having to manually specify is really klunky.\n",
"A web browser doesn't need you to specify what version of SSL a site's using, why should requests?\n",
"I agree with the whole automatic selection of the SSL version. But afaik recent openssl versions are broken in this regard and are not planning to fix it. See also http://trac.macports.org/ticket/33715\n",
"SSLv2 is not enabled by default by the major browser vendors because it is broken. Automatic selection of the SSL/TLS version is fine as long as that version is not SSLv2. See http://en.wikipedia.org/wiki/Transport_Layer_Security#Security\n",
"Perhaps we should attempt a fallback?\n",
"I don't think this issue is actually related to SSLv2 at all. Browsers don't support SSLv2 and as far as I can tell https://*.sharepoint.com is using TLSv1. I think we need more information from the bug reporter in order to continue such as the specific version of openssl in question and what protocol is being used.\n\n```\n% openssl version\n% openssl s_client -connect subdomain.sharepoint.com:443\n```\n\nThe output should contain something along the lines of `Protocol : TLSv1`.\n\nA specific URL that others can try that triggers the problem would also be quite helpful.\n",
"Is there a workaround for this? I am having the same issue.\n\n> > > import requests\n> > > requests.get('https://fed.princeton.edu')\n> > > Traceback (most recent call last):\n> > > File \"<pyshell#6>\", line 1, in <module>\n> > > requests.get('https://fed.princeton.edu')\n> > > File \"C:\\Python32\\lib\\site-packages\\requests-0.13.2-py3.2.egg\\requests\\api.py\", line 54, in get\n> > > return request('get', url, *_kwargs)\n> > > File \"C:\\Python32\\lib\\site-packages\\requests-0.13.2-py3.2.egg\\requests\\safe_mode.py\", line 37, in wrapped\n> > > return function(method, url, *_kwargs)\n> > > File \"C:\\Python32\\lib\\site-packages\\requests-0.13.2-py3.2.egg\\requests\\api.py\", line 42, in request\n> > > return s.request(method=method, url=url, **kwargs)\n> > > File \"C:\\Python32\\lib\\site-packages\\requests-0.13.2-py3.2.egg\\requests\\sessions.py\", line 230, in request\n> > > r.send(prefetch=prefetch)\n> > > File \"C:\\Python32\\lib\\site-packages\\requests-0.13.2-py3.2.egg\\requests\\models.py\", line 605, in send\n> > > raise SSLError(e)\n> > > requests.exceptions.SSLError: [Errno 1] _ssl.c:392: error:140773F2:SSL routines:SSL23_GET_SERVER_HELLO:sslv3 alert unexpected message\n\nApparently, the issue lies with the page enforcing only SSLv3 and urllib fails. Another verification with urrlib:\n\n> > > import urllib.request\n> > > urllib.request.urlopen('https://fed.princeton.edu')\n> > > Traceback (most recent call last):\n> > > File \"<pyshell#4>\", line 1, in <module>\n> > > urllib.request.urlopen('https://fed.princeton.edu')\n> > > File \"C:\\Python32\\lib\\urllib\\request.py\", line 138, in urlopen\n> > > return opener.open(url, data, timeout)\n> > > File \"C:\\Python32\\lib\\urllib\\request.py\", line 369, in open\n> > > response = self._open(req, data)\n> > > File \"C:\\Python32\\lib\\urllib\\request.py\", line 387, in _open\n> > > '_open', req)\n> > > File \"C:\\Python32\\lib\\urllib\\request.py\", line 347, in _call_chain\n> > > result = func(*args)\n> > > File \"C:\\Python32\\lib\\urllib\\request.py\", line 1171, in https_open\n> > > context=self._context, check_hostname=self._check_hostname)\n> > > File \"C:\\Python32\\lib\\urllib\\request.py\", line 1138, in do_open\n> > > raise URLError(err)\n> > > urllib.error.URLError: <urlopen error [Errno 1] _ssl.c:392: error:140773F2:SSL routines:SSL23_GET_SERVER_HELLO:sslv3 alert unexpected message>\n\nSome references:\n\n```\nhttp://stackoverflow.com/questions/9835506/urllib-urlopen-works-on-sslv3-urls-with-python-2-6-6-on-1-machine-but-not-wit\nhttp://bugs.python.org/issue11220\n```\n\nBy using a urllib.install_opener trick from http://bugs.python.org/issue11220 I am able to get the object without error with urllib.\n\n> > > import urllib.request\n> > > import ssl\n> > > https_sslv3_handler = urllib.request.HTTPSHandler(context=ssl.SSLContext(ssl.PROTOCOL_SSLv3))\n> > > opener = urllib.request.build_opener(https_sslv3_handler)\n> > > urllib.request.install_opener(opener)\n> > > urllib.request.urlopen('https://fed.princeton.edu')\n> > > <http.client.HTTPResponse object at 0x0000000003457390>\n",
"I got around this issue by adjusting a line in my ssl.py file and adding it to my virtualenv:\n\n```\n$ cp /usr/lib/python2.7/ssl.py $VIRTUAL_ENV/lib/python2.7\n$ vim $VIRTUAL_ENV/lib/python2.7/ssl.py\n```\n\non line 372 change `PROTOCOL_SSLv23` to `PROTOCOL_SSLv3`\n\nObviously this might have some crazy side effects, but it's contained to my virtual env for the bits of code that need it.\n",
"Closing for now.\n",
"This issue is biting me trying to access https://www.torproject.org/projects/torbrowser.html.en\n",
"@von \nWhat version of openssl are you using? Is your connection using TLSv1?\n\nI do not get the same problem when accessing torproject.org:\n\n> import requests\n> requests.get('https://www.torproject.org/projects/torbrowser.html.en')\n> < Response [200] >\n\nThis issue must be related to your network setup or the version of openssl you are using.\n",
"@davidfischer > What version of openssl are you using? Is your connection using TLSv1?\n\n$ openssl version\nOpenSSL 0.9.8r 8 Feb 2011\n\nEDITED to correct:\n\n> > > ssl.OPENSSL_VERSION\n> > > 'OpenSSL 0.9.7l 28 Sep 2006'\n\n$ python -V\nPython 2.7.1\n\nLooks like TLSv1 from what I can tell...\n$ openssl s_client -connect www.torproject.org:443 | grep Protocol\ndepth=2 /C=US/O=DigiCert Inc/OU=www.digicert.com/CN=DigiCert High Assurance EV Root CA\nverify error:num=20:unable to get local issuer certificate\nverify return:0\n Protocol : TLSv1\n...\n\nAnd to verify:\n\n> > > import requests\n> > > requests.get('https://www.torproject.org/projects/torbrowser.html.en')\n> > > Traceback (most recent call last):\n> > > File \"<stdin>\", line 1, in <module>\n> > > File \"/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/requests-0.13.9-py2.7.egg/requests/api.py\", line 65, in get\n> > > return request('get', url, *_kwargs)\n> > > File \"/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/requests-0.13.9-py2.7.egg/requests/safe_mode.py\", line 39, in wrapped\n> > > return function(method, url, *_kwargs)\n> > > File \"/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/requests-0.13.9-py2.7.egg/requests/api.py\", line 51, in request\n> > > return session.request(method=method, url=url, **kwargs)\n> > > File \"/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/requests-0.13.9-py2.7.egg/requests/sessions.py\", line 252, in request\n> > > r.send(prefetch=prefetch)\n> > > File \"/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/requests-0.13.9-py2.7.egg/requests/models.py\", line 632, in send\n> > > raise SSLError(e)\n> > > requests.exceptions.SSLError: [Errno 1] _ssl.c:499: error:140770FC:SSL routines:SSL23_GET_SERVER_HELLO:unknown protocol\n",
"@davidfischer Thanks for the pointer about the old version of openssl, updating to 2.7.3 with the latest Mac installer fixed it.\n\n```\n$ python\nPython 2.7.3 (v2.7.3:70274d53c1dd, Apr 9 2012, 20:52:43)\n[GCC 4.2.1 (Apple Inc. build 5666) (dot 3)] on darwin\nType \"help\", \"copyright\", \"credits\" or \"license\" for more information.\n>>> import ssl\n>>> ssl.OPENSSL_VERSION\n'OpenSSL 0.9.8r 8 Feb 2011'\n>>> import requests\n>>> requests.get('https://www.torproject.org/projects/torbrowser.html.en')\n<Response [200]>\n```\n",
"@von \nGood point about the version of openssl Python is using, not just the openssl version on the system. Glad we got it resolved.\n",
"For posterity, it sounds like this is solved in OpenSSL 1.0.1a\n\nc.f. http://trac.macports.org/ticket/33715\n",
"FWIW, this is not solved with OpenSSL 1.0.1a (1.0.1f still shows the problem)\n\n``` python\n>>> import requests\n>>> requests.get('https://www.u-gov.sssup.it')\nTraceback (most recent call last):\n File \"/home/dario/.local/share/virtualenvs/6e75bebf401c6c9/lib/python3.3/site-packages/requests/packages/urllib3/connectionpool.py\", line 480, in urlopen\n body=body, headers=headers)\n File \"/home/dario/.local/share/virtualenvs/6e75bebf401c6c9/lib/python3.3/site-packages/requests/packages/urllib3/connectionpool.py\", line 285, in _make_request\n conn.request(method, url, **httplib_request_kw)\n File \"/nix/store/xiqf99vr3b3fhzqfsdvx0aharx1h5s96-python3-3.3.3/lib/python3.3/http/client.py\", line 1065, in request\n self._send_request(method, url, body, headers)\n File \"/nix/store/xiqf99vr3b3fhzqfsdvx0aharx1h5s96-python3-3.3.3/lib/python3.3/http/client.py\", line 1103, in _send_request\n self.endheaders(body)\n File \"/nix/store/xiqf99vr3b3fhzqfsdvx0aharx1h5s96-python3-3.3.3/lib/python3.3/http/client.py\", line 1061, in endheaders\n self._send_output(message_body)\n File \"/nix/store/xiqf99vr3b3fhzqfsdvx0aharx1h5s96-python3-3.3.3/lib/python3.3/http/client.py\", line 906, in _send_output\n self.send(msg)\n File \"/nix/store/xiqf99vr3b3fhzqfsdvx0aharx1h5s96-python3-3.3.3/lib/python3.3/http/client.py\", line 844, in send\n self.connect()\n File \"/home/dario/.local/share/virtualenvs/6e75bebf401c6c9/lib/python3.3/site-packages/requests/packages/urllib3/connection.py\", line 164, in connect\n ssl_version=resolved_ssl_version)\n File \"/home/dario/.local/share/virtualenvs/6e75bebf401c6c9/lib/python3.3/site-packages/requests/packages/urllib3/util.py\", line 639, in ssl_wrap_socket\n return context.wrap_socket(sock, server_hostname=server_hostname)\n File \"/nix/store/xiqf99vr3b3fhzqfsdvx0aharx1h5s96-python3-3.3.3/lib/python3.3/ssl.py\", line 245, in wrap_socket\n _context=self)\n File \"/nix/store/xiqf99vr3b3fhzqfsdvx0aharx1h5s96-python3-3.3.3/lib/python3.3/ssl.py\", line 345, in __init__\n raise x\n File \"/nix/store/xiqf99vr3b3fhzqfsdvx0aharx1h5s96-python3-3.3.3/lib/python3.3/ssl.py\", line 341, in __init__\n self.do_handshake()\n File \"/nix/store/xiqf99vr3b3fhzqfsdvx0aharx1h5s96-python3-3.3.3/lib/python3.3/ssl.py\", line 548, in do_handshake\n self._sslobj.do_handshake()\nssl.SSLError: [SSL] unknown error (_ssl.c:550)\n\nDuring handling of the above exception, another exception occurred:\n\nTraceback (most recent call last):\n File \"/home/dario/.local/share/virtualenvs/6e75bebf401c6c9/lib/python3.3/site-packages/requests/adapters.py\", line 330, in send\n timeout=timeout\n File \"/home/dario/.local/share/virtualenvs/6e75bebf401c6c9/lib/python3.3/site-packages/requests/packages/urllib3/connectionpool.py\", line 504, in urlopen\n raise SSLError(e)\nrequests.packages.urllib3.exceptions.SSLError: [SSL] unknown error (_ssl.c:550)\n\nDuring handling of the above exception, another exception occurred:\n\nTraceback (most recent call last):\n File \"<stdin>\", line 1, in <module>\n File \"/home/dario/.local/share/virtualenvs/6e75bebf401c6c9/lib/python3.3/site-packages/requests/api.py\", line 55, in get\n return request('get', url, **kwargs)\n File \"/home/dario/.local/share/virtualenvs/6e75bebf401c6c9/lib/python3.3/site-packages/requests/api.py\", line 44, in request\n return session.request(method=method, url=url, **kwargs)\n File \"/home/dario/.local/share/virtualenvs/6e75bebf401c6c9/lib/python3.3/site-packages/requests/sessions.py\", line 383, in request\n resp = self.send(prep, **send_kwargs)\n File \"/home/dario/.local/share/virtualenvs/6e75bebf401c6c9/lib/python3.3/site-packages/requests/sessions.py\", line 486, in send\n r = adapter.send(request, **kwargs)\n File \"/home/dario/.local/share/virtualenvs/6e75bebf401c6c9/lib/python3.3/site-packages/requests/adapters.py\", line 385, in send\n raise SSLError(e)\nrequests.exceptions.SSLError: [SSL] unknown error (_ssl.c:550)\n>>> import ssl\n>>> ssl.OPENSSL_VERSION\n'OpenSSL 1.0.1f 6 Jan 2014'\n```\n",
"If you are encountering problems I encourage you to use the [SSLAdapter](http://toolbelt.readthedocs.org/en/latest/user.html#ssladapter) from the `requests-toolbelt`. This allows you to specify an SSL version to use for a specific site or set of sites.\n",
"Thanks \n\nI had already solved it by installing a custom opener with urllib, but I was looking into requests hoping that it offered a less cumbersome way to do it.\n\nIt's a pity that it's not shipped in requests itself, but the toolbelt is what I was looking for... thanks!\n",
"Here's a monkey patching variant of the solution courtesy of [ryanmark](https://github.com/ryanmark)'s solution above, which should work for all Python SSL clients.\n\n```\nimport ssl\nfrom functools import wraps\ndef sslwrap(func):\n @wraps(func)\n def bar(*args, **kw):\n kw['ssl_version'] = ssl.PROTOCOL_TLSv1\n return func(*args, **kw)\n return bar\n\nssl.wrap_socket = sslwrap(ssl.wrap_socket)\n```\n",
"This is how I figured out and fixed the issue on my debian system.\r\nRun nmap to figure out what ssl version is being used by the server\r\nnmap -p443 -sV --script ssl-enum-ciphers 10.10.10.7\r\noutput says TLSv1.0\r\n\r\ntest 10.10.10.7 using example in this comment (gets expected error)\r\nhttps://github.com/requests/requests/issues/606#issuecomment-8036266\r\n\r\ntest with openssl binary (gets expected error)\r\nopenssl s_client -connect 10.10.10.7:443\r\n\r\nfix by editing this value-->MinProtocol = TLSv1.0\r\nin this file--> /etc/ssl/openssl.cnf\r\n\r\nrerun tests without error.\r\nNote the outdated server I am connecting to is internal, non-production, not connected to the internet. "
] |
https://api.github.com/repos/psf/requests/issues/605
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/605/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/605/comments
|
https://api.github.com/repos/psf/requests/issues/605/events
|
https://github.com/psf/requests/issues/605
| 4,522,903 |
MDU6SXNzdWU0NTIyOTAz
| 605 |
async broken on Windows
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/92239?v=4",
"events_url": "https://api.github.com/users/piotr-dobrogost/events{/privacy}",
"followers_url": "https://api.github.com/users/piotr-dobrogost/followers",
"following_url": "https://api.github.com/users/piotr-dobrogost/following{/other_user}",
"gists_url": "https://api.github.com/users/piotr-dobrogost/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/piotr-dobrogost",
"id": 92239,
"login": "piotr-dobrogost",
"node_id": "MDQ6VXNlcjkyMjM5",
"organizations_url": "https://api.github.com/users/piotr-dobrogost/orgs",
"received_events_url": "https://api.github.com/users/piotr-dobrogost/received_events",
"repos_url": "https://api.github.com/users/piotr-dobrogost/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/piotr-dobrogost/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/piotr-dobrogost/subscriptions",
"type": "User",
"url": "https://api.github.com/users/piotr-dobrogost",
"user_view_type": "public"
}
|
[
{
"color": "e10c02",
"default": false,
"description": null,
"id": 117744,
"name": "Bug",
"node_id": "MDU6TGFiZWwxMTc3NDQ=",
"url": "https://api.github.com/repos/psf/requests/labels/Bug"
}
] |
closed
| true | null |
[] | null | 2 |
2012-05-10T21:41:00Z
|
2021-09-09T08:00:43Z
|
2012-05-10T23:35:07Z
|
NONE
|
resolved
|
Running below code
``` python
from requests import async
if __name__ == '__main__':
req = async.get('http://httpbin.org/get')
res = async.map([req])[0]
print res.content
```
I get
```
Traceback (most recent call last):
File "C:\python\virtualenv\requests\lib\site-packages\gevent-0.13.7-py2.7-win-amd64.egg\gevent\greenlet.py", line 390, in run
result = self._run(*self.args, **self.kwargs)
File "C:\Users\Piotr\projects\requests\requests\models.py", line 606, in send
raise ConnectionError(e)
ConnectionError: HTTPConnectionPool(host='httpbin.org', port=80): Max retries exceeded with url: /get
<Greenlet at 0x35e59c8L: <bound method Request.send of <Request [GET]>>(prefetch=True)> failed with ConnectionError
None
```
in about 90% cases.
Requests 0.12.1
gevent 0.13.7-py2.7-win-amd64
greenlet 0.3.4-py2.7-win-amd64
Python 2.7.3 64bit
Windows Vista 64bit
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/376448?v=4",
"events_url": "https://api.github.com/users/slingamn/events{/privacy}",
"followers_url": "https://api.github.com/users/slingamn/followers",
"following_url": "https://api.github.com/users/slingamn/following{/other_user}",
"gists_url": "https://api.github.com/users/slingamn/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/slingamn",
"id": 376448,
"login": "slingamn",
"node_id": "MDQ6VXNlcjM3NjQ0OA==",
"organizations_url": "https://api.github.com/users/slingamn/orgs",
"received_events_url": "https://api.github.com/users/slingamn/received_events",
"repos_url": "https://api.github.com/users/slingamn/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/slingamn/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/slingamn/subscriptions",
"type": "User",
"url": "https://api.github.com/users/slingamn",
"user_view_type": "public"
}
|
{
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/605/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/605/timeline
| null |
completed
| null | null | false |
[
"See also #500.\n",
"Closing in favor of kennethreitz/grequests#2\n"
] |
https://api.github.com/repos/psf/requests/issues/604
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/604/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/604/comments
|
https://api.github.com/repos/psf/requests/issues/604/events
|
https://github.com/psf/requests/pull/604
| 4,514,833 |
MDExOlB1bGxSZXF1ZXN0MTMyNTkyOA==
| 604 |
New implementation of safe_mode.
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/1443719?v=4",
"events_url": "https://api.github.com/users/joshimhoff/events{/privacy}",
"followers_url": "https://api.github.com/users/joshimhoff/followers",
"following_url": "https://api.github.com/users/joshimhoff/following{/other_user}",
"gists_url": "https://api.github.com/users/joshimhoff/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/joshimhoff",
"id": 1443719,
"login": "joshimhoff",
"node_id": "MDQ6VXNlcjE0NDM3MTk=",
"organizations_url": "https://api.github.com/users/joshimhoff/orgs",
"received_events_url": "https://api.github.com/users/joshimhoff/received_events",
"repos_url": "https://api.github.com/users/joshimhoff/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/joshimhoff/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/joshimhoff/subscriptions",
"type": "User",
"url": "https://api.github.com/users/joshimhoff",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 3 |
2012-05-10T14:59:32Z
|
2021-09-08T15:01:07Z
|
2012-05-10T18:06:25Z
|
NONE
|
resolved
|
We throw exceptions in models.py even if in safe_mode. We catch those exceptions at the API level and return a blank Response with the error field filled with the exception thrown. See safe_mode.py for details.
Discussed here: #583
|
{
"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/604/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/604/timeline
| null | null | false |
{
"diff_url": "https://github.com/psf/requests/pull/604.diff",
"html_url": "https://github.com/psf/requests/pull/604",
"merged_at": "2012-05-10T18:06:25Z",
"patch_url": "https://github.com/psf/requests/pull/604.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/604"
}
| true |
[
"This pull request [passes](http://travis-ci.org/kennethreitz/requests/builds/1295925) (merged cff70e75 into 2d328d8a).\n",
"This pull request [passes](http://travis-ci.org/kennethreitz/requests/builds/1296854) (merged db43eb4c into 2d328d8a).\n",
"Fantastic work! This is much cleaner. \n\n:sparkles: :cake: :sparkles:\n"
] |
https://api.github.com/repos/psf/requests/issues/603
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/603/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/603/comments
|
https://api.github.com/repos/psf/requests/issues/603/events
|
https://github.com/psf/requests/pull/603
| 4,513,816 |
MDExOlB1bGxSZXF1ZXN0MTMyNTQ3Mg==
| 603 |
get cookie like dict, such as s.cookies.get('test', 'no cookie')
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/173095?v=4",
"events_url": "https://api.github.com/users/benmao/events{/privacy}",
"followers_url": "https://api.github.com/users/benmao/followers",
"following_url": "https://api.github.com/users/benmao/following{/other_user}",
"gists_url": "https://api.github.com/users/benmao/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/benmao",
"id": 173095,
"login": "benmao",
"node_id": "MDQ6VXNlcjE3MzA5NQ==",
"organizations_url": "https://api.github.com/users/benmao/orgs",
"received_events_url": "https://api.github.com/users/benmao/received_events",
"repos_url": "https://api.github.com/users/benmao/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/benmao/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/benmao/subscriptions",
"type": "User",
"url": "https://api.github.com/users/benmao",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 2 |
2012-05-10T14:18:20Z
|
2021-09-08T15:01:06Z
|
2012-05-10T18:07:01Z
|
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/603/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/603/timeline
| null | null | false |
{
"diff_url": "https://github.com/psf/requests/pull/603.diff",
"html_url": "https://github.com/psf/requests/pull/603",
"merged_at": "2012-05-10T18:07:00Z",
"patch_url": "https://github.com/psf/requests/pull/603.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/603"
}
| true |
[
"This pull request [passes](http://travis-ci.org/kennethreitz/requests/builds/1295371) (merged 44663b5e into 2d328d8a).\n",
"+1 to this. Thanks!\n"
] |
|
https://api.github.com/repos/psf/requests/issues/602
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/602/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/602/comments
|
https://api.github.com/repos/psf/requests/issues/602/events
|
https://github.com/psf/requests/issues/602
| 4,500,221 |
MDU6SXNzdWU0NTAwMjIx
| 602 |
requests.head redirect timeout (on only linux environments?)
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/285920?v=4",
"events_url": "https://api.github.com/users/umbrae/events{/privacy}",
"followers_url": "https://api.github.com/users/umbrae/followers",
"following_url": "https://api.github.com/users/umbrae/following{/other_user}",
"gists_url": "https://api.github.com/users/umbrae/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/umbrae",
"id": 285920,
"login": "umbrae",
"node_id": "MDQ6VXNlcjI4NTkyMA==",
"organizations_url": "https://api.github.com/users/umbrae/orgs",
"received_events_url": "https://api.github.com/users/umbrae/received_events",
"repos_url": "https://api.github.com/users/umbrae/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/umbrae/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/umbrae/subscriptions",
"type": "User",
"url": "https://api.github.com/users/umbrae",
"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,
"name": "Planned",
"node_id": "MDU6TGFiZWwxMTc3NDU=",
"url": "https://api.github.com/repos/psf/requests/labels/Planned"
}
] |
closed
| true | null |
[] | null | 7 |
2012-05-09T19:55:44Z
|
2021-09-09T07:05:20Z
|
2012-07-27T06:14:15Z
|
CONTRIBUTOR
|
resolved
|
On OSX I can run this fine:
``` python
# python2.6
Python 2.6.7 (r267:88850, Jul 31 2011, 19:30:54)
[GCC 4.2.1 (Based on Apple Inc. build 5658) (LLVM build 2335.15.00)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> import requests
>>> r = requests.head("http://feedproxy.google.com/~r/Techcrunch/~3/1P88-kHZWGs/", allow_redirects=True, timeout=10)
>>> r
<Response [200]>
>>> r.history
[<Response [301]>]
>>> requests.__version__
'0.12.1'
```
However, the same request on an Ubuntu box times out - in multiple network environments:
``` python
# python
Python 2.6.5 (r265:79063, Apr 16 2010, 13:57:41)
[GCC 4.4.3] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> import requests
>>> r = requests.head("http://feedproxy.google.com/~r/Techcrunch/~3/1P88-kHZWGs/", allow_redirects=True, timeout=10)
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/home/ubuntu/envs/rdb/lib/python2.6/site-packages/requests/api.py", line 74, in head
return request('head', url, **kwargs)
File "/home/ubuntu/envs/rdb/lib/python2.6/site-packages/requests/api.py", line 40, in request
return s.request(method=method, url=url, **kwargs)
File "/home/ubuntu/envs/rdb/lib/python2.6/site-packages/requests/sessions.py", line 229, in request
r.send(prefetch=prefetch)
File "/home/ubuntu/envs/rdb/lib/python2.6/site-packages/requests/models.py", line 624, in send
self._build_response(r)
File "/home/ubuntu/envs/rdb/lib/python2.6/site-packages/requests/models.py", line 227, in _build_response
r.content # Consume socket so it can be released
File "/home/ubuntu/envs/rdb/lib/python2.6/site-packages/requests/models.py", line 782, in content
self._content = bytes().join(self.iter_content(CONTENT_CHUNK_SIZE)) or bytes()
File "/home/ubuntu/envs/rdb/lib/python2.6/site-packages/requests/models.py", line 728, in generate
chunk = self.raw.read(chunk_size)
File "/home/ubuntu/envs/rdb/lib/python2.6/site-packages/requests/packages/urllib3/response.py", line 146, in read
return self._fp.read(amt)
File "/usr/lib/python2.6/httplib.py", line 518, in read
return self._read_chunked(amt)
File "/usr/lib/python2.6/httplib.py", line 551, in _read_chunked
line = self.fp.readline()
File "/usr/lib/python2.6/socket.py", line 397, in readline
data = recv(1)
socket.timeout: timed out
>>> requests.__version__
'0.12.1'
```
Looks like some sort of chunk reading issue?
|
{
"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/602/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/602/timeline
| null |
completed
| null | null | false |
[
"Hmm, interesting. Thanks for the URL, we'll have to dive in further.\n",
"DNR for me in Fedora with Python 2.7.3 and 3.2.1. Interesting.\n",
"DNR in Ubuntu Precise with Python 2.7.3 as well.\n",
"Here's a quick workaround for anyone else who happens to encounter this before a fix:\n\n``` python\n\nimport requests\nfrom requests.utils import requote_uri\nfrom urlparse import urlparse, urljoin\n\ndef unroll_url(url, max_redirects=30, timeout=None, history=None):\n if history is None:\n history = set()\n\n if max_redirects <= 0:\n raise requests.exceptions.TooManyRedirects()\n\n if url in history:\n raise requests.exceptions.RequestException(\"Redirect loop detected.\")\n\n history.add(url)\n\n r = requests.head(url, timeout=timeout, allow_redirects=False)\n if r.status_code in set([301, 302, 303, 307]) and 'location' in r.headers:\n redirect_url = r.headers['location']\n\n # Handle redirection without scheme (see: RFC 1808 Section 4)\n if redirect_url.startswith('//'):\n parsed_original_url = urlparse(url)\n redirect_url = '%s:%s' % (parsed_original_url.scheme, url)\n\n # Facilitate non-RFC2616-compliant 'location' headers\n # (e.g. '/path/to/resource' instead of 'http://domain.tld/path/to/resource')\n if not urlparse(redirect_url).netloc:\n redirect_url = urljoin(url, requote_uri(redirect_url))\n\n return unroll_url(redirect_url,\n max_redirects = max_redirects - 1,\n timeout = timeout,\n history = history)\n\n return r.url\n```\n\n[Edit: Updated this to include non-absolute URL support, infinite loop redirect checking.]\n",
"I was able to repro on Ubuntu 10.04\n\n``` python\nPython 2.6.5 (r265:79063, Apr 16 2010, 13:09:56) \n[GCC 4.4.3] on linux2\nType \"help\", \"copyright\", \"credits\" or \"license\" for more information.\n>>> import requests\n>>> r = requests.head(\"http://feedproxy.google.com/~r/Techcrunch/~3/1P88-kHZWGs/\", allow_redirects=True, timeout=10)\nTraceback (most recent call last):\n File \"<stdin>\", line 1, in <module>\n File \"/home/david/.virtualenvs/testenv/lib/python2.6/site-packages/requests/api.py\", line 74, in head\n return request('head', url, **kwargs)\nFile \"/home/david/.virtualenvs/testenv/lib/python2.6/site-packages/requests/api.py\", line 40, in request\n return s.request(method=method, url=url, **kwargs)\nFile \"/home/david/.virtualenvs/testenv/lib/python2.6/site-packages/requests/sessions.py\", line 229, in request\n r.send(prefetch=prefetch)\nFile \"/home/david/.virtualenvs/testenv/lib/python2.6/site-packages/requests/models.py\", line 624, in send\n self._build_response(r)\n File \"/home/david/.virtualenvs/testenv/lib/python2.6/site-packages/requests/models.py\", line 227, in _build_response\n r.content # Consume socket so it can be released\nFile \"/home/david/.virtualenvs/testenv/lib/python2.6/site-packages/requests/models.py\", line 782, in content\n self._content = bytes().join(self.iter_content(CONTENT_CHUNK_SIZE)) or bytes()\nFile \"/home/david/.virtualenvs/testenv/lib/python2.6/site-packages/requests/models.py\", line 728, in generate\n chunk = self.raw.read(chunk_size)\nFile \"/home/david/.virtualenvs/testenv/lib/python2.6/site-packages/requests/packages/urllib3/response.py\", line 146, in read\n return self._fp.read(amt)\nFile \"/usr/lib/python2.6/httplib.py\", line 518, in read\n return self._read_chunked(amt)\nFile \"/usr/lib/python2.6/httplib.py\", line 551, in _read_chunked\n line = self.fp.readline()\nFile \"/usr/lib/python2.6/socket.py\", line 397, in readline\n data = recv(1)\n socket.timeout: timed out\n >>> requests.__version__\n '0.12.1'\n```\n",
"DNR for me in Ubuntu Lucid (10.04) with Python 2.6.7:\n\n```\n\n$ python\nPython 2.6.7 (r267:88850, Dec 2 2011, 20:27:26) \n[GCC 4.4.3] on linux2\nType \"help\", \"copyright\", \"credits\" or \"license\" for more information.\n>>> import requests\n>>> r = requests.head(\"http://feedproxy.google.com/~r/Techcrunch/~3/1P88-kHZWGs/\", allow_redirects=True, timeout=10)\n>>> r.status_code\n200\n>>> requests.__version__\n'0.12.1'\n```\n\nI'm starting to believe it's specific to 2.6.5.\n",
"(I guess Lucid officially packages 2.6.5, and I have 2.6.7 via a separate package repository.)\n"
] |
https://api.github.com/repos/psf/requests/issues/601
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/601/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/601/comments
|
https://api.github.com/repos/psf/requests/issues/601/events
|
https://github.com/psf/requests/issues/601
| 4,487,645 |
MDU6SXNzdWU0NDg3NjQ1
| 601 |
document testing practices
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/376448?v=4",
"events_url": "https://api.github.com/users/slingamn/events{/privacy}",
"followers_url": "https://api.github.com/users/slingamn/followers",
"following_url": "https://api.github.com/users/slingamn/following{/other_user}",
"gists_url": "https://api.github.com/users/slingamn/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/slingamn",
"id": 376448,
"login": "slingamn",
"node_id": "MDQ6VXNlcjM3NjQ0OA==",
"organizations_url": "https://api.github.com/users/slingamn/orgs",
"received_events_url": "https://api.github.com/users/slingamn/received_events",
"repos_url": "https://api.github.com/users/slingamn/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/slingamn/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/slingamn/subscriptions",
"type": "User",
"url": "https://api.github.com/users/slingamn",
"user_view_type": "public"
}
|
[
{
"color": "e102d8",
"default": false,
"description": null,
"id": 117745,
"name": "Planned",
"node_id": "MDU6TGFiZWwxMTc3NDU=",
"url": "https://api.github.com/repos/psf/requests/labels/Planned"
},
{
"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 | 8 |
2012-05-09T07:15:07Z
|
2021-09-09T05:30:46Z
|
2012-11-27T01:36:37Z
|
CONTRIBUTOR
|
resolved
|
Currently, as @djco and @arfrever note, the Makefile doesn't make it into the Pypi tarball, and a plain invocation of `nosetests` doesn't run the right tests. So if you've downloaded Requests and you want to run the tests, it's not clear how. This is a reasonable thing to want to do.
Also, we should document which tests contributors should run before they submit their pull requests. (Ideally we would encourage contributors to run `make pyflakes`.)
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/376448?v=4",
"events_url": "https://api.github.com/users/slingamn/events{/privacy}",
"followers_url": "https://api.github.com/users/slingamn/followers",
"following_url": "https://api.github.com/users/slingamn/following{/other_user}",
"gists_url": "https://api.github.com/users/slingamn/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/slingamn",
"id": 376448,
"login": "slingamn",
"node_id": "MDQ6VXNlcjM3NjQ0OA==",
"organizations_url": "https://api.github.com/users/slingamn/orgs",
"received_events_url": "https://api.github.com/users/slingamn/received_events",
"repos_url": "https://api.github.com/users/slingamn/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/slingamn/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/slingamn/subscriptions",
"type": "User",
"url": "https://api.github.com/users/slingamn",
"user_view_type": "public"
}
|
{
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/601/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/601/timeline
| null |
completed
| null | null | false |
[
"In general, we need to document development workflow.\n",
"Does the entire repo need to be included in the PyPI tarball? Is it unreasonable to ask that people who plan to make pull requests on the repo actually get the repo from the origin? (As mentioned here https://github.com/kennethreitz/requests#contribute)\n\nI feel like the PyPI tarball should only include what end-users need to use the library, not necessarily what's needed to contribute back to it.\n",
"I think the idea isn't so much that they want to hack on the tarball or patch it, but that they want to be sure that everything is working as expected on their system.\n",
"I not a fan of including extra things in the distribution. As a user, downloading extra stuff when installing a module often bothers me.\n",
"Some package managers, like Gentoo's, can run tests to check the package is working before installing it in the system. Though in requests' case it wouldn't be useful, as they forbid making network requests.\n",
"Portage (official package manager in Gentoo) does not forbid network requests, so tests of dev-python/requests package pass when internet connection is available.\n",
"@slingamn do #611 and #962 satisfy your desire for better documented testing practices?\n",
"Yeah, legit.\n\nAs a sidenote: the tests should not have to be run (or pass) as part of any automated package build.\n"
] |
https://api.github.com/repos/psf/requests/issues/600
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/600/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/600/comments
|
https://api.github.com/repos/psf/requests/issues/600/events
|
https://github.com/psf/requests/issues/600
| 4,480,818 |
MDU6SXNzdWU0NDgwODE4
| 600 |
tests/test_requests_ext.py uses assertIn and assertNotIn not available in Python <2.7
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/656294?v=4",
"events_url": "https://api.github.com/users/Arfrever/events{/privacy}",
"followers_url": "https://api.github.com/users/Arfrever/followers",
"following_url": "https://api.github.com/users/Arfrever/following{/other_user}",
"gists_url": "https://api.github.com/users/Arfrever/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Arfrever",
"id": 656294,
"login": "Arfrever",
"node_id": "MDQ6VXNlcjY1NjI5NA==",
"organizations_url": "https://api.github.com/users/Arfrever/orgs",
"received_events_url": "https://api.github.com/users/Arfrever/received_events",
"repos_url": "https://api.github.com/users/Arfrever/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Arfrever/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Arfrever/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Arfrever",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 6 |
2012-05-08T20:35:18Z
|
2021-09-09T07:05:27Z
|
2012-07-27T05:58:53Z
|
NONE
|
resolved
|
```
$ nosetests-2.6 tests/test_requests_ext.py
...E.......
======================================================================
ERROR: Test interaction between cookie handling and redirection.
----------------------------------------------------------------------
Traceback (most recent call last):
File "/tmp/requests-0.12.1/tests/test_requests_ext.py", line 113, in test_cookies_on_redirects
self.assertIn('preview', s.cookies)
AttributeError: 'RequestsTestSuite' object has no attribute 'assertIn'
-------------------- >> begin captured logging << --------------------
requests.packages.urllib3.connectionpool: INFO: Starting new HTTP connection (1): tinyurl.com
requests.packages.urllib3.connectionpool: DEBUG: "GET /preview.php?disable=1 ('HTTP/1.1',)" 200 None
--------------------- >> end captured logging << ---------------------
----------------------------------------------------------------------
Ran 11 tests in 7.449s
FAILED (errors=1)
```
The fix:
```
--- tests/test_requests_ext.py
+++ tests/test_requests_ext.py
@@ -110,7 +110,7 @@
s = requests.session()
s.get(url='http://tinyurl.com/preview.php?disable=1')
# we should have set a cookie for tinyurl: preview=0
- self.assertIn('preview', s.cookies)
+ self.assertTrue('preview' in s.cookies)
self.assertEqual(s.cookies['preview'], '0')
self.assertEqual(list(s.cookies)[0].name, 'preview')
self.assertEqual(list(s.cookies)[0].domain, 'tinyurl.com')
@@ -118,13 +118,13 @@
# get cookies on another domain
r2 = s.get(url='http://httpbin.org/cookies')
# the cookie is not there
- self.assertNotIn('preview', json.loads(r2.text)['cookies'])
+ self.assertTrue('preview' not in json.loads(r2.text)['cookies'])
# this redirects to another domain, httpbin.org
# cookies of the first domain should NOT be sent to the next one
r3 = s.get(url='http://tinyurl.com/7zp3jnr')
assert r3.url == 'http://httpbin.org/cookies'
- self.assertNotIn('preview', json.loads(r2.text)['cookies'])
+ self.assertTrue('preview' not in json.loads(r3.text)['cookies'])
if __name__ == '__main__':
unittest.main()
```
I have changed r2.text to r3.text in the last changed line.
|
{
"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/600/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/600/timeline
| null |
completed
| null | null | false |
[
"This is a good point. `test_requests_ext.py` is technically not part of our standard test suite, which is why this isn't breaking the build, but this is not good. Can you turn this diff into a pull request and submit it?\n",
"I would attach a patch if this bug tracker supported attachments.\n",
"@Arfrever are you familiar with the forking / pull-request model? http://help.github.com/send-pull-requests/\n",
"@slingman apparently not ;)\n",
"So could you commit this patch?\n",
"@Arfrever\nFork this repository. Clone it locally to your machine. Make the change. Push it to your fork. Submit a pull request referencing this issue. It will give you attribution for the fix.\n"
] |
https://api.github.com/repos/psf/requests/issues/599
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/599/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/599/comments
|
https://api.github.com/repos/psf/requests/issues/599/events
|
https://github.com/psf/requests/issues/599
| 4,478,569 |
MDU6SXNzdWU0NDc4NTY5
| 599 |
Stream POST requests
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/112152?v=4",
"events_url": "https://api.github.com/users/e98cuenc/events{/privacy}",
"followers_url": "https://api.github.com/users/e98cuenc/followers",
"following_url": "https://api.github.com/users/e98cuenc/following{/other_user}",
"gists_url": "https://api.github.com/users/e98cuenc/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/e98cuenc",
"id": 112152,
"login": "e98cuenc",
"node_id": "MDQ6VXNlcjExMjE1Mg==",
"organizations_url": "https://api.github.com/users/e98cuenc/orgs",
"received_events_url": "https://api.github.com/users/e98cuenc/received_events",
"repos_url": "https://api.github.com/users/e98cuenc/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/e98cuenc/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/e98cuenc/subscriptions",
"type": "User",
"url": "https://api.github.com/users/e98cuenc",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 7 |
2012-05-08T18:39:43Z
|
2021-09-09T08:00:42Z
|
2012-05-10T18:20:56Z
|
NONE
|
resolved
|
I want to make POST requests with a big payload, and right now I have to be able to hold the full payload in memory to do the POST.
It be cool to accept a generator as the "data" argument of requests.post.
|
{
"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/599/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/599/timeline
| null |
completed
| null | null | false |
[
"This is very much planned :)\n",
"I've actually got a need for this, too. Could I take a stab at implementing it, or would you prefer I hold off?\n",
"There's a major refactor in progress ([outlined here](http://kennethreitz.com/the-future-of-python-http.html)) that will facilitate this\n",
"[Armin Ronacher's Thoughts and Writings - I am Doing HTTP Wrong](http://lucumr.pocoo.org/2012/4/14/im-doing-http-wrong/)\n",
"@piotr-dobrogost indeed, the plan is to disable streaming by default but give it a simple flag\n",
"I'd like this for POST and PUT requests.\n",
"It will be for all requests.\n"
] |
https://api.github.com/repos/psf/requests/issues/598
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/598/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/598/comments
|
https://api.github.com/repos/psf/requests/issues/598/events
|
https://github.com/psf/requests/issues/598
| 4,477,023 |
MDU6SXNzdWU0NDc3MDIz
| 598 |
Pass json objects as url parameters
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/1047165?v=4",
"events_url": "https://api.github.com/users/maebert/events{/privacy}",
"followers_url": "https://api.github.com/users/maebert/followers",
"following_url": "https://api.github.com/users/maebert/following{/other_user}",
"gists_url": "https://api.github.com/users/maebert/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/maebert",
"id": 1047165,
"login": "maebert",
"node_id": "MDQ6VXNlcjEwNDcxNjU=",
"organizations_url": "https://api.github.com/users/maebert/orgs",
"received_events_url": "https://api.github.com/users/maebert/received_events",
"repos_url": "https://api.github.com/users/maebert/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/maebert/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/maebert/subscriptions",
"type": "User",
"url": "https://api.github.com/users/maebert",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 5 |
2012-05-08T17:17:06Z
|
2021-09-08T14:00:42Z
|
2012-06-15T18:38:23Z
|
NONE
|
resolved
|
Stumbled up this while trying to use the [Freebase API](http://wiki.freebase.com/wiki/API).
Basically, their API looks like that:
```
https://www.googleapis.com/freebase/v1/mqlread?query=...
```
as a query, they expect a JSON object, here's one that will [return a list of wines with their country and percentage of alcohol](http://www.freebase.com/queryeditor?q=%5B%7B%22country%22%3Anull%2C%22name%22%3Anull%2C%22percentage_alcohol%22%3Anull%2C%22percentage_alcohol%3E%22%3A0%2C%22type%22%3A%22%2Ffood%2Fwine%22%7D%5D):
```
[{
"country": null,
"name": null,
"percentage_alcohol": null,
"percentage_alcohol>": 0,
"type": "/food/wine"
}]
```
Of course, we'll have to escape the hell out of this before passing it to an URL, so the actual query will look like this:
```
fullurl = 'https://www.googleapis.com/freebase/v1/mqlread?query=%5B%7B%22percentage_alcohol%3E%22%3A+0%2C+%22country%22%3A+null%2C+%22type%22%3A+%22%2Ffood%2Fwine%22%2C+%22name%22%3A+null%2C+%22percentage_alcohol%22%3A+null%7D%5D'
```
Now,
```
r = requests.get(fullurl)
print r.status_code
>>> 400
```
because the site claims it couldn't parse the query.
```
r2 = urllib2.urlopen(fullurl)
print r2.getcode()
>>> 200
```
No problem here, I get a proper return. Interestingly,
```
print urllib2.urlopen(r.url).getcode()
>>> 200
```
Why? Am I doing something wrong?
On a related note, it would be nice if requests would parse dictionaries as JSON in `params`:
```
baseurl = "http://localhost/"
query =[{
"name": "bill" ,
"age": 42
}]
r = requests.get(baseurl, params={'query': query})
print r.url
>>> u'http://localhost/?query=age&query=name'
```
It seems as if it is just treating `query` as an iterable.
**EDIT**:
```
r3 = urllib.urlopen(fullurl)
print r3.getcode()
>>> 400
```
Seems `urllib2` does something different than `urllib` there.
|
{
"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/598/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/598/timeline
| null |
completed
| null | null | false |
[
"It's something weird with JSON copied from Freebase site:\n\n```\nimport requests\nfull_url = 'https://www.googleapis.com/freebase/v1/mqlread?query=%5B%7B%22percentage_alcohol%3E%22%3A+0%2C+%22country%22%3A+null%2C+%22type%22%3A+%22%2Ffood%2Fwine%22%2C+%22name%22%3A+null%2C+%22percentage_alcohol%22%3A+null%7D%5D'\nquery = '[{\"percentage_alcohol>\": 0, \"country\": null, \"type\": \"/food/wine\", \"name\": null, \"percentage_alcohol\": null}]'\nprint repr(query)\n```\n\nOutputs:\n\n```\n'...SKIPED... \"percentage_alcohol\": null}]\\xe2\\x80\\x8b'\n```\n\nSee this `\\xe2\\x80\\x8b` at the end? So if I delete it, request is succeed:\n\n```\nquery = query[:-3]\nr1 = requests.get('https://www.googleapis.com/freebase/v1/mqlread', params={'query': query})\nr2 = requests.get(full_url)\nprint r1.status_code # 200\nprint r2.status_code # 200\n```\n\n**Edit**\n\nMaybe it's my editor/browser/os problem.\n",
"```\n>>> fullurl = 'https://www.googleapis.com/freebase/v1/mqlread?query=%5B%7B%22percentage_alcohol%3E%22%3A+0%2C+%22country%22%3A+null%2C+%22type%22%3A+%22%2Ffood%2Fwine%22%2C+%22name%22%3A+null%2C+%22percentage_alcohol%22%3A+null%7D%5D'\n>>> import requests\n>>> requests.__version__\n'0.12.0'\n>>> r = requests.get(fullurl)\n>>> print r.status_code\n200\n```\n\nYou might want to check your setup.\n",
"@reclosedev Interesting, but not the problem I'm having ;-)\n@piotr-dobrogost Okay, I suppose it is my setup indeed:\n\n```\n>>> fullurl = 'https://www.googleapis.com/freebase/v1/mqlread?query=%5B%7B%22percentage_alcohol%3E%22%3A+0%2C+%22country%22%3A+null%2C+%22type%22%3A+%22%2Ffood%2Fwine%22%2C+%22name%22%3A+null%2C+%22percentage_alcohol%22%3A+null%7D%5D'\n>>> import requests\n>>> requests.__version__\n'0.12.1'\n>>> r = requests.get(fullurl)\n>>> print r.status_code\n400\n```\n\nI'm on Ubuntu 12.04, behind a proxy (which is known to do funny things), could that be the problem? If so, why does it work with `urllib2`, but not with `requests` and `urllib`?\n",
"It seems to work fine in my case (I am on Mac Snow Leopard). See the testcase: https://gist.github.com/2838282\n",
"@maebert \n\nI run it in Python3.5, seems your `]` is special char.\n\n```\n>>> '[{\"percentage_alcohol>\": 0, \"country\": null, \"type\": \"/food/wine\", \"name\": null, \"percentage_alcohol\": null}]'\n'[{\"percentage_alcohol>\": 0, \"country\": null, \"type\": \"/food/wine\", \"name\": null, \"percentage_alcohol\": null}]\\u200b'\n>>> '[{\"percentage_alcohol>\": 0, \"country\": null, \"type\": \"/food/wine\", \"name\": null, \"percentage_alcohol\": null}]'\n'[{\"percentage_alcohol>\": 0, \"country\": null, \"type\": \"/food/wine\", \"name\": null, \"percentage_alcohol\": null}]'\n>>> \n```\n"
] |
https://api.github.com/repos/psf/requests/issues/597
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/597/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/597/comments
|
https://api.github.com/repos/psf/requests/issues/597/events
|
https://github.com/psf/requests/pull/597
| 4,474,411 |
MDExOlB1bGxSZXF1ZXN0MTMwODE1NQ==
| 597 |
```chunk_size``` for ```iter_lines()``` versus ```iter_content()```
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/822167?v=4",
"events_url": "https://api.github.com/users/mponton/events{/privacy}",
"followers_url": "https://api.github.com/users/mponton/followers",
"following_url": "https://api.github.com/users/mponton/following{/other_user}",
"gists_url": "https://api.github.com/users/mponton/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/mponton",
"id": 822167,
"login": "mponton",
"node_id": "MDQ6VXNlcjgyMjE2Nw==",
"organizations_url": "https://api.github.com/users/mponton/orgs",
"received_events_url": "https://api.github.com/users/mponton/received_events",
"repos_url": "https://api.github.com/users/mponton/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/mponton/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/mponton/subscriptions",
"type": "User",
"url": "https://api.github.com/users/mponton",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 6 |
2012-05-08T15:05:09Z
|
2021-09-08T23:11:02Z
|
2012-07-27T05:59:13Z
|
NONE
|
resolved
|
Seriously, I think you should merge this one. The latest release and the `develop` branch still have the default `chunk_size` "reversed" for `iter_content()` and `iter_lines()` contrarilly to what you mentioned here: https://github.com/kennethreitz/requests/pull/589#issuecomment-5567553
This pull request may be canned by Travis CI again, but as I mentioned in the above pull request, the issue is located either in the test logic or the way lines ending in `\r\n` in `iter_lines()` depending how you interpret the issue... (I think the later is the real problem as even without changing `chunk_size`, `iter_lines()` could return different results for the same input depending on where the line-ending ends inside the buffer read by `iter_content()`). Not knowing how you perceive the issue, I did not attempt to fix it.
----- Original idea:
Following discussion about issue #539 Kenneth agreed that a default
`chunk_size` of 1 for `iter_lines()` would make more sense, but
apparently changed `chunk_size` for `iter_content()` by mistake
instead, which did solve the `iter_lines()` issue but also changed the
default `iter_content()` chunk to 1 bytes which is not desirable.
|
{
"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/597/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/597/timeline
| null | null | false |
{
"diff_url": "https://github.com/psf/requests/pull/597.diff",
"html_url": "https://github.com/psf/requests/pull/597",
"merged_at": null,
"patch_url": "https://github.com/psf/requests/pull/597.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/597"
}
| true |
[
"This pull request [fails](http://travis-ci.org/kennethreitz/requests/builds/1276587) (merged 87f0a92d into 0308a280).\n",
"As expected. See comments above and for my previous pull request here: https://github.com/kennethreitz/requests/pull/589#issuecomment-5538019\n",
"I agree with @mponton — the current default chunk_size value of 1 for iter_content() seems broken. We were bitten by this performance regression when upgrading to 0.13.2.\n",
"Did this get merged, or ignored? Would have been useful to have had a comment made when the pull request was closed.\n\nLooks like it was ignored, which ... means I had a massive performance regression just now.\n",
"Duly noted but 'ignored' for now. Definitely needs to change, but we need to find a good answer to the issue noted above first.\n",
"I don't entirely know what I'm talking about, but here are some guesses about how `iter_content` should maybe work:\n1. The core use case for this feature seems to be streaming APIs like Twitter's \"firehose\", which use HTTP 1.1 and chunked encoding\n2. As per Twitter's guidelines [https://dev.twitter.com/docs/streaming-apis/processing], the right way to consume an API like this is to use chunked encoding to tell how much data to read at a time. They suggest deferring the details of this to the underlying HTTP library.\n3. Unfortunately, it looks like we can't reuse the chunked encoding implementation from `httplib`, because it's hard-wired to consume the entire document at once and return it. We might need to make our own --- possibly by copying and pasting code from httplib?\n4. For HTTP 1.0 and non-chunked pages, we should probably just try to read the entire document and yield it as a single string?\n\nAs mentioned at #775, I am also interested in changing the `iter_content` behavior so that if the body has already been consumed, it yields a one-item iterator containing the whole body, e.g., `iter([self.body])`.\n"
] |
https://api.github.com/repos/psf/requests/issues/596
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/596/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/596/comments
|
https://api.github.com/repos/psf/requests/issues/596/events
|
https://github.com/psf/requests/issues/596
| 4,469,499 |
MDU6SXNzdWU0NDY5NDk5
| 596 |
Test failure against Python 3.2
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/158471?v=4",
"events_url": "https://api.github.com/users/djc/events{/privacy}",
"followers_url": "https://api.github.com/users/djc/followers",
"following_url": "https://api.github.com/users/djc/following{/other_user}",
"gists_url": "https://api.github.com/users/djc/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/djc",
"id": 158471,
"login": "djc",
"node_id": "MDQ6VXNlcjE1ODQ3MQ==",
"organizations_url": "https://api.github.com/users/djc/orgs",
"received_events_url": "https://api.github.com/users/djc/received_events",
"repos_url": "https://api.github.com/users/djc/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/djc/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/djc/subscriptions",
"type": "User",
"url": "https://api.github.com/users/djc",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 7 |
2012-05-08T09:25:39Z
|
2021-09-09T08:00:45Z
|
2012-05-08T10:02:40Z
|
NONE
|
resolved
|
PYTHONPATH=build-3.2/lib nosetests --verbosity=1
# E...........
## ERROR: Failure: AttributeError ('module' object has no attribute 'translate')
Traceback (most recent call last):
File "/usr/lib64/python3.2/site-packages/nose/failure.py", line 37, in runTest
raise self.exc_class(self.exc_val).with_traceback(self.tb)
File "/usr/lib64/python3.2/site-packages/nose/loader.py", line 390, in loadTestsFromName
addr.filename, addr.module)
File "/usr/lib64/python3.2/site-packages/nose/importer.py", line 39, in importFromPath
return self.importFromDir(dir_path, fqname)
File "/usr/lib64/python3.2/site-packages/nose/importer.py", line 86, in importFromDir
mod = load_module(part_fqname, fh, filename, desc)
File "/var/tmp/portage/dev-python/requests-0.12.1/work/requests-0.12.1/requests/packages/oreos/**init**.py", line 3, in <module>
from .core import dict_from_string
File "/var/tmp/portage/dev-python/requests-0.12.1/work/requests-0.12.1/requests/packages/oreos/core.py", line 10, in <module>
from .monkeys import SimpleCookie
File "/var/tmp/portage/dev-python/requests-0.12.1/work/requests-0.12.1/requests/packages/oreos/monkeys.py", line 327, in <module>
idmap=_idmap, translate=string.translate):
AttributeError: 'module' object has no attribute 'translate'
---
Ran 12 tests in 5.990s
(The tests work fine against 2.7.)
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/376448?v=4",
"events_url": "https://api.github.com/users/slingamn/events{/privacy}",
"followers_url": "https://api.github.com/users/slingamn/followers",
"following_url": "https://api.github.com/users/slingamn/following{/other_user}",
"gists_url": "https://api.github.com/users/slingamn/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/slingamn",
"id": 376448,
"login": "slingamn",
"node_id": "MDQ6VXNlcjM3NjQ0OA==",
"organizations_url": "https://api.github.com/users/slingamn/orgs",
"received_events_url": "https://api.github.com/users/slingamn/received_events",
"repos_url": "https://api.github.com/users/slingamn/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/slingamn/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/slingamn/subscriptions",
"type": "User",
"url": "https://api.github.com/users/slingamn",
"user_view_type": "public"
}
|
{
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/596/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/596/timeline
| null |
completed
| null | null | false |
[
"`make citests` runs the tests (there should be 75 of them). I'm not sure what a bare `nosetests` ends up discovering. Anyway, `oreos` is dead code in trunk, so it isn't breaking the 3.x build.\n\nWe could do a better job of documenting this. Anyway, here are the buildbots:\n\nhttp://travis-ci.org/#!/kennethreitz/requests\nhttp://ci.kennethreitz.com/job/requests/\n",
"Makefile is absent in tarball.\n\nMinimal fix:\n\n```\n--- requests/packages/oreos/monkeys.py\n+++ requests/packages/oreos/monkeys.py\n@@ -324,7 +324,7 @@\n _idmap = ''.join(chr(x) for x in range(256))\n\n def _quote(str, LegalChars=_LegalChars,\n- idmap=_idmap, translate=string.translate):\n+ idmap=_idmap, translate=str.translate):\n #\n # If the string does not need to be double-quoted,\n # then just return the string. Otherwise, surround\n@@ -462,7 +462,7 @@\n\n def set(self, key, val, coded_val,\n LegalChars=_LegalChars,\n- idmap=_idmap, translate=string.translate):\n+ idmap=_idmap, translate=str.translate):\n # First we verify that the key isn't a reserved word\n # Second we make sure it only contains legal characters\n if key.lower() in self._reserved:\n```\n",
"Really, the tests shouldn't be in the tarball either; they are not \"production code\".\n",
"Oh, please. Running the tests before installation is a pretty useful feature, production code or not.\n",
"I don't know how the default discovery mechanism of `nosetests` is implemented exactly, but consider this. The Requests codebase is intended to work with both Python 2 and Python 3; we implement this by means of a compatibility module (`requests.compat`) that detects the version and imports the right module depending on the version. Thus, it would be perfectly reasonable for us to package a module that fails completely under Python 3, for example, with a `SyntaxError` --- as long as that module is not imported when Python 3 is detected.\n\nNow, the entire `oreos` module is dead code in trunk:\n\n```\n$ git grep oreos\nrequests/packages/oreos/core.py:oreos.core\nrequests/packages/oreos/monkeys.py:oreos.monkeys\nrequests/packages/oreos/structures.py:oreos.structure\n```\n\nso I don't know why nosetests is trying to import it. The point is that `nosetests` is not smart enough to detect which modules we intend to be Python 3 compatible.\n\nMaybe the right thing to do would be to put `Makefile` in the tarball, and document exactly which target runs the tests that are expected to succeed under all platforms (currently `make citests`). I'll open a ticket to clarify the situation on this, but currently there is no \"stable answer\" (and, as discussed previously, it can't be a plain `nosetests`).\n\nAnyway, don't you trust us to ship working code? ;-)\n",
"OK, #601.\n",
"I'm not wedded to nosetests or anything, I just want an easy way to run the tests. :) Supporting python setup.py test would also be pretty nice (via the test_suite keyword to setup()).\n"
] |
https://api.github.com/repos/psf/requests/issues/595
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/595/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/595/comments
|
https://api.github.com/repos/psf/requests/issues/595/events
|
https://github.com/psf/requests/pull/595
| 4,469,428 |
MDExOlB1bGxSZXF1ZXN0MTMwNTk0OQ==
| 595 |
Session cookies not saved when Session.request is called with return_response=False
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/660112?v=4",
"events_url": "https://api.github.com/users/reclosedev/events{/privacy}",
"followers_url": "https://api.github.com/users/reclosedev/followers",
"following_url": "https://api.github.com/users/reclosedev/following{/other_user}",
"gists_url": "https://api.github.com/users/reclosedev/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/reclosedev",
"id": 660112,
"login": "reclosedev",
"node_id": "MDQ6VXNlcjY2MDExMg==",
"organizations_url": "https://api.github.com/users/reclosedev/orgs",
"received_events_url": "https://api.github.com/users/reclosedev/received_events",
"repos_url": "https://api.github.com/users/reclosedev/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/reclosedev/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/reclosedev/subscriptions",
"type": "User",
"url": "https://api.github.com/users/reclosedev",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 10 |
2012-05-08T09:19:50Z
|
2021-09-08T15:01:05Z
|
2012-05-08T15:06:51Z
|
CONTRIBUTOR
|
resolved
|
For example, I want to use `request.async` and save cookies to session:
```
import requests
from requests import async
s = requests.Session()
async.map([async.get('http://httpbin.org/cookies/set/async/yes', session=s)])
print 'cookies:', s.cookies
```
cookies are empty.
It's because when `Session.request()` is called with `return_response=False`, it returns request without updating session cookies [sessions.py#L234](https://github.com/kennethreitz/requests/blob/9bf53676b87fa4951e23f67d2251f5dfae4e5206/requests/sessions.py#L234)
So, I think we can solve it by moving cookies saving logic to `Request._build_response()`. Or maybe there is more suitable place?
|
{
"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/595/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/595/timeline
| null | null | false |
{
"diff_url": "https://github.com/psf/requests/pull/595.diff",
"html_url": "https://github.com/psf/requests/pull/595",
"merged_at": "2012-05-08T15:06:51Z",
"patch_url": "https://github.com/psf/requests/pull/595.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/595"
}
| true |
[
"This pull request [passes](http://travis-ci.org/kennethreitz/requests/builds/1274659) (merged 33f10875 into 0308a280).\n",
"Nice catch!\n\nLGTM, except I don't think your test case is actually hitting the async API. Should it be calling `async.map` to make the request?\n\nAdd yourself to `AUTHORS.rst` too? :-)\n",
"> Should it be calling async.map to make the request?\n\nYes, but `get` is patched in this testcase, see [test_requests_async.py#L39](https://github.com/kennethreitz/requests/blob/317f64a11f56d89119baf5db3af65c0343464bc1/tests/test_requests_async.py#L39) so it calls `async.map`.\n\n> Add yourself to AUTHORS.rst too? :-)\n\nOk :)\n",
"This pull request [passes](http://travis-ci.org/kennethreitz/requests/builds/1275024) (merged c010f589 into 0308a280).\n",
"Oh, yeah. Awesome.\n",
":sparkles: :cake: :sparkles:\n",
"@reclosedev \n\nNice work.\n\n> Yes, but `get` is patched in this testcase\n\n... and all sync tests are being run using async api as well. As your two requests in the async test are sequential you might want to replace sync test with the async one (which tests more) and remove the latter. You might also want to reference request from reply instead the other way around in case the link in this direction is removed in the future :)\n\nBtw, please remember not to link to moving target (develop) as this doesn't make sense.\n",
"@piotr-dobrogost \n\nMaybe you are right about sync test, but I think it's not superfluous, because, for example, async api may use another way to create requests in the future, but `return_response=False` should be tested.\n\n> You might also want to reference request from reply instead the other way around in case the link in this direction is removed in the future :)\n\nCan you elaborate?\n\n> Btw, please remember not to link to moving target (develop) as this doesn't make sense.\n\nAre you talking about links in comments? Fixed :)\n",
"> Can you elaborate?\n\nSee issue #520.\n",
"Oh, I don't think it matters; if something like that gets implemented, we'll just change the test.\n"
] |
https://api.github.com/repos/psf/requests/issues/594
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/594/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/594/comments
|
https://api.github.com/repos/psf/requests/issues/594/events
|
https://github.com/psf/requests/pull/594
| 4,467,417 |
MDExOlB1bGxSZXF1ZXN0MTMwNTIyOQ==
| 594 |
unbreak the Jenkins build again/hopefully :-/
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/376448?v=4",
"events_url": "https://api.github.com/users/slingamn/events{/privacy}",
"followers_url": "https://api.github.com/users/slingamn/followers",
"following_url": "https://api.github.com/users/slingamn/following{/other_user}",
"gists_url": "https://api.github.com/users/slingamn/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/slingamn",
"id": 376448,
"login": "slingamn",
"node_id": "MDQ6VXNlcjM3NjQ0OA==",
"organizations_url": "https://api.github.com/users/slingamn/orgs",
"received_events_url": "https://api.github.com/users/slingamn/received_events",
"repos_url": "https://api.github.com/users/slingamn/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/slingamn/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/slingamn/subscriptions",
"type": "User",
"url": "https://api.github.com/users/slingamn",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 4 |
2012-05-08T05:45:08Z
|
2021-09-08T15:01:06Z
|
2012-05-08T05:46:00Z
|
CONTRIBUTOR
|
resolved
|
This makes it so the Python 3 and PyPy Jenkins environments don't try to run Pyflakes, since they can't.
If you're fed up with all my attempts to get Jenkins to check pyflakes, that's cool; we can just remove the target.
However, there's another issue. We should take `oauthlib` out of `requirements.txt`, as per this failure: http://ci.kennethreitz.com/job/requests/244/PYTHON=3.2/console
`oauthlib` will get pulled in for Python 2 only when `setup.py` runs, right?
|
{
"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/594/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/594/timeline
| null | null | false |
{
"diff_url": "https://github.com/psf/requests/pull/594.diff",
"html_url": "https://github.com/psf/requests/pull/594",
"merged_at": "2012-05-08T05:46:00Z",
"patch_url": "https://github.com/psf/requests/pull/594.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/594"
}
| true |
[
"I'd rather not have it honestly :)\n",
"But if it works, it works :)\n",
"This pull request [passes](http://travis-ci.org/kennethreitz/requests/builds/1273543) (merged 175945b0 into 6fd03d5f).\n",
"Yay! http://ci.kennethreitz.com/job/requests/245/\n"
] |
https://api.github.com/repos/psf/requests/issues/593
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/593/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/593/comments
|
https://api.github.com/repos/psf/requests/issues/593/events
|
https://github.com/psf/requests/issues/593
| 4,466,442 |
MDU6SXNzdWU0NDY2NDQy
| 593 |
response.json
|
{
"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 | 2 |
2012-05-08T03:09:31Z
|
2021-09-09T08:00:48Z
|
2012-05-08T04:58:34Z
|
CONTRIBUTOR
|
resolved
|
Never adding another decoded type. ever.
|
{
"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/593/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/593/timeline
| null |
completed
| null | null | false |
[
":fire::wheelchair:\n",
":trollface:\n"
] |
https://api.github.com/repos/psf/requests/issues/592
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/592/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/592/comments
|
https://api.github.com/repos/psf/requests/issues/592/events
|
https://github.com/psf/requests/issues/592
| 4,464,484 |
MDU6SXNzdWU0NDY0NDg0
| 592 |
Internal encoding detection doesn't match external chardet call
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/229843?v=4",
"events_url": "https://api.github.com/users/jessicald/events{/privacy}",
"followers_url": "https://api.github.com/users/jessicald/followers",
"following_url": "https://api.github.com/users/jessicald/following{/other_user}",
"gists_url": "https://api.github.com/users/jessicald/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/jessicald",
"id": 229843,
"login": "jessicald",
"node_id": "MDQ6VXNlcjIyOTg0Mw==",
"organizations_url": "https://api.github.com/users/jessicald/orgs",
"received_events_url": "https://api.github.com/users/jessicald/received_events",
"repos_url": "https://api.github.com/users/jessicald/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/jessicald/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/jessicald/subscriptions",
"type": "User",
"url": "https://api.github.com/users/jessicald",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 7 |
2012-05-07T23:24:31Z
|
2021-09-09T00:34:22Z
|
2012-05-08T01:50:53Z
|
NONE
|
resolved
|
**requests**' method for detecting a document's encoding when the `Content-Type` header does not have it seems to work differently than external methods.
Referencing #480, **chardet** is used to detect the encoding of a document and presumably the `string.decode()` for converting a `response.content` to `response.text` uses this guess, again if the encoding is not in the HTTP headers. However, testing reveals that the guess provided by **requests** is subpar compared to a standalone call to `chardet.detect()`.
Using this code:
``` python
import requests
import urllib
import chardet
page_requests = requests.get('http://www2.ocn.ne.jp/~cast/')
page_urllib = urllib.FancyURLopener().open('http://www2.ocn.ne.jp/~cast/').read()
print page_requests.encoding
print chardet.detect(page_urllib)['encoding']
```
produces as output:
```
$ python2 encoding_test.py
ISO-8859-1
SHIFT_JIS
```
This becomes a problem when relying on `response.text` for input, as improperly decoded Python Unicode strings break a lot of other modules. The present solution would be to rely on `response.content` and do the `response.content.decode(chardet.detect(response.content)['encoding'])` manually, but if **requests** is to have a pre-decoded Unicode string and an `encoding` field, the detection should be as accurate as possible.
|
{
"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/592/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/592/timeline
| null |
completed
| null | null | false |
[
"That page sends a header `Content-Type: text/html`; since the header contains the string `text`, `requests.utils.get_encoding_from_headers()` returns `ISO-8859-1` and we don't attempt detection with `chardet`.\n\nThis looks like the standards-compliant behavior: http://en.wikipedia.org/wiki/ISO/IEC_8859-1#History\n",
"Another wrinkle is that the bytes from that page do successfully decode as ISO-8859-1 (Latin-1). If they failed, there might be a case for trying `chardet` and re-decoding with chardet's guess. But in this case, we don't really seem to have a good indication not to trust the header. @ensigntropic, thoughts?\n",
"Strictly speaking, all bytes successfully decode as ISO-8859-1 since its character width is only one byte. That is, it's a 1:1 conversion between a byte string and a Unicode string. That's how I first noticed the problem was with the encoding; the Unicode string wasn't showing Unicode-escaped characters e.g. `\\u0000`.\n\nStandards-compliant behaviour is good and all but https://github.com/kennethreitz/requests/issues/480#issuecomment-4859364 mentions an internal **chardet** call (specifically referencing the lack of header), and it seems buggy to instantly fallback on Latin-1 without even attempting a heuristic check a la **chardet**, especially when `resource.text` relies on the `resource.encoding` for conversion.\nAgain the main issue is a broken Unicode string that's useless because it doesn't contain the correct Unicode data. If there's going to be a reliance on the encoding of a document for an internal field, it should be as accurate as it can be.\n\nMy ideal fix would be to perform the heuristic check first (after discovering the `Content-Type` header lacked `charset`), then fallback to Latin-1 if _all else fails_. It may not be immediately standards-compliant, but the scenarios where it would break things are possibly far fewer than those where it would help.\n",
"If I may offer another example: http://docs.python.org/library/pdb.html\n\nThis page lacks a `charset` in its headers, but not in its `<meta>` tags. It is UTF-8, and of immediate note is the `<title>` which contains one Unicode em dash (—) and one `&;` escaped em dash (—). When decoded as Latin-1, that first em dash breaks; however, **chardet** successfully identifies the page as UTF-8.\n\n``` python\n>>> import urllib\n>>> import chardet\n>>> import re\n>>> page = urllib.FancyURLopener().open('http://docs.python.org/library/pdb.html').read()\n\n>>> print re.findall('(?i)(?<=<title>).*(?=</title>)', page.decode('latin-1'))[0]\n26.2. pdb â The Python Debugger — Python v2.7.3 documentation\n>>> print chardet.detect(page)['encoding']\nutf-8\n>>> print re.findall('(?i)(?<=<title>).*(?=</title>)', page.decode(chardet.detect(page)['encoding']))[0]\n26.2. pdb — The Python Debugger — Python v2.7.3 documentation\n```\n",
"That sounds reasonable. My concern is that `chardet` is quite slow; right now, we only invoke it lazily, when the user wants the Unicode text of the page (the `Response.text` property) and we couldn't extract an encoding from the headers.\n\nI think it's reasonable that `Response.encoding` should contain the page's declared encoding in accordance with the standards (i.e., the current behavior). But maybe `Response.text` should see if the page actually declared Latin-1, or we just assumed Latin-1 because of `text/html`, and in the second case use `chardet`'s response instead of Latin-1.\n",
"Requests doesn't care about meta tags. This is an http module, not an html module. \n\nI chose to trust the server before I trust chardet. The server is lying to you, so requests should raise an exception, not ignore the http standard. You're more than welcome to change the value of `response.encoding`, however. If you set it to `'utf-8'`, then it will work as expected. If you'd like to do this all the time, you can implement it with a hook.\n",
"Given that, it essentially makes `response.text` useless at worst, and unreliable at best. If I can't trust **requests** to encode the `text` field correctly, I'm better off using `content` and doing my own work on it. That a seeming majority of servers send the charset in the header doesn't make the current behaviour of `response.text`, nor the standard it's based on, reliable. **chardet** may be slow, but it is more reliable and certainly not limited to HTML `<meta>`.\n\nSetting `response.encoding` does indeed change the conversion of `response.content` to `response.text`, but setting it after the request is kind of just an alias for doing the `string.decode()` myself unless I plan on handing the `response` around to other functions; that and I still have to have client code to determine to _what_ encoding it needs to be set (setting it to `utf-8` all the time will not work for documents encoded in `shift-jis`, etc.), again negating the real usefulness of `response.text` in the first place.\n\nThis issue is not constrained to HTML documents; any textual file could be in an encoding that the server doesn't report, and therefore `response.text` will be unreliable every time one doesn't. I fully understand not wanting to do it for every request, but once the first conversion from `content` to `text` is called, the logic should be in place to make sure the resulting Unicode string is going to be properly encoded. The byte string of `content` very obviously doesn't need this extra baggage, and if one knows they won't need to access textual data, the encoding detection logic will never trigger.\n"
] |
https://api.github.com/repos/psf/requests/issues/591
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/591/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/591/comments
|
https://api.github.com/repos/psf/requests/issues/591/events
|
https://github.com/psf/requests/issues/591
| 4,447,320 |
MDU6SXNzdWU0NDQ3MzIw
| 591 |
XML parse issue with requests, not with urllib2
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/99983?v=4",
"events_url": "https://api.github.com/users/dmishe/events{/privacy}",
"followers_url": "https://api.github.com/users/dmishe/followers",
"following_url": "https://api.github.com/users/dmishe/following{/other_user}",
"gists_url": "https://api.github.com/users/dmishe/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/dmishe",
"id": 99983,
"login": "dmishe",
"node_id": "MDQ6VXNlcjk5OTgz",
"organizations_url": "https://api.github.com/users/dmishe/orgs",
"received_events_url": "https://api.github.com/users/dmishe/received_events",
"repos_url": "https://api.github.com/users/dmishe/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/dmishe/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/dmishe/subscriptions",
"type": "User",
"url": "https://api.github.com/users/dmishe",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 5 |
2012-05-06T23:35:10Z
|
2021-09-09T08:00:48Z
|
2012-05-08T05:07:57Z
|
NONE
|
resolved
|
This is the XML response i get https://gist.github.com/2624993
When i try to parse it with cElementTree, first i get ascii codec error, then if i encode `response.text.encode(response.encoding)` i get tag mismatched error (62 col 2).
With urllib2 it seem to work ok.
I'm lost as to what can cause this issue, i would be glad to provide more info
|
{
"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/591/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/591/timeline
| null |
completed
| null | null | false |
[
"Are you using `response.content` or `response.text`?\n",
"text\n",
"Text is unicode.\n",
"Yeah i know that, what's weird is that if get that XML from github, like:\n\n```\nipdb> url = 'https://raw.github.com/gist/2624993/03b7d5e7c9041138f9da132def3e8e1e0c30fa85/gistfile1.xml'\nipdb> ET.fromstring(requests.get(url).text)\n```\n\nit works, but if i get the same XML from goodreads.com, it does not\n\n```\nipdb> url = 'http://www.goodreads.com/book/show/43615?key=REDACTED'\nipdb> ET.fromstring(requests.get(url).text)\n*** UnicodeEncodeError: 'ascii' codec can't encode character u'\\u2018' in position 67922: ordinal not in range(128)\n```\n",
"XML is typically not a unicode-friendly format. \n"
] |
https://api.github.com/repos/psf/requests/issues/590
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/590/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/590/comments
|
https://api.github.com/repos/psf/requests/issues/590/events
|
https://github.com/psf/requests/pull/590
| 4,445,980 |
MDExOlB1bGxSZXF1ZXN0MTI5NjI0Nw==
| 590 |
Fixed broken links in TODO docs.
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/26338?v=4",
"events_url": "https://api.github.com/users/berkerpeksag/events{/privacy}",
"followers_url": "https://api.github.com/users/berkerpeksag/followers",
"following_url": "https://api.github.com/users/berkerpeksag/following{/other_user}",
"gists_url": "https://api.github.com/users/berkerpeksag/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/berkerpeksag",
"id": 26338,
"login": "berkerpeksag",
"node_id": "MDQ6VXNlcjI2MzM4",
"organizations_url": "https://api.github.com/users/berkerpeksag/orgs",
"received_events_url": "https://api.github.com/users/berkerpeksag/received_events",
"repos_url": "https://api.github.com/users/berkerpeksag/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/berkerpeksag/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/berkerpeksag/subscriptions",
"type": "User",
"url": "https://api.github.com/users/berkerpeksag",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 2 |
2012-05-06T19:28:22Z
|
2021-09-08T15:01:06Z
|
2012-05-06T19:54:06Z
|
MEMBER
|
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/590/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/590/timeline
| null | null | false |
{
"diff_url": "https://github.com/psf/requests/pull/590.diff",
"html_url": "https://github.com/psf/requests/pull/590",
"merged_at": "2012-05-06T19:54:06Z",
"patch_url": "https://github.com/psf/requests/pull/590.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/590"
}
| true |
[
"This pull request [passes](http://travis-ci.org/kennethreitz/requests/builds/1260218) (merged a0f991db into c84012ed).\n",
"Thanks!\n"
] |
|
https://api.github.com/repos/psf/requests/issues/589
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/589/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/589/comments
|
https://api.github.com/repos/psf/requests/issues/589/events
|
https://github.com/psf/requests/pull/589
| 4,444,441 |
MDExOlB1bGxSZXF1ZXN0MTI5NjAyMg==
| 589 |
Fixed chunk_size values in iter_content() and iter_lines(). False default instead of None.
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/822167?v=4",
"events_url": "https://api.github.com/users/mponton/events{/privacy}",
"followers_url": "https://api.github.com/users/mponton/followers",
"following_url": "https://api.github.com/users/mponton/following{/other_user}",
"gists_url": "https://api.github.com/users/mponton/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/mponton",
"id": 822167,
"login": "mponton",
"node_id": "MDQ6VXNlcjgyMjE2Nw==",
"organizations_url": "https://api.github.com/users/mponton/orgs",
"received_events_url": "https://api.github.com/users/mponton/received_events",
"repos_url": "https://api.github.com/users/mponton/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/mponton/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/mponton/subscriptions",
"type": "User",
"url": "https://api.github.com/users/mponton",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 5 |
2012-05-06T17:08:45Z
|
2021-09-08T23:10:55Z
|
2012-05-08T05:07:45Z
|
NONE
|
resolved
|
Following discussion about issue #539 Kenneth agreed that a default
`chunk_size` of 1 for `iter_lines()` would make more sense, but
apparently changed `chunk_size` for `iter_content()` by mistake
instead, which did solve the `iter_lines()` issue but also changed the
default `iter_content()` chunk to 1 bytes which is not desirable.
Also changed default for `decode_unicode` to `False` instead of `None` in `iter_lines()`.
|
{
"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/589/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/589/timeline
| null | null | false |
{
"diff_url": "https://github.com/psf/requests/pull/589.diff",
"html_url": "https://github.com/psf/requests/pull/589",
"merged_at": null,
"patch_url": "https://github.com/psf/requests/pull/589.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/589"
}
| true |
[
"This pull request [fails](http://travis-ci.org/kennethreitz/requests/builds/1259283) (merged 85e83c40 into c84012ed).\n",
"Hmmm, I think the logic in\n\n``` python\nif pending is not None:\n chunk = pending + chunk\nlines = chunk.splitlines()\n\nif lines and lines[-1] and chunk and lines[-1][-1] == chunk[-1]:\n pending = lines.pop()\nelse:\n pending = None\n```\n\nDoes not handle \"\\r\\n\" as `splitlines()` does when using a `chunk_size` of 1. The quote:\n\n```\nquote = (\n '''Agamemnon \\n'''\n '''\\tWhy will he not upon our fair request\\r\\n'''\n '''\\tUntent his person and share the air with us?'''\n )\n```\n\nused in `test_requests.py` contains `\\r\\n` which ends up becoming a line in `iter_lines()` when the iterator hits the `\\r` character, next the `\\n` character is read and an empty line is spit by `chunk.splitlines()`. Thus the test fails as 4 lines are returned instead of 3. If the `chunk_size` is larger and `\\r\\n` are read in a single chunk, then it works as expected.\n",
"decode_unicode is `None` for a reason :)\n",
"`iter_content` also has a proper size now, so closing. Thanks though!\n",
"OK, not sure why `decode_unicode` should be `None` but you may then want to change it to `None` in `iter_content()` too...? :-)\n"
] |
https://api.github.com/repos/psf/requests/issues/588
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/588/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/588/comments
|
https://api.github.com/repos/psf/requests/issues/588/events
|
https://github.com/psf/requests/issues/588
| 4,439,914 |
MDU6SXNzdWU0NDM5OTE0
| 588 |
Add response.reason
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/171200?v=4",
"events_url": "https://api.github.com/users/btubbs/events{/privacy}",
"followers_url": "https://api.github.com/users/btubbs/followers",
"following_url": "https://api.github.com/users/btubbs/following{/other_user}",
"gists_url": "https://api.github.com/users/btubbs/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/btubbs",
"id": 171200,
"login": "btubbs",
"node_id": "MDQ6VXNlcjE3MTIwMA==",
"organizations_url": "https://api.github.com/users/btubbs/orgs",
"received_events_url": "https://api.github.com/users/btubbs/received_events",
"repos_url": "https://api.github.com/users/btubbs/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/btubbs/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/btubbs/subscriptions",
"type": "User",
"url": "https://api.github.com/users/btubbs",
"user_view_type": "public"
}
|
[
{
"color": "e102d8",
"default": false,
"description": null,
"id": 117745,
"name": "Planned",
"node_id": "MDU6TGFiZWwxMTc3NDU=",
"url": "https://api.github.com/repos/psf/requests/labels/Planned"
},
{
"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 | 6 |
2012-05-05T23:41:19Z
|
2021-09-09T08:00:36Z
|
2012-06-15T18:38:32Z
|
NONE
|
resolved
|
At work we have an in-house REST API that puts useful information in the text portion of the HTTP status line. I was surprised that this wasn't exposed on the Response object, and I had to go to response.raw.reason to get it.
My fork has a fix (https://github.com/btubbs/requests/commit/742c1681d12f7a4b079c4c3ac49c4991ce898fd1). I think it's worth adding, but am interested in others' thoughts before making a pull request.
|
{
"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/588/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/588/timeline
| null |
completed
| null | null | false |
[
"Thanks for the suggestion!\n\nHonestly though, I don't really see how useful the response reason is. The number is all that matters to me. \n",
"In the API I'm working with, the main culprit is status 409 responses, which use the reason field to say things like \"Bad Username/Password\" or \"Already Exists\", typically in response to POSTs.\n\nHaving that information in an intuitive place on the response object could save future users the 20 minutes or so of head-scratching that I had, trying to figure out where the reason is.\n",
"Hmm, interesting. I didn't even realize that was customizable. \n",
"I had to double-check, but they are. http://www.w3.org/Protocols/rfc2616/rfc2616-sec6.html#sec6.1.1\n",
"tl;dr: +1: \n\nYeah, use of the reason phrase for explanatory detail is part of the spec. As another data point, I, myself, use requests with a small wrapper, and one of the things it does is tack the reason phrase onto the response object for convenient access. In the app I'm currently working on, several of the APIs I pull from do indeed have cases where the reason phrase is the only way to know which of several possible causes actually triggered a particular error status code.\n",
"Let's do this ;)\n"
] |
https://api.github.com/repos/psf/requests/issues/587
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/587/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/587/comments
|
https://api.github.com/repos/psf/requests/issues/587/events
|
https://github.com/psf/requests/pull/587
| 4,422,207 |
MDExOlB1bGxSZXF1ZXN0MTI4Nzc5OQ==
| 587 |
unbreak the Jenkins build by excluding ./env/*
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/376448?v=4",
"events_url": "https://api.github.com/users/slingamn/events{/privacy}",
"followers_url": "https://api.github.com/users/slingamn/followers",
"following_url": "https://api.github.com/users/slingamn/following{/other_user}",
"gists_url": "https://api.github.com/users/slingamn/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/slingamn",
"id": 376448,
"login": "slingamn",
"node_id": "MDQ6VXNlcjM3NjQ0OA==",
"organizations_url": "https://api.github.com/users/slingamn/orgs",
"received_events_url": "https://api.github.com/users/slingamn/received_events",
"repos_url": "https://api.github.com/users/slingamn/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/slingamn/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/slingamn/subscriptions",
"type": "User",
"url": "https://api.github.com/users/slingamn",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 3 |
2012-05-04T11:47:20Z
|
2021-09-08T15:01:05Z
|
2012-05-04T18:48:35Z
|
CONTRIBUTOR
|
resolved
|
Doh! http://ci.kennethreitz.com/job/requests/236/PYTHON=2.7/console
This might be a reason to take pyflakes out of the Jenkins target (`ci`).
|
{
"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/587/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/587/timeline
| null | null | false |
{
"diff_url": "https://github.com/psf/requests/pull/587.diff",
"html_url": "https://github.com/psf/requests/pull/587",
"merged_at": "2012-05-04T18:48:35Z",
"patch_url": "https://github.com/psf/requests/pull/587.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/587"
}
| true |
[
"This pull request [passes](http://travis-ci.org/kennethreitz/requests/builds/1243968) (merged d4227051 into 3d373e2a).\n",
"But personally, I'm a really huge fan of pyflakes as a build step. Catches a ton of issues.\n",
"thank you sir :P\n"
] |
https://api.github.com/repos/psf/requests/issues/586
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/586/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/586/comments
|
https://api.github.com/repos/psf/requests/issues/586/events
|
https://github.com/psf/requests/issues/586
| 4,421,780 |
MDU6SXNzdWU0NDIxNzgw
| 586 |
Problem installing pycrypto on Windows
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/92239?v=4",
"events_url": "https://api.github.com/users/piotr-dobrogost/events{/privacy}",
"followers_url": "https://api.github.com/users/piotr-dobrogost/followers",
"following_url": "https://api.github.com/users/piotr-dobrogost/following{/other_user}",
"gists_url": "https://api.github.com/users/piotr-dobrogost/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/piotr-dobrogost",
"id": 92239,
"login": "piotr-dobrogost",
"node_id": "MDQ6VXNlcjkyMjM5",
"organizations_url": "https://api.github.com/users/piotr-dobrogost/orgs",
"received_events_url": "https://api.github.com/users/piotr-dobrogost/received_events",
"repos_url": "https://api.github.com/users/piotr-dobrogost/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/piotr-dobrogost/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/piotr-dobrogost/subscriptions",
"type": "User",
"url": "https://api.github.com/users/piotr-dobrogost",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 5 |
2012-05-04T11:03:05Z
|
2021-09-09T09:00:30Z
|
2012-05-04T18:51:41Z
|
NONE
|
resolved
|
oauth library depends on pycrypto library which is not pure Python library (has some c extensions). For this reason pycrypto can't be installed from source on Windows without Visual Studio 2008 installed (needed to compile these c extensions of pycrypto). The simplest solution is to download binary installers and install them using easy_install (pip doesn't support installing of binaries). 32bit binary installers for Python 2.2-2.7 and 64bit binary installer for Python 2.6 are at [The Voidspace Python Modules](http://www.voidspace.org.uk/python/modules.shtml#pycrypto) and 64bit binary installer for Python 2.7 is at [Compiling pycrypto on Win7-64](http://yorickdowne.wordpress.com/2010/12/22/compiling-pycrypto-on-win7-64/). Binary installers can be installed in virtualenv - see http://stackoverflow.com/q/3271590/95735
|
{
"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/586/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/586/timeline
| null |
completed
| null | null | false |
[
"I think we should just focus on fixing #584; this really seems like a problem with `oauthlib`, not with Requests.\n\nYou could file a bug at idangazit/oauthlib ?\n",
"Sure we should fix #584. I opened this issue just in case someone had problems installing pycrypto which is needed for oauthlib right now. As to filing bug at oauthlib I don't see what bug I could file :)\n",
"er, s/bug/issue/ --- and file this same one?\n",
"> You could file a bug at idangazit/oauthlib ?\n\nIssue https://github.com/idangazit/oauthlib/issues/34\n",
"Closing for idangazit/oauthlib#34\n"
] |
https://api.github.com/repos/psf/requests/issues/585
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/585/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/585/comments
|
https://api.github.com/repos/psf/requests/issues/585/events
|
https://github.com/psf/requests/pull/585
| 4,421,603 |
MDExOlB1bGxSZXF1ZXN0MTI4NzUyNw==
| 585 |
Fix out-of-range issue with iter_lines (#515).
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/1699013?v=4",
"events_url": "https://api.github.com/users/chazapis/events{/privacy}",
"followers_url": "https://api.github.com/users/chazapis/followers",
"following_url": "https://api.github.com/users/chazapis/following{/other_user}",
"gists_url": "https://api.github.com/users/chazapis/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/chazapis",
"id": 1699013,
"login": "chazapis",
"node_id": "MDQ6VXNlcjE2OTkwMTM=",
"organizations_url": "https://api.github.com/users/chazapis/orgs",
"received_events_url": "https://api.github.com/users/chazapis/received_events",
"repos_url": "https://api.github.com/users/chazapis/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/chazapis/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/chazapis/subscriptions",
"type": "User",
"url": "https://api.github.com/users/chazapis",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 2 |
2012-05-04T10:46:07Z
|
2021-09-08T15:01:04Z
|
2012-05-04T18:49:49Z
|
CONTRIBUTOR
|
resolved
|
This will fix the iter_lines IndexError, which may be caused either by `chunk == ''` (empty string), or `chunk.endswith('\n\n')`.
|
{
"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/585/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/585/timeline
| null | null | false |
{
"diff_url": "https://github.com/psf/requests/pull/585.diff",
"html_url": "https://github.com/psf/requests/pull/585",
"merged_at": "2012-05-04T18:49:49Z",
"patch_url": "https://github.com/psf/requests/pull/585.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/585"
}
| true |
[
"This pull request [passes](http://travis-ci.org/kennethreitz/requests/builds/1243718) (merged c333bd14 into 3d373e2a).\n",
"Excellent, thanks!\n"
] |
https://api.github.com/repos/psf/requests/issues/584
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/584/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/584/comments
|
https://api.github.com/repos/psf/requests/issues/584/events
|
https://github.com/psf/requests/issues/584
| 4,421,130 |
MDU6SXNzdWU0NDIxMTMw
| 584 |
Make oauth an optional dependency
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/92239?v=4",
"events_url": "https://api.github.com/users/piotr-dobrogost/events{/privacy}",
"followers_url": "https://api.github.com/users/piotr-dobrogost/followers",
"following_url": "https://api.github.com/users/piotr-dobrogost/following{/other_user}",
"gists_url": "https://api.github.com/users/piotr-dobrogost/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/piotr-dobrogost",
"id": 92239,
"login": "piotr-dobrogost",
"node_id": "MDQ6VXNlcjkyMjM5",
"organizations_url": "https://api.github.com/users/piotr-dobrogost/orgs",
"received_events_url": "https://api.github.com/users/piotr-dobrogost/received_events",
"repos_url": "https://api.github.com/users/piotr-dobrogost/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/piotr-dobrogost/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/piotr-dobrogost/subscriptions",
"type": "User",
"url": "https://api.github.com/users/piotr-dobrogost",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 13 |
2012-05-04T10:02:22Z
|
2021-09-09T08:00:49Z
|
2012-05-06T07:42:44Z
|
NONE
|
resolved
|
It would be nice not to force oauth on all users especially as it drags in pycrypto which has some binary parts making it more difficult to install.
|
{
"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/584/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/584/timeline
| null |
completed
| null | null | false |
[
"+1.\n\nBasically, if you don't have oauth, all of Requests should work fine except `requests.auth.OAuth1`. I would make it so that `OAuth1` throws an appropriate exception (probably `NotImplementedError`) in `__init__()` if oauth is unavailable.\n\nIf that sounds good, I'll send a pull request.\n",
"How about `ImportError` instead of `NotImplementedError`? The latter one suggests there's no implementation whereas there is one but it needs external module to work.\n",
"It is an optional dependency, like chardet. \n\nBetter yet, it would better if oauthlib had a soft dependency on pycrypto,\n",
"It's getting pulled in by setuptools, though. For example, Travis is having to compile it:\n\nhttp://travis-ci.org/#!/kennethreitz/requests/jobs/1243719\n\nIt might be more appropriate to put it in `extras_require`, like `gevent`.\n",
"Ideally oathlib won't require pycrypto soon. We'll see.\n",
"I guess the real reason is that `chardet` is more important to Requests than `oauthlib` is, e.g., a bunch of the unit tests will `ValueError` without it.\n",
"@piotr-dobrogost can you clarify what happens now if you `pip install requests` on Windows? Does it crash?\n",
"Windows can build pycrypto just fine if you have the proper compilers available. \n",
"From the sound of it, though, the typical Windows user trying to install Requests doesn't.\n",
"Again, ideally oathlib won't require pycrypto soon. We'll see.\n",
"> can you clarify what happens now if you pip install requests on Windows? Does it crash?\n\nOf course it crashes :) which is expected having pycrypto as a strictly required dependency.\n\n> From the sound of it, though, the typical Windows user trying to install Requests doesn't.\n\nThat's right. Why would someone need C compiler to program in Python? :)\n\n> I guess the real reason is that chardet is more important to Requests than oauthlib is, e.g., a bunch of the unit tests will ValueError without it.\n\nIdeally chardet should be optional as well.\n",
"We've dropped pycrypto from oauthlib, it now uses the pure-python [python-rsa](http://stuvel.eu/rsa) instead.\n",
":sparkles::cake::sparkles:\n"
] |
https://api.github.com/repos/psf/requests/issues/583
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/583/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/583/comments
|
https://api.github.com/repos/psf/requests/issues/583/events
|
https://github.com/psf/requests/issues/583
| 4,420,626 |
MDU6SXNzdWU0NDIwNjI2
| 583 |
new implementation for safe_mode?
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/376448?v=4",
"events_url": "https://api.github.com/users/slingamn/events{/privacy}",
"followers_url": "https://api.github.com/users/slingamn/followers",
"following_url": "https://api.github.com/users/slingamn/following{/other_user}",
"gists_url": "https://api.github.com/users/slingamn/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/slingamn",
"id": 376448,
"login": "slingamn",
"node_id": "MDQ6VXNlcjM3NjQ0OA==",
"organizations_url": "https://api.github.com/users/slingamn/orgs",
"received_events_url": "https://api.github.com/users/slingamn/received_events",
"repos_url": "https://api.github.com/users/slingamn/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/slingamn/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/slingamn/subscriptions",
"type": "User",
"url": "https://api.github.com/users/slingamn",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 8 |
2012-05-04T09:21:41Z
|
2021-09-09T08:00:45Z
|
2012-05-10T18:11:19Z
|
CONTRIBUTOR
|
resolved
|
The current implementation of `safe_mode` seems to be a source of bugs. In safe mode, many members of the `Request` and `Response` objects can be `None`, so they have to be checked manually. Also,
Would it be possible to reimplement safe_mode by catching all known exception types (`RequestException`, `ConnectionError`, `HTTPError`) at the outermost API level? Then we would respond to exceptions by falling immediately back down to the API level.
The implementation of this catch-and-save behavior could probably be a decorator on each API method.
|
{
"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/583/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/583/timeline
| null |
completed
| null | null | false |
[
"Basically, if I understand the problem correctly, here's how to implement this change.\n1. `git grep -i safe`\n2. Remove all checks for safe mode\n3. Remove `if baz is None` tests that are only relevant in safe mode\n4. Decorate all the functions in `requests/api.py` with something that catches the relevant exception types, constructs an empty `Response` object, populates its `error` field with the exception, and returns it\n\nThe implementation of `danger_mode` can stay as-is.\n",
"+1\n",
"Sounds reasonable.\n",
"#TODO as per #517, also catch `socket.timeout`.\n",
"I would like to begin contributing to Requests. This seems like something I could handle. If this seems like an okay problem to start with, I'll give it a try.\n",
"@joshimhoff go for it :)\n",
"I have finished my implementation, but I am unsure where in the file-system the safe_mode decorator should live. Anyone have an opinion? Currently, I created a new module, safe_mode.py, as the decorator did not seem to fit into any existing modules.\n",
"@joshimhoff fantastic work.\n"
] |
https://api.github.com/repos/psf/requests/issues/582
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/582/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/582/comments
|
https://api.github.com/repos/psf/requests/issues/582/events
|
https://github.com/psf/requests/pull/582
| 4,418,977 |
MDExOlB1bGxSZXF1ZXN0MTI4NjQ4MQ==
| 582 |
Tests for persistent and secure cookies
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/376448?v=4",
"events_url": "https://api.github.com/users/slingamn/events{/privacy}",
"followers_url": "https://api.github.com/users/slingamn/followers",
"following_url": "https://api.github.com/users/slingamn/following{/other_user}",
"gists_url": "https://api.github.com/users/slingamn/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/slingamn",
"id": 376448,
"login": "slingamn",
"node_id": "MDQ6VXNlcjM3NjQ0OA==",
"organizations_url": "https://api.github.com/users/slingamn/orgs",
"received_events_url": "https://api.github.com/users/slingamn/received_events",
"repos_url": "https://api.github.com/users/slingamn/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/slingamn/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/slingamn/subscriptions",
"type": "User",
"url": "https://api.github.com/users/slingamn",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 2 |
2012-05-04T06:21:49Z
|
2021-09-08T15:01:03Z
|
2012-05-04T06:26:44Z
|
CONTRIBUTOR
|
resolved
|
Spectacularly annoying tests for persistent and secure cookies. This change is test-only.
|
{
"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/582/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/582/timeline
| null | null | false |
{
"diff_url": "https://github.com/psf/requests/pull/582.diff",
"html_url": "https://github.com/psf/requests/pull/582",
"merged_at": "2012-05-04T06:26:44Z",
"patch_url": "https://github.com/psf/requests/pull/582.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/582"
}
| true |
[
"This pull request [passes](http://travis-ci.org/kennethreitz/requests/builds/1242795) (merged 8fedec78 into 1adaba38).\n",
"I'm terrified to add these, but okay :)\n"
] |
https://api.github.com/repos/psf/requests/issues/581
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/581/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/581/comments
|
https://api.github.com/repos/psf/requests/issues/581/events
|
https://github.com/psf/requests/pull/581
| 4,418,553 |
MDExOlB1bGxSZXF1ZXN0MTI4NjMxOQ==
| 581 |
A utility for using environment proxies
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/343499?v=4",
"events_url": "https://api.github.com/users/crodjer/events{/privacy}",
"followers_url": "https://api.github.com/users/crodjer/followers",
"following_url": "https://api.github.com/users/crodjer/following{/other_user}",
"gists_url": "https://api.github.com/users/crodjer/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/crodjer",
"id": 343499,
"login": "crodjer",
"node_id": "MDQ6VXNlcjM0MzQ5OQ==",
"organizations_url": "https://api.github.com/users/crodjer/orgs",
"received_events_url": "https://api.github.com/users/crodjer/received_events",
"repos_url": "https://api.github.com/users/crodjer/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/crodjer/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/crodjer/subscriptions",
"type": "User",
"url": "https://api.github.com/users/crodjer",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 4 |
2012-05-04T05:16:59Z
|
2021-09-08T15:01:03Z
|
2012-05-04T06:28:07Z
|
CONTRIBUTOR
|
resolved
|
This provides a utility function that reads the environment proxies. It returns proxies in a format compatible with request's proxy parameter.
Moreover, it can be used in the request models for proxy defaults.
|
{
"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/581/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/581/timeline
| null | null | false |
{
"diff_url": "https://github.com/psf/requests/pull/581.diff",
"html_url": "https://github.com/psf/requests/pull/581",
"merged_at": "2012-05-04T06:28:07Z",
"patch_url": "https://github.com/psf/requests/pull/581.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/581"
}
| true |
[
"This pull request [passes](http://travis-ci.org/kennethreitz/requests/builds/1242492) (merged abc38cf1 into 1adaba38).\n",
"This pull request [passes](http://travis-ci.org/kennethreitz/requests/builds/1242554) (merged 7cf6ca80 into 1adaba38).\n",
"This is fantastic, thanks a ton!\n",
":sparkles: :cake: :sparkles:\n"
] |
https://api.github.com/repos/psf/requests/issues/580
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/580/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/580/comments
|
https://api.github.com/repos/psf/requests/issues/580/events
|
https://github.com/psf/requests/pull/580
| 4,418,212 |
MDExOlB1bGxSZXF1ZXN0MTI4NjE1Mg==
| 580 |
Fix and test for #458
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/376448?v=4",
"events_url": "https://api.github.com/users/slingamn/events{/privacy}",
"followers_url": "https://api.github.com/users/slingamn/followers",
"following_url": "https://api.github.com/users/slingamn/following{/other_user}",
"gists_url": "https://api.github.com/users/slingamn/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/slingamn",
"id": 376448,
"login": "slingamn",
"node_id": "MDQ6VXNlcjM3NjQ0OA==",
"organizations_url": "https://api.github.com/users/slingamn/orgs",
"received_events_url": "https://api.github.com/users/slingamn/received_events",
"repos_url": "https://api.github.com/users/slingamn/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/slingamn/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/slingamn/subscriptions",
"type": "User",
"url": "https://api.github.com/users/slingamn",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 3 |
2012-05-04T04:18:58Z
|
2021-09-08T15:01:04Z
|
2012-05-04T04:33:42Z
|
CONTRIBUTOR
|
resolved
|
Fix and test for #458.
|
{
"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/580/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/580/timeline
| null | null | false |
{
"diff_url": "https://github.com/psf/requests/pull/580.diff",
"html_url": "https://github.com/psf/requests/pull/580",
"merged_at": "2012-05-04T04:33:42Z",
"patch_url": "https://github.com/psf/requests/pull/580.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/580"
}
| true |
[
"This pull request [passes](http://travis-ci.org/kennethreitz/requests/builds/1242233) (merged 35ec6bb6 into 317f64a1).\n",
"Heh, if the user sets `headers={'connection': 'keep-alive'}` and `config={'keep_alive': False}`, which should win? Right now it's the config.\n",
"You're amazing.\n"
] |
https://api.github.com/repos/psf/requests/issues/579
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/579/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/579/comments
|
https://api.github.com/repos/psf/requests/issues/579/events
|
https://github.com/psf/requests/pull/579
| 4,417,727 |
MDExOlB1bGxSZXF1ZXN0MTI4NTk3Ng==
| 579 |
Changes for #574
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/376448?v=4",
"events_url": "https://api.github.com/users/slingamn/events{/privacy}",
"followers_url": "https://api.github.com/users/slingamn/followers",
"following_url": "https://api.github.com/users/slingamn/following{/other_user}",
"gists_url": "https://api.github.com/users/slingamn/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/slingamn",
"id": 376448,
"login": "slingamn",
"node_id": "MDQ6VXNlcjM3NjQ0OA==",
"organizations_url": "https://api.github.com/users/slingamn/orgs",
"received_events_url": "https://api.github.com/users/slingamn/received_events",
"repos_url": "https://api.github.com/users/slingamn/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/slingamn/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/slingamn/subscriptions",
"type": "User",
"url": "https://api.github.com/users/slingamn",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 3 |
2012-05-04T03:02:48Z
|
2021-09-08T15:01:02Z
|
2012-05-04T06:29:04Z
|
CONTRIBUTOR
|
resolved
|
Mostly what was discussed for #574.
This patch will run pyflakes on a whitelisted set of files during the Jenkins build (but not the Travis); I can remove that if you'd prefer to keep it separate.
|
{
"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/579/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/579/timeline
| null | null | false |
{
"diff_url": "https://github.com/psf/requests/pull/579.diff",
"html_url": "https://github.com/psf/requests/pull/579",
"merged_at": "2012-05-04T06:29:04Z",
"patch_url": "https://github.com/psf/requests/pull/579.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/579"
}
| true |
[
"This pull request [passes](http://travis-ci.org/kennethreitz/requests/builds/1241977) (merged bcc4125a into 317f64a1).\n",
"BTW, Jenkins used to run the `init` target, but doesn't anymore after 57ccd7e65c30 (I foolishly assumed no one was using the original `ci` target). Does Jenkins need that to work?\n",
"Thanks!\n"
] |
https://api.github.com/repos/psf/requests/issues/578
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/578/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/578/comments
|
https://api.github.com/repos/psf/requests/issues/578/events
|
https://github.com/psf/requests/issues/578
| 4,417,361 |
MDU6SXNzdWU0NDE3MzYx
| 578 |
document new cookie API (and maybe improve it)
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/376448?v=4",
"events_url": "https://api.github.com/users/slingamn/events{/privacy}",
"followers_url": "https://api.github.com/users/slingamn/followers",
"following_url": "https://api.github.com/users/slingamn/following{/other_user}",
"gists_url": "https://api.github.com/users/slingamn/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/slingamn",
"id": 376448,
"login": "slingamn",
"node_id": "MDQ6VXNlcjM3NjQ0OA==",
"organizations_url": "https://api.github.com/users/slingamn/orgs",
"received_events_url": "https://api.github.com/users/slingamn/received_events",
"repos_url": "https://api.github.com/users/slingamn/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/slingamn/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/slingamn/subscriptions",
"type": "User",
"url": "https://api.github.com/users/slingamn",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 9 |
2012-05-04T02:05:26Z
|
2021-09-09T07:05:28Z
|
2012-07-27T05:53:30Z
|
CONTRIBUTOR
|
resolved
|
The `cookies` member of the `Response` and `Session` objects is no longer a dict, it's a `RequestsCookieJar` that behaves like a dict in some cases. However:
1. You can't take `dict(resp.cookies)`, since iteration over a `CookieJar` gives you the `Cookie` objects, which are not valid keys for the dict interface (it expects string keynames). Even if we added this, the dict cast would map `Cookie` objects to string values, which would be weird and not very useful.
2. In general, `CookieJar`s are quite awkward to work with. In test cases I found myself writing `list(resp.cookies)[0]` a lot. I'm not sure what the ideal way to work with them would be.
|
{
"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/578/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/578/timeline
| null |
completed
| null | null | false |
[
"It seems reasonable to have cookies.keys return cookie names, and cookies.values return values, so that dict(resp.cookies) returns a name:value dict. The get/set methods would still be available for when it is necessary to get access to the actual cookie objects.\n",
"+100. We should define `keys()`, `items()`, and `values()`. Thanks!\n\nAre you interested in writing a patch?\n",
"And I should have been using `get()` in the unit tests. One of us should docstring which methods return what.\n",
"@slingamn I'll work on a patch for this, if no one else is doing it.\n",
"@dhagrow \n\n> It seems reasonable to have cookies.keys return cookie names, and cookies.values return values (...)\n\nWhat with cookies with the same name and different domain or path?\n",
"@slingamn \nSorry for not responding earlier. I don't think I'll find the time for this soon. If @joshimhoff is willing, that would be great.\n\n@piotr-dobrogost\nI see two use-cases for `RequestsCookieJar`:\n- One is the dev interested in a single domain, in which case `dict(res.cookies)` would be sufficient.\n- The other is the dev interested in multiple domains, in which case it is necessary to be explicit.\n\nI think I would default to the first case, but force the dev to use the second when necessary to avoid ambiguity. In other words, when using the simple API would cause a conflict, raise an exception.\n\n```\n>>> req.cookies['name'] = 'value'\nCookieConflictError: There are multiple cookies with the name 'name'\n```\n\nI'm not sure if it would be better to raise the exception when more than one domain/path is stored in the jar, or only when there is an actually conflicting cookie. I would say the former to favor explicitness. It doesn't make much sense to have a `dict` of cookies from multiple domains.\n\nThe simple API would have `res.cookies` act as a standard `dict` object, including the `.get` method. I would then add a special API for `Cookie` objects:\n- `.get_cookie(name, domain, path, ...)` returns a `Cookie` object.\n- `.set_cookie(name, value, domain, path, ...)` sets/creates a `Cookie`.\n- `.get_dict(domain, path, ...)` returns a `name:value` dict of cookies that match the specified requirements.\n- perhaps some useful info methods as well, like `.list_domains`.\n\nAnyway, it's not a simple problem. It's worth some discussion to get it right.\n",
"@joshimhoff go for it :-)\n",
"@kennethreitz Any opinion on the error handling that @dhagrow mentions? I'm working on a patch, but I don't really think I should make that decision.\n",
"There is an alternative API that might be a little less jarring. The `Request` and `Response` objects don't actually need direct access to the full cookiejar, so they could each store just a `dict` of their own relevant cookies. For the `Request`, just the cookies pulled from the cookiejar as it was created. For the `Response`, those same cookies, plus any new ones from a `Set-Cookie` header.\n\nTo get access to the full set of cookies you would use `session.cookies`, which would no longer have a `dict` interface, but rather just `.set_cookie`, `.get_cookie`, `.get_dict`, etc..., as in my previous suggestion.\n\nDoing it this way seems a little more user-friendly, but you would have to make sure that anytime `request.cookies` is modified, the `session.cookies` object is updated correctly.\n"
] |
https://api.github.com/repos/psf/requests/issues/577
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/577/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/577/comments
|
https://api.github.com/repos/psf/requests/issues/577/events
|
https://github.com/psf/requests/pull/577
| 4,401,102 |
MDExOlB1bGxSZXF1ZXN0MTI3ODM5OA==
| 577 |
Fix and test for #537
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/376448?v=4",
"events_url": "https://api.github.com/users/slingamn/events{/privacy}",
"followers_url": "https://api.github.com/users/slingamn/followers",
"following_url": "https://api.github.com/users/slingamn/following{/other_user}",
"gists_url": "https://api.github.com/users/slingamn/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/slingamn",
"id": 376448,
"login": "slingamn",
"node_id": "MDQ6VXNlcjM3NjQ0OA==",
"organizations_url": "https://api.github.com/users/slingamn/orgs",
"received_events_url": "https://api.github.com/users/slingamn/received_events",
"repos_url": "https://api.github.com/users/slingamn/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/slingamn/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/slingamn/subscriptions",
"type": "User",
"url": "https://api.github.com/users/slingamn",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 1 |
2012-05-03T08:32:26Z
|
2021-09-08T15:01:02Z
|
2012-05-03T08:36:12Z
|
CONTRIBUTOR
|
resolved
|
Fix and test for #537.
Please first fastforward master into develop and then merge #572, though :-)
|
{
"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/577/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/577/timeline
| null | null | false |
{
"diff_url": "https://github.com/psf/requests/pull/577.diff",
"html_url": "https://github.com/psf/requests/pull/577",
"merged_at": "2012-05-03T08:36:12Z",
"patch_url": "https://github.com/psf/requests/pull/577.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/577"
}
| true |
[
"This pull request [passes](http://travis-ci.org/kennethreitz/requests/builds/1234188) (merged 9bf53676 into 373a34a1).\n"
] |
https://api.github.com/repos/psf/requests/issues/576
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/576/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/576/comments
|
https://api.github.com/repos/psf/requests/issues/576/events
|
https://github.com/psf/requests/issues/576
| 4,400,105 |
MDU6SXNzdWU0NDAwMTA1
| 576 |
local testing mock server
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/376448?v=4",
"events_url": "https://api.github.com/users/slingamn/events{/privacy}",
"followers_url": "https://api.github.com/users/slingamn/followers",
"following_url": "https://api.github.com/users/slingamn/following{/other_user}",
"gists_url": "https://api.github.com/users/slingamn/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/slingamn",
"id": 376448,
"login": "slingamn",
"node_id": "MDQ6VXNlcjM3NjQ0OA==",
"organizations_url": "https://api.github.com/users/slingamn/orgs",
"received_events_url": "https://api.github.com/users/slingamn/received_events",
"repos_url": "https://api.github.com/users/slingamn/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/slingamn/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/slingamn/subscriptions",
"type": "User",
"url": "https://api.github.com/users/slingamn",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 6 |
2012-05-03T06:44:06Z
|
2021-09-09T09:00:33Z
|
2012-05-03T06:54:44Z
|
CONTRIBUTOR
|
resolved
|
Right now, it's not really possible to test things like secure cookies that aren't supported by httpbin.org. urllib3 has a "dummy server":
https://github.com/shazow/urllib3/blob/master/dummyserver/server.py
that can be used to serve one-off canned responses from `localhost` --- providing full control over headers, body, etc. I wouldn't want to depend on `tornado` for this, so I'm not suggesting copying and pasting `dummyserver`, but do you think something similar would be useful?
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/376448?v=4",
"events_url": "https://api.github.com/users/slingamn/events{/privacy}",
"followers_url": "https://api.github.com/users/slingamn/followers",
"following_url": "https://api.github.com/users/slingamn/following{/other_user}",
"gists_url": "https://api.github.com/users/slingamn/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/slingamn",
"id": 376448,
"login": "slingamn",
"node_id": "MDQ6VXNlcjM3NjQ0OA==",
"organizations_url": "https://api.github.com/users/slingamn/orgs",
"received_events_url": "https://api.github.com/users/slingamn/received_events",
"repos_url": "https://api.github.com/users/slingamn/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/slingamn/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/slingamn/subscriptions",
"type": "User",
"url": "https://api.github.com/users/slingamn",
"user_view_type": "public"
}
|
{
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/576/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/576/timeline
| null |
completed
| null | null | false |
[
"I run httpbin locally :)\n",
"Hmm, yeah, the `response_headers` method of httpbin should provide most of this functionality.\n\nBut would it be OK to start an httpbin (possibly in-process) from inside the unit tests? And to have them depend on the httpbin package?\n",
"We used to do that, but had to stop for Python 3, unfortunately. Werkzeug and Flask will support Python 3 within the next few months, if things go according to plan. So, I'm holding out until then ;)\n",
"Wait, never mind, that's not necessary either to test secure cookies. The remote httpbin should work just fine.\n\nWhen I get some time, I'll poke around in `test_requests_ext.py` and see if any important tests in there can't be converted to use remote httpbin.\n",
"That would be fantastic.\n",
"I'll close this in favor of incorporating any necessary functionality into a localized httpbin.\n"
] |
https://api.github.com/repos/psf/requests/issues/575
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/575/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/575/comments
|
https://api.github.com/repos/psf/requests/issues/575/events
|
https://github.com/psf/requests/issues/575
| 4,399,489 |
MDU6SXNzdWU0Mzk5NDg5
| 575 |
Redirect of multipart-encoded post
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/1701155?v=4",
"events_url": "https://api.github.com/users/VeniceBeachBum/events{/privacy}",
"followers_url": "https://api.github.com/users/VeniceBeachBum/followers",
"following_url": "https://api.github.com/users/VeniceBeachBum/following{/other_user}",
"gists_url": "https://api.github.com/users/VeniceBeachBum/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/VeniceBeachBum",
"id": 1701155,
"login": "VeniceBeachBum",
"node_id": "MDQ6VXNlcjE3MDExNTU=",
"organizations_url": "https://api.github.com/users/VeniceBeachBum/orgs",
"received_events_url": "https://api.github.com/users/VeniceBeachBum/received_events",
"repos_url": "https://api.github.com/users/VeniceBeachBum/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/VeniceBeachBum/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/VeniceBeachBum/subscriptions",
"type": "User",
"url": "https://api.github.com/users/VeniceBeachBum",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 1 |
2012-05-03T05:09:15Z
|
2021-09-09T08:00:46Z
|
2012-05-08T05:14:23Z
|
NONE
|
resolved
|
I'm scripting a site that returns a redirect in response to the post of a multipart-encoded form. When I do so, I get the following exception:
```
File "C:\Python27\lib\site-packages\requests\sessions.py", line 259, in post
return self.request('post', url, data=data, **kwargs)
File "C:\Python27\lib\site-packages\requests\sessions.py", line 209, in request
r.send(prefetch=prefetch)
File "C:\Python27\lib\site-packages\requests\models.py", line 624, in send
self._build_response(r)
File "C:\Python27\lib\site-packages\requests\models.py", line 297, in _build_response
cert=self.cert
File "C:\Python27\lib\site-packages\requests\models.py", line 119, in __init__
self.files, self._enc_files = self._encode_files(files)
File "C:\Python27\lib\site-packages\requests\models.py", line 346, in _encode_files
fields = dict(self.data)
TypeError: 'NoneType' object is not iterable
```
Browsing through the code, I found the following snippet in models.py - _build_response:
``` python
# Do what the browsers do if strict_mode is off...
if (not self.config.get('strict_mode')):
if r.status_code in (codes.moved, codes.found) and self.method == 'POST':
method = 'GET'
data = None
if (r.status_code == 303) and self.method != 'HEAD':
method = 'GET'
data = None
```
I'm guessing that `self.files` should also get set to `None` here, so that it doesn't get re-used in the subsequent request (causing the exception).
|
{
"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/575/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/575/timeline
| null |
completed
| null | null | false |
[
"Interesting catch, thanks!\n"
] |
https://api.github.com/repos/psf/requests/issues/574
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/574/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/574/comments
|
https://api.github.com/repos/psf/requests/issues/574/events
|
https://github.com/psf/requests/issues/574
| 4,398,867 |
MDU6SXNzdWU0Mzk4ODY3
| 574 |
run pyflakes during CI builds?
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/376448?v=4",
"events_url": "https://api.github.com/users/slingamn/events{/privacy}",
"followers_url": "https://api.github.com/users/slingamn/followers",
"following_url": "https://api.github.com/users/slingamn/following{/other_user}",
"gists_url": "https://api.github.com/users/slingamn/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/slingamn",
"id": 376448,
"login": "slingamn",
"node_id": "MDQ6VXNlcjM3NjQ0OA==",
"organizations_url": "https://api.github.com/users/slingamn/orgs",
"received_events_url": "https://api.github.com/users/slingamn/received_events",
"repos_url": "https://api.github.com/users/slingamn/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/slingamn/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/slingamn/subscriptions",
"type": "User",
"url": "https://api.github.com/users/slingamn",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 11 |
2012-05-03T03:26:07Z
|
2021-09-09T09:00:31Z
|
2012-05-04T11:40:13Z
|
CONTRIBUTOR
|
resolved
|
Sorry about that missing import :-/
Would a Travis build step that runs pyflakes on all relevant files be helpful? I'd whitelist the following:
- `docs/`
- `requests/packages/urllib3/`
- `tests/`
- anything named `__init__.py` or `compat.py`.
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/376448?v=4",
"events_url": "https://api.github.com/users/slingamn/events{/privacy}",
"followers_url": "https://api.github.com/users/slingamn/followers",
"following_url": "https://api.github.com/users/slingamn/following{/other_user}",
"gists_url": "https://api.github.com/users/slingamn/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/slingamn",
"id": 376448,
"login": "slingamn",
"node_id": "MDQ6VXNlcjM3NjQ0OA==",
"organizations_url": "https://api.github.com/users/slingamn/orgs",
"received_events_url": "https://api.github.com/users/slingamn/received_events",
"repos_url": "https://api.github.com/users/slingamn/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/slingamn/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/slingamn/subscriptions",
"type": "User",
"url": "https://api.github.com/users/slingamn",
"user_view_type": "public"
}
|
{
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/574/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/574/timeline
| null |
completed
| null | null | false |
[
"Oh yeah, `requests/packages/oreos/` too.\n",
"No need for travis, but I wouldn't mind adding it to http://ci.kennethreitz.com tests.\n",
"Ah. What make target does that service use?\n",
"`make ci`. We can add another if needed.\n",
"Cool, I added a separate target for travis; I'll send a pull request for this after #572 gets merged.\n",
"I've been wanting to find a purpose for a `make lemonade`. Let's have that be the metrics (pyflakes, coverage, etc)\n",
":-)\n\nBTW, re. #572, you may want to fastforward master into develop before doing any other merging.\n",
"(It's one commit ahead.)\n",
"Actually, if Travis doesn't run pyflakes and Jenkins does, isn't there a risk of pull requests passing Travis and then breaking the Jenkins build?\n\nI guess the question is whether it's worth enforcing pyflakes-compliance for every pull request or not.\n",
"Compliance? No. It'll be a nice metric though. I'll make it a separate job.\n",
":-)\n"
] |
https://api.github.com/repos/psf/requests/issues/573
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/573/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/573/comments
|
https://api.github.com/repos/psf/requests/issues/573/events
|
https://github.com/psf/requests/pull/573
| 4,393,649 |
MDExOlB1bGxSZXF1ZXN0MTI3NTYyMA==
| 573 |
Lazily encode data, params, files
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/22723?v=4",
"events_url": "https://api.github.com/users/idan/events{/privacy}",
"followers_url": "https://api.github.com/users/idan/followers",
"following_url": "https://api.github.com/users/idan/following{/other_user}",
"gists_url": "https://api.github.com/users/idan/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/idan",
"id": 22723,
"login": "idan",
"node_id": "MDQ6VXNlcjIyNzIz",
"organizations_url": "https://api.github.com/users/idan/orgs",
"received_events_url": "https://api.github.com/users/idan/received_events",
"repos_url": "https://api.github.com/users/idan/repos",
"site_admin": true,
"starred_url": "https://api.github.com/users/idan/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/idan/subscriptions",
"type": "User",
"url": "https://api.github.com/users/idan",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 2 |
2012-05-02T21:11:19Z
|
2021-09-08T15:01:01Z
|
2012-05-02T21:19:56Z
|
CONTRIBUTOR
|
resolved
|
Previously, data, params, and files were encoded and stored in
Request.**init**, and subsequently put into service during
Request.send. The problem with this approach is that hooks and auth
callables need to be aware of the eager encoding, and if they touch the
originals, make sure to update the encoded versions.
A better approach is to only encode late in the sending process. This
way, hooks and auth callables can safely make changes without fear of
the old, encoded variant overriding it.
|
{
"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/573/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/573/timeline
| null | null | false |
{
"diff_url": "https://github.com/psf/requests/pull/573.diff",
"html_url": "https://github.com/psf/requests/pull/573",
"merged_at": "2012-05-02T21:19:56Z",
"patch_url": "https://github.com/psf/requests/pull/573.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/573"
}
| true |
[
"This pull request [passes](http://travis-ci.org/kennethreitz/requests/builds/1230802) (merged cf6b2042 into 53d60cac).\n",
":sparkles: :cake: :sparkles:\n"
] |
https://api.github.com/repos/psf/requests/issues/572
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/572/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/572/comments
|
https://api.github.com/repos/psf/requests/issues/572/events
|
https://github.com/psf/requests/pull/572
| 4,379,700 |
MDExOlB1bGxSZXF1ZXN0MTI2OTg2MQ==
| 572 |
cleanup, redux
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/376448?v=4",
"events_url": "https://api.github.com/users/slingamn/events{/privacy}",
"followers_url": "https://api.github.com/users/slingamn/followers",
"following_url": "https://api.github.com/users/slingamn/following{/other_user}",
"gists_url": "https://api.github.com/users/slingamn/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/slingamn",
"id": 376448,
"login": "slingamn",
"node_id": "MDQ6VXNlcjM3NjQ0OA==",
"organizations_url": "https://api.github.com/users/slingamn/orgs",
"received_events_url": "https://api.github.com/users/slingamn/received_events",
"repos_url": "https://api.github.com/users/slingamn/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/slingamn/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/slingamn/subscriptions",
"type": "User",
"url": "https://api.github.com/users/slingamn",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 6 |
2012-05-02T07:10:18Z
|
2021-09-08T15:01:01Z
|
2012-05-03T08:35:47Z
|
CONTRIBUTOR
|
resolved
|
- Raise a ValueError on .text when chardet is unavailable
- `make ci` runs everything except test_requests_async and test_requests_ext
|
{
"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/572/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/572/timeline
| null | null | false |
{
"diff_url": "https://github.com/psf/requests/pull/572.diff",
"html_url": "https://github.com/psf/requests/pull/572",
"merged_at": "2012-05-03T08:35:47Z",
"patch_url": "https://github.com/psf/requests/pull/572.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/572"
}
| true |
[
"This pull request [fails](http://travis-ci.org/kennethreitz/requests/builds/1224921) (merged d4f48c0d into 53d60cac).\n",
"This pull request [passes](http://travis-ci.org/kennethreitz/requests/builds/1224957) (merged 628ffd65 into 53d60cac).\n",
"This pull request [passes](http://travis-ci.org/kennethreitz/requests/builds/1225144) (merged 37361dd8 into 53d60cac).\n",
"It would probably be good to cherry-pick cf34ccecec81 at least; otherwise Travis won't run `cookie_tests.py` against new pull requests.\n",
"This pull request [passes](http://travis-ci.org/kennethreitz/requests/builds/1233185) (merged 853a0711 into 373a34a1).\n",
"(Sorry, I rebased; cf34ccecec81 is now 57ccd7e65c3.)\n"
] |
https://api.github.com/repos/psf/requests/issues/571
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/571/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/571/comments
|
https://api.github.com/repos/psf/requests/issues/571/events
|
https://github.com/psf/requests/pull/571
| 4,379,377 |
MDExOlB1bGxSZXF1ZXN0MTI2OTc1NA==
| 571 |
Various forms of "cleanup"
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/376448?v=4",
"events_url": "https://api.github.com/users/slingamn/events{/privacy}",
"followers_url": "https://api.github.com/users/slingamn/followers",
"following_url": "https://api.github.com/users/slingamn/following{/other_user}",
"gists_url": "https://api.github.com/users/slingamn/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/slingamn",
"id": 376448,
"login": "slingamn",
"node_id": "MDQ6VXNlcjM3NjQ0OA==",
"organizations_url": "https://api.github.com/users/slingamn/orgs",
"received_events_url": "https://api.github.com/users/slingamn/received_events",
"repos_url": "https://api.github.com/users/slingamn/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/slingamn/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/slingamn/subscriptions",
"type": "User",
"url": "https://api.github.com/users/slingamn",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 2 |
2012-05-02T06:33:07Z
|
2021-09-08T15:01:00Z
|
2012-05-02T06:39:09Z
|
CONTRIBUTOR
|
resolved
|
Here are several atomic, largely-unrelated changes, ordered roughly from least to most controversial. Feel free to take whichever ones you like :-)
- Restore something I accidentally removed from the .gitignore
- Small documentation fix for the new cookie API
- Don't crash if we can't import chardet --- assume utf8 instead
- Cache response.text, since computing it can require a call into chardet
- Change setup.py to provide guidance for packagers (I think this is part of what @jnrowe was asking for)
- Have Travis run all the tests, not just `test_requests.py`
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/119893?v=4",
"events_url": "https://api.github.com/users/kennethreitz/events{/privacy}",
"followers_url": "https://api.github.com/users/kennethreitz/followers",
"following_url": "https://api.github.com/users/kennethreitz/following{/other_user}",
"gists_url": "https://api.github.com/users/kennethreitz/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/kennethreitz",
"id": 119893,
"login": "kennethreitz",
"node_id": "MDQ6VXNlcjExOTg5Mw==",
"organizations_url": "https://api.github.com/users/kennethreitz/orgs",
"received_events_url": "https://api.github.com/users/kennethreitz/received_events",
"repos_url": "https://api.github.com/users/kennethreitz/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/kennethreitz/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/kennethreitz/subscriptions",
"type": "User",
"url": "https://api.github.com/users/kennethreitz",
"user_view_type": "public"
}
|
{
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/571/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/571/timeline
| null | null | false |
{
"diff_url": "https://github.com/psf/requests/pull/571.diff",
"html_url": "https://github.com/psf/requests/pull/571",
"merged_at": "2012-05-02T06:39:09Z",
"patch_url": "https://github.com/psf/requests/pull/571.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/571"
}
| true |
[
"This pull request [fails](http://travis-ci.org/kennethreitz/requests/builds/1224813) (merged a453a78c into 45be14ed).\n",
"merged, thanks!\n\n:cake:\n"
] |
https://api.github.com/repos/psf/requests/issues/570
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/570/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/570/comments
|
https://api.github.com/repos/psf/requests/issues/570/events
|
https://github.com/psf/requests/issues/570
| 4,370,161 |
MDU6SXNzdWU0MzcwMTYx
| 570 |
Unnecessary use of list() and items() in "for" loops
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/92239?v=4",
"events_url": "https://api.github.com/users/piotr-dobrogost/events{/privacy}",
"followers_url": "https://api.github.com/users/piotr-dobrogost/followers",
"following_url": "https://api.github.com/users/piotr-dobrogost/following{/other_user}",
"gists_url": "https://api.github.com/users/piotr-dobrogost/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/piotr-dobrogost",
"id": 92239,
"login": "piotr-dobrogost",
"node_id": "MDQ6VXNlcjkyMjM5",
"organizations_url": "https://api.github.com/users/piotr-dobrogost/orgs",
"received_events_url": "https://api.github.com/users/piotr-dobrogost/received_events",
"repos_url": "https://api.github.com/users/piotr-dobrogost/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/piotr-dobrogost/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/piotr-dobrogost/subscriptions",
"type": "User",
"url": "https://api.github.com/users/piotr-dobrogost",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 4 |
2012-05-01T17:11:05Z
|
2021-09-09T09:00:35Z
|
2012-05-01T18:43:08Z
|
NONE
|
resolved
|
In many `for` loops there is unnecessary use of list() and items() instead of iteritems(). One example
[`for (k, v) in list(defaults.items()):`](https://github.com/kennethreitz/requests/blob/775b6f6f0098ffa9edd3874b1af4b98378377211/requests/sessions.py#L83). Adding list() and changing iteritems() to items() was done in changeset b0e2e4f284f619536b7f405122bb1a93900cd743 with commit message "blah"...
What is the point?
|
{
"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/570/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/570/timeline
| null |
completed
| null | null | false |
[
"Based on the commit message, I'm guessing it's something to do with Py32. :P\n",
"I'm sure there was a reason at the time :)\n",
"How about reverting to the proper state until you find out what was the reason? :)\n",
":bike: :house:\n"
] |
https://api.github.com/repos/psf/requests/issues/569
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/569/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/569/comments
|
https://api.github.com/repos/psf/requests/issues/569/events
|
https://github.com/psf/requests/pull/569
| 4,356,919 |
MDExOlB1bGxSZXF1ZXN0MTI2MDI4MQ==
| 569 |
Proper test for str vs unicode when preparing data
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/22723?v=4",
"events_url": "https://api.github.com/users/idan/events{/privacy}",
"followers_url": "https://api.github.com/users/idan/followers",
"following_url": "https://api.github.com/users/idan/following{/other_user}",
"gists_url": "https://api.github.com/users/idan/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/idan",
"id": 22723,
"login": "idan",
"node_id": "MDQ6VXNlcjIyNzIz",
"organizations_url": "https://api.github.com/users/idan/orgs",
"received_events_url": "https://api.github.com/users/idan/received_events",
"repos_url": "https://api.github.com/users/idan/repos",
"site_admin": true,
"starred_url": "https://api.github.com/users/idan/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/idan/subscriptions",
"type": "User",
"url": "https://api.github.com/users/idan",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 3 |
2012-04-30T20:12:08Z
|
2021-09-08T23:06:31Z
|
2012-05-01T10:01:24Z
|
CONTRIBUTOR
|
resolved
|
In python 2.x, requests sets str = unicode in requests/compat.py. This causes
isinstance(foo, str) to return True even if foo is a unicode string.
Supersedes #556, which I totally broke.
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/22723?v=4",
"events_url": "https://api.github.com/users/idan/events{/privacy}",
"followers_url": "https://api.github.com/users/idan/followers",
"following_url": "https://api.github.com/users/idan/following{/other_user}",
"gists_url": "https://api.github.com/users/idan/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/idan",
"id": 22723,
"login": "idan",
"node_id": "MDQ6VXNlcjIyNzIz",
"organizations_url": "https://api.github.com/users/idan/orgs",
"received_events_url": "https://api.github.com/users/idan/received_events",
"repos_url": "https://api.github.com/users/idan/repos",
"site_admin": true,
"starred_url": "https://api.github.com/users/idan/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/idan/subscriptions",
"type": "User",
"url": "https://api.github.com/users/idan",
"user_view_type": "public"
}
|
{
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/569/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/569/timeline
| null | null | false |
{
"diff_url": "https://github.com/psf/requests/pull/569.diff",
"html_url": "https://github.com/psf/requests/pull/569",
"merged_at": null,
"patch_url": "https://github.com/psf/requests/pull/569.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/569"
}
| true |
[
"This pull request [fails](http://travis-ci.org/kennethreitz/requests/builds/1213530) (merged 0ec0e9f3 into ef0bf79f).\n",
"Le big sigh, this breaks something. Working it out, fix coming shortly.\n",
"Let's all agree to forget I ever made this PR.\n"
] |
https://api.github.com/repos/psf/requests/issues/568
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/568/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/568/comments
|
https://api.github.com/repos/psf/requests/issues/568/events
|
https://github.com/psf/requests/issues/568
| 4,342,267 |
MDU6SXNzdWU0MzQyMjY3
| 568 |
Import error using requests.async with 10000 URLs
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/294177?v=4",
"events_url": "https://api.github.com/users/esaurito/events{/privacy}",
"followers_url": "https://api.github.com/users/esaurito/followers",
"following_url": "https://api.github.com/users/esaurito/following{/other_user}",
"gists_url": "https://api.github.com/users/esaurito/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/esaurito",
"id": 294177,
"login": "esaurito",
"node_id": "MDQ6VXNlcjI5NDE3Nw==",
"organizations_url": "https://api.github.com/users/esaurito/orgs",
"received_events_url": "https://api.github.com/users/esaurito/received_events",
"repos_url": "https://api.github.com/users/esaurito/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/esaurito/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/esaurito/subscriptions",
"type": "User",
"url": "https://api.github.com/users/esaurito",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 3 |
2012-04-29T18:13:54Z
|
2021-09-09T08:00:44Z
|
2012-05-10T22:06:06Z
|
NONE
|
resolved
|
I'm using requests to download asynchronously and parse the content of a bunch of URLs from different hosts. When the number of URLs is small (up to 1000 URLs) all works fine. When I run the same script with 10000 I get the following error **only when there are about 10 URLs left to download**:
``` python
Traceback (most recent call last):
File "many_async_req.py", line 35, in <module>
File "/home/alex/code/.virtualenvs/testreq/local/lib/python2.7/site-packages/requests-0.11.2-py2.7.egg/requests/async.py", line 83, in map
File "/home/alex/code/.virtualenvs/testreq/local/lib/python2.7/site-packages/gevent/greenlet.py", line 487, in joinall
ImportError: No module named queue
```
Sometimes the script just hangs with about 10 URLs left. I observed this behavior with requests installed from pipy and with the code downloaded from the development branch.
This happened to me using the version of gevent from pypi **and** using the [latest version](http://code.google.com/p/gevent/downloads/list) downloaded from gevent's Google Code repository.
I'm using a virtualenv with only the relevant modules installed:
``` bash
(testreq)alex@haiku:~/code$ pip freeze
certifi==0.0.8
chardet==1.0.1
distribute==0.6.19
gevent==0.13.7
greenlet==0.3.4
requests==0.11.2
wsgiref==0.1.2
```
To reproduce the error I'm using the following script (that is a stripped-down version of the original) that basically just print the status code of each URL.
``` python
import codecs
import random
from requests import async
from requests import defaults
import sys
defaults.defaults['base_headers']['User-Agent'] = "Mozilla/5.0 (Windows NT 5.1; rv:11.0) Gecko/20100101 Firefox/11.0"
defaults.defaults['max_retries'] = 5
defaults.defaults['verbose'] = sys.stderr
def check(response):
global counter
print "\t %s HTTP status code: %s" % (counter, response.status_code)
counter += 1
def load_urls(fname):
""" Read URLs from file and remove duplicates """
with codecs.open(fname, 'r', 'utf-8') as fh:
urls = list(set([url.strip() for url in fh.readlines()]))
random.shuffle(urls)
return urls
if __name__ == '__main__':
urls = load_urls('urls.txt')
limit = int(sys.argv[1])
urls = urls[:limit]
rs = []
counter = 0
todo = len(urls)
for url in urls:
rs.append(async.get(url, hooks=dict(response=check), timeout=5.0))
async.map(rs, size=10)
print "To check: %s" % todo
print "To checked: %s" % counter
```
|
{
"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/568/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/568/timeline
| null |
completed
| null | null | false |
[
"It is curious to me why you aren't using a generator for this, but it looks like it wouldn't work anyway due to this sorcery\nhttps://github.com/kennethreitz/requests/blob/develop/requests/async.py#L79. \n\nWell there is the imap function that looks to be generator compatible, but its not mentioned in the docs anywhere. http://docs.python-requests.org/en/latest/search/?q=imap&check_keywords=yes&area=default\n",
"@pythonben It's just because I'm a n00b :-)\n",
"Async is removed from requests now. A new module, [grequests](https://github.com/kennethreitz/grequests) will replace it.\n"
] |
https://api.github.com/repos/psf/requests/issues/567
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/567/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/567/comments
|
https://api.github.com/repos/psf/requests/issues/567/events
|
https://github.com/psf/requests/issues/567
| 4,332,409 |
MDU6SXNzdWU0MzMyNDA5
| 567 |
Document Client Certs
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/119893?v=4",
"events_url": "https://api.github.com/users/kennethreitz/events{/privacy}",
"followers_url": "https://api.github.com/users/kennethreitz/followers",
"following_url": "https://api.github.com/users/kennethreitz/following{/other_user}",
"gists_url": "https://api.github.com/users/kennethreitz/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/kennethreitz",
"id": 119893,
"login": "kennethreitz",
"node_id": "MDQ6VXNlcjExOTg5Mw==",
"organizations_url": "https://api.github.com/users/kennethreitz/orgs",
"received_events_url": "https://api.github.com/users/kennethreitz/received_events",
"repos_url": "https://api.github.com/users/kennethreitz/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/kennethreitz/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/kennethreitz/subscriptions",
"type": "User",
"url": "https://api.github.com/users/kennethreitz",
"user_view_type": "public"
}
|
[
{
"color": "e102d8",
"default": false,
"description": null,
"id": 117745,
"name": "Planned",
"node_id": "MDU6TGFiZWwxMTc3NDU=",
"url": "https://api.github.com/repos/psf/requests/labels/Planned"
},
{
"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 | 2 |
2012-04-28T01:53:57Z
|
2021-09-09T06:00:51Z
|
2012-08-16T21:46:00Z
|
CONTRIBUTOR
|
resolved
|
https://gist.github.com/1943933
|
{
"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/567/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/567/timeline
| null |
completed
| null | null | false |
[
"Is this done, should the issue be closed?\n",
"Also yes. =)\n"
] |
https://api.github.com/repos/psf/requests/issues/566
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/566/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/566/comments
|
https://api.github.com/repos/psf/requests/issues/566/events
|
https://github.com/psf/requests/pull/566
| 4,308,490 |
MDExOlB1bGxSZXF1ZXN0MTI0MTEwMw==
| 566 |
Update AUTHORS.rst
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/6088?v=4",
"events_url": "https://api.github.com/users/bitprophet/events{/privacy}",
"followers_url": "https://api.github.com/users/bitprophet/followers",
"following_url": "https://api.github.com/users/bitprophet/following{/other_user}",
"gists_url": "https://api.github.com/users/bitprophet/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/bitprophet",
"id": 6088,
"login": "bitprophet",
"node_id": "MDQ6VXNlcjYwODg=",
"organizations_url": "https://api.github.com/users/bitprophet/orgs",
"received_events_url": "https://api.github.com/users/bitprophet/received_events",
"repos_url": "https://api.github.com/users/bitprophet/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/bitprophet/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/bitprophet/subscriptions",
"type": "User",
"url": "https://api.github.com/users/bitprophet",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 8 |
2012-04-26T18:17:20Z
|
2021-09-08T23:06:18Z
|
2012-04-26T18:32:14Z
|
NONE
|
resolved
|
lulz
|
{
"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/566/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/566/timeline
| null | null | false |
{
"diff_url": "https://github.com/psf/requests/pull/566.diff",
"html_url": "https://github.com/psf/requests/pull/566",
"merged_at": null,
"patch_url": "https://github.com/psf/requests/pull/566.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/566"
}
| true |
[
":trollface:\n",
"This pull request [fails](http://travis-ci.org/kennethreitz/requests/builds/1182970) (merged 72a75838 into ef0bf79f).\n",
"\n",
"FUCK THIS SHIT\n",
":-1::-1::-1::-1::-1::-1::-1::-1::-1::-1::-1::-1::-1::-1::-1::-1::-1::-1::-1::-1::-1::-1::-1::-1::-1::-1::-1::-1::-1::-1::-1::-1::-1::-1::-1::-1::-1::-1::-1::-1::-1::-1::-1::-1::-1::-1::-1::-1::-1::-1::-1::-1::-1::-1::-1::-1::-1::-1::-1::-1::-1::-1::-1::-1::-1::-1::-1::-1::-1::-1:\n\nYou can't change the authors THE TESTS FAIL\n",
"this made my day.\n",
"This pull request [fails](http://travis-ci.org/kennethreitz/requests/builds/1183066) (merged 72a75838 into ef0bf79f).\n",
"Two failures?! this is like failing calculus, retaking it in a summer course and _failing that too_. :cry:\n"
] |
https://api.github.com/repos/psf/requests/issues/565
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/565/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/565/comments
|
https://api.github.com/repos/psf/requests/issues/565/events
|
https://github.com/psf/requests/pull/565
| 4,276,005 |
MDExOlB1bGxSZXF1ZXN0MTIyODM0Mw==
| 565 |
Support CookieJar, references #281
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/376448?v=4",
"events_url": "https://api.github.com/users/slingamn/events{/privacy}",
"followers_url": "https://api.github.com/users/slingamn/followers",
"following_url": "https://api.github.com/users/slingamn/following{/other_user}",
"gists_url": "https://api.github.com/users/slingamn/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/slingamn",
"id": 376448,
"login": "slingamn",
"node_id": "MDQ6VXNlcjM3NjQ0OA==",
"organizations_url": "https://api.github.com/users/slingamn/orgs",
"received_events_url": "https://api.github.com/users/slingamn/received_events",
"repos_url": "https://api.github.com/users/slingamn/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/slingamn/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/slingamn/subscriptions",
"type": "User",
"url": "https://api.github.com/users/slingamn",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 30 |
2012-04-25T07:58:50Z
|
2021-09-08T23:06:18Z
|
2012-05-02T00:22:38Z
|
CONTRIBUTOR
|
resolved
|
This is my update of dhagrow's branch. It makes the backing store for cookies be a `CookieJar`, and adds compatibility with passed-in `CookieJar` subclasses like `LWPCookieJar`.
The default `CookieJar` implementation is compatible with existing code that expects `response.cookies` to be a dict.
This branch is complete to the best of my knowledge, but I haven't tested it against Python 3.x, since the current `develop` branch is broken against 3.x. I thought about trying to fix it but this change is confusing enough already :-)
I would appreciate suggestions for additional tests :-)
```
Traceback (most recent call last):
File "./test_requests_https.py", line 10, in <module>
import requests
File "/home/shivaram/workspace/requests/requests/__init__.py", line 25, in <module>
from . import utils
File "/home/shivaram/workspace/requests/requests/utils.py", line 476, in <module>
_unreserved_hextochr = dict((binascii.b2a_hex(c), c) for c in _unreserved_set)
File "/home/shivaram/workspace/requests/requests/utils.py", line 476, in <genexpr>
_unreserved_hextochr = dict((binascii.b2a_hex(c), c) for c in _unreserved_set)
TypeError: 'str' does not support the buffer interface
```
|
{
"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/565/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/565/timeline
| null | null | false |
{
"diff_url": "https://github.com/psf/requests/pull/565.diff",
"html_url": "https://github.com/psf/requests/pull/565",
"merged_at": "2012-05-02T00:22:38Z",
"patch_url": "https://github.com/psf/requests/pull/565.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/565"
}
| true |
[
"Right now, in `develop` and in this branch, it looks like if you pass in extra cookies via the `cookies` kwarg, they get stuck to the session:\n\nhttps://gist.github.com/2488388\n\nIs this correct / expected?\n",
"Python 3 definitely needs to be supported :)\n",
"This looks fantastic, btw. Going to dive in shortly.\n",
"Looks great to me as well.\n",
"Looks like I was wrong, it works properly on redirects. Here is my test for reference.\n\n``` python\n\n# get a cookie for tinyurl.com ONLY\nr1 = session.request(url='http://tinyurl.com/preview.php?disable=1', method='GET')\n# we have the cookie\nassert 'preview' in r1.cookies\n\n# get cookies on another domain\nr2 = session.request(url='http://httpbin.org/cookies', method='GET')\n# the cookie is not there\nassert 'preview' not in r2.text\n\n# this redirects to another domain, httpbin.org\n# cookies of the first domain should NOT be sent to the next one\nr3 = session.request(url='http://tinyurl.com/7zp3jnr', method='GET')\nassert r3.url == 'http://httpbin.org/cookies'\nassert 'preview' not in r3.text\n```\n\nThis was my biggest issue with the current implementation, I had to disable the redirection handling entirely because there was no way to intervene between redirects (I still think that part is broken though, hooks would be nice).\n\nI also tested it against some weird Set-Cookie: combinations, and it seems to work. The secure flag works too.\n",
"This pull request [fails](http://travis-ci.org/kennethreitz/requests/builds/1184171) (merged 0faf1c6c into a744edd0).\n",
"@travisbot that's the same traceback I get from `develop` under Python 3.2.\n",
"@slingamn I'll update the repo to pass today :)\n",
"This pull request [fails](http://travis-ci.org/kennethreitz/requests/builds/1209718) (merged cc6b1ce3 into a744edd0).\n",
"would it be possible for you to remove the commits that are included that aren't by you?\n",
"The ones by dhagrow? Any particular reason? Most of the code is originally his, and in particular c04bf801a339 is an atomic bug fix.\n",
"Oh, I think what happened is that `develop` was rebased and force-pushed:\n\n```\nFrom git://github.com/kennethreitz/requests\n + a744edd...a189c23 develop -> parent/develop (forced update)\n```\n\nso now commits that were force-removed from `develop` are showing up as part of this pull request.\n\nI'll rebase the commits from me and dhagrow on top of the current `develop` and archive the current version of this branch in my fork.\n",
"Actually, wait. It looks like that force-push removed some stuff that might actually be relevant, e.g., #563 and #564. Did you intend to force those out of `develop`?\n",
"It wasn't force pushed, it was removed and republished with the bad commits removed. I should have taken the time to revert properly, but I couldn't find the offending commit easily and was an impatient mood ;(\n\nI may create a new pull request with only your actual changes included.\n",
"No problem; if a189c238cc2 is the correct version of develop, then I'll rebase on that myself. Coming up.\n",
"Oh, heh, I left something out. I'll update again.\n",
"This pull request [fails](http://travis-ci.org/kennethreitz/requests/builds/1222636) (merged 722338f6 into a189c238).\n",
"Only fails on 3.x now :)\n",
"This pull request [fails](http://travis-ci.org/kennethreitz/requests/builds/1222656) (merged 7af97b69 into a189c238).\n",
"Oh, cool, an actual failure! I'll get that fixed.\n",
"Actually, `develop` is still broken for me under Python 3:\n\n```\n======================================================================\nERROR: test_HTTP_200_OK_GET_WITH_PARAMS (__main__.RequestsTestSuite)\n----------------------------------------------------------------------\nTraceback (most recent call last):\n File \"./test_requests.py\", line 100, in test_HTTP_200_OK_GET_WITH_PARAMS\n assert heads['User-agent'] in r.text\nTypeError: argument of type 'NoneType' is not iterable\n\n======================================================================\nERROR: test_nonurlencoded_post_data (__main__.RequestsTestSuite)\n----------------------------------------------------------------------\nTraceback (most recent call last):\n File \"./test_requests.py\", line 421, in test_nonurlencoded_post_data\n rbody = json.loads(r.text)\n File \"/usr/lib64/python3.2/json/__init__.py\", line 307, in loads\n return _default_decoder.decode(s)\n File \"/usr/lib64/python3.2/json/decoder.py\", line 351, in decode\n obj, end = self.raw_decode(s, idx=_w(s, 0).end())\nTypeError: expected string or buffer\n```\n",
"Looks like you need the `chardet` dependency installed.\n",
"This pull request [passes](http://travis-ci.org/kennethreitz/requests/builds/1223031) (merged 11a3eaec into a189c238).\n",
"\\o/\n",
"Any thoughts on the expected behavior question?\n\nhttps://github.com/kennethreitz/requests/pull/565#issuecomment-5327172\n",
"Wow, this is a really fantastic implementation. Thanks for the fantastic work!\n",
"Extremely fantastic work.\n",
"https://gist.github.com/2488388#gistcomment-294773\n",
"Thanks! The core implementation is all @dhagrow's, I just rearranged stuff and made the tests green :-)\n",
"@dhagrow and @slingamn are my heroes.\n\n:sparkles: :cake: :sparkles:\n"
] |
https://api.github.com/repos/psf/requests/issues/564
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/564/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/564/comments
|
https://api.github.com/repos/psf/requests/issues/564/events
|
https://github.com/psf/requests/pull/564
| 4,262,296 |
MDExOlB1bGxSZXF1ZXN0MTIyMzAxNw==
| 564 |
Fix the ordered list formatting that I screwed up with my last pull request :-(
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/305268?v=4",
"events_url": "https://api.github.com/users/msabramo/events{/privacy}",
"followers_url": "https://api.github.com/users/msabramo/followers",
"following_url": "https://api.github.com/users/msabramo/following{/other_user}",
"gists_url": "https://api.github.com/users/msabramo/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/msabramo",
"id": 305268,
"login": "msabramo",
"node_id": "MDQ6VXNlcjMwNTI2OA==",
"organizations_url": "https://api.github.com/users/msabramo/orgs",
"received_events_url": "https://api.github.com/users/msabramo/received_events",
"repos_url": "https://api.github.com/users/msabramo/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/msabramo/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/msabramo/subscriptions",
"type": "User",
"url": "https://api.github.com/users/msabramo",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 1 |
2012-04-24T15:44:03Z
|
2021-09-08T15:01:00Z
|
2012-04-24T15:44:47Z
|
CONTRIBUTOR
|
resolved
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/119893?v=4",
"events_url": "https://api.github.com/users/kennethreitz/events{/privacy}",
"followers_url": "https://api.github.com/users/kennethreitz/followers",
"following_url": "https://api.github.com/users/kennethreitz/following{/other_user}",
"gists_url": "https://api.github.com/users/kennethreitz/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/kennethreitz",
"id": 119893,
"login": "kennethreitz",
"node_id": "MDQ6VXNlcjExOTg5Mw==",
"organizations_url": "https://api.github.com/users/kennethreitz/orgs",
"received_events_url": "https://api.github.com/users/kennethreitz/received_events",
"repos_url": "https://api.github.com/users/kennethreitz/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/kennethreitz/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/kennethreitz/subscriptions",
"type": "User",
"url": "https://api.github.com/users/kennethreitz",
"user_view_type": "public"
}
|
{
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/564/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/564/timeline
| null | null | false |
{
"diff_url": "https://github.com/psf/requests/pull/564.diff",
"html_url": "https://github.com/psf/requests/pull/564",
"merged_at": "2012-04-24T15:44:47Z",
"patch_url": "https://github.com/psf/requests/pull/564.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/564"
}
| true |
[
":cake:\n"
] |
|
https://api.github.com/repos/psf/requests/issues/563
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/563/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/563/comments
|
https://api.github.com/repos/psf/requests/issues/563/events
|
https://github.com/psf/requests/pull/563
| 4,262,142 |
MDExOlB1bGxSZXF1ZXN0MTIyMjk0Ng==
| 563 |
Add a few links and minor tweaks to README.rst
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/305268?v=4",
"events_url": "https://api.github.com/users/msabramo/events{/privacy}",
"followers_url": "https://api.github.com/users/msabramo/followers",
"following_url": "https://api.github.com/users/msabramo/following{/other_user}",
"gists_url": "https://api.github.com/users/msabramo/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/msabramo",
"id": 305268,
"login": "msabramo",
"node_id": "MDQ6VXNlcjMwNTI2OA==",
"organizations_url": "https://api.github.com/users/msabramo/orgs",
"received_events_url": "https://api.github.com/users/msabramo/received_events",
"repos_url": "https://api.github.com/users/msabramo/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/msabramo/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/msabramo/subscriptions",
"type": "User",
"url": "https://api.github.com/users/msabramo",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 1 |
2012-04-24T15:37:17Z
|
2021-09-08T23:06:10Z
|
2012-04-24T15:38:05Z
|
CONTRIBUTOR
|
resolved
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/119893?v=4",
"events_url": "https://api.github.com/users/kennethreitz/events{/privacy}",
"followers_url": "https://api.github.com/users/kennethreitz/followers",
"following_url": "https://api.github.com/users/kennethreitz/following{/other_user}",
"gists_url": "https://api.github.com/users/kennethreitz/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/kennethreitz",
"id": 119893,
"login": "kennethreitz",
"node_id": "MDQ6VXNlcjExOTg5Mw==",
"organizations_url": "https://api.github.com/users/kennethreitz/orgs",
"received_events_url": "https://api.github.com/users/kennethreitz/received_events",
"repos_url": "https://api.github.com/users/kennethreitz/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/kennethreitz/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/kennethreitz/subscriptions",
"type": "User",
"url": "https://api.github.com/users/kennethreitz",
"user_view_type": "public"
}
|
{
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/563/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/563/timeline
| null | null | false |
{
"diff_url": "https://github.com/psf/requests/pull/563.diff",
"html_url": "https://github.com/psf/requests/pull/563",
"merged_at": "2012-04-24T15:38:05Z",
"patch_url": "https://github.com/psf/requests/pull/563.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/563"
}
| true |
[
"Thanks!\n"
] |
|
https://api.github.com/repos/psf/requests/issues/562
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/562/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/562/comments
|
https://api.github.com/repos/psf/requests/issues/562/events
|
https://github.com/psf/requests/pull/562
| 4,256,066 |
MDExOlB1bGxSZXF1ZXN0MTIyMDMzMg==
| 562 |
replace utils.randombytes with os.urandom
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/376448?v=4",
"events_url": "https://api.github.com/users/slingamn/events{/privacy}",
"followers_url": "https://api.github.com/users/slingamn/followers",
"following_url": "https://api.github.com/users/slingamn/following{/other_user}",
"gists_url": "https://api.github.com/users/slingamn/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/slingamn",
"id": 376448,
"login": "slingamn",
"node_id": "MDQ6VXNlcjM3NjQ0OA==",
"organizations_url": "https://api.github.com/users/slingamn/orgs",
"received_events_url": "https://api.github.com/users/slingamn/received_events",
"repos_url": "https://api.github.com/users/slingamn/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/slingamn/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/slingamn/subscriptions",
"type": "User",
"url": "https://api.github.com/users/slingamn",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 7 |
2012-04-24T09:06:04Z
|
2021-09-08T15:00:59Z
|
2012-05-16T05:49:27Z
|
CONTRIBUTOR
|
resolved
|
My understanding is that Python's `random` module is not recommended for cryptographic use. `os.urandom` should provide random bytes on all major platforms: Linux, OS X, *nix, and Windows:
http://docs.python.org/library/os.html#os.urandom
http://docs.python.org/release/3.0.1/library/os.html#os.urandom
Since the function provides a `str` under 2.x and a `bytes` under 3.x, and the result is fed directly into SHA, there shouldn't be an issue with the encoding.
Thoughts? Thanks for your time.
|
{
"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/562/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/562/timeline
| null | null | false |
{
"diff_url": "https://github.com/psf/requests/pull/562.diff",
"html_url": "https://github.com/psf/requests/pull/562",
"merged_at": "2012-05-16T05:49:27Z",
"patch_url": "https://github.com/psf/requests/pull/562.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/562"
}
| true |
[
"This pull request [fails](http://travis-ci.org/kennethreitz/requests/builds/1217425) (merged f1b054e4 into 2159c802).\n",
"I'll stick with it the way it is _for now_ because that's the same behavior the stdlib uses\n",
"Thanks though :)\n",
"I see this in my version of urllib2:\n\n``` python\ndef randombytes(n):\n \"\"\"Return n random bytes.\"\"\"\n # Use /dev/urandom if it is available. Fall back to random module\n # if not. It might be worthwhile to extend this function to use\n # other platform-specific mechanisms for getting random bytes.\n if os.path.exists(\"/dev/urandom\"):\n f = open(\"/dev/urandom\")\n s = f.read(n)\n f.close()\n return s\n else:\n L = [chr(random.randrange(0, 256)) for i in range(n)]\n return \"\".join(L)\n```\n\nso it's preferring the secure randomness functionality to the `random` library --- I guess they thought it preferable to fall back to `random` rather than choke.\n",
"I guess this does leave one question --- why doesn't Windows use `os.urandom` (backed by their own `/dev/urandom` analogue) instead of `random`? But still, `os.urandom` seems closer to the stdlib behavior.\n",
"This pull request [passes](http://travis-ci.org/kennethreitz/requests/builds/1342925) (merged f25827c5 into 6a9d59ea).\n",
"Awesome, thanks so much ;)\n"
] |
https://api.github.com/repos/psf/requests/issues/561
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/561/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/561/comments
|
https://api.github.com/repos/psf/requests/issues/561/events
|
https://github.com/psf/requests/pull/561
| 4,237,429 |
MDExOlB1bGxSZXF1ZXN0MTIxMjU3OQ==
| 561 |
Fix decoding of invalid %encodings in URLs (Python 3.x compatible)
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/1553?v=4",
"events_url": "https://api.github.com/users/Jonty/events{/privacy}",
"followers_url": "https://api.github.com/users/Jonty/followers",
"following_url": "https://api.github.com/users/Jonty/following{/other_user}",
"gists_url": "https://api.github.com/users/Jonty/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Jonty",
"id": 1553,
"login": "Jonty",
"node_id": "MDQ6VXNlcjE1NTM=",
"organizations_url": "https://api.github.com/users/Jonty/orgs",
"received_events_url": "https://api.github.com/users/Jonty/received_events",
"repos_url": "https://api.github.com/users/Jonty/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Jonty/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Jonty/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Jonty",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 1 |
2012-04-23T09:55:39Z
|
2021-09-08T23:11:02Z
|
2012-04-23T13:26:02Z
|
CONTRIBUTOR
|
resolved
|
An updated version of https://github.com/kennethreitz/requests/pull/535 with Python 3.x compatibility.
|
{
"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/561/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/561/timeline
| null | null | false |
{
"diff_url": "https://github.com/psf/requests/pull/561.diff",
"html_url": "https://github.com/psf/requests/pull/561",
"merged_at": "2012-04-23T13:26:02Z",
"patch_url": "https://github.com/psf/requests/pull/561.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/561"
}
| true |
[
"Thanks!\n"
] |
https://api.github.com/repos/psf/requests/issues/560
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/560/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/560/comments
|
https://api.github.com/repos/psf/requests/issues/560/events
|
https://github.com/psf/requests/issues/560
| 4,227,818 |
MDU6SXNzdWU0MjI3ODE4
| 560 |
Redefine order of pre_request hook and auth execution
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/22723?v=4",
"events_url": "https://api.github.com/users/idan/events{/privacy}",
"followers_url": "https://api.github.com/users/idan/followers",
"following_url": "https://api.github.com/users/idan/following{/other_user}",
"gists_url": "https://api.github.com/users/idan/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/idan",
"id": 22723,
"login": "idan",
"node_id": "MDQ6VXNlcjIyNzIz",
"organizations_url": "https://api.github.com/users/idan/orgs",
"received_events_url": "https://api.github.com/users/idan/received_events",
"repos_url": "https://api.github.com/users/idan/repos",
"site_admin": true,
"starred_url": "https://api.github.com/users/idan/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/idan/subscriptions",
"type": "User",
"url": "https://api.github.com/users/idan",
"user_view_type": "public"
}
|
[
{
"color": "02e10c",
"default": false,
"description": null,
"id": 76800,
"name": "Feature Request",
"node_id": "MDU6TGFiZWw3NjgwMA==",
"url": "https://api.github.com/repos/psf/requests/labels/Feature%20Request"
}
] |
closed
| true | null |
[] | null | 0 |
2012-04-22T06:37:13Z
|
2021-09-09T08:00:47Z
|
2012-05-08T05:09:31Z
|
CONTRIBUTOR
|
resolved
|
## Background
Auth callables, in their current incarnation, run much in the same fashion as a hook—they get the request at some point after it is asked to execute itself, and may mutate it. Currently, auth callables run before the pre_request hook.
The problem with this arises with auth schemes that expect the request's information to be immutable, like OAuth, because they are signing data in the request. If the pre_request hook comes along and changes a header, the signature would no longer be valid.
I'm suggesting that we swap the order of auth and pre_request: auth would run later in the cycle, directly after pre_request.
## Impact
Existing pre-request hooks which rely on the request content not changing after they run would suffer the same problems as the OAuth callable scenario described above. We'd need to document the fact that pre-request hooks do not have a guarantee of immutability if used together with some kinds of auth callables.
I don't think this is a big deal to change, but wanted to hear if anybody had some case I hadn't thought of.
### Edit
Worth noting that a potential solution here is simply to document that Auth callables are the ones with no guarantees. This would allow us to leave auth callables in their current location.
|
{
"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/560/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/560/timeline
| null |
completed
| null | null | false |
[] |
https://api.github.com/repos/psf/requests/issues/559
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/559/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/559/comments
|
https://api.github.com/repos/psf/requests/issues/559/events
|
https://github.com/psf/requests/pull/559
| 4,220,932 |
MDExOlB1bGxSZXF1ZXN0MTIwNzQ4MA==
| 559 |
Issue #526
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/503436?v=4",
"events_url": "https://api.github.com/users/barberj/events{/privacy}",
"followers_url": "https://api.github.com/users/barberj/followers",
"following_url": "https://api.github.com/users/barberj/following{/other_user}",
"gists_url": "https://api.github.com/users/barberj/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/barberj",
"id": 503436,
"login": "barberj",
"node_id": "MDQ6VXNlcjUwMzQzNg==",
"organizations_url": "https://api.github.com/users/barberj/orgs",
"received_events_url": "https://api.github.com/users/barberj/received_events",
"repos_url": "https://api.github.com/users/barberj/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/barberj/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/barberj/subscriptions",
"type": "User",
"url": "https://api.github.com/users/barberj",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 24 |
2012-04-21T02:21:36Z
|
2021-09-08T23:06:24Z
|
2012-05-08T04:58:18Z
|
CONTRIBUTOR
|
resolved
|
Added test and updated _encode_files.
Had me really confused there for a moment with the bytes = str, str = unicode.... I haven't gotten a py3 environment up yet. I really need to, I know. Passes all tests in py2.
|
{
"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/559/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/559/timeline
| null | null | false |
{
"diff_url": "https://github.com/psf/requests/pull/559.diff",
"html_url": "https://github.com/psf/requests/pull/559",
"merged_at": "2012-05-08T04:58:20Z",
"patch_url": "https://github.com/psf/requests/pull/559.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/559"
}
| true |
[
"Hows it look?\n",
"Hmm, is there a way to kick Travis for arbitrary branches?\n\n@travisbot kick\n",
"did i do something wrong? should i pull request off a local branch named develop?\n",
"Oh, no, you didn't do anything wrong. I was just curious if I could get Travis to run tests on your branch by talking to it.\n\n+1 for this change :-)\n",
"@barberj there is some (likely trivial) merge conflict now; can you update? Sorry.\n",
"@slingamn done\n",
"@barberj hey sorry, it looks like the merge is messed up; upstream changes since your branch are showing as part of your branch.\n\nCan you try this?\n\n```\ngit branch backup_branch 56f968f4e\ngit reset --hard 56f968f4e\ngit fetch --all\ngit rebase parent/develop\n```\n",
"@slingamn its not letting me push...\n! [rejected] issue_526 -> issue_526 (non-fast-forward)\n",
"Ah, you need `push -f`. Do `git branch backup_merge_branch db11bee` to save a backup of the ref you'll be overwriting.\n",
"@slingamn looks like that did it. thanks\n",
"Hmm, I don't think it worked; if it had worked, this pull request would show as updated.\n\nJust for kicks, I rebased your branch in my fork. Try this:\n\n```\ngit fetch https://[email protected]/slingamn/requests.git +issue_526_rebased\ngit reset --hard FETCH_HEAD\ngit push -f origin issue_526\n```\n",
"It worked. commit 8667efd it shows import cookielib, instead of SimpleCookie which was part of the conflict. I pushed up my backup_branch if you want to verify requests/models.py (84c4bd4142ae5711fef5c02db11da11bee0414ef) to see that import...\n",
"Oh, yeah, you're right. Unfortunately, the rebase is against an old version of `develop` and is still conflicting against the current version. (The conflict is trivial, in `AUTHORS.rst`.)\n\nYou could try this.\n\n```\ngit checkout develop\ngit fetch git://github.com/kennethreitz/requests.git +develop\ngit reset --hard FETCH_HEAD\ngit checkout issue_526\ngit rebase develop\n```\n\nI have my `develop` branch set up to track the `develop` branch of `kennethreitz/requests`, rather than `slingamn/requests`, which avoids this problem at the cost of being counterintuitive / confusing.\n",
"This pull request [fails](http://travis-ci.org/kennethreitz/requests/builds/1261579) (merged e912a6f5 into 7b6338c4).\n",
"did it, but says everything is up to date \n",
"Travis (http://travis-ci.org/#!/kennethreitz/requests/jobs/1261582) is complaining about this Python 3 issue:\n\n```\n[shivaram@good-fortune ~/workspace/requests/tests]$ python3 ./test_requests.py \n File \"./test_requests.py\", line 347\n post4 = post(url, files={'fname.txt': u'fdata'})\n```\n",
"er\n\n```\n[shivaram@good-fortune ~/workspace/requests/tests]$ python3 ./test_requests.py \n File \"./test_requests.py\", line 347\n post4 = post(url, files={'fname.txt': u'fdata'})\n ^\nSyntaxError: invalid syntax\n```\n",
"(But your merge is now up-to-date --- awesome. Sorry about all the headaches.)\n",
"This pull request [passes](http://travis-ci.org/kennethreitz/requests/builds/1261634) (merged 64eb415e into 7b6338c4).\n",
"+1 for merging this patch, looks great.\n\nFor extra cake, could you assert in one of the unit tests that httpbin actually does see the correct file data (as in your documentation change)?\n\nBut I like this patch either way, nice work :-)\n",
"This pull request [passes](http://travis-ci.org/kennethreitz/requests/builds/1261761) (merged b0669027 into 7b6338c4).\n",
"@slingamn good call. obvious test case that i missed... mmm cake.\n",
"@kennethreitz want to merge this? Looks correct, is tested, Travis likes it, it closes #526.\n",
"Beautiful, thanks!\n"
] |
https://api.github.com/repos/psf/requests/issues/558
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/558/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/558/comments
|
https://api.github.com/repos/psf/requests/issues/558/events
|
https://github.com/psf/requests/issues/558
| 4,202,464 |
MDU6SXNzdWU0MjAyNDY0
| 558 |
Remove chardet from dependencies
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/120601?v=4",
"events_url": "https://api.github.com/users/stevvooe/events{/privacy}",
"followers_url": "https://api.github.com/users/stevvooe/followers",
"following_url": "https://api.github.com/users/stevvooe/following{/other_user}",
"gists_url": "https://api.github.com/users/stevvooe/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/stevvooe",
"id": 120601,
"login": "stevvooe",
"node_id": "MDQ6VXNlcjEyMDYwMQ==",
"organizations_url": "https://api.github.com/users/stevvooe/orgs",
"received_events_url": "https://api.github.com/users/stevvooe/received_events",
"repos_url": "https://api.github.com/users/stevvooe/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/stevvooe/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/stevvooe/subscriptions",
"type": "User",
"url": "https://api.github.com/users/stevvooe",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 11 |
2012-04-19T23:13:37Z
|
2021-09-09T09:00:36Z
|
2012-04-20T03:39:02Z
|
NONE
|
resolved
|
Chardet is LGPL, which is unfortunate to have installed when using an ISC licensed library.
|
{
"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/558/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/558/timeline
| null |
completed
| null | null | false |
[
"It is indeed a shame, but it's the only available module that works. \n\nLuckily, Requests works fine without it. You just don't get character ecoding guessing.\n",
"Yes, it is conditionally imported, but it gets installed when installing requests via pip. Is it possible to remove it from the setup.py?\n",
"Unfortunately, no. Requests is not bound by the terms of the LGPL.\n",
"I understand that Requests is not, but by requiring chardet on installation, it effectively is. If its not required and conditionally imported, why can chardet not be removed from the setup.py?\n\nAlternatively, is there a way to black list modules in requirements.txt files?\n",
"It effectively is not.\n",
"Ok, thank you.\n",
"Not trying to be short, sorry :) \n\nIt's a pain point for me at the moment. I've definitely put a lot of thought into it though.\n",
"No worries. I understand the issue.\n",
"I don't even see how LGPL could be an issue for a library. It does not restrict software linking to it.\n",
"@laurentb exactly.\n",
"While I personally with this interpretation of the LGPL agree with you, others do not.\n\nAs always, thanks for your time.\n"
] |
https://api.github.com/repos/psf/requests/issues/557
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/557/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/557/comments
|
https://api.github.com/repos/psf/requests/issues/557/events
|
https://github.com/psf/requests/issues/557
| 4,199,296 |
MDU6SXNzdWU0MTk5Mjk2
| 557 |
Seeing SSLError: [Errno 185090050] _ssl.c:340: error:0B084002:x509 certificate routines:X509_load_cert_crl_file:system lib
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/519545?v=4",
"events_url": "https://api.github.com/users/stantonk/events{/privacy}",
"followers_url": "https://api.github.com/users/stantonk/followers",
"following_url": "https://api.github.com/users/stantonk/following{/other_user}",
"gists_url": "https://api.github.com/users/stantonk/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/stantonk",
"id": 519545,
"login": "stantonk",
"node_id": "MDQ6VXNlcjUxOTU0NQ==",
"organizations_url": "https://api.github.com/users/stantonk/orgs",
"received_events_url": "https://api.github.com/users/stantonk/received_events",
"repos_url": "https://api.github.com/users/stantonk/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/stantonk/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/stantonk/subscriptions",
"type": "User",
"url": "https://api.github.com/users/stantonk",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 34 |
2012-04-19T20:18:29Z
|
2014-10-15T08:10:17Z
|
2013-01-26T18:10:25Z
|
NONE
| null |
In our logs, I noticed this error when using requests to perform a POST to Facebook's Graph API using HTTPS:
```
File "/home/api/api/lib/python2.7/site-packages/requests/api.py", line 85, in post
return request('post', url, data=data, **kwargs)
File "/home/api/api/lib/python2.7/site-packages/requests/api.py", line 40, in request
return s.request(method=method, url=url, **kwargs)
File "/home/api/api/lib/python2.7/site-packages/requests/sessions.py", line 208, in request
r.send(prefetch=prefetch)
File "/home/api/api/lib/python2.7/site-packages/requests/models.py", line 584, in send
raise SSLError(e)
SSLError: [Errno 185090050] _ssl.c:340: error:0B084002:x509 certificate routines:X509_load_cert_crl_file:system lib
```
This is the first time I've seen it... could it be at all related to the cacerts file included in one of the dependencies of requests?
Is it related to this at all? https://github.com/kennethreitz/requests/issues/30
|
{
"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/557/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/557/timeline
| null |
completed
| null | null | false |
[
"Do you have `certifi` installed?\n",
"Yessir. I just double checked on all our servers and ran `pip freeze` in each of our virtualenvs:\n\n... snip ...\ncertifi==0.0.8\nchardet==1.0.1\nhttplib2==0.7.2\nrequests==0.11.1\n... snip ...\n",
"Hmm, can you do this?\n\n``` python\nimport cerifi\nprint certifi.where()\n```\n\nAnd then make sure that file is readable?\n",
"I checked on all our servers:\n\n> > > import certifi\n> > > print certifi.where()\n> > > ..snip../lib/python2.7/site-packages/certifi/cacert.pem\n\n$ ll ../lib/python2.7/site-packages/certifi/cacert.pem\n-rw-rw-r-- 1 ..snip.. Apr 19 18:29 ..snip../lib/python2.7/site-packages/certifi/cacert.pem\n",
"There shouldn't be a problem then :)\n",
"Is this when making _any_ HTTPS request?\n",
"Sorry, I thought I mentioned earlier, this is the first time I've ever seen the issue in the logs, and we're doing an awful lot of https requests, so maybe it's just an anomaly, some malformed packet or something...maybe a neutrino ;-)\n",
"Letcha know if I see this more...\n",
"I am seeing this same error\n\nSSLError: [Errno 185090050] _ssl.c:340: error:0B084002:x509 certificate routines:X509_load_cert_crl_file:system lib\n",
"Clarification, For me error is only happening when program is packaged by pyinstaller\n",
"I'm having the same problem. I'm using ActivePython and Windows 7 64 bit:\n\nrequests.exceptions.SSLError: [Errno 185090050] _ssl.c:340: error:0B084002:x509\ncertificate routines:X509_load_cert_crl_file:system lib\n\nProgram:\n\nimport requests\nr = requests.get('https://github.com/timeline.json')\nprint r\n\ni have all the packages mentioned in this thread and certifi.where() prints out \nC:\\Python27\\lib\\site-packages\\certifi\\cacert.pem\nFile exists and is readable. \n\nAny ideas ?\n",
"@gkappel: \nI also faced a similar error when using pyinstaller with Httplib2.\nYou need to explicitly pass the path to ssl client cert file to the 'cert' argument http request. Also, you would need to package your. .pem file as a data file in pyinstaller.\n\nHope it helps!\n",
"@sahilgupta \n\nThat works! Thanks a lot.\n",
"@sahilgupta Could you elaborate on how you fixed this? I'm having this problem as well and it would be great to know your solution.\n",
"I did something like this:\n\n``` python\nimport certifi\nprint certifi.where()\n..snip../lib/python2.7/site-packages/certifi/cacert.pem\n```\n\nto get a cert file and then copied it to somewhere in my python project directory.\n\n``` python\nh = httplib2.Http(ca_certs= '/this/new/path/to/cacert.pem')\n```\n\nTo package this .pem file as a data file with pyinstaller, follow:\nhttp://stackoverflow.com/questions/7674790/bundling-data-files-with-pyinstaller-onefile\n\nI don't have the exact code lying around at the moment, so you might have to play a bit to get it working. I guess ideally we shouldn't need to do all this because httplib2 comes with a cert file of its own, but pyinstaller probably fails to pack this alongwith and hence the call fails from a binary compiled with pyinstaller.\n\nAnyways, hope this helps!\n",
"@sahilgupta Thanks for the help! I think I've figured out how to package the data file with PyInstaller, but I couldn't figure out how to pass that to requests to use, and I've already got enough code that uses requests that I'm not willing to switch to httplib2. For now, I've just disabled SSL verification.\n",
"@seanfisk Did some further digging. Specifying certificate is even easier in requests than with httplib2. Try something on the lines of :\n\n``` python\nos.environ['REQUESTS_CA_BUNDLE'] = '/path/to/cacert.pem'\n```\n\nand enable SSL verification.\nThis would force requests to use this certificate instead of the default one as per http://kennethreitz.com/major-progress-for-requests.html\n",
"@sahilgupta Thanks, that worked. It was actually a RTFM on my part. Checked the [SSL Verification section](http://docs.python-requests.org/en/latest/user/advanced/#ssl-cert-verification) in the requests documentation and it was right there, and now it works. I could swear I was passing the path to `verify` before, but it's working now, so who cares. Here's the code I used for future reference:\n\n``` python\n#!/usr/bin/env python\n# requests_ssl.py\n# main script\n\nimport requests\nimport os\nimport sys\n\n# stolen and adpated from <http://stackoverflow.com/questions/7674790/bundling-data-files-with-pyinstaller-onefile>\ndef resource_path(relative):\n return os.path.join(getattr(sys, '_MEIPASS', os.path.abspath(\".\")),\n relative)\n\ncert_path = resource_path('cacert.pem')\n# this would also work, but I'd rather not set unnecessary env vars\n# os.environ['REQUESTS_CA_BUNDLE'] = cert_path\nprint requests.get('https://www.google.com/', verify=cert_path).text\n```\n\n``` python\n# PyInstaller spec file\na = Analysis(\n ['requests_ssl.py'],\n pathex=['.'],\n hiddenimports=[],\n hookspath=None)\na.datas.append(('cacert.pem', 'cacert.pem', 'DATA'))\npyz = PYZ(a.pure)\nexe = EXE(\n pyz,\n a.scripts,\n a.binaries,\n a.zipfiles,\n a.datas,\n name=os.path.join('dist', 'requests_ssl'),\n debug=False,\n strip=None,\n upx=True,\n console=True)\n```\n\nThanks for your help!\n",
"Cool! Glad that you got it working :)\n",
"I had the same error on fedora based system and `pip install certifi` solved the issue.\nI had installed requests via pip before, but on that particular machine certifi was not installed automatically when pip install requests.\n\nVersions:\n\n```\nrequests==0.14.2\ncertifi==0.0.8\n```\n\nNote, that on debian squeeze or mac I didn't have this issue and I didn't need to install certifi by hand.\n",
"Which version of requests do you have installed and how did you install it? \n\n@viciu thanks for editing your comment with the versions.\n",
"This is unfortunate; Requests is now supposed to use the system certificate bundle `/etc/pki/tls/certs/ca-bundle.crt` on Fedora by default, without requiring certifi.\n",
"@slingamn is it possible @viciu doesn't have that path? Maybe some other package he's installed removed it/replaced it/moved it?\n",
"Yeah, that's possible. This can be tested by inspecting the following values:\n\n``` python\nimport requests.utils\n# this is the theoretical OS-packaged CA bundle, if available\nprint requests.utils.get_os_ca_bundle_path()\n# this is the path that is used in practice\nprint requests.utils.DEFAULT_CA_BUNDLE_PATH\n```\n",
"Actually, heh. Ever since c3ad7af06c5fdd603d4ac114cfa114a12a386d10, the OS bundle path is a no-op since a CA bundle (`requests/cacert.pem`) is versioned together with Requests.\n",
"@slingamn: Given #1065 (which was opened after a discussion on #1033), can we close this?\n",
"@Lukasa I'm for closing it. \n",
"Let's do it. We can always reopen it.\n",
"I see a similar problem while running bandersnatcher on Ubuntu 10.04 LTS\nbandersnatch==1.0dev\ncov-core==1.7\ncoverage==3.6\ndistribute==0.6.35\nmercurial==2.5.2\nmock==1.0.1\npy==1.4.13\npytest==2.3.4\npytest-cov==1.6\nrequests==1.1.0\nvirtualenv==1.6.1\nwsgiref==0.1.2\n\n2013-03-26 17:25:49,493 ERROR: Error syncing package: OpenCorePaste\nTraceback (most recent call last):\n File \"/srv/pypi/lib/python2.7/site-packages/bandersnatch-1.0dev-py2.7.egg/bandersnatch/package.py\", line 56, in sync\n self.sync_release_files()\n File \"/srv/pypi/lib/python2.7/site-packages/bandersnatch-1.0dev-py2.7.egg/bandersnatch/package.py\", line 74, in sync_release_files\n self.download_file(release_file['url'], release_file['md5_digest'])\n File \"/srv/pypi/lib/python2.7/site-packages/bandersnatch-1.0dev-py2.7.egg/bandersnatch/package.py\", line 137, in download_file\n r = requests.get(url, stream=True)\n File \"/srv/pypi/lib/python2.7/site-packages/requests-1.1.0-py2.7.egg/requests/api.py\", line 55, in get\n return request('get', url, *_kwargs)\n File \"/srv/pypi/lib/python2.7/site-packages/requests-1.1.0-py2.7.egg/requests/api.py\", line 44, in request\n return session.request(method=method, url=url, *_kwargs)\n File \"/srv/pypi/lib/python2.7/site-packages/requests-1.1.0-py2.7.egg/requests/sessions.py\", line 279, in request\n resp = self.send(prep, stream=stream, timeout=timeout, verify=verify, cert=cert, proxies=proxies)\n File \"/srv/pypi/lib/python2.7/site-packages/requests-1.1.0-py2.7.egg/requests/sessions.py\", line 374, in send\n r = adapter.send(request, **kwargs)\n File \"/srv/pypi/lib/python2.7/site-packages/requests-1.1.0-py2.7.egg/requests/adapters.py\", line 213, in send\n raise SSLError(e)\nSSLError: [Errno 185090050] _ssl.c:340: error:0B084002:x509 certificate routines:X509_load_cert_crl_file:system lib\n\nThe error happens with https downloads from PyPI.\n",
"I'm experiencing this when import from a zip file. Copy the `cacert.pem` to approot will solve it:\n\n```\nos.environ['REQUESTS_CA_BUNDLE'] = os.path.join(app_root, 'cacert.pem')\n```\n\nI have not set up a clean env to reproduce it, but I have tested it in my app and narrow down it to be zip related.\n\nFYI, the zip file way is how my cloud-host suggested to upload virtualenv packages. It's like:\n\n```\n# bundle_it.sh\ncp ./virtualenv.bundle/requests/cacert.pem ./cacert.pem\ncd virtualenv.bundle/\nzip -r ../virtualenv.bundle.zip .\n# index.wsgi\nsys.path.insert(0, os.path.join(app_root, 'virtualenv.bundle.zip'))\n```\n"
] |
https://api.github.com/repos/psf/requests/issues/556
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/556/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/556/comments
|
https://api.github.com/repos/psf/requests/issues/556/events
|
https://github.com/psf/requests/pull/556
| 4,186,347 |
MDExOlB1bGxSZXF1ZXN0MTE5MjMwOQ==
| 556 |
Proper test for str vs unicode when preparing data
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/22723?v=4",
"events_url": "https://api.github.com/users/idan/events{/privacy}",
"followers_url": "https://api.github.com/users/idan/followers",
"following_url": "https://api.github.com/users/idan/following{/other_user}",
"gists_url": "https://api.github.com/users/idan/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/idan",
"id": 22723,
"login": "idan",
"node_id": "MDQ6VXNlcjIyNzIz",
"organizations_url": "https://api.github.com/users/idan/orgs",
"received_events_url": "https://api.github.com/users/idan/received_events",
"repos_url": "https://api.github.com/users/idan/repos",
"site_admin": true,
"starred_url": "https://api.github.com/users/idan/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/idan/subscriptions",
"type": "User",
"url": "https://api.github.com/users/idan",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 6 |
2012-04-19T06:22:51Z
|
2021-09-08T15:00:59Z
|
2012-04-30T20:12:32Z
|
CONTRIBUTOR
|
resolved
|
In python 2.x, requests sets str = unicode in `requests/compat.py`. This causes
`isinstance(foo, str)` to return True even if foo is a unicode string.
Would appreciate review of this change because my understanding of how this impacts py3x compatibility is tenuous.
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/22723?v=4",
"events_url": "https://api.github.com/users/idan/events{/privacy}",
"followers_url": "https://api.github.com/users/idan/followers",
"following_url": "https://api.github.com/users/idan/following{/other_user}",
"gists_url": "https://api.github.com/users/idan/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/idan",
"id": 22723,
"login": "idan",
"node_id": "MDQ6VXNlcjIyNzIz",
"organizations_url": "https://api.github.com/users/idan/orgs",
"received_events_url": "https://api.github.com/users/idan/received_events",
"repos_url": "https://api.github.com/users/idan/repos",
"site_admin": true,
"starred_url": "https://api.github.com/users/idan/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/idan/subscriptions",
"type": "User",
"url": "https://api.github.com/users/idan",
"user_view_type": "public"
}
|
{
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/556/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/556/timeline
| null | null | false |
{
"diff_url": "https://github.com/psf/requests/pull/556.diff",
"html_url": "https://github.com/psf/requests/pull/556",
"merged_at": null,
"patch_url": "https://github.com/psf/requests/pull/556.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/556"
}
| true |
[
"I just pushed a change for issue 526. because of the compat (byte=str; str=unicode) i did a isinstance(x, byte) when i was checking for str. \n\nIs this wrong? Should i update to be consistent with your change?\n\nhttps://github.com/kennethreitz/requests/pull/559\n",
"@barberj I don't know—that's the point. I'm not sure what the correct approach is for py2 AND py3.\n",
"D'oh, accidentally included more commits in this than intended. Please don't merge the request, but discussion is desired.\n",
"@idangazit can you make this PR again?\n",
"This pull request [fails](http://travis-ci.org/kennethreitz/requests/builds/1213297) (merged 3857de64 into ef0bf79f).\n",
"Superseded by #569\n"
] |
https://api.github.com/repos/psf/requests/issues/555
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/555/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/555/comments
|
https://api.github.com/repos/psf/requests/issues/555/events
|
https://github.com/psf/requests/issues/555
| 4,184,133 |
MDU6SXNzdWU0MTg0MTMz
| 555 |
IronPython: LookupError: unknown encoding: idna
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/1376355?v=4",
"events_url": "https://api.github.com/users/bhadra/events{/privacy}",
"followers_url": "https://api.github.com/users/bhadra/followers",
"following_url": "https://api.github.com/users/bhadra/following{/other_user}",
"gists_url": "https://api.github.com/users/bhadra/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/bhadra",
"id": 1376355,
"login": "bhadra",
"node_id": "MDQ6VXNlcjEzNzYzNTU=",
"organizations_url": "https://api.github.com/users/bhadra/orgs",
"received_events_url": "https://api.github.com/users/bhadra/received_events",
"repos_url": "https://api.github.com/users/bhadra/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/bhadra/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/bhadra/subscriptions",
"type": "User",
"url": "https://api.github.com/users/bhadra",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 3 |
2012-04-19T01:11:54Z
|
2021-09-09T09:00:37Z
|
2012-04-20T03:40:06Z
|
NONE
|
resolved
|
C:\MyProjects\IronPython>ipy -X:FullFrames
IronPython 2.7.2.1 (2.7.0.40) on .NET 4.0.30319.239 (32-bit)
Type "help", "copyright", "credits" or "license" for more information.
> > > import requests
> > > r = requests.get('https://github.com/timeline.json')
> > > Traceback (most recent call last):
> > > File "C:MyProjects\IronPython\requests\api.py", line 52, in get
> > > File "C:MyProjects\IronPython\requests\sessions.py", line 208, in request
> > > File "C:MyProjects\IronPython\requests\models.py", line 349, in full_url
> > > File "<stdin>", line 1, in <module>
> > > File "C:\MyProjects\IronPython\requests\api.py", line 40, in request
> > > File "C:\MyProjects\IronPython\requests\models.py", line 424, in send
> > > LookupError: unknown encoding: idna
As expected, the same works fine with CPython 2.7.3. I am using requests-0.11.1.
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/119893?v=4",
"events_url": "https://api.github.com/users/kennethreitz/events{/privacy}",
"followers_url": "https://api.github.com/users/kennethreitz/followers",
"following_url": "https://api.github.com/users/kennethreitz/following{/other_user}",
"gists_url": "https://api.github.com/users/kennethreitz/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/kennethreitz",
"id": 119893,
"login": "kennethreitz",
"node_id": "MDQ6VXNlcjExOTg5Mw==",
"organizations_url": "https://api.github.com/users/kennethreitz/orgs",
"received_events_url": "https://api.github.com/users/kennethreitz/received_events",
"repos_url": "https://api.github.com/users/kennethreitz/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/kennethreitz/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/kennethreitz/subscriptions",
"type": "User",
"url": "https://api.github.com/users/kennethreitz",
"user_view_type": "public"
}
|
{
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/555/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/555/timeline
| null |
completed
| null | null | false |
[
"IronPython should really fix that ;)\n",
"@kennethreitz: Can you suggest a workaround?\n",
"No suggestions at this time. That encoding is pretty key to requests's functionality. I'd follow up here: \n\nhttp://ironpython.codeplex.com/workitem/4565\n"
] |
https://api.github.com/repos/psf/requests/issues/554
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/554/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/554/comments
|
https://api.github.com/repos/psf/requests/issues/554/events
|
https://github.com/psf/requests/pull/554
| 4,166,817 |
MDExOlB1bGxSZXF1ZXN0MTE4NDIwNw==
| 554 |
Breaks Py3k
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/73153?v=4",
"events_url": "https://api.github.com/users/bluemoon/events{/privacy}",
"followers_url": "https://api.github.com/users/bluemoon/followers",
"following_url": "https://api.github.com/users/bluemoon/following{/other_user}",
"gists_url": "https://api.github.com/users/bluemoon/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/bluemoon",
"id": 73153,
"login": "bluemoon",
"node_id": "MDQ6VXNlcjczMTUz",
"organizations_url": "https://api.github.com/users/bluemoon/orgs",
"received_events_url": "https://api.github.com/users/bluemoon/received_events",
"repos_url": "https://api.github.com/users/bluemoon/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/bluemoon/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/bluemoon/subscriptions",
"type": "User",
"url": "https://api.github.com/users/bluemoon",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 8 |
2012-04-18T06:09:24Z
|
2021-09-08T23:08:17Z
|
2012-04-23T02:36:19Z
|
NONE
|
resolved
|
The u before the string in the tests breaks py3k
|
{
"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/554/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/554/timeline
| null | null | false |
{
"diff_url": "https://github.com/psf/requests/pull/554.diff",
"html_url": "https://github.com/psf/requests/pull/554",
"merged_at": null,
"patch_url": "https://github.com/psf/requests/pull/554.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/554"
}
| true |
[
"I'll likely be moving to support only 3.3 soon, because of this.\n",
"This will leave next Ubuntu LTS users without python 3 support by default. Isn't it better to drop python 2.5 support (PSF already drops python 2.5 support) and use `from __future__ import unicode_literals` across the codebase?\n",
"I mean only official 2.6, 2.7, and 3.3 support. \n\nPython 2.5 support was dropped when support for 3.1 and 3.2 was added several months ago.\n",
"Did my understanding correct and you're going to leave u in codebase as-is and drop python 3.2 support because of this? What's wrong with official python 3.2 support using `from __future__ import unicode_literals` approach?\n",
"This is just a mean of adding a import, removing u's and adding b's when appropriate - not a big price for the most used python 3 version support :) I really don't care about 3.0 or 3.1 but 3.2 is mainstream and it is default python3 in a lot of distros. \n",
"It has nothing to do with the codebase, only the tests. \n\nI needed explicit unicode literals for my test suite. I tweeted my frustration. Armin made it happen :)\n",
"Still don't get what are the practical reasons tests can't be run under 3.2 but ok, no more drama as you say code works :)\n",
"@kmike essentially i need \"native\" strings (unicode in 3, bytes in 2) with the same literal, since these are integration tests, not unit tests. That's why I can't use just do `from __future_ import unicode_literals`.\n\nBut I also need explicit unicode strings and explicit bytecode strings.\n"
] |
https://api.github.com/repos/psf/requests/issues/553
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/553/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/553/comments
|
https://api.github.com/repos/psf/requests/issues/553/events
|
https://github.com/psf/requests/issues/553
| 4,165,952 |
MDU6SXNzdWU0MTY1OTUy
| 553 |
IronPython: import issue
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/1376355?v=4",
"events_url": "https://api.github.com/users/bhadra/events{/privacy}",
"followers_url": "https://api.github.com/users/bhadra/followers",
"following_url": "https://api.github.com/users/bhadra/following{/other_user}",
"gists_url": "https://api.github.com/users/bhadra/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/bhadra",
"id": 1376355,
"login": "bhadra",
"node_id": "MDQ6VXNlcjEzNzYzNTU=",
"organizations_url": "https://api.github.com/users/bhadra/orgs",
"received_events_url": "https://api.github.com/users/bhadra/received_events",
"repos_url": "https://api.github.com/users/bhadra/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/bhadra/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/bhadra/subscriptions",
"type": "User",
"url": "https://api.github.com/users/bhadra",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 9 |
2012-04-18T03:46:15Z
|
2021-09-09T09:00:34Z
|
2012-05-03T06:11:50Z
|
NONE
|
resolved
|
It will be great if requests is made compatible with IronPython. This is a pure python library. So it should be feasible.
|
{
"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/553/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/553/timeline
| null |
completed
| null | null | false |
[
"+1 for this, also for PyPy support.\n\nDoes requests not work out of the box in these environments right now? Are there any specific bugs?\n",
"requests does not work out of box in IronPython. \"import requests\" fails.\n",
"Do you have a traceback?\n",
"I actively test Requests against PyPy.\n\nThere's no reason IronPython should have any problems.\n",
"File requests\\packages\\urllib3\\packages\\six.py\", line 307, in exec_\nAttributeError: 'module' object has no attribute '_getframe'\n\nsys._getframe(1) is not supported in IronPython.2.7.2.1.\n",
"This is a bug with urllib3, not Requests.\n\nYou can file a bug [here](https://github.com/shazow/urllib3)\n",
" sys._getframe(1) is supported with the option -X:FullFrames. So import requests is now working with ipy -X:FullFrames.\n",
"_sigh_ :)\n",
"Closing for out of scope.\n"
] |
https://api.github.com/repos/psf/requests/issues/552
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/552/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/552/comments
|
https://api.github.com/repos/psf/requests/issues/552/events
|
https://github.com/psf/requests/pull/552
| 4,145,648 |
MDExOlB1bGxSZXF1ZXN0MTE3NTM4Mg==
| 552 |
attempt to use the OS's certificate bundle
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/376448?v=4",
"events_url": "https://api.github.com/users/slingamn/events{/privacy}",
"followers_url": "https://api.github.com/users/slingamn/followers",
"following_url": "https://api.github.com/users/slingamn/following{/other_user}",
"gists_url": "https://api.github.com/users/slingamn/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/slingamn",
"id": 376448,
"login": "slingamn",
"node_id": "MDQ6VXNlcjM3NjQ0OA==",
"organizations_url": "https://api.github.com/users/slingamn/orgs",
"received_events_url": "https://api.github.com/users/slingamn/received_events",
"repos_url": "https://api.github.com/users/slingamn/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/slingamn/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/slingamn/subscriptions",
"type": "User",
"url": "https://api.github.com/users/slingamn",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 18 |
2012-04-17T01:00:47Z
|
2021-09-08T23:01:15Z
|
2012-04-23T01:53:31Z
|
CONTRIBUTOR
|
resolved
|
I thought it might be a good idea to attempt to use the OS's certificate bundle on systems where one is available. I was thinking something like this:
1. It could be dangerous to install `certifi` and then forget about it, in case a CA in it is compromised (like with Diginotar).
2. Might be good not to depend on another package?
Anyway, thanks for your time.
I used github for the smoke test because, amusingly enough, httpbin's certificate didn't verify on my system (Fedora 16):
```
[shivaram@good-fortune ~]$ curl -v https://httpbin.org/get
* About to connect() to httpbin.org port 443 (#0)
* Trying 107.21.118.103... connected
* Connected to httpbin.org (107.21.118.103) port 443 (#0)
* Initializing NSS with certpath: sql:/etc/pki/nssdb
* CAfile: /etc/pki/tls/certs/ca-bundle.crt
CApath: none
* Peer's certificate issuer is not recognized: 'CN=RapidSSL CA,O="GeoTrust, Inc.",C=US'
* NSS error -8179
* Closing connection #0
* Peer certificate cannot be authenticated with given CA certificates
curl: (60) Peer certificate cannot be authenticated with given CA certificates
More details here: http://curl.haxx.se/docs/sslcerts.html
curl performs SSL certificate verification by default, using a "bundle"
of Certificate Authority (CA) public keys (CA certs). If the default
bundle file isn't adequate, you can specify an alternate file
using the --cacert option.
If this HTTPS server uses a certificate signed by a CA represented in
the bundle, the certificate verification probably failed due to a
problem with the certificate (it might be expired, or the name might
not match the domain name in the URL).
If you'd like to turn off curl's verification of the certificate, use
the -k (or --insecure) option.
```
|
{
"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/552/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/552/timeline
| null | null | false |
{
"diff_url": "https://github.com/psf/requests/pull/552.diff",
"html_url": "https://github.com/psf/requests/pull/552",
"merged_at": "2012-04-23T01:53:31Z",
"patch_url": "https://github.com/psf/requests/pull/552.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/552"
}
| true |
[
"This, or something similar, would be a great addition for our use too.\n\nWe have a few code bases at work that require some hoop jumping to work around system `requests` using system certs[1] and virtualenvs in `tox` runs attempting to use the certs in `certifi`.\n\nI [ended up](https://github.com/ask/python-github2/issues/68#issuecomment-3159947) adding something along the same lines to [github2](https://github.com/ask/python-github2/blob/master/github2/request.py#L41) to work around `httplib2` using bundled certs on some hosts, and it would be nice if I didn't need to worry about it when using `requests` ;)\n1. Debian and Gentoo patch system certs support in to their packages, possibly others too.\n",
"JNRowe: thanks! I added the FreeBSD path.\n",
"I wouldn't mind adding a utility function that makes it simple to use the system's CAs, but I definitely prefer to default to my own packaged CA bundle. It _deeply_ helps reduce unexpected behavior.\n",
"That's fair.\n\nWould you prefer a patch where a failure to import `certifi` results in an attempt to use the system CAs (but `certifi` is preferred when present)? That way, administrators and distributions can package `requests` without `certifi` and have it default to the system CAs.\n",
"That sounds awesome.\n",
"Cool, changed it to prefer the `certifi` bundle.\n\nTell me if you want me to squash the commits, or remove the unit test (or feel free to do that yourself).\n",
"This looks great!\n\n---\n\nLast things:\n\nIt'd be great if `DEFAULT_CA_BUNDLE_PATH` took into account the value of the `CURL_CA_BUNDLE` env var (this exists elsewhere in the code now (I think models.py))\n",
"Ah, yeah. Right now those environment variables (`REQUESTS_CA_BUNDLE` and `CURL_CA_BUNDLE`) get checked at runtime (i.e., verification time) in `models.py`.\n\nThe checks depend on `self.config` (the `TRUST_ENV` variable), though, so maybe they should remain there? Also, it's theoretically possible that someone might monkeypatch the environment variables at runtime and expect the behavior to change, as it does now.\n",
"Ah, great point. Agreed.\n",
"This is fantastic, thanks!\n\n:sparkles: :cake: :sparkles:\n",
"@kennethreitz, quick question. Do you consider `DEFAULT_CA_BUNDLE_PATH` part of the supported API now? I'm just wondering if I can call `assert` against it, and expect code to carry on working for the foreseeable future. Not asking for promises, just a nod ;)\n\nPerhaps, the One Blessed Method for disabling the `certifi` support should be stated in a packaging document? I'd be surprised if the changes here allowed packagers to use the package as-is, and a continuing variety of solutions is quite difficult to support for naïve `requests` users like me.\n",
"I'm not so sure about `DEFAULT_CA_BUNDLE_PATH` itself. I'll probably document using `get_os_ca_bundle_path`. \n",
"@JNRowe Yeah, it's tricky. Perhaps, as the administrator, you could `export REQUESTS_CA_BUNDLE` in `/etc/profile.d` or something similar? That would globally override local installations of `certifi`.\n\nWhat further changes do you think would be required for packaging?\n",
"_EDIT_: Oh wow, sorry guys. I didn't realise this comment was so long, it'll teach me to keep to the tiny textbox next time.\n\n> @JNRowe Yeah, it's tricky. Perhaps, as the administrator, you could `export REQUESTS_CA_BUNDLE` in `/etc/profile.d` or something similar? That would globally override local installations of `certifi`.\n\nGood idea, and it would work for managed desktop and server deployment.\n\nMy question was more concerned with a stable method for testing the environment we're running under on client systems. I guess if `requests.utils.get_os_ca_bundle_path()` is part of the stable API we could check that, `.startswith('/etc/')` is most of the way there for me.\n\nIt is far better than the current situation, needing a lot of code pasting to check for various changes. On Debian, the `where()` call is just replaced with `/etc/ssl/certs/ca-certificates.crt`. On Gentoo, `certifi` is installed with a symlink to the system certs, which necessitates a call to `os.path.realpath()`.\n\n> What further changes do you think would be required for packaging?\n\nWithout trying to be deliberately obtuse I'd say \"ask the packagers\". I may be totally wrong, the next round of distributor packages could accept this behaviour and ship vanilla packages. The only reason I doubt it is the automagic nature of the changes, the certs being chosen depending on whether another package is currently installed system-wide or available in `$PYTHONUSERBASE` or somewhere else seems a little off.\n\nDon't get me wrong, I think you and @kennethreitz came to the right conclusion for the common case. Most people simply don't care about this stuff that deeply, and the ones that do will patch the behaviour anyway. That is why I resigned myself to checking at runtime, and asked for a little confirmation on an acceptable way to do it.\n",
"@JNRowe Thanks, these are really good observations. I'll get in touch with the guy who maintains `requests` for Fedora and see if this change is sufficient for him to package `python-requests` with a dependency on `ca-certificates`.\n\nI understand now why you wanted to be able to test `DEFAULT_CA_BUNDLE_PATH`. I'd put in a tentative +1 for making this part of the API, but my understanding of how stable that would be is shaky at best :-)\n\nBy the way, do you know what the standard path to the CA certificates is on Gentoo, and the name of the package that provides them?\n",
"> By the way, do you know what the standard path to the CA certificates is on Gentoo, and the name of the package that provides them?\n\n`/etc/ssl/certs/ca-certificates.crt` provided by [app-misc/ca-certificates](http://sources.gentoo.org/cgi-bin/viewvc.cgi/gentoo-x86/app-misc/ca-certificates/). It is the Debian package, you even use the same `update-ca-certificates` tool when managing your certs database. If it wasn't for the differing approach to patching `requests` I could tell the difference between a system and `pip` installation with practically no effort, which is why I thought a blessed solution for forcing system certs in a `README.packagers` would be a good idea.\n\nWhile we're collecting other locations to test I'll add that [suse](http://rpmfind.net/linux/RPM/opensuse/12.1/noarch/ca-certificates-1-14.12.1.noarch.html) uses `/etc/ssl/ca-bundle.pem`. And that covers the only three Linux distributions I ever have to worry about :)\n",
"Fedora maintainer here, @slingamn this is a clean approach, i was lucky that people allowed me to package python-certifi, i would be happy to remove any dependency on certifi and default to system CA certs.\n",
"Looks like I _was_ wrong, the [Debian package](http://packages.debian.org/changelogs/pool/main/r/requests/requests_0.11.2-1/changelog) accepts this behaviour.\n"
] |
https://api.github.com/repos/psf/requests/issues/551
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/551/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/551/comments
|
https://api.github.com/repos/psf/requests/issues/551/events
|
https://github.com/psf/requests/issues/551
| 4,143,631 |
MDU6SXNzdWU0MTQzNjMx
| 551 |
Ability to interrupt / stop iter_content
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/1649850?v=4",
"events_url": "https://api.github.com/users/Polygraph/events{/privacy}",
"followers_url": "https://api.github.com/users/Polygraph/followers",
"following_url": "https://api.github.com/users/Polygraph/following{/other_user}",
"gists_url": "https://api.github.com/users/Polygraph/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Polygraph",
"id": 1649850,
"login": "Polygraph",
"node_id": "MDQ6VXNlcjE2NDk4NTA=",
"organizations_url": "https://api.github.com/users/Polygraph/orgs",
"received_events_url": "https://api.github.com/users/Polygraph/received_events",
"repos_url": "https://api.github.com/users/Polygraph/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Polygraph/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Polygraph/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Polygraph",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 2 |
2012-04-16T22:02:25Z
|
2021-09-09T08:00:47Z
|
2012-05-08T05:09:40Z
|
NONE
|
resolved
|
When using iter_content, in some instances it would be beneficial to have the ability to interrupt the request. If you take the Twitter streaming API as an example, there is no current way to exit cleanly as iter_content will continuously block. For example, in the following code:
```
for line in self.conn.req_content(self.ITER_BYTES):
self.status += line
if line.endswith(self.DIVIDER) and self.status.strip():
print self.status
self.status = ""
```
The only way to I can stop the stream connection is by either running it in a separate thread and joining or by manually setting the raw property of the request to None (and catch the AttributeError that subsequently gets thrown):
```
self.req.raw = None
```
I understand that currently only the Twitter streaming API makes this issue relevant but going forward I'm sure more streaming APIs will emerge and it'd be useful if there was a nicer way to unblock.
|
{
"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/551/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/551/timeline
| null |
completed
| null | null | false |
[
"Can't you just break out of the generator when you so desire?\n",
"Twitter will endeavour to always keep the connection open for as long as possible meaning if you are tracking a particularly low frequency predicate, it could potentially be hours before the request receives a response and you are able to break. \n"
] |
https://api.github.com/repos/psf/requests/issues/550
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/550/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/550/comments
|
https://api.github.com/repos/psf/requests/issues/550/events
|
https://github.com/psf/requests/pull/550
| 4,105,278 |
MDExOlB1bGxSZXF1ZXN0MTE2MDEzMA==
| 550 |
Fix issue #549. Add 'prefetch' to Session.__attrs__ and Requests.__init__
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/660112?v=4",
"events_url": "https://api.github.com/users/reclosedev/events{/privacy}",
"followers_url": "https://api.github.com/users/reclosedev/followers",
"following_url": "https://api.github.com/users/reclosedev/following{/other_user}",
"gists_url": "https://api.github.com/users/reclosedev/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/reclosedev",
"id": 660112,
"login": "reclosedev",
"node_id": "MDQ6VXNlcjY2MDExMg==",
"organizations_url": "https://api.github.com/users/reclosedev/orgs",
"received_events_url": "https://api.github.com/users/reclosedev/received_events",
"repos_url": "https://api.github.com/users/reclosedev/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/reclosedev/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/reclosedev/subscriptions",
"type": "User",
"url": "https://api.github.com/users/reclosedev",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 1 |
2012-04-13T15:33:16Z
|
2021-09-08T23:01:10Z
|
2012-04-14T10:19:10Z
|
CONTRIBUTOR
|
resolved
|
Possible fix for issue #549.
|
{
"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/550/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/550/timeline
| null | null | false |
{
"diff_url": "https://github.com/psf/requests/pull/550.diff",
"html_url": "https://github.com/psf/requests/pull/550",
"merged_at": "2012-04-14T10:19:10Z",
"patch_url": "https://github.com/psf/requests/pull/550.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/550"
}
| true |
[
"This is excellent (and long overdue), thanks!\n"
] |
https://api.github.com/repos/psf/requests/issues/549
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/549/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/549/comments
|
https://api.github.com/repos/psf/requests/issues/549/events
|
https://github.com/psf/requests/issues/549
| 4,090,389 |
MDU6SXNzdWU0MDkwMzg5
| 549 |
Session.prefetch not pickled and causing AttributeError on next request after unpickle
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/660112?v=4",
"events_url": "https://api.github.com/users/reclosedev/events{/privacy}",
"followers_url": "https://api.github.com/users/reclosedev/followers",
"following_url": "https://api.github.com/users/reclosedev/following{/other_user}",
"gists_url": "https://api.github.com/users/reclosedev/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/reclosedev",
"id": 660112,
"login": "reclosedev",
"node_id": "MDQ6VXNlcjY2MDExMg==",
"organizations_url": "https://api.github.com/users/reclosedev/orgs",
"received_events_url": "https://api.github.com/users/reclosedev/received_events",
"repos_url": "https://api.github.com/users/reclosedev/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/reclosedev/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/reclosedev/subscriptions",
"type": "User",
"url": "https://api.github.com/users/reclosedev",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 0 |
2012-04-12T19:36:50Z
|
2021-09-09T09:00:37Z
|
2012-04-14T10:19:10Z
|
CONTRIBUTOR
|
resolved
|
Code that reproduces the problem:
``` python
import pickle
import requests
url = 'http://httpbin.org/cookies'
session = requests.session()
session.get('%s/set/key1/value1' % url)
before_pickle = session.get(url).text
pickled_session = pickle.dumps(session)
session = pickle.loads(pickled_session)
# AttributeError: 'Session' object has no attribute 'prefetch'
after_pickle = session.get(url).text
assert before_pickle == after_pickle
```
Ways to solve:
1. Dirty one: dont' save `prefetch`, just replace [sessions.py#L158](https://github.com/kennethreitz/requests/blob/develop/requests/sessions.py#L158)
`prefetch = self.prefetch or prefetch`
to
`prefetch = getattr(self, 'prefetch', False) or prefetch`
2. Add prefetch to `Session.__attrs__`, [`args` at sessions.py#L169](https://github.com/kennethreitz/requests/blob/develop/requests/sessions.py#L169) and to `Request.__init__()`
3. Another one?
|
{
"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/549/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/549/timeline
| null |
completed
| null | null | false |
[] |
https://api.github.com/repos/psf/requests/issues/548
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/548/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/548/comments
|
https://api.github.com/repos/psf/requests/issues/548/events
|
https://github.com/psf/requests/pull/548
| 4,087,247 |
MDExOlB1bGxSZXF1ZXN0MTE1MjcyMQ==
| 548 |
A get with an invalid port should wrap urllib3's LocationParseError exception with our own.
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/285920?v=4",
"events_url": "https://api.github.com/users/umbrae/events{/privacy}",
"followers_url": "https://api.github.com/users/umbrae/followers",
"following_url": "https://api.github.com/users/umbrae/following{/other_user}",
"gists_url": "https://api.github.com/users/umbrae/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/umbrae",
"id": 285920,
"login": "umbrae",
"node_id": "MDQ6VXNlcjI4NTkyMA==",
"organizations_url": "https://api.github.com/users/umbrae/orgs",
"received_events_url": "https://api.github.com/users/umbrae/received_events",
"repos_url": "https://api.github.com/users/umbrae/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/umbrae/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/umbrae/subscriptions",
"type": "User",
"url": "https://api.github.com/users/umbrae",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 1 |
2012-04-12T16:39:18Z
|
2021-09-08T23:06:08Z
|
2012-04-12T19:44:45Z
|
CONTRIBUTOR
|
resolved
|
Fixes this issue:
``` python
>>> import requests
>>> requests.get('http://google.com:banana')
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/Users/umbrae/Envs/rdb/lib/python2.6/site-packages/requests/api.py", line 51, in get
return request('get', url, **kwargs)
[...snip...]
File "/Users/umbrae/Envs/rdb/lib/python2.6/site-packages/requests/packages/urllib3/connectionpool.py", line 579, in get_host
raise LocationParseError("Failed to parse: %s")
requests.packages.urllib3.exceptions.LocationParseError: (LocationParseError(...), 'Failed to parse: Failed to parse: %s')
```
To now return a wrapped exception, which hides the use of urllib3 and is more intuitive to catch:
``` python
>>> import requests
re>>> requests.get('http://google.com:banana')
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "requests/api.py", line 52, in get
return request('get', url, **kwargs)
File "requests/api.py", line 40, in request
return s.request(method=method, url=url, **kwargs)
File "requests/sessions.py", line 208, in request
r.send(prefetch=prefetch)
File "requests/models.py", line 506, in send
raise InvalidURL(e)
requests.exceptions.InvalidURL: (LocationParseError(...), 'Failed to parse: Failed to parse: google.com')
```
|
{
"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/548/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/548/timeline
| null | null | false |
{
"diff_url": "https://github.com/psf/requests/pull/548.diff",
"html_url": "https://github.com/psf/requests/pull/548",
"merged_at": "2012-04-12T19:44:45Z",
"patch_url": "https://github.com/psf/requests/pull/548.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/548"
}
| true |
[
"You're amazing: \n\n:cake:\n"
] |
https://api.github.com/repos/psf/requests/issues/547
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/547/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/547/comments
|
https://api.github.com/repos/psf/requests/issues/547/events
|
https://github.com/psf/requests/pull/547
| 4,084,946 |
MDExOlB1bGxSZXF1ZXN0MTE1MTcyMw==
| 547 |
Fix infinite loop on wrong Digest Authentication
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/221332?v=4",
"events_url": "https://api.github.com/users/catwell/events{/privacy}",
"followers_url": "https://api.github.com/users/catwell/followers",
"following_url": "https://api.github.com/users/catwell/following{/other_user}",
"gists_url": "https://api.github.com/users/catwell/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/catwell",
"id": 221332,
"login": "catwell",
"node_id": "MDQ6VXNlcjIyMTMzMg==",
"organizations_url": "https://api.github.com/users/catwell/orgs",
"received_events_url": "https://api.github.com/users/catwell/received_events",
"repos_url": "https://api.github.com/users/catwell/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/catwell/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/catwell/subscriptions",
"type": "User",
"url": "https://api.github.com/users/catwell",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 2 |
2012-04-12T14:38:37Z
|
2021-09-08T14:01:16Z
|
2012-04-13T06:34:45Z
|
CONTRIBUTOR
|
resolved
|
The most straightforward way to fix #541 seems to be to deregister the hook on the first 401. This is what I have implemented 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/547/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/547/timeline
| null | null | false |
{
"diff_url": "https://github.com/psf/requests/pull/547.diff",
"html_url": "https://github.com/psf/requests/pull/547",
"merged_at": "2012-04-13T06:34:45Z",
"patch_url": "https://github.com/psf/requests/pull/547.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/547"
}
| true |
[
"Hmm, the second commit is something different (I should have created a branch).\nIt fixes the conflict between Digest Auth and Multipart Post (#298).\n\nI am less convinced that my implementation is the right way to do it there, so take it as a suggestion (and motivation to fix a 4 months old bug hit by one of our clients :p).\n",
"This is fantastic. Thanks!\n\n:cake:\n"
] |
https://api.github.com/repos/psf/requests/issues/546
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/546/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/546/comments
|
https://api.github.com/repos/psf/requests/issues/546/events
|
https://github.com/psf/requests/issues/546
| 4,049,891 |
MDU6SXNzdWU0MDQ5ODkx
| 546 |
I think cookie_header should not use DOUBLE SPACE after ";"
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/1536813?v=4",
"events_url": "https://api.github.com/users/listeng/events{/privacy}",
"followers_url": "https://api.github.com/users/listeng/followers",
"following_url": "https://api.github.com/users/listeng/following{/other_user}",
"gists_url": "https://api.github.com/users/listeng/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/listeng",
"id": 1536813,
"login": "listeng",
"node_id": "MDQ6VXNlcjE1MzY4MTM=",
"organizations_url": "https://api.github.com/users/listeng/orgs",
"received_events_url": "https://api.github.com/users/listeng/received_events",
"repos_url": "https://api.github.com/users/listeng/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/listeng/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/listeng/subscriptions",
"type": "User",
"url": "https://api.github.com/users/listeng",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 2 |
2012-04-10T17:03:02Z
|
2021-09-09T09:00:35Z
|
2012-05-03T05:54:36Z
|
NONE
|
resolved
|
At line 550 in file models.py, I found the code like this:
... sep='; ' ...
There is one space character after semicolon character. so that the result of cookie string in the header like this:
airkey=; clientkey=; clientuin=; confirmuin=0;
There are two space characters after ";".
I checked IE and Firefox that are just generate one space character after ";".
And, some website can not recognize the formation of cookie which have two space characters as separator.
|
{
"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/546/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/546/timeline
| null |
completed
| null | null | false |
[
"This is fixed in master:\n\n```\n\n>>> import requests\n>>> c = requests.get('http://httpbin.org/cookies/set/key/value').cookies\n>>> c = requests.get('http://httpbin.org/cookies/set/key2/value2', cookies=c).cookies\n>>> print requests.get('http://httpbin.org/headers', cookies=c).text\n{\n \"headers\": {\n \"Content-Length\": \"\", \n \"Accept-Encoding\": \"identity, deflate, compress, gzip\", \n \"Connection\": \"keep-alive\", \n \"Accept\": \"*/*\", \n \"User-Agent\": \"python-requests/0.12.0\", \n \"Host\": \"httpbin.org\", \n \"Cookie\": \"key2=value2; key=value\", \n \"Content-Type\": \"\"\n }\n}\n```\n",
"<3\n"
] |
https://api.github.com/repos/psf/requests/issues/545
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/545/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/545/comments
|
https://api.github.com/repos/psf/requests/issues/545/events
|
https://github.com/psf/requests/pull/545
| 4,042,657 |
MDExOlB1bGxSZXF1ZXN0MTEzMzU0OA==
| 545 |
Add docs on sending lists for multivalued query params.
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/120119?v=4",
"events_url": "https://api.github.com/users/sharat87/events{/privacy}",
"followers_url": "https://api.github.com/users/sharat87/followers",
"following_url": "https://api.github.com/users/sharat87/following{/other_user}",
"gists_url": "https://api.github.com/users/sharat87/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/sharat87",
"id": 120119,
"login": "sharat87",
"node_id": "MDQ6VXNlcjEyMDExOQ==",
"organizations_url": "https://api.github.com/users/sharat87/orgs",
"received_events_url": "https://api.github.com/users/sharat87/received_events",
"repos_url": "https://api.github.com/users/sharat87/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/sharat87/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/sharat87/subscriptions",
"type": "User",
"url": "https://api.github.com/users/sharat87",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 1 |
2012-04-10T09:14:14Z
|
2021-09-08T14:01:16Z
|
2012-04-10T15:43:47Z
|
CONTRIBUTOR
|
resolved
|
The ability to send arrays in the values of query params doesn't seem to be documented anywhere. So, I added a small mention of it.
This was added in this change: https://github.com/kennethreitz/requests/commit/73b414ab4564486f2335f02a1727fd0f4d005608
|
{
"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/545/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/545/timeline
| null | null | false |
{
"diff_url": "https://github.com/psf/requests/pull/545.diff",
"html_url": "https://github.com/psf/requests/pull/545",
"merged_at": "2012-04-10T15:43:47Z",
"patch_url": "https://github.com/psf/requests/pull/545.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/545"
}
| true |
[
"Thanks!\n"
] |
https://api.github.com/repos/psf/requests/issues/544
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/544/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/544/comments
|
https://api.github.com/repos/psf/requests/issues/544/events
|
https://github.com/psf/requests/issues/544
| 4,042,508 |
MDU6SXNzdWU0MDQyNTA4
| 544 |
get() partial download
|
{
"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 |
2012-04-10T09:00:13Z
|
2021-09-09T08:00:47Z
|
2012-05-08T05:08:28Z
|
NONE
|
resolved
|
The command
resp = get(url, verify=False, prefetch=True, timeout=20)
does not read the whole content, i.e., len(resp.text) differs from the expected value.
The expected page size is in the range 50-60 KB, while len(resp.text) is about 8 KB.
I have tried get(url) as well, but I have not noticed any difference.
I have made some tests with other libraries (i.e., https://github.com/Lispython/human_curl or a Java client), and I get the expected behavior.
|
{
"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/544/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/544/timeline
| null |
completed
| null | null | false |
[
"`resp.text` is unicode, so measuring its length has little to do with its size :)\n"
] |
https://api.github.com/repos/psf/requests/issues/543
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/543/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/543/comments
|
https://api.github.com/repos/psf/requests/issues/543/events
|
https://github.com/psf/requests/issues/543
| 4,027,723 |
MDU6SXNzdWU0MDI3NzIz
| 543 |
Inclusion in the standard library.
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/72590?v=4",
"events_url": "https://api.github.com/users/TkTech/events{/privacy}",
"followers_url": "https://api.github.com/users/TkTech/followers",
"following_url": "https://api.github.com/users/TkTech/following{/other_user}",
"gists_url": "https://api.github.com/users/TkTech/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/TkTech",
"id": 72590,
"login": "TkTech",
"node_id": "MDQ6VXNlcjcyNTkw",
"organizations_url": "https://api.github.com/users/TkTech/orgs",
"received_events_url": "https://api.github.com/users/TkTech/received_events",
"repos_url": "https://api.github.com/users/TkTech/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/TkTech/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/TkTech/subscriptions",
"type": "User",
"url": "https://api.github.com/users/TkTech",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 6 |
2012-04-09T11:00:12Z
|
2021-09-09T08:00:36Z
|
2012-06-15T18:39:09Z
|
CONTRIBUTOR
|
resolved
|
Has any thought been put into proposing (via the guidelines of PEP2) `requests` as a standard module (please excuse me if I missed this discussion elsewhere. Hard to google for "python" and "requests" :)).
With full support for older versions of Python and Py3k, it seems like a good candidate. Interacting with HTTP is one of the biggest uses of Python and will likely to continue to become more important. `requests` is battle-tested, portable, extremely popular and actively developed. In this manner, it would be very similar to the inclusion of `simplejson` (as the `json` module) since 2.6.
|
{
"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/543/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/543/timeline
| null |
completed
| null | null | false |
[
"I've chatted with Guido about this, his advice was that we want to stay away from the standard library. Being included in the standard library requires a great deal of stability, and the process to introduce changes is slow. Requests is still rapidly improving and being included in the standard library will likely stunt its growth more than help.\n\nRegarding Googling for \"requests\", have a look at this thread: https://github.com/kennethreitz/requests/issues/538\n",
"Excellent point. I would think however that a stable release would be suitable for inclusion, with development continuing rapidly in parallel, much the same as pysqlite (the sqlite3 module) and simplejson (the json module). If only included in the standard library for 3.*, then there will be more opportunities to include an updated stable, and users will expect potentially breaking changes.\n\nJust my two cents. I trust Guido's input above my own :) Glad to see I'm not the only one who was having google-fu issues.\n",
"Now, when there's [PEP 411 - Provisional packages in the Python standard library](http://www.python.org/dev/peps/pep-0411/) we can eat this cake and have it too.\n\n> Other possible future use cases include:\n> - Improved HTTP modules (e.g. requests)\n",
"This literally appears to have been made with requests in mind (and is mentioned in the examples as an acceptable project). Input @shazow, if you don't mind?\n",
"I started a big thread in python-dev about making the Python standard docs more inclusive of third-party solutions: http://mail.python.org/pipermail/python-dev/2012-March/thread.html#117518\n\nLooks like this PEP was updated the same week, perhaps it took some of the feedback into account. Who knows, we'll see what happens. I personally don't have high hopes or desire to deal with the standard library at the moment, given the feedback from that thread. :)\n",
"Sorry for the lack of response here. I've given this extensive thought for this and I'm currently :-1: on it. \n\n---\n\nI briefly talk about it at the end of [this talk](http://www.leancrew.com/all-this/2012/04/where-modules-go-to-die/).\n"
] |
https://api.github.com/repos/psf/requests/issues/542
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/542/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/542/comments
|
https://api.github.com/repos/psf/requests/issues/542/events
|
https://github.com/psf/requests/pull/542
| 4,023,970 |
MDExOlB1bGxSZXF1ZXN0MTEyNTkyMg==
| 542 |
Attempting to address issue #377 by making content on the response model a little smarter
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/64894?v=4",
"events_url": "https://api.github.com/users/newmaniese/events{/privacy}",
"followers_url": "https://api.github.com/users/newmaniese/followers",
"following_url": "https://api.github.com/users/newmaniese/following{/other_user}",
"gists_url": "https://api.github.com/users/newmaniese/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/newmaniese",
"id": 64894,
"login": "newmaniese",
"node_id": "MDQ6VXNlcjY0ODk0",
"organizations_url": "https://api.github.com/users/newmaniese/orgs",
"received_events_url": "https://api.github.com/users/newmaniese/received_events",
"repos_url": "https://api.github.com/users/newmaniese/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/newmaniese/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/newmaniese/subscriptions",
"type": "User",
"url": "https://api.github.com/users/newmaniese",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 1 |
2012-04-08T22:51:34Z
|
2021-09-08T14:01:15Z
|
2012-04-09T03:13:38Z
|
CONTRIBUTOR
|
resolved
|
Calling the content attribute on a response that has no content causes an error after the second time. On async requests, prefetch is set to true by default so all calls to content from an async response cause an error.
My change does change the default value for _content. All tests pass and I added a new one to replicate the issue and ensure that it works with my patch.
|
{
"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/542/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/542/timeline
| null | null | false |
{
"diff_url": "https://github.com/psf/requests/pull/542.diff",
"html_url": "https://github.com/psf/requests/pull/542",
"merged_at": "2012-04-09T03:13:38Z",
"patch_url": "https://github.com/psf/requests/pull/542.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/542"
}
| true |
[
"This is a fantastic contribution. Thanks for the catch/fix!\n\nBonus cake for tests: :cake: \n"
] |
https://api.github.com/repos/psf/requests/issues/541
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/541/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/541/comments
|
https://api.github.com/repos/psf/requests/issues/541/events
|
https://github.com/psf/requests/issues/541
| 4,016,294 |
MDU6SXNzdWU0MDE2Mjk0
| 541 |
Digest Authentication wrong password bug
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/690429?v=4",
"events_url": "https://api.github.com/users/madsholden/events{/privacy}",
"followers_url": "https://api.github.com/users/madsholden/followers",
"following_url": "https://api.github.com/users/madsholden/following{/other_user}",
"gists_url": "https://api.github.com/users/madsholden/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/madsholden",
"id": 690429,
"login": "madsholden",
"node_id": "MDQ6VXNlcjY5MDQyOQ==",
"organizations_url": "https://api.github.com/users/madsholden/orgs",
"received_events_url": "https://api.github.com/users/madsholden/received_events",
"repos_url": "https://api.github.com/users/madsholden/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/madsholden/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/madsholden/subscriptions",
"type": "User",
"url": "https://api.github.com/users/madsholden",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 6 |
2012-04-07T16:30:09Z
|
2021-09-09T07:05:27Z
|
2012-07-27T05:57:19Z
|
NONE
|
resolved
|
When using digest authentication with a wrong password, requests will retry the request for infinity.
This code snippet will run forever:
```
import requests
from requests.auth import HTTPDigestAuth
requests.get('http://httpbin.org/digest-auth/auth/user/passwd', auth=HTTPDigestAuth('user', 'incorrect'))
```
|
{
"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/541/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/541/timeline
| null |
completed
| null | null | false |
[
"Gah, I forgot about this bug. \n",
"Closeable, right?\n",
"@slingamn you're a machine\n",
"FWIW, I am still seeing this bug on 0.13.0. Stack dump below:\n\n```\n>>> import requests\n>>> from requests.auth import HTTPDigestAuth\n>>> url = 'http://REDACTED'\n>>> auth = HTTPDigestAuth('foo', 'bar')\n>>> r = requests.get(url, auth=auth)\nTraceback (most recent call last):\n File \"/Users/coj/Dropbox/Sites/dnd-auth-test/venv/lib/python2.7/site-packages/requests/hooks.py\", line 47, in dispatch_hook\n hook_data = hook(hook_data) or hook_data\n File \"/Users/coj/Dropbox/Sites/dnd-auth-test/venv/lib/python2.7/site-packages/requests/auth.py\", line 219, in handle_401\n r.request.send(anyway=True)\n File \"/Users/coj/Dropbox/Sites/dnd-auth-test/venv/lib/python2.7/site-packages/requests/models.py\", line 602, in send\n timeout=self.timeout,\n File \"/Users/coj/Dropbox/Sites/dnd-auth-test/venv/lib/python2.7/site-packages/requests/packages/urllib3/connectionpool.py\", line 384, in urlopen\n body=body, headers=headers)\n File \"/Users/coj/Dropbox/Sites/dnd-auth-test/venv/lib/python2.7/site-packages/requests/packages/urllib3/connectionpool.py\", line 254, in _make_request\n conn.request(method, url, **httplib_request_kw)\n File \"/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/httplib.py\", line 941, in request\n self._send_request(method, url, body, headers)\n File \"/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/httplib.py\", line 975, in _send_request\n self.endheaders(body)\n File \"/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/httplib.py\", line 937, in endheaders\n self._send_output(message_body)\n File \"/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/httplib.py\", line 797, in _send_output\n self.send(msg)\n File \"/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/httplib.py\", line 759, in send\n self.connect()\n File \"/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/httplib.py\", line 740, in connect\n self.timeout, self.source_address)\n File \"/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/socket.py\", line 557, in create_connection\n sock = socket(af, socktype, proto)\nRuntimeError: maximum recursion depth exceeded\n```\n",
"Just to follow-up, similar results in 0.13.1:\n\n```\n>>> import requests\n>>> requests.__version__\n'0.13.1'\n>>> from requests.auth import HTTPDigestAuth\n>>> url = 'http://funkatron.com/digest-test/'\n>>> auth = HTTPDigestAuth('foo', 'bar')\n>>> r = requests.get(url, auth=auth)\nTraceback (most recent call last):\n File \"/Users/coj/Documents/gbvm-3.0/donenotdone.com/frontend/venv/lib/python2.7/site-packages/requests/hooks.py\", line 46, in dispatch_hook\n _hook_data = hook(hook_data)\n File \"/Users/coj/Documents/gbvm-3.0/donenotdone.com/frontend/venv/lib/python2.7/site-packages/requests/auth.py\", line 219, in handle_401\n r.request.send(anyway=True)\n File \"/Users/coj/Documents/gbvm-3.0/donenotdone.com/frontend/venv/lib/python2.7/site-packages/requests/models.py\", line 609, in send\n raise ConnectionError(e)\nConnectionError: HTTPConnectionPool(host='funkatron.com', port=80): Max retries exceeded with url: /digest-test/\n```\n",
"Is there any workaround for this issue?\n"
] |
https://api.github.com/repos/psf/requests/issues/540
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/540/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/540/comments
|
https://api.github.com/repos/psf/requests/issues/540/events
|
https://github.com/psf/requests/pull/540
| 4,005,674 |
MDExOlB1bGxSZXF1ZXN0MTExOTg4Nw==
| 540 |
Correct path to test_requests.py for setup.py test
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/357333?v=4",
"events_url": "https://api.github.com/users/jhalcrow/events{/privacy}",
"followers_url": "https://api.github.com/users/jhalcrow/followers",
"following_url": "https://api.github.com/users/jhalcrow/following{/other_user}",
"gists_url": "https://api.github.com/users/jhalcrow/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/jhalcrow",
"id": 357333,
"login": "jhalcrow",
"node_id": "MDQ6VXNlcjM1NzMzMw==",
"organizations_url": "https://api.github.com/users/jhalcrow/orgs",
"received_events_url": "https://api.github.com/users/jhalcrow/received_events",
"repos_url": "https://api.github.com/users/jhalcrow/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/jhalcrow/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/jhalcrow/subscriptions",
"type": "User",
"url": "https://api.github.com/users/jhalcrow",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 1 |
2012-04-06T15:51:14Z
|
2021-09-08T14:01:14Z
|
2012-04-06T17:01:19Z
|
CONTRIBUTOR
|
resolved
|
In setup.py the path to test_requests.py is incorrect - breaking python setup.py test, this fixes it.
|
{
"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/540/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/540/timeline
| null | null | false |
{
"diff_url": "https://github.com/psf/requests/pull/540.diff",
"html_url": "https://github.com/psf/requests/pull/540",
"merged_at": "2012-04-06T17:01:19Z",
"patch_url": "https://github.com/psf/requests/pull/540.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/540"
}
| true |
[
"thanks!\n"
] |
https://api.github.com/repos/psf/requests/issues/539
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/539/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/539/comments
|
https://api.github.com/repos/psf/requests/issues/539/events
|
https://github.com/psf/requests/issues/539
| 4,005,004 |
MDU6SXNzdWU0MDA1MDA0
| 539 |
iter_lines small chunks
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/105168?v=4",
"events_url": "https://api.github.com/users/dbrgn/events{/privacy}",
"followers_url": "https://api.github.com/users/dbrgn/followers",
"following_url": "https://api.github.com/users/dbrgn/following{/other_user}",
"gists_url": "https://api.github.com/users/dbrgn/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/dbrgn",
"id": 105168,
"login": "dbrgn",
"node_id": "MDQ6VXNlcjEwNTE2OA==",
"organizations_url": "https://api.github.com/users/dbrgn/orgs",
"received_events_url": "https://api.github.com/users/dbrgn/received_events",
"repos_url": "https://api.github.com/users/dbrgn/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/dbrgn/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/dbrgn/subscriptions",
"type": "User",
"url": "https://api.github.com/users/dbrgn",
"user_view_type": "public"
}
|
[
{
"color": "e10c02",
"default": false,
"description": null,
"id": 117744,
"name": "Bug",
"node_id": "MDU6TGFiZWwxMTc3NDQ=",
"url": "https://api.github.com/repos/psf/requests/labels/Bug"
}
] |
closed
| true | null |
[] | null | 15 |
2012-04-06T15:04:40Z
|
2021-09-09T08:00:46Z
|
2012-05-08T05:09:24Z
|
CONTRIBUTOR
|
resolved
|
I'm writing a script to track keywords in the twitter realtime api.
At first, I was using requests v0.10.8. Showing the tweets was almost instant, but the issue #515 occured frequently.
Then I upgraded requests to v0.11.1. Now #515 is resolved, but apparently small chunks are not processed instantly, if they don't reach the `chunk_size`. By setting the chunk size to a value like 10, it works, but that can't be the solution :)
|
{
"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/539/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/539/timeline
| null |
completed
| null | null | false |
[
"Hmm, it might be actually :)\n\nSomeone implemented \"proper\" chunks, but it caused way more problems than it solved, so we took it out.\n",
"So, I had opened #533, came back to update it about `chunk_size` and noticed this issue.\n\nI guess there aren't many ways to read lines from a blocking socket, so `chunk_size` probably is the solution.\n\nStill, I would like to raise two points:\n1. `iter_lines()` is supposed to iterate on _lines_. Should the user be expected to specify a `chunk_size` for it to work? (You know, HTTP for Humans ;-)). If the argument could be considered useful to some, should't it have a default value of 1? (`iter_lines()` should return empty lines too)\n2. `iter_lines()` should handle the case where the server closes the connection without raising `httplib.IncompleteRead: IncompleteRead(0 bytes read)`. It should simply stop yielding. No? It seems wrong to provide a \"readline-style\" interface and expect the user to handle read exception related to chunk sizes.\n",
"Good thoughts, @mponton :) +1 on both of them.\n",
"1: It originally did have a default size of `1`, actually, before `iter_content` was written. :)\n\n2: :+1:\n",
"I still think `chunk_size` is valuable though. Let's just change the default.\n",
"On 2: I was thinking a bit more on this, shouldn't this also apply to `iter_content` too? I mean, if I iterate over chunks of content from a streaming URL and the server closes the connection, I would expect the generator to stop yielding. Then, if I really expected a number of bytes, I would check if I got everything. My interpretation of `chunk_size` is a _maximum_ number of bytes read per iteration, not a guarantee that the content is either exactly that size or a multiple of that size.\n\nI think `iter_content` should be the one to catch `IncompleteRead` exceptions and then check if `self.raw.isclosed()` is true. If it is, it would simply return the last chunk read and exit. If not, it should re-raise the exception (but I say that because I am not certain if a blocking `HTTPResponse.read()` could return less than the specified amount of bytes when a connection was not closed by the server... Please correct me if this is not possible.).\n\nThat said, all this is really only necessary for streaming connections AFAIK. A `read(x)` on a \"normal\" HTTP connection that has a remaining content size less than `x` will simply return the remaining content and `''` on next `read`s. I assume this is due to the `Content-Size` header being present.\n",
"Agreed, leaving `chunk_size` doesn't hurt if the default is `1` for `iter_lines`.\n\nYou may want to add a short note in the documentation though. People may change the `chunk_size` thinking they will still get each line as it comes in for streaming requests.\n",
"I see no connection between size of `chunk_size` and problems mentioned in this ticket. Default size of `1` is very bad idea. Am I missing something here?\n",
"`iter_lines` uses `iter_content` which has a default of 10K bytes for its chunk size (well, it had, then was changed, see my pull request). Thus, `iter_lines()` would \"hang\" until it read at least 10K of data before returning any lines.\n\nSo using a `chunk_size` of 1 for `iter_lines()`, although not efficient, makes more sense as it will return lines as soon as they become available, even if they have only 10 characters for example.\n",
"Well, if `read(chunk_size)` blocks until at least `chunk_size` bytes are read then the whole implementation does not make sense and changing `chunk_size` to 1 is not the solution.\n",
"@mponton when `chunk_size` was set to `1`, requests of more than a few KB were exponentially slower than with any other client. \n",
"@kennethreitz Well, of course it will be. You're reading \"chunks\" of 1 byte at a time. However, when we talked about changing the default `chunk_size`, it was for `iter_lines()`, not `iter_chunk()` (see my pull request). The reason was to allow `iter_lines()` to behave like most people using requests would expect it to behave: Read lines as they come in. If you do use `iter_lines()` to read from a streaming API like the Twitter API, and it was used with an `chunk_size` of 10K, you may have to wait a freaking long time before you ever get any line.\n\nThat said, I'm open to alternatives, but unless you start polling the socket in non-blocking mode, the `read(chunk_size)` will block until it get `chunk_size` or the connection is closed AFAIK. Please let me know if I'm missing something.\n\n@piotr-dobrogost If you know of another implementation to read lines as they come in from a socket while using blocking I/O, please feel free to let me (or us) know. I'm not trying to sell my quick fix to anyone, I'm simply trying to find a way to have `iter_lines()` behave like (I hope) it was meant to behave.\n\n@kennethreitz Also, if you feel `chunk_size` should not be set to 1 in the distribution, please change it back, I don't want to impose on anybody. I can specify it in my code but I'm pretty sure you'll get regular \"issues\" opened about this thing by people wondering why their \"lines\" are not coming in when sent by the server as expected. You already had two soon after the initial code change, @gwrtheyrn and I.\n",
"@mponton would `iter_lines` ideally put the socket into nonblocking mode and read until it sees `\\n`?\n",
"It may limit the number of reads on the socket, but you'd have to handle cases where I/O would block (EWOULDBLOCK) when no data is available. The next step would be to go completely async behind the scene in `iter_lines()` and ask the system to call us back only when data is available to minimize the number of reads while still returning data line by line, but this might be a bit overkill and would definitely make the code more complex. I'm not sure its worth the effort.\n\nIf you expect to have hundred of lines per seconds in the streaming response, you could still set the `chunk_size` to something bigger. The only issue is if the \"flow\" of data slows down, your requests may start to hang with complete lines already available.\n",
"That makes sense; we'd need our own event loop, and it probably wouldn't play nice with the `gevent` event loop.\n"
] |
https://api.github.com/repos/psf/requests/issues/538
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/538/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/538/comments
|
https://api.github.com/repos/psf/requests/issues/538/events
|
https://github.com/psf/requests/issues/538
| 4,000,812 |
MDU6SXNzdWU0MDAwODEy
| 538 |
Name:"Requests" is too general
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/1563501?v=4",
"events_url": "https://api.github.com/users/EwyynTomato/events{/privacy}",
"followers_url": "https://api.github.com/users/EwyynTomato/followers",
"following_url": "https://api.github.com/users/EwyynTomato/following{/other_user}",
"gists_url": "https://api.github.com/users/EwyynTomato/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/EwyynTomato",
"id": 1563501,
"login": "EwyynTomato",
"node_id": "MDQ6VXNlcjE1NjM1MDE=",
"organizations_url": "https://api.github.com/users/EwyynTomato/orgs",
"received_events_url": "https://api.github.com/users/EwyynTomato/received_events",
"repos_url": "https://api.github.com/users/EwyynTomato/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/EwyynTomato/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/EwyynTomato/subscriptions",
"type": "User",
"url": "https://api.github.com/users/EwyynTomato",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 9 |
2012-04-06T07:06:59Z
|
2021-09-09T00:10:17Z
|
2012-04-06T07:08:29Z
|
NONE
|
resolved
|
The name of the module "requests" is really general, resulting in "python requests"-related question hardly searchable with search engine.
|
{
"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/538/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/538/timeline
| null |
completed
| null | null | false |
[
"A search for [\"python-requests\"](https://www.google.com/search?sourceid=chrome&ie=UTF-8&q=python-requests) is all good results.\n",
"I'm sorry that I'm not specific enough, now for an example:\n\nI want to search for \"python requests post xml\", since \"requests\" isn't really specific to the name of the module, most of the result returned is not \"requests\" module-related.\n",
"Search instead for this:\n\n`python-requests post xml`\n",
"We could rename it to requests3. :P\n",
"urlrequests5\n",
"coreurlrequestslib5\n",
"python-coreurlrequestslib5\n",
"@EwyynTomato \n\nIt's true that the library's name which consists of two general words doesn't help when searching the web. Searching would be easier if the lib was named for instance pyrequests following the common pattern among Python libs. Well, I guess you have to deal with it.\n\nSearching for word `python-requests` (http://stackoverflow.com/search?q=python-requests&submit=search) gives 45 results and searching for tag `python-requests` (http://stackoverflow.com/questions/tagged/python-requests) gives 10 results. If you don't find the question you're looking for please ask one.\n",
"Well, I guess as long as I limit my search my question in stack overflow, this wouldn't be a problem.\n\nAnd I really should read the docs.\n"
] |
https://api.github.com/repos/psf/requests/issues/537
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/537/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/537/comments
|
https://api.github.com/repos/psf/requests/issues/537/events
|
https://github.com/psf/requests/issues/537
| 3,999,105 |
MDU6SXNzdWUzOTk5MTA1
| 537 |
requests.get throws TooManyRedirects in safe_mode
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/292606?v=4",
"events_url": "https://api.github.com/users/spulec/events{/privacy}",
"followers_url": "https://api.github.com/users/spulec/followers",
"following_url": "https://api.github.com/users/spulec/following{/other_user}",
"gists_url": "https://api.github.com/users/spulec/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/spulec",
"id": 292606,
"login": "spulec",
"node_id": "MDQ6VXNlcjI5MjYwNg==",
"organizations_url": "https://api.github.com/users/spulec/orgs",
"received_events_url": "https://api.github.com/users/spulec/received_events",
"repos_url": "https://api.github.com/users/spulec/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/spulec/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/spulec/subscriptions",
"type": "User",
"url": "https://api.github.com/users/spulec",
"user_view_type": "public"
}
|
[
{
"color": "e10c02",
"default": false,
"description": null,
"id": 117744,
"name": "Bug",
"node_id": "MDU6TGFiZWwxMTc3NDQ=",
"url": "https://api.github.com/repos/psf/requests/labels/Bug"
}
] |
closed
| true | null |
[] | null | 3 |
2012-04-06T01:50:52Z
|
2021-09-09T09:00:32Z
|
2012-05-04T01:49:58Z
|
CONTRIBUTOR
|
resolved
|
``` python
>>> import requests
>>> requests.__version__
'0.11.1'
>>> res = requests.get("http://httpbin.org/redirect/3", config=dict(safe_mode=True, max_redirects=2))
Starting new HTTP connection (1): httpbin.org
"GET /redirect/3 HTTP/1.1" 302 229
"GET /redirect/2 HTTP/1.1" 302 229
"GET /redirect/1 HTTP/1.1" 302 215
Traceback (most recent call last):
File "<console>", line 1, in <module>
File "/Users/spulec/Development/yipit-env/lib/python2.7/site-packages/requests/api.py", line 52, in get
return request('get', url, **kwargs)
File "/Users/spulec/Development/yipit-env/lib/python2.7/site-packages/requests/api.py", line 40, in request
return s.request(method=method, url=url, **kwargs)
File "/Users/spulec/Development/yipit-env/lib/python2.7/site-packages/requests/sessions.py", line 208, in request
r.send(prefetch=prefetch)
File "/Users/spulec/Development/yipit-env/lib/python2.7/site-packages/requests/models.py", line 597, in send
self._build_response(r)
File "/Users/spulec/Development/yipit-env/lib/python2.7/site-packages/requests/models.py", line 226, in _build_response
raise TooManyRedirects()
TooManyRedirects
```
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/376448?v=4",
"events_url": "https://api.github.com/users/slingamn/events{/privacy}",
"followers_url": "https://api.github.com/users/slingamn/followers",
"following_url": "https://api.github.com/users/slingamn/following{/other_user}",
"gists_url": "https://api.github.com/users/slingamn/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/slingamn",
"id": 376448,
"login": "slingamn",
"node_id": "MDQ6VXNlcjM3NjQ0OA==",
"organizations_url": "https://api.github.com/users/slingamn/orgs",
"received_events_url": "https://api.github.com/users/slingamn/received_events",
"repos_url": "https://api.github.com/users/slingamn/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/slingamn/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/slingamn/subscriptions",
"type": "User",
"url": "https://api.github.com/users/slingamn",
"user_view_type": "public"
}
|
{
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/537/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/537/timeline
| null |
completed
| null | null | false |
[
"Thanks for the report! This is definitely a bug.\n",
"Different traceback now :-/\n\n```\n>>> import requests\n>>> res = requests.get(\"http://httpbin.org/redirect/3\", config=dict(safe_mode=True, max_redirects=2))\nTraceback (most recent call last):\n File \"<stdin>\", line 1, in <module>\n File \"requests/api.py\", line 52, in get\n return request('get', url, **kwargs)\n File \"requests/api.py\", line 40, in request\n return s.request(method=method, url=url, **kwargs)\n File \"requests/sessions.py\", line 232, in request\n for cookie in r.response.cookies:\nTypeError: 'NoneType' object is not iterable\n>>> requests.__version__\n'0.12.0'\n```\n",
"Fixed!\n"
] |
https://api.github.com/repos/psf/requests/issues/536
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/536/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/536/comments
|
https://api.github.com/repos/psf/requests/issues/536/events
|
https://github.com/psf/requests/issues/536
| 3,972,354 |
MDU6SXNzdWUzOTcyMzU0
| 536 |
unicode in cookies
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/173095?v=4",
"events_url": "https://api.github.com/users/benmao/events{/privacy}",
"followers_url": "https://api.github.com/users/benmao/followers",
"following_url": "https://api.github.com/users/benmao/following{/other_user}",
"gists_url": "https://api.github.com/users/benmao/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/benmao",
"id": 173095,
"login": "benmao",
"node_id": "MDQ6VXNlcjE3MzA5NQ==",
"organizations_url": "https://api.github.com/users/benmao/orgs",
"received_events_url": "https://api.github.com/users/benmao/received_events",
"repos_url": "https://api.github.com/users/benmao/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/benmao/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/benmao/subscriptions",
"type": "User",
"url": "https://api.github.com/users/benmao",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 13 |
2012-04-04T15:12:25Z
|
2021-09-09T06:00:47Z
|
2012-05-03T08:11:53Z
|
NONE
|
resolved
|
```
Set-Cookie: xx=\u4E2A\u4EBA; expires=Wed, 04-Apr-42 15:00:05 GMT; path=/;
```
requests SimpleCookie
``` python
>>> s = SimpleCookie()
>>> s.load('xx=\u4E2A\u4EBA; expires=Wed, 04-Apr-42 15:00:05 GMT; path=/; ')
>>> s
<SimpleCookie: xx=''>
```
The result should be like this.
``` python
>>> s
<SimpleCookie: xx='\u4E2A\u4EBA'>
```
|
{
"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/536/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/536/timeline
| null |
completed
| null | null | false |
[
"I've been studying this issue for a couple of days, I don't believe that this is a valid use case. The RFC's for HTML require that the header be encoded in iso-8859-1, so there should never be a case where the header contains unencoded unicode characters as you've shown here.\n\nNonetheless, I'm thinking about whether it's possible to handle cases like this, which do seem to occur in the real world due to sloppy implementation by others.\n",
"@benmao \nWhat Python version are we talking about?\n\n@rwzehner \nWhat does HTML spec have to do with HTTP headers?\n",
"Sorry, should have written HTTP spec, not HTML spec. Check out RFC 2109, which defines the cookie spec and references RFC 2068. Bottom line, although HTTP allows one to specify different encodings for the body of a reply, all of the header information must be Latin-1 encoded.\n\nIn any case, looking at the above situation further (with Python 2.7.1), the string passed in contains Unicode escapes, but does not have a unicode signifier on it, so Python does not properly interpret the escapes. This could be fixed by decoding the string using the raw_unicode_escape encoding:\n\n```\ns.load('xx=\\u4E2A\\u4EBA; expires=Wed, 04-Apr-42 15:00:05 GMT; path=/; '.decode('raw_unicode_escape'))\n```\n\nIt's a fairly easy change to make, but I haven't been able to think through whether it would potentially break if the user had already encoded their string using another technique.\n",
"@piotr-dobrogost Python Version: 2.7.2\n\nI found monkeys.py is copy of Cookie.py which from Python Lib.\n\nurllib2 + cookielib works well.\n\nSo I do not think \"monkeys.py\" have problem.\n",
"https://gist.github.com/2450467\n\nI have write a test .\n",
"@benmao\n\n> The result should be like this.\n\n```\n<SimpleCookie: xx='\\u4E2A\\u4EBA'>\n```\n\nI guess you meant \n\n```\n<SimpleCookie: xx='\\\\u4E2A\\\\u4EBA'>\n```\n\nbecause backslash which is not part of escape sequence is doubled in string representation.\n\nAccording to RFC 2109 backslash is not allowed in cookie's value unless the value is quoted. As [`Cookie`](http://docs.python.org/library/cookie.html) module implements this RFC (albeit with modifications) this could be the reason for not _accepting_ value `\\u4E2A\\u4EBA` as a valid cookie's value. The reason it works in `cookielib` is because it has its own `Cookie` class and apparently different parser - see [parse_ns_headers](http://hg.python.org/cpython/file/2.7/Lib/cookielib.py#l444) method. [Cookies](https://github.com/sashahart/cookies) lib doesn't allow this cookie value as well:\n\n```\n>>> import cookies\n>>> cookies.Cookies.from_response('xx=\\u4E2A\\u4EBA; expires=Wed, 04-Apr-42 15:00:05 GMT; path=/; ')\nCookies(xx=u'')\n```\n\nHowever, there is a difference when using double quoted value of cookie:\n\n```\n>>> import Cookie\n>>> s=Cookie.SimpleCookie()\n>>> s.load('xx=\"\\u4E2A\\u4EBA\"; expires=Wed, 04-Apr-42 15:00:05 GMT; path=/; ')\n>>> s\n<SimpleCookie: xx='u4E2Au4EBA'>\n\n>>> import cookies\n>>> cookies.Cookies.from_response('xx=\"\\u4E2A\\u4EBA\"; expires=Wed, 04-Apr-42 15:00:05 GMT; path=/; ')\nCookies(xx=u'\\\\u4E2A\\\\u4EBA')\n```\n\nRFC 2109 defines cookie's value (`value`) as:\n\n```\nvalue = word\nword = token | quoted-string\n```\n\n, where `quoted-string` is defined in RFC 2068 as:\n\n```\nquoted-string = ( <\"> *(qdtext) <\"> )\n\nqdtext = <any TEXT except <\">>\n\nThe backslash character (\"\\\") may be used as a single-character quoting\nmechanism only within quoted-string and comment constructs.\n\nquoted-pair = \"\\\" CHAR\n```\n\nBecause there's no further description of quoting mechanism I don't know which behavior is right (see https://github.com/sashahart/cookies/issues/1).\n\nWhat's interesting is that RFC 6265 (which obsoletes RFC 2109 and which Cookies supposedly implements) states this:\n\n```\ncookie-value = *cookie-octet / ( DQUOTE *cookie-octet DQUOTE )\ncookie-octet = %x21 / %x23-2B / %x2D-3A / %x3C-5B / %x5D-7E\n ; US-ASCII characters excluding CTLs,\n ; whitespace DQUOTE, comma, semicolon,\n ; and backslash\n```\n\nwhich does not allow backslash in cookie's value at all. This is surprising as this RFC was meant to take into account existing practice and relax rules of previous RFCs.\n",
"@rwzehner \n\n> Bottom line, although HTTP allows one to specify different encodings for the body of a reply, all of the header information must be Latin-1 encoded.\n\nNo, it does not have to be Latin-1. See http://stackoverflow.com/a/818188/95735\n",
"I forked @benmao's gist at https://gist.github.com/2584020 , changing it to use the new `CookieJar` API.\n\n```\n[shivaram@good-fortune ~/workspace/requests]$ python ./benmao2.py \nurllib2 and cookielib test: True\nrequests test: True\n```\n",
"Uh, sec, I did something wrong.\n",
"OK, the main problem was that the test case was querying two different URLs. urllib2 was querying `requests.sinaapp.com` and Requests was querying `request.sinaapp.com`.\n\nHere is my corrected fork of the test: https://gist.github.com/2584138\n\nHere is the output:\n\n```\n[shivaram@good-fortune ~/workspace/requests]$ python ./benmao.py \nurllib2 and cookielib test: True\nrequests.session test: True\n```\n",
"Anyway, I think this is probably closeable, although @piotr-dobrogost and @rwzehner may want to weigh in on the standards-compliance issues. Basically, for better or worse, cookie parsing is now being deferred directly to `cookielib`.\n",
"+1\n",
"@sashahart \n\nThanks for dropping in here and sharing your knowledge with us. It's good to have cookie expert on board.\n\nAs to the backslash I'm not done yet :) - I've just posted to ongoing thread at https://github.com/sashahart/cookies/issues/1\n\n> As author of cookies.py and a close follower of the thrilling world of RFC cookie value syntax, I think letting cookielib handle it is a very sound choice for code focused on the client side of HTTP.\n\nI think the main reason cookielib is used is because it implements cookie jars. However as you know its parsing is not perfect - that's why you created Cookies. The perfect solution would be to use your Cookies and write implementation of cookie jars.\n"
] |
https://api.github.com/repos/psf/requests/issues/535
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/535/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/535/comments
|
https://api.github.com/repos/psf/requests/issues/535/events
|
https://github.com/psf/requests/pull/535
| 3,968,250 |
MDExOlB1bGxSZXF1ZXN0MTEwMzI2OA==
| 535 |
Fix decoding of invalid %encodings in URLs
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/1553?v=4",
"events_url": "https://api.github.com/users/Jonty/events{/privacy}",
"followers_url": "https://api.github.com/users/Jonty/followers",
"following_url": "https://api.github.com/users/Jonty/following{/other_user}",
"gists_url": "https://api.github.com/users/Jonty/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Jonty",
"id": 1553,
"login": "Jonty",
"node_id": "MDQ6VXNlcjE1NTM=",
"organizations_url": "https://api.github.com/users/Jonty/orgs",
"received_events_url": "https://api.github.com/users/Jonty/received_events",
"repos_url": "https://api.github.com/users/Jonty/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Jonty/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Jonty/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Jonty",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 4 |
2012-04-04T10:16:58Z
|
2021-09-08T14:01:15Z
|
2012-04-11T15:02:46Z
|
CONTRIBUTOR
|
resolved
|
Currently a URL with invalid %encodings will cause an exception to be thrown in unquote_unreserved.
This patch reimplements unquote_unreserved to be almost identical to urllib.unquote, thus fixing the problem and simplifying the code.
|
{
"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/535/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/535/timeline
| null | null | false |
{
"diff_url": "https://github.com/psf/requests/pull/535.diff",
"html_url": "https://github.com/psf/requests/pull/535",
"merged_at": "2012-04-11T15:02:46Z",
"patch_url": "https://github.com/psf/requests/pull/535.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/535"
}
| true |
[
"Awesome, thanks! \n\nLooks like there's a merge conflict now. Would you mind bringing it back up to date?\n",
"Rebased and fixed, should merge cleanly now.\n",
"You're the best. Thanks!\n",
"Reverting for now.\n"
] |
https://api.github.com/repos/psf/requests/issues/534
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/534/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/534/comments
|
https://api.github.com/repos/psf/requests/issues/534/events
|
https://github.com/psf/requests/pull/534
| 3,966,688 |
MDExOlB1bGxSZXF1ZXN0MTEwMjcxNg==
| 534 |
Remove bad tab indent
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/179599?v=4",
"events_url": "https://api.github.com/users/ThiefMaster/events{/privacy}",
"followers_url": "https://api.github.com/users/ThiefMaster/followers",
"following_url": "https://api.github.com/users/ThiefMaster/following{/other_user}",
"gists_url": "https://api.github.com/users/ThiefMaster/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/ThiefMaster",
"id": 179599,
"login": "ThiefMaster",
"node_id": "MDQ6VXNlcjE3OTU5OQ==",
"organizations_url": "https://api.github.com/users/ThiefMaster/orgs",
"received_events_url": "https://api.github.com/users/ThiefMaster/received_events",
"repos_url": "https://api.github.com/users/ThiefMaster/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/ThiefMaster/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/ThiefMaster/subscriptions",
"type": "User",
"url": "https://api.github.com/users/ThiefMaster",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 1 |
2012-04-04T08:04:26Z
|
2021-09-08T14:01:13Z
|
2012-04-04T08:05:00Z
|
CONTRIBUTOR
|
resolved
|
The "Streaming Requests" example was indented using tabs instead of spaces.
|
{
"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/534/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/534/timeline
| null | null | false |
{
"diff_url": "https://github.com/psf/requests/pull/534.diff",
"html_url": "https://github.com/psf/requests/pull/534",
"merged_at": "2012-04-04T08:05:00Z",
"patch_url": "https://github.com/psf/requests/pull/534.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/534"
}
| true |
[
"Thanks!\n"
] |
https://api.github.com/repos/psf/requests/issues/533
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/533/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/533/comments
|
https://api.github.com/repos/psf/requests/issues/533/events
|
https://github.com/psf/requests/issues/533
| 3,965,793 |
MDU6SXNzdWUzOTY1Nzkz
| 533 |
Broken HTTPResponse.iter_lines() in 0.11.1
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/822167?v=4",
"events_url": "https://api.github.com/users/mponton/events{/privacy}",
"followers_url": "https://api.github.com/users/mponton/followers",
"following_url": "https://api.github.com/users/mponton/following{/other_user}",
"gists_url": "https://api.github.com/users/mponton/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/mponton",
"id": 822167,
"login": "mponton",
"node_id": "MDQ6VXNlcjgyMjE2Nw==",
"organizations_url": "https://api.github.com/users/mponton/orgs",
"received_events_url": "https://api.github.com/users/mponton/received_events",
"repos_url": "https://api.github.com/users/mponton/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/mponton/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/mponton/subscriptions",
"type": "User",
"url": "https://api.github.com/users/mponton",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 1 |
2012-04-04T06:19:32Z
|
2021-09-09T09:00:38Z
|
2012-04-10T22:25:38Z
|
NONE
|
resolved
|
Code like `for line in http_response.iter_lines():` works fine with 0.10.8 but when used with 0.11.1, lines are not yielded as expected and when the server closes the connection, the following exception is raised:
`httplib.IncompleteRead: IncompleteRead(354 bytes read)` (where that 354 bytes is about the size of the lines I should I received ;-))
I did not have time to further investigate but opened this ticket in case you have an idea what recent change may have introduced this issue.
Will try to dig in further when I have some spare time.
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/822167?v=4",
"events_url": "https://api.github.com/users/mponton/events{/privacy}",
"followers_url": "https://api.github.com/users/mponton/followers",
"following_url": "https://api.github.com/users/mponton/following{/other_user}",
"gists_url": "https://api.github.com/users/mponton/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/mponton",
"id": 822167,
"login": "mponton",
"node_id": "MDQ6VXNlcjgyMjE2Nw==",
"organizations_url": "https://api.github.com/users/mponton/orgs",
"received_events_url": "https://api.github.com/users/mponton/received_events",
"repos_url": "https://api.github.com/users/mponton/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/mponton/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/mponton/subscriptions",
"type": "User",
"url": "https://api.github.com/users/mponton",
"user_view_type": "public"
}
|
{
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/533/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/533/timeline
| null |
completed
| null | null | false |
[
"\"Issue\" is really #539. Not really broken. Just working differently :-)\n\nClosed and commented on #539.\n"
] |
https://api.github.com/repos/psf/requests/issues/532
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/532/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/532/comments
|
https://api.github.com/repos/psf/requests/issues/532/events
|
https://github.com/psf/requests/pull/532
| 3,931,754 |
MDExOlB1bGxSZXF1ZXN0MTA5MTA0OA==
| 532 |
Modified tests to use MissingSchema and InvalidSchema instead of ValueError
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/155016?v=4",
"events_url": "https://api.github.com/users/silent1mezzo/events{/privacy}",
"followers_url": "https://api.github.com/users/silent1mezzo/followers",
"following_url": "https://api.github.com/users/silent1mezzo/following{/other_user}",
"gists_url": "https://api.github.com/users/silent1mezzo/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/silent1mezzo",
"id": 155016,
"login": "silent1mezzo",
"node_id": "MDQ6VXNlcjE1NTAxNg==",
"organizations_url": "https://api.github.com/users/silent1mezzo/orgs",
"received_events_url": "https://api.github.com/users/silent1mezzo/received_events",
"repos_url": "https://api.github.com/users/silent1mezzo/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/silent1mezzo/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/silent1mezzo/subscriptions",
"type": "User",
"url": "https://api.github.com/users/silent1mezzo",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 1 |
2012-04-02T18:31:14Z
|
2021-09-08T14:01:12Z
|
2012-05-08T05:06:16Z
|
CONTRIBUTOR
|
resolved
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/119893?v=4",
"events_url": "https://api.github.com/users/kennethreitz/events{/privacy}",
"followers_url": "https://api.github.com/users/kennethreitz/followers",
"following_url": "https://api.github.com/users/kennethreitz/following{/other_user}",
"gists_url": "https://api.github.com/users/kennethreitz/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/kennethreitz",
"id": 119893,
"login": "kennethreitz",
"node_id": "MDQ6VXNlcjExOTg5Mw==",
"organizations_url": "https://api.github.com/users/kennethreitz/orgs",
"received_events_url": "https://api.github.com/users/kennethreitz/received_events",
"repos_url": "https://api.github.com/users/kennethreitz/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/kennethreitz/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/kennethreitz/subscriptions",
"type": "User",
"url": "https://api.github.com/users/kennethreitz",
"user_view_type": "public"
}
|
{
"+1": 0,
"-1": 0,
"confused": 0,
"eyes": 0,
"heart": 0,
"hooray": 0,
"laugh": 0,
"rocket": 0,
"total_count": 0,
"url": "https://api.github.com/repos/psf/requests/issues/532/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/532/timeline
| null | null | false |
{
"diff_url": "https://github.com/psf/requests/pull/532.diff",
"html_url": "https://github.com/psf/requests/pull/532",
"merged_at": null,
"patch_url": "https://github.com/psf/requests/pull/532.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/532"
}
| true |
[
"Awesome, thanks!\n"
] |
|
https://api.github.com/repos/psf/requests/issues/531
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/531/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/531/comments
|
https://api.github.com/repos/psf/requests/issues/531/events
|
https://github.com/psf/requests/pull/531
| 3,923,214 |
MDExOlB1bGxSZXF1ZXN0MTA4NzU5MA==
| 531 |
fixed bug in setup.py where running from outside project dir would fail
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/441766?v=4",
"events_url": "https://api.github.com/users/nikcub/events{/privacy}",
"followers_url": "https://api.github.com/users/nikcub/followers",
"following_url": "https://api.github.com/users/nikcub/following{/other_user}",
"gists_url": "https://api.github.com/users/nikcub/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/nikcub",
"id": 441766,
"login": "nikcub",
"node_id": "MDQ6VXNlcjQ0MTc2Ng==",
"organizations_url": "https://api.github.com/users/nikcub/orgs",
"received_events_url": "https://api.github.com/users/nikcub/received_events",
"repos_url": "https://api.github.com/users/nikcub/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/nikcub/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/nikcub/subscriptions",
"type": "User",
"url": "https://api.github.com/users/nikcub",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 1 |
2012-04-02T09:15:34Z
|
2021-09-08T23:08:16Z
|
2012-04-23T02:34:12Z
|
NONE
|
resolved
|
If you run setup from outside the project directory it will fail on attempting to open the README, etc. files.
for eg.
python requests/setup.py install
now works because the full path name is used in reading the file. implement as a separate func since it is used three times.
this is a pretty common bug, but I see it a lot because of my deploy scripts
|
{
"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/531/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/531/timeline
| null | null | false |
{
"diff_url": "https://github.com/psf/requests/pull/531.diff",
"html_url": "https://github.com/psf/requests/pull/531",
"merged_at": "2012-04-23T02:34:12Z",
"patch_url": "https://github.com/psf/requests/pull/531.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/531"
}
| true |
[
"Unnecessary, but good changes. :) \n\nThanks!\n"
] |
https://api.github.com/repos/psf/requests/issues/530
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/530/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/530/comments
|
https://api.github.com/repos/psf/requests/issues/530/events
|
https://github.com/psf/requests/pull/530
| 3,922,287 |
MDExOlB1bGxSZXF1ZXN0MTA4NzIzNw==
| 530 |
Fix #506: Change "Support Requests" to "Donate".
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/193106?v=4",
"events_url": "https://api.github.com/users/Osmose/events{/privacy}",
"followers_url": "https://api.github.com/users/Osmose/followers",
"following_url": "https://api.github.com/users/Osmose/following{/other_user}",
"gists_url": "https://api.github.com/users/Osmose/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/Osmose",
"id": 193106,
"login": "Osmose",
"node_id": "MDQ6VXNlcjE5MzEwNg==",
"organizations_url": "https://api.github.com/users/Osmose/orgs",
"received_events_url": "https://api.github.com/users/Osmose/received_events",
"repos_url": "https://api.github.com/users/Osmose/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/Osmose/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/Osmose/subscriptions",
"type": "User",
"url": "https://api.github.com/users/Osmose",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 3 |
2012-04-02T07:41:48Z
|
2021-09-08T14:01:12Z
|
2012-04-02T07:44:00Z
|
NONE
|
resolved
|
omg am i a core dev now? :P
|
{
"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/530/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/530/timeline
| null | null | false |
{
"diff_url": "https://github.com/psf/requests/pull/530.diff",
"html_url": "https://github.com/psf/requests/pull/530",
"merged_at": "2012-04-02T07:44:00Z",
"patch_url": "https://github.com/psf/requests/pull/530.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/530"
}
| true |
[
"Haha, not yet :)\n",
"You're on the AUTHORS list though :) \n\n37f3a29d49453244c354b98a01fe765b5f01aaec\n",
"Thanks!\n\n:cake:\n"
] |
https://api.github.com/repos/psf/requests/issues/529
|
https://api.github.com/repos/psf/requests
|
https://api.github.com/repos/psf/requests/issues/529/labels{/name}
|
https://api.github.com/repos/psf/requests/issues/529/comments
|
https://api.github.com/repos/psf/requests/issues/529/events
|
https://github.com/psf/requests/pull/529
| 3,912,692 |
MDExOlB1bGxSZXF1ZXN0MTA4NDAxMQ==
| 529 |
Removed unnecessary leading slashes in httpbin's endpoints
|
{
"avatar_url": "https://avatars.githubusercontent.com/u/92239?v=4",
"events_url": "https://api.github.com/users/piotr-dobrogost/events{/privacy}",
"followers_url": "https://api.github.com/users/piotr-dobrogost/followers",
"following_url": "https://api.github.com/users/piotr-dobrogost/following{/other_user}",
"gists_url": "https://api.github.com/users/piotr-dobrogost/gists{/gist_id}",
"gravatar_id": "",
"html_url": "https://github.com/piotr-dobrogost",
"id": 92239,
"login": "piotr-dobrogost",
"node_id": "MDQ6VXNlcjkyMjM5",
"organizations_url": "https://api.github.com/users/piotr-dobrogost/orgs",
"received_events_url": "https://api.github.com/users/piotr-dobrogost/received_events",
"repos_url": "https://api.github.com/users/piotr-dobrogost/repos",
"site_admin": false,
"starred_url": "https://api.github.com/users/piotr-dobrogost/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/piotr-dobrogost/subscriptions",
"type": "User",
"url": "https://api.github.com/users/piotr-dobrogost",
"user_view_type": "public"
}
|
[] |
closed
| true | null |
[] | null | 1 |
2012-03-31T20:20:12Z
|
2021-09-08T14:01:11Z
|
2012-03-31T20:21:18Z
|
NONE
|
resolved
|
Removed unnecessary leading slashes in httpbin's endpoints
|
{
"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/529/reactions"
}
|
https://api.github.com/repos/psf/requests/issues/529/timeline
| null | null | false |
{
"diff_url": "https://github.com/psf/requests/pull/529.diff",
"html_url": "https://github.com/psf/requests/pull/529",
"merged_at": "2012-03-31T20:21:18Z",
"patch_url": "https://github.com/psf/requests/pull/529.patch",
"url": "https://api.github.com/repos/psf/requests/pulls/529"
}
| true |
[
"thanks!\n"
] |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.