feat: allow multiple credentials for input connector#938
feat: allow multiple credentials for input connector#938
Conversation
…too, improved checking for correct auth by time constant comparison and not, halt checking for is in
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #938 +/- ##
==========================================
+ Coverage 96.13% 96.16% +0.02%
==========================================
Files 217 217
Lines 14220 14245 +25
==========================================
+ Hits 13671 13698 +27
+ Misses 549 547 -2 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
kaya-david
left a comment
There was a problem hiding this comment.
LGTM, left some comments
|
|
||
| if self._token.is_expired and self._token.refresh_token is not None: | ||
| if self._token and self._token.is_expired and self._token.refresh_token is not None: | ||
| session = Session() |
There was a problem hiding this comment.
This creates a fresh session without the super().get_session() semantics which ensure a retry behavior is configured. I would propose to refactor Credentials.get_session() to call a new method self._create_and_save_session(). This new method can then be re-used in this line to ensure a retry configuration is being set properly.
I propose to include setting self._session in this new method as well (in contrast to a pure self._create_session() method) because the management of this attribute is an internal aspect of the super class.
Description
Assignee
Documentation
Code Quality
How did you verify that the changes work in practice?
Reviewer
The rendered docs for this PR can be found here.