You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If an env-file does not exist, IntelliJ repeatedly throws a scary looking error due to plugin exception:
com.intellij.execution.ExecutionException: EnvFile: invalid path - environment.json
at net.ashald.envfile.platform.ui.EnvFileConfigurationEditor.validateConfiguration(EnvFileConfigurationEditor.java:151)
at net.ashald.envfile.products.idea.IdeaRunConfigurationExtension.validateConfiguration(IdeaRunConfigurationExtension.java:51)
at com.intellij.execution.configuration.RunConfigurationExtensionsManager.validateConfiguration(RunConfigurationExtensionsManager.java:127)
at com.intellij.execution.JavaRunConfigurationExtensionManager.checkConfigurationIsValid(JavaRunConfigurationExtensionManager.java:37)
at com.intellij.spring.boot.run.SpringBootApplicationRunConfiguration.checkConfiguration(SpringBootApplicationRunConfiguration.java:98)
at com.intellij.execution.impl.RunnerAndConfigurationSettingsImpl.checkSettings(RunnerAndConfigurationSettingsImpl.kt:321)
at com.intellij.execution.RunnerAndConfigurationSettings.checkSettings(RunnerAndConfigurationSettings.java:116)
at com.intellij.execution.impl.TimedIconCache.calcIcon(TimedIconCache.kt:66)
at com.intellij.execution.impl.TimedIconCache.access$calcIcon(TimedIconCache.kt:18)
at com.intellij.execution.impl.TimedIconCache$get$$inlined$write$lambda$1.fun(TimedIconCache.kt:50)
at com.intellij.execution.impl.TimedIconCache$get$$inlined$write$lambda$1.fun(TimedIconCache.kt:18)
at com.intellij.ui.DeferredIconImpl.evaluate(DeferredIconImpl.java:282)
at com.intellij.ui.DeferredIconImpl.lambda$null$0(DeferredIconImpl.java:167)
at com.intellij.ui.IconDeferrerImpl.evaluateDeferred(IconDeferrerImpl.java:114)
at com.intellij.ui.DeferredIconImpl.lambda$null$1(DeferredIconImpl.java:167)
at com.intellij.openapi.application.impl.ApplicationImpl.tryRunReadAction(ApplicationImpl.java:1161)
at com.intellij.openapi.progress.util.ProgressIndicatorUtils.lambda$runInReadActionWithWriteActionPriority$0(ProgressIndicatorUtils.java:70)
at com.intellij.openapi.progress.util.ProgressIndicatorUtils.lambda$runWithWriteActionPriority$1(ProgressIndicatorUtils.java:123)
at com.intellij.openapi.progress.impl.CoreProgressManager.lambda$runProcess$1(CoreProgressManager.java:157)
at com.intellij.openapi.progress.impl.CoreProgressManager.registerIndicatorAndRun(CoreProgressManager.java:580)
at com.intellij.openapi.progress.impl.CoreProgressManager.executeProcessUnderProgress(CoreProgressManager.java:525)
at com.intellij.openapi.progress.impl.ProgressManagerImpl.executeProcessUnderProgress(ProgressManagerImpl.java:85)
at com.intellij.openapi.progress.impl.CoreProgressManager.runProcess(CoreProgressManager.java:144)
at com.intellij.openapi.progress.util.ProgressIndicatorUtils.runWithWriteActionPriority(ProgressIndicatorUtils.java:112)
at com.intellij.openapi.progress.util.ProgressIndicatorUtils.runInReadActionWithWriteActionPriority(ProgressIndicatorUtils.java:70)
at com.intellij.openapi.progress.util.ProgressIndicatorUtils.runInReadActionWithWriteActionPriority(ProgressIndicatorUtils.java:91)
at com.intellij.ui.DeferredIconImpl.lambda$paintIcon$4(DeferredIconImpl.java:166)
at com.intellij.util.concurrency.BoundedTaskExecutor.doRun(BoundedTaskExecutor.java:226)
at com.intellij.util.concurrency.BoundedTaskExecutor.access$100(BoundedTaskExecutor.java:26)
at com.intellij.util.concurrency.BoundedTaskExecutor$2$1.run(BoundedTaskExecutor.java:199)
at com.intellij.util.ConcurrencyUtil.runUnderThreadName(ConcurrencyUtil.java:229)
at com.intellij.util.concurrency.BoundedTaskExecutor$2.run(BoundedTaskExecutor.java:193)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
at java.lang.Thread.run(Thread.java:745)
If error is dismissed, it will reappear once again and then again and again and again.
In my use-case, I have multiple services that I run, each with their own env file. This file is created only when I connect to a certain server, before I run the service locally (more specifically, using Telepresence to swap a service in a Kubernetes cluster and running it locally) and this file can be occasionally deleted - when I finish my session.
There are 2 different stacktrace patterns, the one I posted and another one that goes through a bunch of com.intellij.ui.mac.touchbar.* packages, I can add if it's of interest.
While I don't think that a missing env file should raise such a scary exception and instead either log a warning in the log once, or show a warning balloon when trying to run a Configuration with the missing file, I would also be fine with a config option to suppress this error.
The text was updated successfully, but these errors were encountered:
Unfortunately, this is one of those cases when there is no easy answer.
According to JetBrains API, extensions willing to perform run configuration validation are supposed to throw exceptions in a particular place. They used to catch particular sub-type of those exceptions and extract an error message. They're no longer doing that and just log exception as is so that it looks scary. I don't see any ways how I can address that gracefully at this time so for now I just added an option to skip validation and don't check if files exist. If files are missing they will be skipped during execution. Hope this helps.
This will be released with v3.1.0. I'm submitting an udpate right away but it usually takes couple of days for it to be published.
If an env-file does not exist, IntelliJ repeatedly throws a scary looking error due to plugin exception:
If error is dismissed, it will reappear once again and then again and again and again.
In my use-case, I have multiple services that I run, each with their own env file. This file is created only when I connect to a certain server, before I run the service locally (more specifically, using Telepresence to swap a service in a Kubernetes cluster and running it locally) and this file can be occasionally deleted - when I finish my session.
There are 2 different stacktrace patterns, the one I posted and another one that goes through a bunch of
com.intellij.ui.mac.touchbar.*
packages, I can add if it's of interest.While I don't think that a missing env file should raise such a scary exception and instead either log a warning in the log once, or show a warning balloon when trying to run a Configuration with the missing file, I would also be fine with a config option to suppress this error.
The text was updated successfully, but these errors were encountered: