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

0.13.0 nativeCompile failing, unable to find index.json #1464

Open
slithernix opened this issue Feb 20, 2024 · 22 comments
Open

0.13.0 nativeCompile failing, unable to find index.json #1464

slithernix opened this issue Feb 20, 2024 · 22 comments

Comments

@slithernix
Copy link

Got this weird exception related to some type of dependency for an index.json in the root of the checkout... I grep'd for index.json no mention of it anywhere I could find so I don't really know what would pull that in and what requires it. Here is the stacktrace:

#36 [build 30/36] RUN ./gradlew --stacktrace -Djava.net.preferIPv4Stack=true nativeCompile
#36 0.314 Downloading https://services.gradle.org/distributions/gradle-8.6-bin.zip
#36 1.069 ............10%.............20%............30%.............40%.............50%............60%.............70%.............80%............90%.............100%
#36 6.613 
#36 6.613 Welcome to Gradle 8.6!
#36 6.613 
#36 6.613 Here are the highlights of this release:
#36 6.613  - Configurable encryption key for configuration cache
#36 6.613  - Build init improvements
#36 6.613  - Build authoring improvements
#36 6.613 
#36 6.613 For more details see https://docs.gradle.org/8.6/release-notes.html
#36 6.613 
#36 6.712 Starting a Gradle Daemon (subsequent builds will be faster)
#36 34.31 > Task :buildSrc:checkKotlinGradlePluginConfigurationErrors
#36 38.71 > Task :buildSrc:pluginDescriptors
#36 38.81 > Task :buildSrc:processResources
#36 42.91 > Task :buildSrc:compileKotlin
#36 42.91 > Task :buildSrc:compileJava NO-SOURCE
#36 42.91 > Task :buildSrc:compileGroovy NO-SOURCE
#36 42.91 > Task :buildSrc:classes
#36 42.91 > Task :buildSrc:jar
#36 51.31 
#36 51.31 FAILURE: Build failed with an exception.
#36 51.31 
#36 51.31 * What went wrong:
#36 51.31 Could not determine the dependencies of task ':nativeCompile'.
#36 51.31 > java.nio.file.NoSuchFileException: /signal-cli/index.json
#36 51.31 
#36 51.31 * Try:
#36 51.31 > Run with --info or --debug option to get more log output.
#36 51.31 > Run with --scan to get full insights.
#36 51.31 > Get more help at https://help.gradle.org.
#36 51.31 
#36 51.31 * Exception is:
#36 51.31 org.gradle.api.internal.tasks.TaskDependencyResolveException: Could not determine the dependencies of task ':nativeCompile'.
#36 51.31 	at org.gradle.api.internal.tasks.CachingTaskDependencyResolveContext.getDependencies(CachingTaskDependencyResolveContext.java:68)
#36 51.31 	at org.gradle.execution.plan.TaskDependencyResolver.resolveDependenciesFor(TaskDependencyResolver.java:49)
#36 51.31 	at org.gradle.execution.plan.LocalTaskNode.getDependencies(LocalTaskNode.java:148)
#36 51.31 	at org.gradle.execution.plan.LocalTaskNode.resolveDependencies(LocalTaskNode.java:122)
#36 51.31 	at org.gradle.execution.plan.DefaultExecutionPlan.discoverNodeRelationships(DefaultExecutionPlan.java:182)
#36 51.31 	at org.gradle.execution.plan.DefaultExecutionPlan.doAddEntryNodes(DefaultExecutionPlan.java:154)
#36 51.31 	at org.gradle.execution.plan.DefaultExecutionPlan.addEntryTasks(DefaultExecutionPlan.java:129)
#36 51.31 	at org.gradle.execution.plan.DefaultExecutionPlan.addEntryTasks(DefaultExecutionPlan.java:121)
#36 51.31 	at org.gradle.execution.TaskNameResolvingBuildTaskScheduler.scheduleRequestedTasks(TaskNameResolvingBuildTaskScheduler.java:54)
#36 51.31 	at org.gradle.execution.DefaultTasksBuildTaskScheduler.scheduleRequestedTasks(DefaultTasksBuildTaskScheduler.java:72)
#36 51.31 	at org.gradle.initialization.DefaultTaskExecutionPreparer.lambda$scheduleRequestedTasks$0(DefaultTaskExecutionPreparer.java:46)
#36 51.31 	at org.gradle.internal.Factories$1.create(Factories.java:31)
#36 51.31 	at org.gradle.internal.work.DefaultWorkerLeaseService.withReplacedLocks(DefaultWorkerLeaseService.java:360)
#36 51.31 	at org.gradle.api.internal.project.DefaultProjectStateRegistry$DefaultBuildProjectRegistry.withMutableStateOfAllProjects(DefaultProjectStateRegistry.java:240)
#36 51.31 	at org.gradle.api.internal.project.DefaultProjectStateRegistry$DefaultBuildProjectRegistry.withMutableStateOfAllProjects(DefaultProjectStateRegistry.java:233)
#36 51.31 	at org.gradle.initialization.DefaultTaskExecutionPreparer.scheduleRequestedTasks(DefaultTaskExecutionPreparer.java:45)
#36 51.31 	at org.gradle.initialization.VintageBuildModelController.lambda$scheduleRequestedTasks$0(VintageBuildModelController.java:76)
#36 51.31 	at org.gradle.internal.model.StateTransitionController.lambda$inState$1(StateTransitionController.java:99)
#36 51.31 	at org.gradle.internal.model.StateTransitionController.lambda$inState$2(StateTransitionController.java:114)
#36 51.31 	at org.gradle.internal.work.DefaultSynchronizer.withLock(DefaultSynchronizer.java:44)
#36 51.31 	at org.gradle.internal.model.StateTransitionController.inState(StateTransitionController.java:110)
#36 51.31 	at org.gradle.internal.model.StateTransitionController.inState(StateTransitionController.java:98)
#36 51.31 	at org.gradle.initialization.VintageBuildModelController.scheduleRequestedTasks(VintageBuildModelController.java:76)
#36 51.31 	at org.gradle.internal.build.DefaultBuildLifecycleController$DefaultWorkGraphBuilder.addRequestedTasks(DefaultBuildLifecycleController.java:404)
#36 51.31 	at org.gradle.internal.buildtree.DefaultBuildTreeWorkPreparer.lambda$scheduleRequestedTasks$0(DefaultBuildTreeWorkPreparer.java:41)
#36 51.31 	at org.gradle.internal.build.DefaultBuildLifecycleController.lambda$populateWorkGraph$7(DefaultBuildLifecycleController.java:189)
#36 51.31 	at org.gradle.internal.build.DefaultBuildWorkPreparer.populateWorkGraph(DefaultBuildWorkPreparer.java:42)
#36 51.31 	at org.gradle.internal.build.BuildOperationFiringBuildWorkPreparer$PopulateWorkGraph.populateTaskGraph(BuildOperationFiringBuildWorkPreparer.java:106)
#36 51.31 	at org.gradle.internal.build.BuildOperationFiringBuildWorkPreparer$PopulateWorkGraph.run(BuildOperationFiringBuildWorkPreparer.java:92)
#36 51.31 	at org.gradle.internal.operations.DefaultBuildOperationRunner$1.execute(DefaultBuildOperationRunner.java:29)
#36 51.31 	at org.gradle.internal.operations.DefaultBuildOperationRunner$1.execute(DefaultBuildOperationRunner.java:26)
#36 51.31 	at org.gradle.internal.operations.DefaultBuildOperationRunner$2.execute(DefaultBuildOperationRunner.java:66)
#36 51.31 	at org.gradle.internal.operations.DefaultBuildOperationRunner$2.execute(DefaultBuildOperationRunner.java:59)
#36 51.31 	at org.gradle.internal.operations.DefaultBuildOperationRunner.execute(DefaultBuildOperationRunner.java:157)
#36 51.32 	at org.gradle.internal.operations.DefaultBuildOperationRunner.execute(DefaultBuildOperationRunner.java:59)
#36 51.32 	at org.gradle.internal.operations.DefaultBuildOperationRunner.run(DefaultBuildOperationRunner.java:47)
#36 51.32 	at org.gradle.internal.operations.DefaultBuildOperationExecutor.run(DefaultBuildOperationExecutor.java:68)
#36 51.32 	at org.gradle.internal.build.BuildOperationFiringBuildWorkPreparer.populateWorkGraph(BuildOperationFiringBuildWorkPreparer.java:67)
#36 51.32 	at org.gradle.internal.build.DefaultBuildLifecycleController.lambda$populateWorkGraph$8(DefaultBuildLifecycleController.java:189)
#36 51.32 	at org.gradle.internal.model.StateTransitionController.lambda$inState$1(StateTransitionController.java:99)
#36 51.32 	at org.gradle.internal.model.StateTransitionController.lambda$inState$2(StateTransitionController.java:114)
#36 51.32 	at org.gradle.internal.work.DefaultSynchronizer.withLock(DefaultSynchronizer.java:44)
#36 51.32 	at org.gradle.internal.model.StateTransitionController.inState(StateTransitionController.java:110)
#36 51.32 	at org.gradle.internal.model.StateTransitionController.inState(StateTransitionController.java:98)
#36 51.32 	at org.gradle.internal.build.DefaultBuildLifecycleController.populateWorkGraph(DefaultBuildLifecycleController.java:189)
#36 51.32 	at org.gradle.internal.build.DefaultBuildWorkGraphController$DefaultBuildWorkGraph.populateWorkGraph(DefaultBuildWorkGraphController.java:169)
#36 51.32 	at org.gradle.composite.internal.DefaultBuildController.populateWorkGraph(DefaultBuildController.java:76)
#36 51.32 	at org.gradle.composite.internal.DefaultIncludedBuildTaskGraph$DefaultBuildTreeWorkGraphBuilder.withWorkGraph(DefaultIncludedBuildTaskGraph.java:153)
#36 51.32 	at org.gradle.internal.buildtree.DefaultBuildTreeWorkPreparer.lambda$scheduleRequestedTasks$1(DefaultBuildTreeWorkPreparer.java:41)
#36 51.32 	at org.gradle.composite.internal.DefaultIncludedBuildTaskGraph$DefaultBuildTreeWorkGraph$1.run(DefaultIncludedBuildTaskGraph.java:209)
#36 51.32 	at org.gradle.internal.operations.DefaultBuildOperationRunner$1.execute(DefaultBuildOperationRunner.java:29)
#36 51.32 	at org.gradle.internal.operations.DefaultBuildOperationRunner$1.execute(DefaultBuildOperationRunner.java:26)
#36 51.32 	at org.gradle.internal.operations.DefaultBuildOperationRunner$2.execute(DefaultBuildOperationRunner.java:66)
#36 51.32 	at org.gradle.internal.operations.DefaultBuildOperationRunner$2.execute(DefaultBuildOperationRunner.java:59)
#36 51.32 	at org.gradle.internal.operations.DefaultBuildOperationRunner.execute(DefaultBuildOperationRunner.java:157)
#36 51.32 	at org.gradle.internal.operations.DefaultBuildOperationRunner.execute(DefaultBuildOperationRunner.java:59)
#36 51.32 	at org.gradle.internal.operations.DefaultBuildOperationRunner.run(DefaultBuildOperationRunner.java:47)
#36 51.32 	at org.gradle.internal.operations.DefaultBuildOperationExecutor.run(DefaultBuildOperationExecutor.java:68)
#36 51.32 	at org.gradle.composite.internal.DefaultIncludedBuildTaskGraph$DefaultBuildTreeWorkGraph.scheduleWork(DefaultIncludedBuildTaskGraph.java:204)
#36 51.32 	at org.gradle.internal.buildtree.DefaultBuildTreeWorkPreparer.scheduleRequestedTasks(DefaultBuildTreeWorkPreparer.java:37)
#36 51.32 	at org.gradle.configurationcache.VintageBuildTreeWorkController$scheduleAndRunRequestedTasks$1.apply(VintageBuildTreeWorkController.kt:36)
#36 51.32 	at org.gradle.configurationcache.VintageBuildTreeWorkController$scheduleAndRunRequestedTasks$1.apply(VintageBuildTreeWorkController.kt:35)
#36 51.32 	at org.gradle.composite.internal.DefaultIncludedBuildTaskGraph.withNewWorkGraph(DefaultIncludedBuildTaskGraph.java:112)
#36 51.32 	at org.gradle.configurationcache.VintageBuildTreeWorkController.scheduleAndRunRequestedTasks(VintageBuildTreeWorkController.kt:35)
#36 51.32 	at org.gradle.internal.buildtree.DefaultBuildTreeLifecycleController.lambda$scheduleAndRunTasks$1(DefaultBuildTreeLifecycleController.java:76)
#36 51.32 	at org.gradle.internal.buildtree.DefaultBuildTreeLifecycleController.lambda$runBuild$4(DefaultBuildTreeLifecycleController.java:119)
#36 51.32 	at org.gradle.internal.model.StateTransitionController.lambda$transition$6(StateTransitionController.java:169)
#36 51.32 	at org.gradle.internal.model.StateTransitionController.doTransition(StateTransitionController.java:266)
#36 51.32 	at org.gradle.internal.model.StateTransitionController.lambda$transition$7(StateTransitionController.java:169)
#36 51.32 	at org.gradle.internal.work.DefaultSynchronizer.withLock(DefaultSynchronizer.java:44)
#36 51.32 	at org.gradle.internal.model.StateTransitionController.transition(StateTransitionController.java:169)
#36 51.32 	at org.gradle.internal.buildtree.DefaultBuildTreeLifecycleController.runBuild(DefaultBuildTreeLifecycleController.java:116)
#36 51.32 	at org.gradle.internal.buildtree.DefaultBuildTreeLifecycleController.scheduleAndRunTasks(DefaultBuildTreeLifecycleController.java:76)
#36 51.32 	at org.gradle.internal.buildtree.DefaultBuildTreeLifecycleController.scheduleAndRunTasks(DefaultBuildTreeLifecycleController.java:71)
#36 51.32 	at org.gradle.tooling.internal.provider.ExecuteBuildActionRunner.run(ExecuteBuildActionRunner.java:31)
#36 51.32 	at org.gradle.launcher.exec.ChainingBuildActionRunner.run(ChainingBuildActionRunner.java:35)
#36 51.32 	at org.gradle.internal.buildtree.ProblemReportingBuildActionRunner.run(ProblemReportingBuildActionRunner.java:49)
#36 51.32 	at org.gradle.launcher.exec.BuildOutcomeReportingBuildActionRunner.run(BuildOutcomeReportingBuildActionRunner.java:65)
#36 51.32 	at org.gradle.tooling.internal.provider.FileSystemWatchingBuildActionRunner.run(FileSystemWatchingBuildActionRunner.java:140)
#36 51.32 	at org.gradle.launcher.exec.BuildCompletionNotifyingBuildActionRunner.run(BuildCompletionNotifyingBuildActionRunner.java:41)
#36 51.32 	at org.gradle.launcher.exec.RootBuildLifecycleBuildActionExecutor.lambda$execute$0(RootBuildLifecycleBuildActionExecutor.java:40)
#36 51.32 	at org.gradle.composite.internal.DefaultRootBuildState.run(DefaultRootBuildState.java:123)
#36 51.32 	at org.gradle.launcher.exec.RootBuildLifecycleBuildActionExecutor.execute(RootBuildLifecycleBuildActionExecutor.java:40)
#36 51.32 	at org.gradle.internal.buildtree.InitDeprecationLoggingActionExecutor.execute(InitDeprecationLoggingActionExecutor.java:62)
#36 51.32 	at org.gradle.internal.buildtree.InitProblems.execute(InitProblems.java:38)
#36 51.32 	at org.gradle.internal.buildtree.DefaultBuildTreeContext.execute(DefaultBuildTreeContext.java:40)
#36 51.32 	at org.gradle.launcher.exec.BuildTreeLifecycleBuildActionExecutor.lambda$execute$0(BuildTreeLifecycleBuildActionExecutor.java:71)
#36 51.32 	at org.gradle.internal.buildtree.BuildTreeState.run(BuildTreeState.java:60)
#36 51.32 	at org.gradle.launcher.exec.BuildTreeLifecycleBuildActionExecutor.execute(BuildTreeLifecycleBuildActionExecutor.java:71)
#36 51.32 	at org.gradle.launcher.exec.RunAsBuildOperationBuildActionExecutor$3.call(RunAsBuildOperationBuildActionExecutor.java:61)
#36 51.32 	at org.gradle.launcher.exec.RunAsBuildOperationBuildActionExecutor$3.call(RunAsBuildOperationBuildActionExecutor.java:57)
#36 51.32 	at org.gradle.internal.operations.DefaultBuildOperationRunner$CallableBuildOperationWorker.execute(DefaultBuildOperationRunner.java:204)
#36 51.32 	at org.gradle.internal.operations.DefaultBuildOperationRunner$CallableBuildOperationWorker.execute(DefaultBuildOperationRunner.java:199)
#36 51.32 	at org.gradle.internal.operations.DefaultBuildOperationRunner$2.execute(DefaultBuildOperationRunner.java:66)
#36 51.32 	at org.gradle.internal.operations.DefaultBuildOperationRunner$2.execute(DefaultBuildOperationRunner.java:59)
#36 51.32 	at org.gradle.internal.operations.DefaultBuildOperationRunner.execute(DefaultBuildOperationRunner.java:157)
#36 51.32 	at org.gradle.internal.operations.DefaultBuildOperationRunner.execute(DefaultBuildOperationRunner.java:59)
#36 51.32 	at org.gradle.internal.operations.DefaultBuildOperationRunner.call(DefaultBuildOperationRunner.java:53)
#36 51.32 	at org.gradle.internal.operations.DefaultBuildOperationExecutor.call(DefaultBuildOperationExecutor.java:73)
#36 51.32 	at org.gradle.launcher.exec.RunAsBuildOperationBuildActionExecutor.execute(RunAsBuildOperationBuildActionExecutor.java:57)
#36 51.32 	at org.gradle.launcher.exec.RunAsWorkerThreadBuildActionExecutor.lambda$execute$0(RunAsWorkerThreadBuildActionExecutor.java:36)
#36 51.32 	at org.gradle.internal.work.DefaultWorkerLeaseService.withLocks(DefaultWorkerLeaseService.java:264)
#36 51.32 	at org.gradle.internal.work.DefaultWorkerLeaseService.runAsWorkerThread(DefaultWorkerLeaseService.java:128)
#36 51.32 	at org.gradle.launcher.exec.RunAsWorkerThreadBuildActionExecutor.execute(RunAsWorkerThreadBuildActionExecutor.java:36)
#36 51.32 	at org.gradle.tooling.internal.provider.continuous.ContinuousBuildActionExecutor.execute(ContinuousBuildActionExecutor.java:110)
#36 51.32 	at org.gradle.tooling.internal.provider.SubscribableBuildActionExecutor.execute(SubscribableBuildActionExecutor.java:64)
#36 51.32 	at org.gradle.internal.session.DefaultBuildSessionContext.execute(DefaultBuildSessionContext.java:46)
#36 51.32 	at org.gradle.tooling.internal.provider.BuildSessionLifecycleBuildActionExecuter$ActionImpl.apply(BuildSessionLifecycleBuildActionExecuter.java:92)
#36 51.32 	at org.gradle.tooling.internal.provider.BuildSessionLifecycleBuildActionExecuter$ActionImpl.apply(BuildSessionLifecycleBuildActionExecuter.java:80)
#36 51.32 	at org.gradle.internal.session.BuildSessionState.run(BuildSessionState.java:69)
#36 51.32 	at org.gradle.tooling.internal.provider.BuildSessionLifecycleBuildActionExecuter.execute(BuildSessionLifecycleBuildActionExecuter.java:62)
#36 51.32 	at org.gradle.tooling.internal.provider.BuildSessionLifecycleBuildActionExecuter.execute(BuildSessionLifecycleBuildActionExecuter.java:41)
#36 51.32 	at org.gradle.tooling.internal.provider.StartParamsValidatingActionExecuter.execute(StartParamsValidatingActionExecuter.java:64)
#36 51.32 	at org.gradle.tooling.internal.provider.StartParamsValidatingActionExecuter.execute(StartParamsValidatingActionExecuter.java:32)
#36 51.32 	at org.gradle.tooling.internal.provider.SessionFailureReportingActionExecuter.execute(SessionFailureReportingActionExecuter.java:51)
#36 51.32 	at org.gradle.tooling.internal.provider.SessionFailureReportingActionExecuter.execute(SessionFailureReportingActionExecuter.java:39)
#36 51.32 	at org.gradle.tooling.internal.provider.SetupLoggingActionExecuter.execute(SetupLoggingActionExecuter.java:47)
#36 51.32 	at org.gradle.tooling.internal.provider.SetupLoggingActionExecuter.execute(SetupLoggingActionExecuter.java:31)
#36 51.32 	at org.gradle.launcher.daemon.server.exec.ExecuteBuild.doBuild(ExecuteBuild.java:65)
#36 51.32 	at org.gradle.launcher.daemon.server.exec.BuildCommandOnly.execute(BuildCommandOnly.java:37)
#36 51.32 	at org.gradle.launcher.daemon.server.api.DaemonCommandExecution.proceed(DaemonCommandExecution.java:104)
#36 51.32 	at org.gradle.launcher.daemon.server.exec.WatchForDisconnection.execute(WatchForDisconnection.java:39)
#36 51.32 	at org.gradle.launcher.daemon.server.api.DaemonCommandExecution.proceed(DaemonCommandExecution.java:104)
#36 51.32 	at org.gradle.launcher.daemon.server.exec.ResetDeprecationLogger.execute(ResetDeprecationLogger.java:29)
#36 51.32 	at org.gradle.launcher.daemon.server.api.DaemonCommandExecution.proceed(DaemonCommandExecution.java:104)
#36 51.32 	at org.gradle.launcher.daemon.server.exec.RequestStopIfSingleUsedDaemon.execute(RequestStopIfSingleUsedDaemon.java:35)
#36 51.32 	at org.gradle.launcher.daemon.server.api.DaemonCommandExecution.proceed(DaemonCommandExecution.java:104)
#36 51.32 	at org.gradle.launcher.daemon.server.exec.ForwardClientInput$2.create(ForwardClientInput.java:78)
#36 51.32 	at org.gradle.launcher.daemon.server.exec.ForwardClientInput$2.create(ForwardClientInput.java:75)
#36 51.32 	at org.gradle.util.internal.Swapper.swap(Swapper.java:38)
#36 51.32 	at org.gradle.launcher.daemon.server.exec.ForwardClientInput.execute(ForwardClientInput.java:75)
#36 51.32 	at org.gradle.launcher.daemon.server.api.DaemonCommandExecution.proceed(DaemonCommandExecution.java:104)
#36 51.32 	at org.gradle.launcher.daemon.server.exec.LogAndCheckHealth.execute(LogAndCheckHealth.java:64)
#36 51.32 	at org.gradle.launcher.daemon.server.api.DaemonCommandExecution.proceed(DaemonCommandExecution.java:104)
#36 51.32 	at org.gradle.launcher.daemon.server.exec.LogToClient.doBuild(LogToClient.java:63)
#36 51.32 	at org.gradle.launcher.daemon.server.exec.BuildCommandOnly.execute(BuildCommandOnly.java:37)
#36 51.32 	at org.gradle.launcher.daemon.server.api.DaemonCommandExecution.proceed(DaemonCommandExecution.java:104)
#36 51.32 	at org.gradle.launcher.daemon.server.exec.EstablishBuildEnvironment.doBuild(EstablishBuildEnvironment.java:84)
#36 51.32 	at org.gradle.launcher.daemon.server.exec.BuildCommandOnly.execute(BuildCommandOnly.java:37)
#36 51.32 	at org.gradle.launcher.daemon.server.api.DaemonCommandExecution.proceed(DaemonCommandExecution.java:104)
#36 51.32 	at org.gradle.launcher.daemon.server.exec.StartBuildOrRespondWithBusy$1.run(StartBuildOrRespondWithBusy.java:52)
#36 51.32 	at org.gradle.launcher.daemon.server.DaemonStateCoordinator$1.run(DaemonStateCoordinator.java:297)
#36 51.32 	at org.gradle.internal.concurrent.ExecutorPolicy$CatchAndRecordFailures.onExecute(ExecutorPolicy.java:64)
#36 51.32 	at org.gradle.internal.concurrent.AbstractManagedExecutor$1.run(AbstractManagedExecutor.java:47)
#36 51.32 Caused by: org.graalvm.reachability.internal.UncheckedIOException: java.nio.file.NoSuchFileException: /signal-cli/index.json
#36 51.32 	at org.graalvm.reachability.internal.index.artifacts.SingleModuleJsonVersionToConfigDirectoryIndex.parseIndexFile(SingleModuleJsonVersionToConfigDirectoryIndex.java:79)
#36 51.32 	at org.graalvm.reachability.internal.index.artifacts.SingleModuleJsonVersionToConfigDirectoryIndex.<init>(SingleModuleJsonVersionToConfigDirectoryIndex.java:64)
#36 51.32 	at org.graalvm.reachability.internal.FileSystemRepository.lambda$findConfigurationsFor$1(FileSystemRepository.java:106)
#36 51.32 	at org.graalvm.reachability.internal.FileSystemRepository.findConfigurationsFor(FileSystemRepository.java:133)
#36 51.32 	at org.graalvm.buildtools.gradle.internal.GraalVMReachabilityMetadataService.findConfigurationsFor(GraalVMReachabilityMetadataService.java:186)
#36 51.32 	at org.graalvm.buildtools.gradle.internal.GraalVMReachabilityMetadataService.findConfigurationsFor(GraalVMReachabilityMetadataService.java:218)
#36 51.32 	at org.graalvm.buildtools.gradle.NativeImagePlugin.lambda$graalVMReachabilityQueryForConfigDirectories$2719e1b0$1(NativeImagePlugin.java:398)
#36 51.32 	at org.graalvm.buildtools.gradle.NativeImagePlugin.lambda$graalVMReachabilityQueryForConfigDirectories$c0398307$1(NativeImagePlugin.java:402)
#36 51.32 	at org.gradle.api.internal.provider.ValueSupplier$Present.transform(ValueSupplier.java:507)
#36 51.32 	at org.gradle.api.internal.provider.TransformBackedProvider.mapValue(TransformBackedProvider.java:91)
#36 51.32 	at org.gradle.api.internal.provider.TransformBackedProvider.calculateOwnValue(TransformBackedProvider.java:82)
#36 51.32 	at org.gradle.api.internal.provider.AbstractMinimalProvider.calculateValue(AbstractMinimalProvider.java:115)
#36 51.32 	at org.gradle.api.internal.provider.FlatMapProvider.calculateOwnValue(FlatMapProvider.java:53)
#36 51.32 	at org.gradle.api.internal.provider.AbstractMinimalProvider.calculateOwnPresentValue(AbstractMinimalProvider.java:80)
#36 51.32 	at org.gradle.api.internal.provider.AbstractMinimalProvider.get(AbstractMinimalProvider.java:100)
#36 51.32 	at org.gradle.api.internal.provider.ProviderResolutionStrategy$2.resolve(ProviderResolutionStrategy.java:33)
#36 51.32 	at org.gradle.api.internal.file.collections.ProviderBackedFileCollection.visitDependencies(ProviderBackedFileCollection.java:57)
#36 51.32 	at org.gradle.api.internal.tasks.CachingTaskDependencyResolveContext$TaskGraphImpl.getNodeValues(CachingTaskDependencyResolveContext.java:103)
#36 51.32 	at org.gradle.internal.graph.CachingDirectedGraphWalker$GraphWithEmptyEdges.getNodeValues(CachingDirectedGraphWalker.java:213)
#36 51.32 	at org.gradle.internal.graph.CachingDirectedGraphWalker.doSearch(CachingDirectedGraphWalker.java:121)
#36 51.32 	at org.gradle.internal.graph.CachingDirectedGraphWalker.findValues(CachingDirectedGraphWalker.java:73)
#36 51.32 	at org.gradle.api.internal.tasks.CachingTaskDependencyResolveContext.getDependencies(CachingTaskDependencyResolveContext.java:66)
#36 51.32 	... 143 more
#36 51.32 Caused by: java.nio.file.NoSuchFileException: /signal-cli/index.json
#36 51.32 	at org.gradle.internal.classpath.declarations.NioFileInterceptors.intercept_newBufferedReader(NioFileInterceptors.java:137)
#36 51.32 	at org.graalvm.reachability.internal.index.artifacts.SingleModuleJsonVersionToConfigDirectoryIndex.parseIndexFile(SingleModuleJsonVersionToConfigDirectoryIndex.java:71)
#36 51.32 	... 164 more
#36 51.32 
#36 51.32 
#36 51.32 BUILD FAILED in 50s
#36 51.32 5 actionable tasks: 5 executed
#36 ERROR: process "/bin/sh -c ./gradlew --stacktrace -Djava.net.preferIPv4Stack=true nativeCompile" did not complete successfully: exit code: 1
@slithernix
Copy link
Author

