Biome Id Fixer (Forge)

Biome Id Fixer (Forge)

2M Downloads

Massive debug.log spam

aaronhowser1 opened this issue · 18 comments

commented

Describe the bug
image

Looks like it's making a new line for every biome, instead of just putting them all in one?
image

The first 41000-odd lines are all from this mod. I would upload it but I literally can't because it's 123MB.

Screenshots AND BiomeIdFixer jsonFiles
If applicable, add screenshots and your biomeidfixer(doNOTedit).json files to help explain your problem.

Versions (please complete the following information):

  • Forge Version: 36.2.2
  • Biome mods and Versions: A lot, but I don't think they're the problem
  • Version of Biome Fixer: biomeidfixer-1.16.5-1.0.1.s4
commented

But, I can not actually make it any less without removing it all together, as this is the way Minecraft and Forge actually register biomes. They are not all registered at once.

I did try to make it only show the last line, but, if anything goes wrong in between, I would have no way of finding out what went wrong, and, it is almost impossible to know when there are no more biomes to register.

I’ll try and take a look again in the next few days here.

commented

These is a reason why it is called debug …

commented

You think it's normal for any single mod to make the debug.log 123 MB? That's how big this one is after removing everything that isn't from Biome ID Fixer.

image

commented

I did try and introduce code that did a check if the line already existed, then do not log it. But, something went wrong, and it didn’t work as intended, it is still on the plate. I tried asking for help in the missing community, but got nothing. Literally, some discord servers told me not to even fix what I fixed, some told me my code was garbage, but wouldn’t tell me how …

This was my first mod, my first time coding, my first time learning how brutal this community is.

that said, I’m open for specific feedback

commented

I am aware the log is big. If you have an idea of how to reduce it, that would help, within the context of my code …

commented

Is the only way to get a list of all biomes to print it to the log over forty thousand times? What benefit is there to logging it like this? The first line having one biome, the second line having that biome and another, the third having those two and another, why does it do any but the last line with all of them?

commented

Why does it write anything until it's done making the list of biomes? Is it not saving that list anywhere outside of the debug.log? image
Why does it do it multiple times?
image

Am I understanding correctly that it goes through the entire list factorial(biome count) times? If it's comparing every biome to every other biome. There's not really a reason to log all of this, is there? Unless it's pulling the list of biomes it's already compared to from the debug.log, which it should super not be doing if so.

commented

why does it do any but the last line with all of them?

As soon as I can access the forge Gradle again, which hasn’t been working for me at all over the last couple weeks, I will try again to have it only log the newest added line, rather than the archive. However, this will only reduce the size of the lines with each new biome, and not the number of lines.

Sadly, the number of lines is a direct result of Forge and Minecraft biome registrations. This is the exact number of times when loading your world that Minecraft and Forge have fired a biome registration event.

commented

Even if it were one biome per line (rather, if it's doing 1 biome pair per line, I suppose) that would cut it by a lot. But... could we get a config option or something to disable the logging entirely? That's still a massive amount of lines, for something that we don't really need to know unless it goes wrong, in which case we would just enable the config and relaunch.

commented

Ah, yes, when you add a new mod, or update an existing mod with new biomes or deleted biomes or remove mods with biomes, this will happen.

I was thinking of adding a config option to stop this comparison from happening. I see what you are saying. I may shut it off all together. As soon as I have my new dev environment up and running, I’ll do that. I agree, it is not necessary, at least, not for the end user.

commented

This happens every time I launch a world, with no mod changes. I've had changes in the past that added/removed biomes, but not in a few weeks

Unfortunately, because this mod checks for differences to biomes when world was first created against present, it doesn’t matter if it has been a few weeks. Forge and Minecraft will still try to reassign the biome ids, sadly, which is why this check happens. But, we can reduce the debug spam.

commented

This happens every time I launch a world, with no mod changes. I've had changes in the past that added/removed biomes, but not in a few weeks

commented

So, with this fix that I’ll implement, it should reduce ~95% of the debug spam. Fingers crossed.

commented

Awesome, tysm

commented

You’re the Aaron from Discord, FTB University, are you not? Thanks for the help in talking me through what you meant.

commented

yep yep, feel free to ping me if needed

commented

Here is a temp fix, it just removes that spam period. After thinking about it, I can not see a reason to have it in the first place. This will do until it doesn't, at which point I will have to work on building strings a bit better.

CurseForge just needs to approve it first, and then the link should work.

https://www.curseforge.com/minecraft/mc-mods/biome-id-fixer/files/3446595

commented

Thank you very much!