nus-cs2103-AY2122S2 / forum

13 stars 1 forks source link

Error creating a `jar` #235

Closed waffledood closed 2 years ago

waffledood commented 2 years ago

Hey all, Wanted to create a release for the tP by running gradlew shadowJar, but encountered the following error

Could not initialize class org.codehaus.groovy.reflection.ReflectionCache

This StackOverflow post suggested updating the gradle distribution value in distributionUrl in gradle/gradle-wrapper.properties.

If this was indeed the fix for the solution, what was the new gradle distribution used?

Thanks in advance!

waffledood commented 2 years ago

hey guys, it's okay! I managed to fix the issue, i ran the command gradlew shadowJar in tp/ & that's why i faced the error, i realized i could've just run the shadowJar command from the Gradle panel in IntelliJ!

As a follow-up, is there a specific location in the repo to run the gradlew shadowJar command? or perhaps I've inputted the wrong command?

yusufaine commented 2 years ago

@waffledood thats a little weird, I run ./gradlew shadowJar in the base directory of my TP and it works fine (running on MacOS, if it matters)

Could you perhaps try ./gradlew clean shadowJar?

waffledood commented 2 years ago

@yusufaine I'm on Windows, so gradlew clean shadowJar but facing some other errors instead 😓

Could not initialize class org.codehaus.groovy.runtime.InvokerHelper
damithc commented 2 years ago

@waffledood are you still facing this problem?

nus-se-bot commented 2 years ago

@waffledood A gentle reminder to close this issue if the problem has been resolved. If not resolved yet, please post a comment explaining which part of the problem/question remains unresolved.

nus-se-bot commented 2 years ago

@waffledood I'm closing this issue due to inactivity. Feel free to reopen if the issue is still unresolved.