slithernix commented Feb 20, 2024

BTW I am definitely using jdk 21, i checked with java --version right before that command.

Was using this just fine like a week or so ago when you dropped the 0.12.8 release to fix the version lockout.

@m-ueberall
Copy link

@slithernix: Did you do as suggested and add "--info" to see whether this provides additional hints? The local build script uses "./gradlew --refresh-dependencies nativeCompile --info --stacktrace --no-daemon --console plain" for logging purposes (and the build was successful).

@morph027
Copy link
Contributor

My pipeline builds are working too: https://gitlab.com/packaging/signal-cli/-/jobs/6205355371

Ran into another issue with old gcc an arm64 builds, but nothing like this.

@slithernix
Copy link
Author

/gradlew --refresh-dependencies nativeCompile --info --stacktrace --no-daemon --console plain

I did that, and the last thing that happens before the error seen above is:

#36 55.26 Downloading https://repo.maven.apache.org/maven2/org/graalvm/buildtools/graalvm-reachability-metadata/0.10.0/graalvm-reachability-metadata-0.10.0-repository.zip to /root/.gradle/.tmp/gradle_download4434218493956767529bin
#36 55.36 Extracting /root/.gradle/caches/modules-2/files-2.1/org.graalvm.buildtools/graalvm-reachability-metadata/0.10.0/d46f65a97e258d0092a9157ec98dc8d728925b7a/graalvm-reachability-metadata-0.10.0-repository.zip to /root/.gradle/native-build-tools/repositories/cb739c0eb6aedc6d3fa041b4dcabebd7911c92e1/exploded

