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 you are submitting a bug, please include the following:
summary of problem
If you use one version of spotless (e.g. 3.15.0-SNAPSHOT)
and you run a spotlessApply that uses an npm rule
then use a new version (e.g. 3.15.0)
and you run a spotlessApply that uses an npm rule
then you'll get the stacktrace copy-pasted later in this bug.
The workaround is easy, just run gradlew --stop to kill the old daemon. Better would be to catch the error and tell the user "You can fix this with 'gradlew --stop'". Best would be to fix it.
Not a high priority issue. :)
gradle or maven version: 4.10.2
spotless version: 3.15.0
operating system and version: macOS 10.13.6
copy-paste your full Spotless configuration block(s), and a link to a public git repo that reproduces the problem if possible
spotless {
format 'scss', {
target 'src/main/styles/**/*.scss'
prettier().config(['parser': 'postcss'])
}
format 'typescript', {
target 'src/main/scripts/**'
prettier().config(['parser': 'typescript'])
}
}
copy-paste the full content of any console errors emitted by gradlew spotless[Apply/Check] --stacktrace
Caused by: java.lang.IllegalStateException: J2V8 native library not loaded
at com.eclipsesource.v8.V8.checkNativeLibraryLoaded(V8.java:195)
at com.eclipsesource.v8.V8.createV8Runtime(V8.java:149)
at com.eclipsesource.v8.V8.createV8Runtime(V8.java:125)
at com.eclipsesource.v8.NodeJS.createNodeJS(NodeJS.java:58)
at com.eclipsesource.v8.NodeJS.createNodeJS(NodeJS.java:45)
at com.diffplug.spotless.npm.Reflective.invokeStaticMethod(Reflective.java:56)
at com.diffplug.spotless.npm.NodeJSWrapper.lambda$new$0(NodeJSWrapper.java:39)
at com.diffplug.spotless.npm.ReflectiveObjectWrapper.<init>(ReflectiveObjectWrapper.java:34)
at com.diffplug.spotless.npm.NodeJSWrapper.<init>(NodeJSWrapper.java:33)
at com.diffplug.spotless.npm.NpmFormatterStepStateBase.nodeJSWrapper(NpmFormatterStepStateBase.java:95)
at com.diffplug.spotless.npm.PrettierFormatterStep$State.createFormatterFunc(PrettierFormatterStep.java:68)
at com.diffplug.spotless.FormatterStepImpl$Standard.format(FormatterStepImpl.java:76)
at com.diffplug.spotless.FormatterStep$Strict.format(FormatterStep.java:76)
at com.diffplug.spotless.Formatter.compute(Formatter.java:230)
at com.diffplug.spotless.Formatter.applyToAndReturnResultIfDirty(Formatter.java:192)
at com.diffplug.gradle.spotless.SpotlessTask.applyAnyChanged(SpotlessTask.java:230)
at com.diffplug.gradle.spotless.SpotlessTask.performAction(SpotlessTask.java:193)
at org.gradle.internal.reflect.JavaMethod.invoke(JavaMethod.java:73)
at org.gradle.api.internal.project.taskfactory.IncrementalTaskAction.doExecute(IncrementalTaskAction.java:50)
at org.gradle.api.internal.project.taskfactory.StandardTaskAction.execute(StandardTaskAction.java:39)
at org.gradle.api.internal.project.taskfactory.StandardTaskAction.execute(StandardTaskAction.java:26)
at org.gradle.api.internal.tasks.execution.ExecuteActionsTaskExecuter$1.run(ExecuteActionsTaskExecuter.java:131)
at org.gradle.internal.operations.DefaultBuildOperationExecutor$RunnableBuildOperationWorker.execute(DefaultBuildOperationExecutor.java:300)
at org.gradle.internal.operations.DefaultBuildOperationExecutor$RunnableBuildOperationWorker.execute(DefaultBuildOperationExecutor.java:292)
at org.gradle.internal.operations.DefaultBuildOperationExecutor.execute(DefaultBuildOperationExecutor.java:174)
at org.gradle.internal.operations.DefaultBuildOperationExecutor.run(DefaultBuildOperationExecutor.java:90)
at org.gradle.internal.operations.DelegatingBuildOperationExecutor.run(DelegatingBuildOperationExecutor.java:31)
at org.gradle.api.internal.tasks.execution.ExecuteActionsTaskExecuter.executeAction(ExecuteActionsTaskExecuter.java:120)
at org.gradle.api.internal.tasks.execution.ExecuteActionsTaskExecuter.executeActions(ExecuteActionsTaskExecuter.java:99)
at org.gradle.api.internal.tasks.execution.ExecuteActionsTaskExecuter.execute(ExecuteActionsTaskExecuter.java:77)
at org.gradle.api.internal.tasks.execution.OutputDirectoryCreatingTaskExecuter.execute(OutputDirectoryCreatingTaskExecuter.java:51)
at org.gradle.api.internal.tasks.execution.SkipUpToDateTaskExecuter.execute(SkipUpToDateTaskExecuter.java:59)
at org.gradle.api.internal.tasks.execution.ResolveTaskOutputCachingStateExecuter.execute(ResolveTaskOutputCachingStateExecuter.java:54)
at org.gradle.api.internal.tasks.execution.ValidatingTaskExecuter.execute(ValidatingTaskExecuter.java:59)
at org.gradle.api.internal.tasks.execution.SkipEmptySourceFilesTaskExecuter.execute(SkipEmptySourceFilesTaskExecuter.java:101)
at org.gradle.api.internal.tasks.execution.FinalizeInputFilePropertiesTaskExecuter.execute(FinalizeInputFilePropertiesTaskExecuter.java:44)
at org.gradle.api.internal.tasks.execution.CleanupStaleOutputsExecuter.execute(CleanupStaleOutputsExecuter.java:91)
at org.gradle.api.internal.tasks.execution.ResolveTaskArtifactStateTaskExecuter.execute(ResolveTaskArtifactStateTaskExecuter.java:62)
at org.gradle.api.internal.tasks.execution.SkipTaskWithNoActionsExecuter.execute(SkipTaskWithNoActionsExecuter.java:59)
at org.gradle.api.internal.tasks.execution.SkipOnlyIfTaskExecuter.execute(SkipOnlyIfTaskExecuter.java:54)
at org.gradle.api.internal.tasks.execution.ExecuteAtMostOnceTaskExecuter.execute(ExecuteAtMostOnceTaskExecuter.java:43)
at org.gradle.api.internal.tasks.execution.CatchExceptionTaskExecuter.execute(CatchExceptionTaskExecuter.java:34)
at org.gradle.api.internal.tasks.execution.EventFiringTaskExecuter$1.run(EventFiringTaskExecuter.java:51)
at org.gradle.internal.operations.DefaultBuildOperationExecutor$RunnableBuildOperationWorker.execute(DefaultBuildOperationExecutor.java:300)
at org.gradle.internal.operations.DefaultBuildOperationExecutor$RunnableBuildOperationWorker.execute(DefaultBuildOperationExecutor.java:292)
at org.gradle.internal.operations.DefaultBuildOperationExecutor.execute(DefaultBuildOperationExecutor.java:174)
at org.gradle.internal.operations.DefaultBuildOperationExecutor.run(DefaultBuildOperationExecutor.java:90)
at org.gradle.internal.operations.DelegatingBuildOperationExecutor.run(DelegatingBuildOperationExecutor.java:31)
at org.gradle.api.internal.tasks.execution.EventFiringTaskExecuter.execute(EventFiringTaskExecuter.java:46)
at org.gradle.execution.taskgraph.LocalTaskInfoExecutor.execute(LocalTaskInfoExecutor.java:42)
at org.gradle.execution.taskgraph.DefaultTaskExecutionGraph$BuildOperationAwareWorkItemExecutor.execute(DefaultTaskExecutionGraph.java:277)
at org.gradle.execution.taskgraph.DefaultTaskExecutionGraph$BuildOperationAwareWorkItemExecutor.execute(DefaultTaskExecutionGraph.java:262)
at org.gradle.execution.taskgraph.DefaultTaskPlanExecutor$ExecutorWorker$1.execute(DefaultTaskPlanExecutor.java:135)
at org.gradle.execution.taskgraph.DefaultTaskPlanExecutor$ExecutorWorker$1.execute(DefaultTaskPlanExecutor.java:130)
at org.gradle.execution.taskgraph.DefaultTaskPlanExecutor$ExecutorWorker.execute(DefaultTaskPlanExecutor.java:200)
at org.gradle.execution.taskgraph.DefaultTaskPlanExecutor$ExecutorWorker.executeWithWork(DefaultTaskPlanExecutor.java:191)
at org.gradle.execution.taskgraph.DefaultTaskPlanExecutor$ExecutorWorker.run(DefaultTaskPlanExecutor.java:130)
at org.gradle.internal.concurrent.ExecutorPolicy$CatchAndRecordFailures.onExecute(ExecutorPolicy.java:63)
at org.gradle.internal.concurrent.ManagedExecutorImpl$1.run(ManagedExecutorImpl.java:46)
at org.gradle.internal.concurrent.ThreadFactoryImpl$ManagedThreadRunnable.run(ThreadFactoryImpl.java:55)
Caused by: java.lang.UnsatisfiedLinkError: Could not load J2V8 library. Reasons:
no j2v8_macosx_x86_64 in java.library.path
Native Library /Users/ntwigg/libj2v8_macosx_x86_64.dylib already loaded in another classloader
at com.eclipsesource.v8.LibraryLoader.loadLibrary(LibraryLoader.java:75)
at com.eclipsesource.v8.V8.load(V8.java:71)
at com.eclipsesource.v8.V8.createV8Runtime(V8.java:145)
... 58 more
The text was updated successfully, but these errors were encountered:
This seems like a very promising tool, but unfortunately I get this error simply by running the exact same build twice (different daemon). As it stands, this bug makes the tool unusable to me and my team.
Using version 3.30.0 with Gradle 6.4.0 and kotlin dsl.
As a side-note I should add that to get it running at all I had to configure "parser" to "babylon", and have it overridden to "typescript" by the plugin (or lib?), or else a java.lang.reflect.InvocationTargetException is thrown - this happens both when parser is unspecified in the config, as well as when it's specified as "typescript".
If you are submitting a bug, please include the following:
summary of problem
3.15.0-SNAPSHOT
)spotlessApply
that uses an npm rule3.15.0
)spotlessApply
that uses an npm ruleThe workaround is easy, just run
gradlew --stop
to kill the old daemon. Better would be to catch the error and tell the user "You can fix this with 'gradlew --stop'". Best would be to fix it.Not a high priority issue. :)
4.10.2
3.15.0
macOS 10.13.6
Public repo is here.
gradlew spotless[Apply/Check] --stacktrace
The text was updated successfully, but these errors were encountered: