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

[Bug]: Inadequate error message for duplicate projects #1276

Closed
2 tasks done
eaxreg opened this issue Sep 9, 2023 · 0 comments
Closed
2 tasks done

[Bug]: Inadequate error message for duplicate projects #1276

eaxreg opened this issue Sep 9, 2023 · 0 comments
Labels
bug Something isn't working
Milestone

Comments

@eaxreg
Copy link

eaxreg commented Sep 9, 2023

What happened?

When attempting to create a new project, there is an issue with how duplicate projects in the working directory are handled. Currently the IDE is just displaying a generic "failed to create project" message without specific details or assistance. This lack of informative error feedback poses challenges for users trying to identify and rectify the issue efficiently.

What's the expected behavior?

The expected behavior should involve clear error messaging that highlights the presence of a duplicate project.

What version of AndroidIDE you're using?

v2.5.2 (debug builds)

Relevant log output

06-30 17:36:00.159 17313 17313 W System.err: java.util.concurrent.CompletionException: java.lang.IllegalArgumentException: Project directory already exists
06-30 17:36:00.160 17313 17313 W System.err: 	at com.itsaky.androidide.tasks.TaskExecutor.executeAsyncProvideError$lambda$2(TaskExecutor.kt:59)
06-30 17:36:00.160 17313 17313 W System.err: 	at com.itsaky.androidide.tasks.TaskExecutor.$r8$lambda$f3-4Gj0qijV9u6rZ4nrtqEYJ6HQ(Unknown Source:0)
06-30 17:36:00.160 17313 17313 W System.err: 	at com.itsaky.androidide.tasks.TaskExecutor$$ExternalSyntheticLambda0.get(Unknown Source:2)
06-30 17:36:00.160 17313 17313 W System.err: 	at java.util.concurrent.CompletableFuture$AsyncSupply.run(CompletableFuture.java:1627)
06-30 17:36:00.160 17313 17313 W System.err: 	at java.util.concurrent.CompletableFuture$AsyncSupply.exec(CompletableFuture.java:1619)
06-30 17:36:00.160 17313 17313 W System.err: 	at java.util.concurrent.ForkJoinTask.doExec(ForkJoinTask.java:285)
06-30 17:36:00.160 17313 17313 W System.err: 	at java.util.concurrent.ForkJoinPool$WorkQueue.runTask(ForkJoinPool.java:1155)
06-30 17:36:00.161 17313 17313 W System.err: 	at java.util.concurrent.ForkJoinPool.scan(ForkJoinPool.java:1993)
06-30 17:36:00.161 17313 17313 W System.err: 	at java.util.concurrent.ForkJoinPool.runWorker(ForkJoinPool.java:1941)
06-30 17:36:00.161 17313 17313 W System.err: 	at java.util.concurrent.ForkJoinWorkerThread.run(ForkJoinWorkerThread.java:157)
06-30 17:36:00.161 17313 17313 W System.err: Caused by: java.lang.IllegalArgumentException: Project directory already exists
06-30 17:36:00.161 17313 17313 W System.err: 	at com.itsaky.androidide.templates.base.BaseKt$baseProject$1$2.invoke(base.kt:102)
06-30 17:36:00.161 17313 17313 W System.err: 	at com.itsaky.androidide.templates.base.BaseKt$baseProject$1$2.invoke(base.kt:92)
06-30 17:36:00.161 17313 17313 W System.err: 	at com.itsaky.androidide.templates.base.PrePostRecipeTemplateBuilder._get_recipe_$lambda$0(templateBuilders.kt:42)
06-30 17:36:00.161 17313 17313 W System.err: 	at com.itsaky.androidide.templates.base.PrePostRecipeTemplateBuilder.$r8$lambda$PKrLUS4nIOtLUY9OZro0oKgjHnU(Unknown Source:0)
06-30 17:36:00.161 17313 17313 W System.err: 	at com.itsaky.androidide.templates.base.PrePostRecipeTemplateBuilder$$ExternalSyntheticLambda0.execute(Unknown Source:2)
06-30 17:36:00.162 17313 17313 W System.err: 	at com.itsaky.androidide.templates.ProjectTemplate._get_recipe_$lambda$6$lambda$5(template.kt:291)
06-30 17:36:00.162 17313 17313 W System.err: 	at com.itsaky.androidide.templates.ProjectTemplate.$r8$lambda$4MgEmKPnQM3QbSeq1hrv7bw7q_0(Unknown Source:0)
06-30 17:36:00.162 17313 17313 W System.err: 	at com.itsaky.androidide.templates.ProjectTemplate$$ExternalSyntheticLambda0.execute(Unknown Source:4)
06-30 17:36:00.162 17313 17313 W System.err: 	at com.itsaky.androidide.fragments.TemplateDetailsFragment$onViewCreated$4$1.invoke(TemplateDetailsFragment.kt:94)
06-30 17:36:00.162 17313 17313 W System.err: 	at com.itsaky.androidide.fragments.TemplateDetailsFragment$onViewCreated$4$1.invoke(TemplateDetailsFragment.kt:93)
06-30 17:36:00.162 17313 17313 W System.err: 	at com.itsaky.androidide.tasks.TaskExecutorKt.executeAsyncProvideError$lambda$2(TaskExecutor.kt:100)
06-30 17:36:00.162 17313 17313 W System.err: 	at com.itsaky.androidide.tasks.TaskExecutorKt.$r8$lambda$x7IXk6t6H_AV2CW63VkpPRkWyJ8(Unknown Source:0)
06-30 17:36:00.162 17313 17313 W System.err: 	at com.itsaky.androidide.tasks.TaskExecutorKt$$ExternalSyntheticLambda0.call(Unknown Source:2)
06-30 17:36:00.162 17313 17313 W System.err: 	at com.itsaky.androidide.tasks.TaskExecutor.executeAsyncProvideError$lambda$2(TaskExecutor.kt:56)
06-30 17:36:00.162 17313 17313 W System.err: 	... 9 more
06-30 17:36:00.163 17313 17313 E TemplateDetailsFragment:  Failed to create project. result=null, err=java.lang.IllegalArgumentException: Project directory already exists

Duplicate issues

  • This issue has not been reported yet.

Code of Conduct

  • I agree to follow this project's Code of Conduct
@eaxreg eaxreg added the bug Something isn't working label Sep 9, 2023
@itsaky itsaky added this to the v2.6.0-beta milestone Sep 10, 2023
@itsaky itsaky closed this as completed in 87c6e3b Sep 12, 2023
Ruan625Br pushed a commit to Ruan625Br/AndroidIDE that referenced this issue Sep 14, 2023
itsaky added a commit that referenced this issue Nov 9, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants