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 regression in 0.2.0, rework logic for clarity #12

Merged
merged 2 commits into from
Aug 2, 2024

Conversation

Stormheg
Copy link
Member

Fixes #10

Replaces #11

While reviewing #11 and the surrounding code I wrote a couple months ago, I noticed some opportunities for improvement.

  • Some of the checks to see if we should allow authentication to proceed were duplicated among AuthenticationCeremonyMixin and the CompleteCredentialAuthenticationView. This PR addresses that.
  • Raise exceptions directly instead of a 'catch all' exception based on the return value of some boolean
  • Clean up (now) unused exception classes

- Raising exceptions directly allows for more fine-grained error
  reporting
- Reduce the spread of logic and try to keep things in one place.
@Stormheg
Copy link
Member Author

@jmichalicek would you like to review this?

Copy link
Contributor

@jmichalicek jmichalicek left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me and all seems to be working when I run through it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

Passwordless authentication fails due to AuthenticationDisabled exception
2 participants