SpongePowered / MixinGradle

Gradle plugin that adds the Mixin technology capability to your project.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Build failure when applied after the 'eclipse' plugin

Cheos137 opened this issue · comments

commented

I've just noticed that mixingradle 0.7-SNAPSHOT causes a build failure if the 'eclipse' plugin is applied before the 'org.spongeforge.mixin' plugin (it works fine the other way around).

It would be nice to see this fixed, as finding the cause was really time consuming with such an obscure error message from gradle.

Error message:

FAILURE: Build failed with an exception.

* What went wrong:
A problem was found with the configuration of task ':forge-1.19:eclipseFactoryPath' (type 'MixinEclipse.EclipseFactoryPath').
  - In plugin 'org.spongepowered.mixin' type 'org.spongepowered.asm.gradle.plugins.MixinEclipse.EclipseFactoryPath' property 'config' has @Input annotation used on property of type 'Configuration'.

    Reason: A property of type 'Configuration' annotated with @Input cannot determine how to interpret the file.

    Possible solutions:
      1. Annotate with @InputFile for regular files.
      2. Annotate with @InputDirectory for directories.
      3. If you want to track the path, return File.absolutePath as a String and keep @Input.

    Please refer to https://docs.gradle.org/7.5/userguide/validation_problems.html#incorrect_use_of_input_annotation for more details about this problem.

* 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

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.5/userguide/command_line_interface.html#sec:command_line_warnings

It works fine the other way around because Mixin doesn't try to enable Eclipse integration in the first place. This issue has existed for a while and I am frankly amazed to see that it has not yet been fixed.

commented

use of incorrect annotations seems to be fixed with commit 8381249

Nope this is still an issue in a multi mod setup. The fix by @DarkShadow44 still works. I forked the newest version of ForgeGradle 6 and applied the fix once more: https://github.com/CreativeMD/MixinGradle/tree/task_fix
Would be great if this fix could be included.