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

Credentials with optional file locking caching feature whenever token refreshes #56

Open
junpeng-jp opened this issue May 7, 2022 · 1 comment

Comments

@junpeng-jp
Copy link

Feature Requested
A Credentials object with file locking read / write option that emulates the old google oauth2client's Storage and the post-refresh caching in Client

Potential Implementation

  • a custom Credential object that has self.cache & modify before_request method (see here) to do some sort of caching every time a refresh occurs

Other Comments

  • Happy to help add this feature to this repo but would like some guidance
  • before_request is called in both the AuthorizedSession and AuthorizedHttp object's request method. I think this could be a good place to add some post-refresh functionality
@junpeng-jp junpeng-jp changed the title Credentials with file locking read / write option whenever token refreshes in the before_request method Credentials with file locking read / write option whenever token refreshes May 7, 2022
@junpeng-jp junpeng-jp changed the title Credentials with file locking read / write option whenever token refreshes Credentials with optional file locking caching feature whenever token refreshes May 7, 2022
@tswast
Copy link
Collaborator

tswast commented Jun 29, 2022

@junpeng-jp This makes some sense to me, but I'd like to understand more. Is there a specific use case you have in mind / problem you're having that this would solve?

This package already has some capability for writing credentials to a file and reading them, so I'd like to understand where the gaps are in the current capabilities.

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