Accept httpx URL objects on OAuth client requests - #934
Conversation
httpx/httpx2 pass URL instances around; request() and stream() were typed and implemented against plain strings, so those objects failed at various call sites. Coerce with str() before talking to the session.
It was dropped when the URL-object test was written in its place. The new test now sits alongside it, and covers all three token placements so a URL object is exercised on the body and uri paths too. Co-authored-by: Cursor <cursoragent@cursor.com>
|
Hey,... In principle it might also be nice if authlib's other methods that take URLs (like But these do stuff like e.g. the which isn't supported by |
|
@calestyo agreed those other methods would be nicer with
I would keep this PR on the request path and do those helpers in a follow-up that stringifies (or wraps) before the |
|
Fine for me :-) |
httpx/httpx2 pass URL instances into get/request/stream. The Authlib wrappers forwarded those objects through as-is and they broke in places that expected a str.
str() them at the request/stream boundary on the async and sync OAuth2 and assertion clients.
Fixes #931