Flagsmith / flagsmith

Open Source Feature Flagging and Remote Config Service. Host on-prem or use our hosted version at https://flagsmith.com/
https://flagsmith.com/
BSD 3-Clause "New" or "Revised" License
4.61k stars 351 forks source link

Improve Error Handling for Unregistered Account Sign-In #4270

Open sumtzehern opened 2 weeks ago

sumtzehern commented 2 weeks ago

How are you running Flagsmith

Describe the bug

Currently, when a user attempts to sign in with an unregistered account, the application displays a generic "Server Error (500)" message in the toast notification. This error message is not user-friendly and does not provide helpful information to the user.

Steps To Reproduce

  1. Go to the sign-in page.
  2. Enter an invalid email and password (e.g. foo / bar).
  3. Submit the sign-in form.

Expected behavior

The application should display a toast notification with a clear and user-friendly error message, such as "Username provided is not a valid email."

Screenshots

Screenshot 2024-07-01 at 6 06 31 PM
matthewelwell commented 1 week ago

@sumtzehern I am unable to reproduce this behaviour, please can you provide further steps to reproduce this.

image
sumtzehern commented 1 week ago

This would happen when a user type in a Unregistered username, email would work fine.

image
matthewelwell commented 1 week ago

Ok, thanks - I've updated the description of the issue with further clarifications regarding this behaviour. If you'd like to submit a PR for this, please feel free to do so. Otherwise, since this isn't a valid use case (we don't support non-email address usernames), this will likely not be prioritised.