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

New Project Wizard needs to check that SDK home path stil exists before listing it as a selectable SDK #3173

Closed
william-intelligencebank opened this issue Apr 12, 2023 · 4 comments · Fixed by #3271
Labels
Milestone

Comments

@william-intelligencebank

System

Plugin Version: 14.0.1
Application: IntelliJ IDEA Community Edition (2022.3.3)
Operating System: Mac OS X (13.3)

Event

Exception

Stacktrace

java.io.FileNotFoundException: /opt/homebrew/Cellar/erlang/25.2/lib/erlang/bin/erl does not exist
java.io.FileNotFoundException: /opt/homebrew/Cellar/erlang/25.2/lib/erlang/bin/erl does not exist
	at org.elixir_lang.jps.SdkType.exeFileToExePath(SdkType.java:21)
	at org.elixir_lang.jps.sdk_type.Erlang.homePathToErlExePath(Erlang.java:44)
	at org.elixir_lang.Erl.exePath(Erl.kt:31)
	at org.elixir_lang.Erl.setErl(Erl.kt:49)
	at org.elixir_lang.Erl.commandLine(Erl.kt:17)
	at org.elixir_lang.Elixir.commandLine(Elixir.kt:20)
	at org.elixir_lang.Mix.commandLine(Mix.kt:19)
	at org.elixir_lang.Mix.commandLine$default(Mix.kt:12)
	at org.elixir_lang.new_project_wizard.Step.setupProject(Step.kt:120)
	at com.intellij.ide.wizard.AbstractNewProjectWizardMultiStepBase.setupProject(AbstractNewProjectWizardMultiStepBase.kt:74)
	at com.intellij.ide.wizard.NewProjectWizardLanguageStep.setupProject(NewProjectWizardLanguageStep.kt:51)
	at com.intellij.ide.wizard.UIWizardUtil$stepSequence$1.setupProject(UIWizardUtil.kt:68)
	at com.intellij.ide.wizard.AbstractNewProjectWizardBuilder$commitModule$1.invoke(AbstractNewProjectWizardBuilder.kt:42)
	at com.intellij.ide.wizard.AbstractNewProjectWizardBuilder$commitModule$1.invoke(AbstractNewProjectWizardBuilder.kt:41)
	at com.intellij.ide.wizard.AbstractNewProjectWizardBuilder$Companion.detectCreatedModule(AbstractNewProjectWizardBuilder.kt:67)
	at com.intellij.ide.wizard.AbstractNewProjectWizardBuilder$Companion.access$detectCreatedModule(AbstractNewProjectWizardBuilder.kt:63)
	at com.intellij.ide.wizard.AbstractNewProjectWizardBuilder.commitModule(AbstractNewProjectWizardBuilder.kt:41)
	at com.intellij.openapi.roots.ui.configuration.actions.NewModuleAction.createModuleFromWizard(NewModuleAction.java:60)
@KronicDeth
Copy link
Owner

Was a /opt/homebrew/Cellar/erlang/25.2 a previously installed SDK that is no longer installed?

@william-intelligencebank
Copy link
Author

/opt/homebrew/Cellar/erlang/25.2.3 exists on my mac @KronicDeth

@KronicDeth
Copy link
Owner

It's looking for /opt/homebrew/Cellar/erlang/25.2 and not /opt/homebrew/Cellar/erlang/25.2.3 though, so the SDK just has the path for the version that was replaced on upgrade. I'll add a check that the SDK path is still valid before allowing users to select it in the New Project Wizard.

@KronicDeth KronicDeth changed the title java.io.FileNotFoundException: /opt/homebrew/Cellar/erlang/25.2/lib/erlang/bin/erl does not exist at org.elixir_lang.jps.SdkType.exeFileToExePath(SdkType.java:21) New Project Wizard needs to check that SDK home path stil exists before listing it as a selectable SDK Apr 17, 2023
@KronicDeth KronicDeth added this to the 15.0.1 milestone Apr 17, 2023
@william-intelligencebank
Copy link
Author

yes, just need to update under File -> Project Structure -> SDKs, thanks

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants