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

Datagen Failure with Sniffer+ #5

Closed
xanthian opened this issue Jul 15, 2023 · 5 comments
Closed

Datagen Failure with Sniffer+ #5

xanthian opened this issue Jul 15, 2023 · 5 comments
Labels
bug Something isn't working

Comments

@xanthian
Copy link

I'm trying to create compatability for Sniffer+ in a number of my 'Variant' style mods,

I've added Sniffer+ to build.gradle
modImplementation("curse.maven:hellionssiffer-871962:4591532")

Error log states :

Caused by: java.lang.IllegalStateException: Errors during registry creation
Suppressed: java.lang.IllegalStateException: Unreferenced key: ResourceKey[minecraft:worldgen/biome / snifferplus:timeless_grotto]
at net.minecraft.registry.RegistryBuilder$Registries.validateReferences(RegistryBuilder.java:128) ~[minecraft-merged-project-root-1.20.1-net.fabricmc.yarn.1_20_1.1.20.1+build.9-v2.jar:?]
at net.minecraft.registry.RegistryBuilder.createWrapperLookup(RegistryBuilder.java:268) ~[minecraft-merged-project-root-1.20.1-net.fabricmc.yarn.1_20_1.1.20.1+build.9-v2.jar:?]
at net.fabricmc.fabric.impl.datagen.FabricDataGenHelper.createRegistryWrapper(FabricDataGenHelper.java:194) ~[fabric-data-generation-api-v1-12.1.12+b3afc78b77.jar:?]
at net.fabricmc.fabric.impl.datagen.FabricDataGenHelper.lambda$runInternal$0(FabricDataGenHelper.java:108) ~[fabric-data-generation-api-v1-12.1.12+b3afc78b77.jar:?]
at java.util.concurrent.CompletableFuture$AsyncSupply.run(CompletableFuture.java:1768) ~[?:?]
at java.util.concurrent.CompletableFuture$AsyncSupply.exec(CompletableFuture.java:1760) ~[?:?]
at java.util.concurrent.ForkJoinTask.doExec(ForkJoinTask.java:373) ~[?:?]
at java.util.concurrent.ForkJoinPool$WorkQueue.topLevelExec(ForkJoinPool.java:1182) ~[?:?]
at java.util.concurrent.ForkJoinPool.scan(ForkJoinPool.java:1655) ~[?:?]
at java.util.concurrent.ForkJoinPool.runWorker(ForkJoinPool.java:1622) ~[?:?]
at java.util.concurrent.ForkJoinWorkerThread.run(ForkJoinWorkerThread.java:165) ~[?:?]

If i remove the Sniffer+ implementation from Gradle my datagen runs perfectly fine.
Link to 1 of my mods with gradle setup
https://github.com/xanthian/variantcraftingtables/tree/1.20

@Dariensg
Copy link
Owner

Hmmm... Datagen is still pretty new to me and I've never implemented it myself, so I'm not entirely sure here. My best guess is that, since I use JSON biomes for the Timeless Grotto, your datagen is picking up on the fact that the key exists, but is confused that it doesn't exist anywhere in code. I'm not too sure how you'd get around this or that it's really what's happening, but that's my gut reaction. I'd have to go through a bit more closely to confirm 100% that the Timeless Grotto resource key never shows up in code, but a quick glance through the relevant packages turned up nothing. I'm not sure how you'd get around this, however, but you'd probably know better than I since you seem to have worked with datagen quite a bit. Happy to continue discussing this until we can figure it out!

@xanthian
Copy link
Author

Hi, thanks for replying!
I'm far far from a datagen expert, only decided to adopt it in 1.20.x this is probably maybe 5th mod using it.
But its the 1st time I've required to implement other mods I'm wanting to add compatibility for.
The recipe and model datagen require the block/item from the mod source to generate the files, so implementation is required.
If it was a string value none of this would be an issue!!
I've not worked with biomes before, so i'm clueless on this.

@Dariensg
Copy link
Owner

Every block in the mod definitely has an in-code implementation. The only thing I can think of that shouldn't is the biome, as the error here seems to indicate, and some of the features used in that biome. I'd say this may actually be a question for the Fabric team. They would probably be able to answer it better than I can, since they most likely have a better sense of how their datagen is working. Here is their Discord. Let me know if I can help with anything else!

@xanthian
Copy link
Author

Raised it on Fabric Git but it got closed..
FabricMC/fabric#3199
no clue..

@Dariensg
Copy link
Owner

Yeah, Git is for issues typically, not support. As their bot said, it's better suited for a discussion thread or their discord, which is why I linked their discord.

@Dariensg Dariensg added the bug Something isn't working label Sep 23, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants