8000 🐛 Bug Report: Getting user_already_exists error while creating user from Flutter SDK · Issue #6374 · appwrite/appwrite · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content
8000

🐛 Bug Report: Getting user_already_exists error while creating user from Flutter SDK #6374

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

Open
2 tasks done
chakshumraval opened this issue Sep 30, 2023 · 4 comments
Open
2 tasks done
Assignees
Labels
bug Something isn't working product / auth Fixes and upgrades for the Appwrite Auth / Users / Teams services.

Comments

@chakshumraval
Copy link

👟 Reproduction steps

When I create user first time, it is working perfectly. when I again do that, it is showing error that user_already_exists.

await account.create(
          userId: DateTime.now().microsecondsSinceEpoch.toString(),
          email: email,
          password: password,
          name: username);

When I create user for first time, let's say name with "user1" and there different mail id,Uniq id and phone number, It is creating perfectly.

When I try to create for second user, with all different details, It is giving error "users_already_exists"

Can someone please look into this?

👍 Expected behavior

It should allow to create n number of users without giving error

👎 Actual Behavior

it actually giving error when creating another user from device side

🎲 Appwrite version

Version 1.4.x

💻 Operating system

Linux

🧱 Your Environment

I hosted Appwrite on my linux server. I am calling api through flutter SDK from flutter code base

👀 Have you spent some time to check if this issue has been raised before?

  • I checked and didn't find similar issue

🏢 Have you read the Code of Conduct?

@safwanyp
Copy link
Contributor
safwanyp commented Oct 1, 2023

@chakshumraval Why are you using DateTime.now().microsecondsSinceEpoch.toString() for the user ID?
This can cause problems in a large scale, when multiple people try to signup at the same time.

Try to use the ID.unique() helper that comes with the Appwrite SDK, and see if it fixes the issue!

@chakshumraval
Copy link
Author

@safwanyp , I have done that initially but changed due to this issue. I have checked with ID.unique() issue is still replicable

@safwanyp
Copy link
Contributor
safwanyp commented Oct 3, 2023

@chakshumraval I recommend that you join the Discord Server and make a post in the #support channel for this issue.

@stnguyen90 stnguyen90 added the product / auth Fixes and upgrades for the Appwrite Auth / Users / Teams services. label Feb 16, 2024
@stnguyen90
Copy link
Contributor

@chakshumraval, are you still having this problem? Did you create a support post on our Discord server?

@stnguyen90 stnguyen90 self-assigned this Feb 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working product / auth Fixes and upgrades for the Appwrite Auth / Users / Teams services.
Projects
None yet
Development

No branches or pull requests

3 participants
0