-
-
Notifications
You must be signed in to change notification settings - Fork 9.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Auth fail for private github repo #56
Comments
I'm going to have to play with this. #74 may fix the problem, once it is implemented. |
Same problem here. From Wireshark, requests.get('https://api.github.com', auth=('user', 'pass')) seems to not send the HTTP authentication headers. |
I'm going to get on this tonight. It's because GitHub's api isn't asking for authentication. |
Until I figure out a good method for overriding default HTTP behavior, you can do this: http://stackoverflow.com/questions/2407126/python-urllib2-basic-auth-problem/2955687#2955687 |
Alright, a new ForcedHTTPBasicAuthenticationHandler was added, and it's default. This should work fine now::
:) |
Thanks for writing this! I just ran easy_install -U and now it seems to work, because I get a <Response 200> instead of the <Response 404>. Of course when I tried to read from the response, I got a huge stream of gibberish, but I'll try to figure that out myself. |
I've got a private repo here on github. I want to suck down all the issues. This works in curl (password removed):
And this is what happens when I don't include the -u authentication stuff:
Then I tried the same thing with requests (again XXXXXX ain't really my password):
I wondered if maybe you don't actually send the auth stuff unless the server replies with a 403, and since github is replying with a 404, the requests code never knows to send the credentials.
I tried reading through the requests code, but didn't see anything that supported that guess.
The text was updated successfully, but these errors were encountered: