JustEnoughResources icon indicating copy to clipboard operation
JustEnoughResources copied to clipboard

1.12.2 profile command freezes world server

Open tyon2006 opened this issue 4 years ago • 5 comments

Hello! I am running /jer_profile 1 0 in single player mode and it seems to freeze the world server. The client continues to run, but blocks stop ticking and mobs stop moving when I run this. I've run this as long as 10 minutes before closing down. Can you provide guidance on how to run a profile for the overworld or help address as undesired behavior?

tyon2006 avatar Aug 29 '21 20:08 tyon2006

Freezing should normally not happen, but is possible especially when doing large scans.
Is there any spam in the client log when you do something link /jer_profile 10 all ?

way2muchnoise avatar Aug 30 '21 15:08 way2muchnoise

I tried that exact command and this is what I got:

image

image

Looks like a incompat with customoregen

[16:07:57] [Server thread/FATAL]: Error executing task
java.util.concurrent.ExecutionException: java.lang.RuntimeException: CustomOreGen: Detected a possible infinite loop during bezier interpolation.  Please report this error.
	at java.util.concurrent.FutureTask.report(FutureTask.java:122) ~[?:1.8.0_51]
	at java.util.concurrent.FutureTask.get(FutureTask.java:192) ~[?:1.8.0_51]
	at net.minecraft.util.Util.runTask(SourceFile:531) [h.class:?]
	at net.minecraft.server.MinecraftServer.updateTimeLightAndEntities(MinecraftServer.java:723) [MinecraftServer.class:?]
	at net.minecraft.server.MinecraftServer.tick(MinecraftServer.java:668) [MinecraftServer.class:?]
	at net.minecraft.server.integrated.IntegratedServer.tick(IntegratedServer.java:185) [chd.class:?]
	at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:526) [MinecraftServer.class:?]
	at java.lang.Thread.run(Thread.java:745) [?:1.8.0_51]
Caused by: java.lang.RuntimeException: CustomOreGen: Detected a possible infinite loop during bezier interpolation.  Please report this error.
	at CustomOreGen.Server.MapGenVeins$BezierTubeComponent$interpolationContext.advance(MapGenVeins.java:625) ~[MapGenVeins$BezierTubeComponent$interpolationContext.class:?]
	at CustomOreGen.Server.MapGenVeins$BezierTubeComponent.addComponentParts(MapGenVeins.java:477) ~[MapGenVeins$BezierTubeComponent.class:?]
	at svenhjol.charm.base.ASMHooks.addComponentParts(ASMHooks.java:76) ~[ASMHooks.class:1.4.1]
	at net.minecraft.world.gen.structure.StructureStart.generateStructure(StructureStart.java:47) ~[bby.class:?]
	at CustomOreGen.Server.MapGenOreDistribution$StructureGroup.generateStructure(MapGenOreDistribution.java:729) ~[MapGenOreDistribution$StructureGroup.class:?]
	at CustomOreGen.Server.MapGenOreDistribution.generateStructuresInChunk(MapGenOreDistribution.java:553) ~[MapGenOreDistribution.class:?]
	at CustomOreGen.Server.MapGenOreDistribution.populate(MapGenOreDistribution.java:278) ~[MapGenOreDistribution.class:?]
	at CustomOreGen.Server.ServerState.populateDistributions(ServerState.java:141) ~[ServerState.class:?]
	at CustomOreGen.Server.ServerState.onPopulateChunk(ServerState.java:202) ~[ServerState.class:?]
	at CustomOreGen.FMLInterface.generate(FMLInterface.java:80) ~[FMLInterface.class:?]
	at net.minecraftforge.fml.common.registry.GameRegistry.generateWorld(GameRegistry.java:167) ~[GameRegistry.class:?]
	at net.minecraft.world.chunk.Chunk.populate(Chunk.java:1020) ~[axw.class:?]
	at net.minecraft.world.chunk.Chunk.populate(Chunk.java:999) ~[axw.class:?]
	at net.minecraft.world.gen.ChunkProviderServer.provideChunk(ChunkProviderServer.java:157) ~[on.class:?]
	at net.minecraft.world.World.getChunk(World.java:310) ~[amu.class:?]
	at jeresources.profiling.ChunkGetter.centerChunks(ChunkGetter.java:148) ~[ChunkGetter.class:?]
	at jeresources.profiling.ChunkGetter.access$700(ChunkGetter.java:12) ~[ChunkGetter.class:?]
	at jeresources.profiling.ChunkGetter$ChunkGetterRandom.generateChunks(ChunkGetter.java:105) ~[ChunkGetter$ChunkGetterRandom.class:?]
	at jeresources.profiling.ChunkGetter$1.run(ChunkGetter.java:34) ~[ChunkGetter$1.class:?]
	at jeresources.profiling.ChunkGetter.run(ChunkGetter.java:60) ~[ChunkGetter.class:?]
	at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) ~[?:1.8.0_51]
	at java.util.concurrent.FutureTask.run(FutureTask.java:266) ~[?:1.8.0_51]
	at net.minecraft.util.Util.runTask(SourceFile:529) ~[h.class:?]
	... 5 more
[16:07:57] [Server thread/WARN]: Can't keep up! Did the system time change, or is the server overloaded? Running 3771ms behind, skipping 75 tick(s)

tyon2006 avatar Sep 04 '21 20:09 tyon2006

Looks like a cross mod issue with CustomOreGen, would also report to them. I don't really support 1.12 anymore, but if needed I can make a fix if we can figure it out.

way2muchnoise avatar Sep 07 '21 09:09 way2muchnoise

I've reported this over to customoregen, but I suspect that project is dead.

tyon2006 avatar Feb 16 '22 16:02 tyon2006

Looks like the random sampling of chunks causes some issue with the generation algorithm, which might only behave well under ordinary chunk generation. While I've been maintaining CustomOreGen since like 1.4.7 times, I'm not the original author, and don't fully understand all of the algorithms. A possible fix would be to pregen a sufficiently large part of the world and then sample it.

lawremi avatar Feb 17 '22 03:02 lawremi

Exactly right! If you remove the mod the scan completes perfectly and results are as expected. Awesome!

tyon2006 avatar Sep 15 '22 21:09 tyon2006