Can't Run Two Gradle Things Simultaneously - "Gradle could not start your build. Cannot create service of type BuildSessionActionExecutor"

已回答

I develop Minecraft mods. Recently, I've occasionally been getting the below error when attempting to run my projects. Once it shows up, it persists until I run ./gradlew --stop to shut down a strange daemon of unknown purpose. (Or until I restart my computer.) I also get the error every single time I try to run a second process while one is already running. This is important because to properly test a Minecraft mod you have to concurrently run a server and a client, so I need to be able to run two simultaneous processes.

The error in question:

Gradle could not start your build.
> Cannot create service of type BuildSessionActionExecutor using method LauncherServices$ToolingBuildSessionScopeServices.createActionExecutor() as there is a problem with parameter #21 of type FileSystemWatchingInformation.
   > Cannot create service of type BuildLifecycleAwareVirtualFileSystem using method VirtualFileSystemServices$GradleUserHomeServices.createVirtualFileSystem() as there is a problem with parameter #7 of type GlobalCacheLocations.
      > Cannot create service of type GlobalCacheLocations using method GradleUserHomeScopeServices.createGlobalCacheLocations() as there is a problem with parameter #1 of type List<GlobalCache>.
         > Could not create service of type FileAccessTimeJournal using GradleUserHomeScopeServices.createFileAccessTimeJournal().
            > Timeout waiting to lock journal cache (C:\Users\Syric\.gradle\caches\journal-1). It is currently in use by another Gradle instance.
              Owner PID: 4072
              Our PID: 16368
              Owner Operation: 
              Our operation: 
              Lock file: C:\Users\Syric\.gradle\caches\journal-1\journal-1.lock

The closest match for this issue I've been able to find is here.

I've tried installing older versions of IntelliJ but it doesn't seem to have fixed the issue. Does anyone know how I can repair this?

 

If I should be asking this elsewhere (i.e. ‘it’s a gradle issue', ‘go ask on this other issue tracker’, whatever), please let me know.

0

Hello!

In some cases it might be an expected behavior, if, for instance, you have two Daemons actively running Tasks running at the same time, but generally this error indicates an actual issue.

Since IDEA delegates Tasks execution directly to Gradle itself, the issue is most likely occurs on the Gradle end (there is a corresponding entry on the Gradle GitHub).

However, I would appreciate, if you could share the Projects / Tasks that typically cause the issue, so we can take a closer look. 

0

请先登录再写评论。