Skip to content

Improve authentication error messages that are shown to users #86

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

Merged
merged 4 commits into from
Jan 26, 2021

Conversation

interstateone
Copy link
Contributor

@interstateone interstateone commented Jan 26, 2021

This PR makes two changes:

Improve how auth errors are shown in an Alert. They all provide their own descriptions now, where before some of them would default to String(describing:) which didn't do a great job. I also removed some of the associated values from the descriptions because while it might be useful for debugging, it is not immediately helpful for users. We may want to find another way to provide users with this information, even if it's how to find it in Console.app, in the future. A 400 status code during security code submission is now treated as an "incorrect code" error. I'm not sure why it wasn't before, as I thought this implementation was just taken from xcodes, but when I tested this situation I got a 400 instead of a 401.

Added bug report and feature request items to the Help menu so it's easier for users to find these options and so that we can refer to them in error messages.

@interstateone interstateone added the bugfix Fixes a bug label Jan 26, 2021
Copy link
Contributor

@MattKiazyk MattKiazyk left a comment

Choose a reason for hiding this comment

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

I tried a few different ways to error and work as advertised.

I did in my testing find a new bug which is created in #88

@interstateone
Copy link
Contributor Author

Interesting, good catch Matt. Looking again at the Preferences library I see what I did wrong.

@interstateone interstateone merged commit b27b0bf into main Jan 26, 2021
@interstateone interstateone deleted the improve-auth-errors branch January 26, 2021 15:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bugfix Fixes a bug
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants