Skip to content
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

Preparing requests #181

Open
arosen32 opened this issue May 19, 2015 · 1 comment
Open

Preparing requests #181

arosen32 opened this issue May 19, 2015 · 1 comment

Comments

@arosen32
Copy link

In regular requests one can prepare a request using parameters from a session to be sent later:

req = Request('GET', 'http://example.com')
prepped = session.prepare_request(req)
checksomething()
session.send(prepped)

When I attempt to use an OAUTH1 session to prepare the request, it won't sign it and apply necessary headers/params.

@maxcountryman
Copy link
Contributor

It's been a while since I've looked at this but as I recall there was a fundamental limitation around prepared requests: I think that Requests itself does some things after the prepared request object is created which could invalidate parts of the signing process. Therefore we don't use prepared requests at all in the implementation. Instead we implement our own session.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants