Join GitHub today
GitHub is home to over 36 million developers working together to host and review code, manage projects, and build software together.Sign up
Remove refresh auth #119
This PR is just a suggestion, close it if it's out of the project goals.
So I changed the TapiocaClientExecutor and TapiocaAdapter to basically call refresh_authentication method whenever it is necessary (and without break existing adapters).
Unfortunately it breaks the interface for clients that already use refresh_auth flag.
I've removed some dead-code and pep8 fixes.
Hey @georgeyk, I've been thinking about this. Let me expose my points here to you, maybe you can help me:
This is what I have so far, what do you think? Any other ideas?
@filipeximenes the follow-up:
Thinking about the client user, would he mind to know if his credentials needs to be "updated" ? Personally, I just want to access a resource and I want to get this (auth-thing) out of my way.
The worst scenario would be the "token refresh" optionally implemented (and used), right ?
Your last point is tricky. Because
Maybe, another class in the chain to deal with authencation/ token retrieval might work. I'll see if I can do a PoC.
An idea to solve retrieving the new token would be to make the method
I made a small comment on the PR the rest looks good. Can you add information about this new behavior to the docs before we merge?
@filipeximenes thx for the review, I'll try to update the docs in the next days (also in a hush here).
About the token retrieval issue, returning token data in
I was thinking about replace this machinery to a callback-style to be defined upon client initialization (like