GatorEducator / gatorgradle

:electric_plug: Gradle Plugin to Enable Running GatorGrader as a Gradle Task
https://gatoreducator.github.io/gatorgradle/
GNU General Public License v2.0
7 stars 7 forks source link

Installation on WSL Failed with the Warning of Illegal Access #40

Closed Lancasterwu closed 2 years ago

Lancasterwu commented 5 years ago

I was using WSL(Windows Subsystem for Linux) to install gradle and trying to run gradle grade. The build failed with the following error:

muen@Yueshen:/mnt/c/Users/Yueshen/Documents/CS203/Practicle/computer-science-203-spring-2019-practical-3-Lancasterwu$ pipenv run gradle grade
WARNING: An illegal reflective access operation has occurred
WARNING: Illegal reflective access by org.gradle.internal.reflect.JavaMethod (file:/usr/share/gradle/lib/gradle-base-services-3.4.1.jar) to method java.lang.ClassLoader.getPackages()
WARNING: Please consider reporting this to the maintainers of org.gradle.internal.reflect.JavaMethod
WARNING: Use --illegal-access=warn to enable warnings of further illegal reflective access operations
WARNING: All illegal access operations will be denied in a future release
Starting a Gradle Daemon (subsequent builds will be faster)
Download https://plugins.gradle.org/m2/gradle/plugin/org/gatored/gatorgradle/0.3.0/gatorgradle-0.3.0.pom
Download https://plugins.gradle.org/m2/gradle/plugin/org/gatored/gatorgradle/0.3.0/gatorgradle-0.3.0.jar

FAILURE: Build failed with an exception.

* Where:
Build file '/mnt/c/Users/Yueshen/Documents/CS203/Practicle/computer-science-203-spring-2019-practical-3-Lancasterwu/build.gradle' line: 9

* What went wrong:
An exception occurred applying plugin request [id: 'org.gatored.gatorgradle', version: '0.3.0']
> Failed to apply plugin [id 'org.gatored.gatorgradle']
   > Could not generate a proxy class for class org.gatorgradle.task.GatorGradleTask.

I'm wondering if I did something improperly or it is a bug with the installation of gatorgrader on WSL. Thanks!

gkapfham commented 5 years ago

Hello @Michionlion, I think that this is actually an issue with the Gradle plugin, right? If so, I suggest that we transfer it to the appropriate repository. Let me know, thanks!

Michionlion commented 5 years ago

Yes this is probably a problem with GatorGradle. I'm not sure what though, there's no reflective access to java.lang.ClassLoader.getPackages() anywhere in our code. Perhaps update Gradle to 5.0 first and try again? These kind of errors are often related to version conflicts.

I've also transferred the issue.

gkapfham commented 5 years ago

Thanks for the transfer @Michionlion. Also, @Lancasterwu can you please upgrade your version of Gradle and report back as to what you found? It seems that this may not be related to our plugin but rather to Gradle itself. Let us know what you find!

gkapfham commented 5 years ago

@Lancasterwu can you please let us know if you are still experiencing problems with this issue?