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

handle 409 error in settings flow #1107

Closed
williamohara opened this issue Mar 1, 2021 · 6 comments
Closed

handle 409 error in settings flow #1107

williamohara opened this issue Mar 1, 2021 · 6 comments
Labels
bug Something is not working. good first issue A good issue to tackle when being a novice to the project. help wanted We are looking for help on this one.

Comments

@williamohara
Copy link

williamohara commented Mar 1, 2021

Is your feature request related to a problem? Please describe.

if a user tries to sign up with the same identifier twice using the registration flow, a message is returned
id: 4000007 text: "An account with the same identifier (email, phone, username, ...) exists already." type: "error"
if a user tires to update their identifier in the settings flow, the error flow is started returning a less descript error message

code: 409 message: "Unable to insert or update resource because a resource with that value exists already" status: "Conflict"
Describe the solution you'd like

handle the 409 error in the settings flow and make it parallel to the registration flow. Return a message in the settings flow under the methods.profile.config.messages

Describe alternatives you've considered

Additional context

I am using the Admin endpoint for settings flow i tried with the public endpoint and same

@aeneasr
Copy link
Member

aeneasr commented Mar 2, 2021

Yup, that should be fixed!

@aeneasr aeneasr added bug Something is not working. good first issue A good issue to tackle when being a novice to the project. help wanted We are looking for help on this one. labels Mar 2, 2021
@aeneasr aeneasr added this to the v0.7.0-alpha.1 milestone Mar 2, 2021
@williamohara
Copy link
Author

I am building an authentication service for my project on top of kratos. I am going to integrate with hydra and possibly keto too. I have built my auth FE app from scratch and I think that it would be a good idea to get to know your code a bit better AND learn Go ( I am just beginning to learn it) I think that this would be a good one as you already have messages for other flows - it would be just repeating the pattern. I'm going to fork and give it a try. Hopefully you will see a pull request soon. I have never done an open source contribution before either 😮 so it will be my first.

@aeneasr
Copy link
Member

aeneasr commented Mar 5, 2021

Awesome! I think it will be a great learning experience! And you can't do anything wrong - just give it your best try and we'll continuously improve it :)

@williamohara
Copy link
Author

Seems to only be a problem when using MySQL

@williamohara
Copy link
Author

williamohara commented Mar 24, 2021

@aeneasr I finally got back to this. I set up my dev environment and built off of the latest code - and I could not reproduce this bug. I looked back at the commits since the last release.. (docker pull oryd/kratos:latest-sqlite) and it seems that this issue is a duplicate of this issue #694. Which was already fixed..

I guess I'll need to find another way to contribute :)

@aeneasr
Copy link
Member

aeneasr commented Mar 24, 2021

Thank you for getting back!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something is not working. good first issue A good issue to tackle when being a novice to the project. help wanted We are looking for help on this one.
Projects
None yet
Development

No branches or pull requests

2 participants