Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

NoClassDefFound inside downgraded jar #4

Closed
lebedynskyi opened this issue Jun 12, 2024 · 3 comments
Closed

NoClassDefFound inside downgraded jar #4

lebedynskyi opened this issue Jun 12, 2024 · 3 comments

Comments

@lebedynskyi
Copy link

lebedynskyi commented Jun 12, 2024

I 've used console comand like:

java -jar jvmdowngrader-0.7.1-all.jar -c 52 downgrade -t vineflower-1.10.1.jar vineflower-1.10.1-down.jar

And after build in prod project with dowgraded jar i see next error in first class (Library enter)

java.lang.NoClassDefFoundError: Failed resolution of: Lxyz/wagyourtail/jvmdg/j9/stub/java_base/J_U_Map;
	at org.jetbrains.java.decompiler.main.decompiler.ConsoleDecompiler.<clinit>(ConsoleDecompiler.java:29)
	...

Inside downgraded class I see these imports:

import xyz.wagyourtail.jvmdg.j11.NestHost;
import xyz.wagyourtail.jvmdg.j11.NestMembers;
import xyz.wagyourtail.jvmdg.j9.stub.java_base.J_U_Map;

IDE does not see its implementation. Do you think I should add some additional library jar to the project?

@Geolykt
Copy link

Geolykt commented Jun 12, 2024

@lebedynskyi
Copy link
Author

You might be missing https://maven.wagyourtail.xyz/releases/xyz/wagyourtail/jvmdowngrader/jvmdowngrader-java-api/0.7.1/jvmdowngrader-java-api-0.7.1-downgraded-8.jar or similar at runtime

Now it compiles. Thanks.. Didn't noticed this in docs.. Anyway thanks.

@wagyourtail
Copy link
Contributor

wagyourtail commented Jun 13, 2024

Yeah. It's either that or using the shade method in the docs. which is preferable in many cases

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

No branches or pull requests

3 participants