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

Fix expired session login redirect. #170

Merged
merged 2 commits into from
Jul 26, 2024
Merged

Conversation

abrightwell
Copy link
Member

When we switched to session based authentication from token based, we
introduced an undesired UX issue when a session expires. In summary,
when a session expires, the desired functionality is that the user will
be presented with a message indicating the expiration and prompted to
login in again.

While the first of these was occuring in the form of a formatted HTTP
error output the latter was not. Also, the form of the error was less
than desirable too.

Therefore, what we've done here is updated the error handling around
session expiration/unauthorized errors to prompt the user to login
again. Also, we've taken the opporunity to clean up the error output of
other API errors as well such that it's presents the error. Use of
HTTP_DEBUG is still supported if the full HTTP error details is
necessary for debugging purposes.

Adds `tailscale` status to the output of the `cb info` command.
When we switched to session based authentication from token based, we
introduced an undesired UX issue when a session expires. In summary,
when a session expires, the desired functionality is that the user will
be presented with a message indicating the expiration and prompted to
login in again.

While the first of these was occuring in the form of a formatted HTTP
error output the latter was not. Also, the form of the error was less
than desirable too.

Therefore, what we've done here is updated the error handling around
session expiration/unauthorized errors to prompt the user to login
again.  Also, we've taken the opporunity to clean up the error output of
other API errors as well such that it's presents the error. Use of
`HTTP_DEBUG` is still supported if the full HTTP error details is
necessary for debugging purposes.
@abrightwell abrightwell requested a review from a team as a code owner July 25, 2024 14:37
@abrightwell
Copy link
Member Author

Thanks.

@abrightwell abrightwell merged commit d9f45c6 into main Jul 26, 2024
2 checks passed
@abrightwell abrightwell deleted the abrightwell/fix-login-expired branch July 26, 2024 12:32
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

Successfully merging this pull request may close these issues.

2 participants