Skip to content
This repository has been archived by the owner on Apr 15, 2024. It is now read-only.

Circular dependency between tasks #1

Closed
DAQEM opened this issue Oct 14, 2022 · 4 comments
Closed

Circular dependency between tasks #1

DAQEM opened this issue Oct 14, 2022 · 4 comments

Comments

@DAQEM
Copy link

DAQEM commented Oct 14, 2022

Syncing and building the projects works just fine, but when I try to run a client (Fabric, Forge or Quilt), I get the following error:

3:42:56 PM: Executing ':Quilt:classes'...

> Configure project :Common
Quilt Loom: 0.12.40

> Configure project :Fabric
Fabric Loom: 0.12.56

> Configure project :Quilt
Quilt Loom: 0.12.40

FAILURE: Build failed with an exception.

* What went wrong:
Circular dependency between the following tasks:
:Common:prepareRemapJar
\--- :Quilt:jar
     \--- :Quilt:classes
          \--- :Quilt:compileJava
               \--- :Common:remapJar
                    \--- :Common:prepareRemapJar (*)

(*) - details omitted (listed previously)


* Try:
> Run with --stacktrace option to get the stack trace.
> Run with --info or --debug option to get more log output.
> Run with --scan to get full insights.

* Get more help at https://help.gradle.org

BUILD FAILED in 5s

Deprecated Gradle features were used in this build, making it incompatible with Gradle 8.0.

You can use '--warning-mode all' to show the individual deprecation warnings and determine if they come from your own scripts or plugins.

See https://docs.gradle.org/7.4.2/userguide/command_line_interface.html#sec:command_line_warnings
3:43:01 PM: Execution finished ':Quilt:classes'.

Full debug log: https://gist.github.com/DAQEM/d4b7e985972fcec4d3f1259980336152

How to reproduce:

  • Download the files and open them using Intellij.
  • Wait for it to sync and download all the dependencies.
  • Generate the runs for forge.
  • Try to run any of the clients.
@DAQEM
Copy link
Author

DAQEM commented Oct 14, 2022

Removing compileOnly project(":Common") from the Quilt build.gradle fixed the issue for me.
Everything seems to work just fine. Syncing, Building and running a client.

I don't have that much knowledge of Gradle and multiloader setups, but I don't think this is the best way to fix it.
Any ideas how to fix it with a different solution?

@Witixin1512
Copy link
Owner

I can't replicate this on my side.
I downloaded the repo, imported into IntelliJ, set the project sdk to 17 as well as configured gradle to use that, refreshed again, genIntelliJ runs and both Forge and Fabric ran fine.
If you remove compileOnly project(":Common") from the Quilt build.gradle you should stop having access to Common classes in the Quilt module... so no, that shouldn't be a great solution...

@DAQEM
Copy link
Author

DAQEM commented Oct 15, 2022

Yeah that's exactly what I did as well. Very strange. Thanks for checking tho. I'll let you know when I find the solution.

@DAQEM DAQEM closed this as completed Oct 15, 2022
@Witixin1512
Copy link
Owner

jaredlll08/MultiLoader-Template#17
I've seen other people get this but haven't been able to encounter it myself, maybe applying that fixes it?
I'm thinking of probably switching the common module to VanillaGradle since loom in common comes with quite a bit of issues in a ML Environment.
I'm starting to think that having parchment is not that worth it.

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

No branches or pull requests

2 participants