Improve authentication error messages that are shown to users #86
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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.