then this error (same as above):

#36 55.66 FAILURE: Build failed with an exception.
#36 55.66 
#36 55.66 * What went wrong:
#36 55.66 Could not determine the dependencies of task ':nativeCompile'.
#36 55.66 > java.nio.file.NoSuchFileException: /signal-cli/index.json
#36 55.66 
#36 55.66 * Try:
#36 55.66 > Run with --debug option to get more log output.
#36 55.66 > Run with --scan to get full insights.
#36 55.66 > Get more help at https://help.gradle.org.
#36 55.66 
#36 55.66 * Exception is:
#36 55.66 org.gradle.api.internal.tasks.TaskDependencyResolveException: Could not determine the dependencies of task ':nativeCompile'.

So, obviously no index.json in the root of the signal-cli project.

Now, on a hunch I ran a find /root/.gradle -type f -name index.json, lots of index.json files in there. so it seems like maybe I am missing an environment variable or something and gradle is looking in the working directory when it should be looking somewhere else for that index.json. Ring any bells?

@m-ueberall
Copy link

m-ueberall commented Feb 22, 2024

@slithernix: I tried to reproduce the above error message, but to no avail. I'm afraid we'd need more information regarding your build environment to narrow it down (is this the same as the one mentioned by you in discussion #1431?):

  • Linux distribution (to rule out it's Alpine), host architecture (amd64/x86_64, arm64/aarch64)
  • the CD/CI environment (if any; this usually provides a suitable build container)
    • (I'm a bit puzzled by the "#36 55.66 " prefix shown in the excerpt you posted, because neither gradlew --info nor gradlew --debug produces this) EDIT: Forgot to reread the very first line–that's supposedly a step/timestamp prefix from Docker 😝
  • the version/flavour of GraalVM you're using (CE/EE/...) and maybe how you installed it
    • (IIRC, Gradle 8.x tries to install the required native-image component using the gu command itself as a last resort, but this has recently been changed upstream (by Oracle) and should not work anymore, so you need to ensure GraalVM is installed including said component and Gradle is able to locate it.)
  • the JDK21 installation(s): Is the JDK21 you mentioned part of GraalVM which you need to build the native image, or an OpenJDK/Azul Zulu/… variant? – In the latter case, your log file might also contain an error message like Make sure to declare the GRAALVM_HOME environment variable or install GraalVM with native-image in a standard location recognized by Gradle Java toolchain support.
    • At least when using --debug instead of --info with gradlew, you should see the predefined/auto-detected value for JAVA_HOME in your log; however, a simple gradlew --version will also show this.

@slithernix
Copy link
Author

I can do you one better and just make the repo public, give me a few minutes to make sure main has the working 0.12.8 build and then i will show you the diff of me trying to get 13 going

@slithernix
Copy link
Author

oh i bet it's GRAALVM_HOME dude, gonna try that first before i inundate you with scripts and Dockerfile etc

@slithernix
Copy link
Author

that didn't seem to help. here is the working Dockerfile for 0.12.8:

FROM debian:11.8 as build

ARG GRAAL_ARCH=x64
ARG JDK_VERSION=17
ARG LIBSIGNAL_VERSION=0.36.1
ARG SIGNAL_CLI_VERSION=0.12.8

RUN mkdir /release

WORKDIR /

# Pre-requisites
RUN apt-get update
RUN DEBIAN_FRONTEND=noninteractive apt-get -o Dpkg::Options::="--force-confnew" -f -y install \
  build-essential \
  cmake \
  curl \
  git \
  libclang-dev \
  openjdk-${JDK_VERSION}-jdk \
  openjdk-${JDK_VERSION}-jre \
  protobuf-compiler \
  python3 \
  wget \
  zip \
  zlib1g-dev

RUN bash -lc "curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y"

# GraalVM (Pre-requisite for signal-cli native image)
WORKDIR /opt
RUN curl \
  -o ./graal.tgz \
  https://download.oracle.com/graalvm/${JDK_VERSION}/latest/graalvm-jdk-${JDK_VERSION}_linux-${GRAAL_ARCH}_bin.tar.gz

RUN tar xzvf graal.tgz
RUN rm -f graal.tgz
RUN /bin/bash -c "mv /opt/graal* /opt/graal"

ENV PATH="/opt/graal/bin:${PATH}"
ENV JAVA_HOME="/opt/graal"

RUN gu install native-image

WORKDIR /
RUN git clone --branch v${SIGNAL_CLI_VERSION} --depth 1 https://github.com/AsamK/signal-cli
RUN git clone --branch v${LIBSIGNAL_VERSION} --depth 1 https://github.com/signalapp/libsignal

# Patch signal-cli build stuff to use the custom libsignal
COPY etc/build.gradle.patch /
RUN /bin/bash -c 'patch -p0 < /build.gradle.patch'

WORKDIR /libsignal/java
RUN sed -i "/include ':android'/d" settings.gradle
#RUN /bin/bash -c 'source $HOME/.cargo/env && ./build_jni.sh desktop'
RUN /bin/bash -c 'source $HOME/.cargo/env && ./gradlew build'

WORKDIR /libsignal/target/release
RUN strip libsignal_jni.so
RUN find /libsignal/ -type f -name '*.jar'
RUN zip -d "/libsignal/java/client/build/libs/libsignal-client-${LIBSIGNAL_VERSION}.jar" libsignal_jni.so
RUN zip -9 "/libsignal/java/client/build/libs/libsignal-client-${LIBSIGNAL_VERSION}.jar" libsignal_jni.so


WORKDIR /signal-cli
RUN ./gradlew -Djava.net.preferIPv4Stack=true nativeCompile
RUN cp ./build/native/nativeCompile/signal-cli /release/

# Release container just strictly for copying release files to out/
FROM debian:11.8 as release

RUN apt-get update
RUN DEBIAN_FRONTEND=noninteractive apt-get -o Dpkg::Options::="--force-confnew" -f -y install \
  rsync

VOLUME /out

COPY --from=build /release /release
ADD scripts/release.sh /release.sh
ENTRYPOINT /release.sh

this is the patch that is applied to gradle

--- /signal-cli/build.gradle.kts.org        2023-04-16 18:20:15.653077805 +0000
+++ /signal-cli/build.gradle.kts    2023-04-17 16:13:42.264347948 +0000
@@ -44,4 +44,9 @@
     implementation(libs.logback)
     implementation(project(":lib"))
+    implementation(files("/libsignal/java/client/build/libs/libsignal-client-0.36.1.jar"))
+}
+
+configurations.all {
+    exclude(group = "org.signal", module = "libsignal-client")
 }

The update to .13.0 has me re-arranging some stuff and doing things slightly differently as it appears that libsignal still uses java 17 while signal-cli now uses 21. I'll get you the broken one soon. tried a few differnt things last night to no avail but just wanted to post the working one so you could have a look.

@m-ueberall
Copy link

m-ueberall commented Feb 25, 2024

@slithernix : I'll rerun the above locally tonight with and without changing the respective versions to see whether the latter shows the same error message. At first glance, there are two three changes I'd like to apply to the above–will come back to you later about these.

@slithernix
Copy link
Author

ok so here is the updated version for the 0.13.0. i def see one bug where i set the path since that ${PATH} is evaluated in Docker and expands to probably nothing. i didn't tackle that yet but here is the updated one:

FROM debian:11.8 as build

ARG GRAAL_ARCH=x64
ARG JDK_VERSION_LIBSIGNAL=17
ARG JDK_VERSION_SIGNALCLI=21
ARG LIBSIGNAL_VERSION=0.39.2
ARG SIGNAL_CLI_VERSION=0.13.0

RUN mkdir /release

WORKDIR /

# Pre-requisites
RUN apt-get update
RUN DEBIAN_FRONTEND=noninteractive apt-get -o Dpkg::Options::="--force-confnew" -f -y install \
  build-essential \
  cmake \
  curl \
  git \
  libclang-dev \
  openjdk-${JDK_VERSION_LIBSIGNAL}-jdk \
  openjdk-${JDK_VERSION_LIBSIGNAL}-jre \
  protobuf-compiler \
  python3 \
  wget \
  zip \
  zlib1g-dev

RUN bash -lc "curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y"

WORKDIR /
RUN git clone --branch v${SIGNAL_CLI_VERSION} --depth 1 https://github.com/AsamK/signal-cli
RUN git clone --branch v${LIBSIGNAL_VERSION} --depth 1 https://github.com/signalapp/libsignal

WORKDIR /libsignal/java
RUN sed -i "/include ':android'/d" settings.gradle
RUN /bin/bash -c 'source $HOME/.cargo/env && ./gradlew build'

WORKDIR /libsignal/target/release
RUN strip libsignal_jni.so
RUN zip -d "/libsignal/java/client/build/libs/libsignal-client-${LIBSIGNAL_VERSION}.jar" libsignal_jni.so
RUN zip -9 "/libsignal/java/client/build/libs/libsignal-client-${LIBSIGNAL_VERSION}.jar" libsignal_jni.so

# GraalVM (Pre-requisite for signal-cli native image)
WORKDIR /opt
RUN curl \
  -o ./graal.tgz \
  https://download.oracle.com/graalvm/${JDK_VERSION_SIGNALCLI}/latest/graalvm-jdk-${JDK_VERSION_SIGNALCLI}_linux-${GRAAL_ARCH}_bin.tar.gz

RUN tar xzvf graal.tgz
RUN rm -f graal.tgz
RUN /bin/bash -c "mv /opt/graal* /opt/graal"

#RUN gu install native-image

ENV PATH="/opt/graal/bin:${PATH}"
ENV JAVA_HOME="/opt/graal"
ENV GRAALVM_HOME="/opt/graal"

# Patch signal-cli build stuff to use the custom libsignal
WORKDIR /
COPY etc/build.gradle.patch /
RUN /bin/bash -c 'patch -p0 < /build.gradle.patch'
RUN sed -i "s/_LIBSIGNAL_VERSION_/${LIBSIGNAL_VERSION}/"  /signal-cli/build.gradle.kts

WORKDIR /signal-cli
RUN ./gradlew -Djava.net.preferIPv4Stack=true nativeCompile
RUN cp ./build/native/nativeCompile/signal-cli /release/

# Release container just strictly for copying release files to out/
FROM debian:11.8 as release

RUN apt-get update
RUN DEBIAN_FRONTEND=noninteractive apt-get -o Dpkg::Options::="--force-confnew" -f -y install \
  rsync

VOLUME /out

COPY --from=build /release /release
ADD scripts/release.sh /release.sh
ENTRYPOINT /release.sh

and the updated patch file for build.gradle:

--- /signal-cli/build.gradle.kts.org        2023-04-16 18:20:15.653077805 +0000
+++ /signal-cli/build.gradle.kts    2023-04-17 16:13:42.264347948 +0000
@@ -44,4 +44,9 @@
     implementation(libs.logback)
     implementation(project(":lib"))
+    implementation(files("/libsignal/java/client/build/libs/libsignal-client-_LIBSIGNAL_VERSION_.jar"))
+}
+
+configurations.all {
+    exclude(group = "org.signal", module = "libsignal-client")
 }

@m-ueberall
Copy link

m-ueberall commented Feb 25, 2024

A short update: I started with your previous versions of Dockerfile and build.gradle.patch and applied similar changes (namely, using JDK17 for the signalapp/libsignal repository, commenting out the unneeded separate installation of the native-image module with gu and removing the hard-coded version in the patch).

I can now reproduce the consequential error java.nio.file.NoSuchFileException: /signal-cli/index.json; what you should see in your log as well are two earlier error messages, though (at least when adding --info --stacktrace --no-daemon --console plain to the last invocation of gradlew nativeCompile):

#32 24.75 Resource missing. [HTTP HEAD: https://plugins.gradle.org/m2/org/gradle/kotlin/kotlin-dsl/org.gradle.kotlin.kotlin-dsl.gradle.plugin/4.2.1/org.gradle.kotlin.kotlin-dsl.gradle.plugin-4.2.1.jar]
#32 60.65 Resource missing. [HTTP HEAD: https://jcenter.bintray.com/org/graalvm/buildtools/native/org.graalvm.buildtools.native.gradle.plugin/0.10.0/org.graalvm.buildtools.native.gradle.plugin-0.10.0.jar]

Now I need to figure out what's the reason for the above errors (does not seem to be a cache-related problem, you can remove $HOME/.gradle and purge the JDK17 packages and still run into them). One possible workaround might be to simply use another version of GraalVM (as we do in our own build script), at least for the time being.

By the way, the use of ${PATH} works as intended here (which you can verify by putting a RUN env && echo "----" && ./gradlew -version line in front of each build triggered by gradlew).

One change I'd recommend (to make sure that you exactly reproduce the upstream configuration for a given version of the library) is to first clone the signalapp/libsignal repository and then invoke rustup using something along the lines of

# Rust (nightly version)
RUN bash -lc "curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- --profile minimal --default-toolchain $(cat /libsignal/rust-toolchain) -y"

@slithernix
Copy link
Author

nice catch on the rust toolchain loading. i've made that modification.

now, when you say use another version of graalvm... you mean downloading 17 and 21? i actually tried that and had two separate graalvms, and modified the env like /opt/graal/17 and /opt/graal/21 depending on which phase of the build i was in. iirc i got the same error. pretty puzzled here. lmk if you come up with anything else or think of something else i can try. appreciate the help.

@slithernix
Copy link
Author

oh, this is sort of a tangent but i've got an alpine project on the horizon and will need to put signal-cli on there. is there some kind of musl issue right now? i def have encountered my share of those when using alpine for various things...

@m-ueberall
Copy link

m-ueberall commented Feb 25, 2024

Ok, I replaced Oracle GraalVM with GraalVM CE that we use …

#RUN curl \
#  -o ./graal.tgz \
#  https://download.oracle.com/graalvm/${JDK_VERSION}/latest/graalvm-jdk-${JDK_VERSION}_linux-${GRAAL_ARCH}_bin.tar.gz

#NOTE: you could use `jq` instead of grep, sed here
RUN /bin/bash -c 'export GRAAL_VERSION="$(curl --silent https://api.github.com/repos/graalvm/graalvm-ce-builds/releases | grep tag_name | grep "jdk-${JDK_VERSION}" | head -1 | sed -e "s/.*jdk-//" -e "s/\".*//")"; \
  export GRAAL_URI="https://github.com/graalvm/graalvm-ce-builds/releases/download/jdk-${GRAAL_VERSION}/graalvm-community-jdk-${GRAAL_VERSION}_linux-${GRAAL_ARCH}_bin.tar.gz"; env; wget -O ./graal.tgz "${GRAAL_URI}"'

...and still see the same problem. This means that the build environment somehow differs from those we're using, though this really shouldn't be the case given that the working directory contents, caches should be identical/clean. Really strange. I guess I'll have to sleep over that one. 😝

Regarding musl, see discussion #1453.

@slithernix
Copy link
Author

i have been away from the java world for a long time now, do you think it's possible that somehow the debian openjdk package is affecting things somehow?

@m-ueberall
Copy link

No, because it doesn't work even in the absence of said package. My money is on Docker here, seeing the large amount of posts stating problems when using Gradle in conjunction with Docker (and since a GraalVM-based build is a rather complex process, this likely weighs in as well). I'd suggest to simply convert the Dockerfile into a bash script that creates and uses a chroot (using debootstrap) and see whether this solves the problem–of which I'm almost certain as we don't use Docker here and never faced the errors/warnings shown in the logs.

If you must use Docker, then IMHO the only (time-consuming!) way to pinpoint the cause would be to also start with the above and afterwards try to compare every step Gradle takes inside and outside of Docker.

@m-ueberall
Copy link

m-ueberall commented Feb 26, 2024

Lest I forget: It might be worth a shot to compare your own (build) container image with one of the GraalVM Community Edition Container Images, although those use Oracle Linux.

@slithernix
Copy link
Author

ok i'll probably do a vagrantfile next week or so. i will update this with results.

@morph027
Copy link
Contributor

I'm quite sure that Docker is not the problem as I'm using for both local and pipeline builds on purpose for multiarch.

@m-ueberall
Copy link

That's great! If you can share the part that installs/invokes GraalVM, we can compare the resulting Docker layers, which should be much easier!

@morph027
Copy link
Contributor

Local build instructions: https://gitlab.com/packaging/signal-cli/-/blob/master/DEV.md

@slithernix
Copy link
Author

Figured it's about time to make a new build of signal-cli and still getting this weird index.json error.

Local build instructions: https://gitlab.com/packaging/signal-cli/-/blob/master/DEV.md

i took a look here and i don't see really what could be a substantial difference to cause this. the libsignal compile is working fine.

any idea what creates index.json in the root of the signal-cli repo? the only thing i see that maybe might have something to do with it is REFLECT_CONFIG. i have even run find / -type f -name index.json, it doesn't exist at all anywhere.

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

No branches or pull requests

3 participants