console icon indicating copy to clipboard operation
console copied to clipboard

🐛 Bug Report: Project creates two times

Open Honzoraptor31415 opened this issue 10 months ago • 3 comments

👟 Reproduction steps

  1. Go to the console https://cloud.appwrite.io/console
  2. Click "Create project"
  3. Go trough the setup proccess

👍 Expected behavior

It should take me to the new project page right after clicking the button (of course with some delay because of some async stuff).

👎 Actual Behavior

At the end after clicking the "Create" button, nothing happens even after waiting a few seconds, but after I click it the second time, it takes me to the new project page. However now when I go to the console again, I can see two projects named the same, even tho I just wanted created one.

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

  • [X] I checked and didn't find similar issue

🏢 Have you read the Code of Conduct?

Also I apologise for accidentally creating the issue in the website repo, I had to move it here

Honzoraptor31415 avatar Apr 14 '24 15:04 Honzoraptor31415

Can reproduce this, probably a state management issue which re-enables the Create button before the setup is completed.

I proceeded to click the Create three times and 3 projects were created. Also note, if you provide a Project ID then the multiple projects will not be created and an error will be thrown.

Probable source - https://github.com/appwrite/console/blob/737457c1446318c4f39fcc373024537af1bc09b6/src/lib/layout/wizard.svelte#L103-L105

ItzNotABug avatar Apr 14 '24 16:04 ItzNotABug

Can reproduce this, probably a state management issue which re-enables the Create button before the setup is completed.

I proceeded to click the Create three times and 3 projects were created. Also note, if you provide a Project ID then the multiple projects will not be created and an error will be thrown.

Probable source -

https://github.com/appwrite/console/blob/737457c1446318c4f39fcc373024537af1bc09b6/src/lib/layout/wizard.svelte#L103-L105

Does the setTimeout() function have any purpose? Because I feel like this part of code doesn't make sense with the timeout there.

Also is the timeout really the cause if this? As I already mentioned, it doesn't even work after waiting a few seconds.

Honzoraptor31415 avatar Apr 15 '24 05:04 Honzoraptor31415

@Honzoraptor31415 I took a look at the source and it seems that timeout might be the issue but I am not 100% sure on that. Lets wait till a core member bumps in.

ItzNotABug avatar Apr 15 '24 06:04 ItzNotABug

This is fixed in a recent release

ernstmul avatar Sep 09 '24 12:09 ernstmul