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

Dependency remap breaks dependency #192

Closed
slava110 opened this issue Jan 17, 2024 · 6 comments
Closed

Dependency remap breaks dependency #192

slava110 opened this issue Jan 17, 2024 · 6 comments

Comments

@slava110
Copy link

slava110 commented Jan 17, 2024

Hi. I've added GeckoLib mod as dependency for my Forge project. However, my game wasn't starting. I was wondering why and found out that META-INF/jarjar/metadata.json file isn't present in remapped jar. It exists in jar obtained from maven, but after remapping it disappears. Maybe this error has something to do with it:
log.txt
Dependency (from repo: https://dl.cloudsmith.io/public/geckolib3/geckolib/maven/):

modImplementation("software.bernie.geckolib:geckolib-forge-1.20.1:4.4")

I'm using:
minecraft: 1.20.1
forge: 1.20.1-47.2.20
dev.architectury.loom: 1.4-SNAPSHOT

@Jab125
Copy link
Member

Jab125 commented Jan 18, 2024

Jar in Jar'd mods are removed on remap.
Geckolib should add the JiJ'd dependency as a normal dependency.

@slava110
Copy link
Author

There is normal dependency but it doesn't load in the game.
I'm adding it using

implementation("com.eliotlash.mclib:mclib:20")

But when I launch my game in dev environment I'm getting
image

Is there any reason why jar-in-jar mods are removed on remap? Also why only metadata is removed on remap, not the actual jar file inside META-INF/jarjar directory?

@Jab125
Copy link
Member

Jab125 commented Jan 18, 2024

consistency with fabric mods getting their JiJ'd files removed probably

@Juuxel
Copy link
Member

Juuxel commented Jan 18, 2024

Is there any reason why jar-in-jar mods are removed on remap? Also why only metadata is removed on remap, not the actual jar file inside META-INF/jarjar directory?

Both are done for consistency with Fabric. (Deleting the actual jars isn't necessary here, it's easier to remove the metadata file.)

Jar-in-jar deps are also not easy to remap, so they are removed to fix issues such as #125. See #159.

@Juuxel Juuxel closed this as not planned Won't fix, can't repro, duplicate, stale Jan 18, 2024
@slava110
Copy link
Author

Is it possible for it to leave dependency if it isn't obfuscated? I think there is JSON property in metadata.json to specify if dependency is obfuscated or not

@Juuxel
Copy link
Member

Juuxel commented Jan 19, 2024

No, since all dependencies should still be available as their normal variants in the mod's POM file. This is for consistency between different platforms.

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