Custom authentication schemes and the follow_redirects parameter #3527
Unanswered
whilenot-dev
asked this question in
Potential Issue
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Version
0.28.1
Goal
I'm currently writing my own authentication scheme by subclassing the
Auth
class as mentioned in the docs. The requests in my authentication scheme sometimes need to follow redirects, but sometimes don't. I'd like to keep the default client behavior of following redirects, but would like to configure it on a "per-request"-basis in myAuth
-subclass.Potential issue
The
follow_redirects
setting is only available as parameter in the client instance and its corresponding methods to initiate a request (get
,post
,send
etc.). Both these things are currently hidden from (A) theauth_flow
-method when subclassing theAuth
class, or from (B) a callable that accepts a request and returns an authenticated request instance.Question
How is it currently possible to configure the
follow_redirects
parameter within a custom authentication scheme?Beta Was this translation helpful? Give feedback.
All reactions