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

Implement an error handling mechanism #22

Closed
ArtyomVancyan opened this issue Sep 9, 2023 · 0 comments
Closed

Implement an error handling mechanism #22

ArtyomVancyan opened this issue Sep 9, 2023 · 0 comments
Assignees
Labels
documentation Improvements or additions to documentation enhancement New feature or request hacktoberfest Participating in Hacktoberfest

Comments

@ArtyomVancyan
Copy link
Member

ArtyomVancyan commented Sep 9, 2023

The only exception raised is the OAuth2LoginError exception that can occur when parsing the obtained token from the response. Library users must be able to handle the custom errors in their own way, whether they are building an SSR or REST API application.

@ArtyomVancyan ArtyomVancyan self-assigned this Sep 9, 2023
@ArtyomVancyan ArtyomVancyan added documentation Improvements or additions to documentation enhancement New feature or request labels Sep 9, 2023
ArtyomVancyan added a commit to ArtyomVancyan/fastapi-oauth2 that referenced this issue Sep 11, 2023
ArtyomVancyan added a commit to ArtyomVancyan/fastapi-oauth2 that referenced this issue Sep 11, 2023
@ArtyomVancyan ArtyomVancyan added the hacktoberfest Participating in Hacktoberfest label Oct 1, 2023
ArtyomVancyan added a commit to ArtyomVancyan/fastapi-oauth2 that referenced this issue Oct 6, 2023
ArtyomVancyan added a commit to ArtyomVancyan/fastapi-oauth2 that referenced this issue Oct 9, 2023
ArtyomVancyan added a commit to ArtyomVancyan/fastapi-oauth2 that referenced this issue Oct 9, 2023
ArtyomVancyan added a commit to ArtyomVancyan/fastapi-oauth2 that referenced this issue Oct 12, 2023
ArtyomVancyan added a commit to ArtyomVancyan/fastapi-oauth2 that referenced this issue Oct 12, 2023
ArtyomVancyan added a commit to ArtyomVancyan/fastapi-oauth2 that referenced this issue Oct 12, 2023
ArtyomVancyan added a commit to ArtyomVancyan/fastapi-oauth2 that referenced this issue Oct 12, 2023
ArtyomVancyan added a commit to ArtyomVancyan/fastapi-oauth2 that referenced this issue Oct 12, 2023
vokimon added a commit to vokimon/fastapi-oauth2 that referenced this issue Jul 30, 2024
That is:
- raising starlette.authentication.AuthenticationError
- providing an on_error callback turning starlet 400 into 401
  to keep same api
- letting the user provide their own on_error when instantiating
  the middleware.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation enhancement New feature or request hacktoberfest Participating in Hacktoberfest
Projects
Status: Done
Development

When branches are created from issues, their pull requests are automatically linked.

1 participant