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

httpx 0.24 OAuth1Auth integration broken? #541

Closed
marban opened this issue Apr 16, 2023 · 0 comments
Closed

httpx 0.24 OAuth1Auth integration broken? #541

marban opened this issue Apr 16, 2023 · 0 comments

Comments

@marban
Copy link

marban commented Apr 16, 2023

Haven't gotten into the details but by upgrading httpx to 0.24 and using
OAuth1Auth from authlib.integrations.httpx_client, I can no longer use e.g. Twitter's API and get an unauthorized header back. Reverting to the previous versions resolves this.

I assume it has to do with their recent change:

  • Query parameter encoding switches from using + for spaces and %2F for forward slash, to instead using %20 for spaces and treating forward slash as a safe, unescaped character. This differs from requests, but is in line with browser behavior in Chrome, Safari, and Firefox. Both options are RFC valid. (Use '%20' for encoding spaces in query parameters. encode/httpx#2543)
@marban marban closed this as completed Apr 16, 2023
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

1 participant