Custom-Ore-Generator icon indicating copy to clipboard operation
Custom-Ore-Generator copied to clipboard

Server Crashed: WorldConfig not Parsed from File

Open Cynadyde opened this issue 5 years ago • 4 comments

I am using spigot mc 1.15.2 and custom-ore-generator 2020.02.29

My server crashed while was I traveling through a world using the custom-ore-generator plugin. From the error message, I could tell it's because of an error during chunk generation: Caused by: java.lang.RuntimeException: File plugins/custom-ore-generator/data/world-config/world13_subterra.yml does not have a WorldConfig under the key 'value'.

I've pasted the contents of world13_subterra.yml below. (I have not edited the file at all) Interestingly, the plugin was generating chunks just fine until I restarted the server. After this, the plugin generated the world13_subterra.yml file and began trying to parse it when I loaded a new chunk. I've pasted the stack trace below as well.

# Only edit this file if you 10000% sure you know what you are doing. 
# You can set everything via the plugin commands, no need to edit this file manully.
value:
  ==: CustomOreGenerator#WorldConfig
  name: world13_subterra
  ore-config:
  - subterra_lights
  - subterra_prismarine
[05:31:47] [Server thread/ERROR]: Encountered an unexpected exception
net.minecraft.server.v1_15_R1.ReportedException: Exception generating new chunk
	at net.minecraft.server.v1_15_R1.MinecraftServer.b(MinecraftServer.java:1095) ~[spigot-1.15.2.jar:git-Spigot-c574e08-708be69]
	at net.minecraft.server.v1_15_R1.DedicatedServer.b(DedicatedServer.java:406) ~[spigot-1.15.2.jar:git-Spigot-c574e08-708be69]
	at net.minecraft.server.v1_15_R1.MinecraftServer.a(MinecraftServer.java:984) ~[spigot-1.15.2.jar:git-Spigot-c574e08-708be69]
	at net.minecraft.server.v1_15_R1.MinecraftServer.run(MinecraftServer.java:824) [spigot-1.15.2.jar:git-Spigot-c574e08-708be69]
	at java.lang.Thread.run(Thread.java:748) [?:1.8.0_242]
Caused by: java.lang.RuntimeException: File plugins/custom-ore-generator/data/world-config/world13_subterra.yml does not have a WorldConfig under the key 'value'
	at de.derfrzocker.custom.ore.generator.impl.dao.LazyWorldConfigCache.getWorldConfig(LazyWorldConfigCache.java:127) ~[?:?]
	at de.derfrzocker.custom.ore.generator.impl.dao.WorldConfigYamlDao.get(WorldConfigYamlDao.java:65) ~[?:?]
	at de.derfrzocker.custom.ore.generator.impl.dao.WorldConfigYamlDao.get(WorldConfigYamlDao.java:37) ~[?:?]
	at de.derfrzocker.custom.ore.generator.impl.CustomOreGeneratorServiceImpl.getWorldConfig(CustomOreGeneratorServiceImpl.java:191) ~[?:?]
	at de.derfrzocker.custom.ore.generator.impl.v1_15_R1.ChunkOverrider.addDecorations(ChunkOverrider.java:109) ~[?:?]
	at net.minecraft.server.v1_15_R1.ChunkStatus.c(SourceFile:84) ~[spigot-1.15.2.jar:git-Spigot-c574e08-708be69]
	at net.minecraft.server.v1_15_R1.ChunkStatus.a(SourceFile:214) ~[spigot-1.15.2.jar:git-Spigot-c574e08-708be69]
	at net.minecraft.server.v1_15_R1.PlayerChunkMap.lambda$26(PlayerChunkMap.java:524) ~[spigot-1.15.2.jar:git-Spigot-c574e08-708be69]
	at com.mojang.datafixers.util.Either$Left.map(Either.java:38) ~[spigot-1.15.2.jar:git-Spigot-c574e08-708be69]
	at net.minecraft.server.v1_15_R1.PlayerChunkMap.lambda$24(PlayerChunkMap.java:522) ~[spigot-1.15.2.jar:git-Spigot-c574e08-708be69]
	at java.util.concurrent.CompletableFuture.uniCompose(CompletableFuture.java:966) ~[?:1.8.0_242]
	at java.util.concurrent.CompletableFuture$UniCompose.tryFire(CompletableFuture.java:940) ~[?:1.8.0_242]
	at java.util.concurrent.CompletableFuture$Completion.run(CompletableFuture.java:456) ~[?:1.8.0_242]
	at net.minecraft.server.v1_15_R1.ChunkTaskQueueSorter.b(SourceFile:58) ~[spigot-1.15.2.jar:git-Spigot-c574e08-708be69]
	at net.minecraft.server.v1_15_R1.ThreadedMailbox.e(SourceFile:83) ~[spigot-1.15.2.jar:git-Spigot-c574e08-708be69]
	at net.minecraft.server.v1_15_R1.ThreadedMailbox.a(SourceFile:123) ~[spigot-1.15.2.jar:git-Spigot-c574e08-708be69]
	at net.minecraft.server.v1_15_R1.ThreadedMailbox.run(SourceFile:91) ~[spigot-1.15.2.jar:git-Spigot-c574e08-708be69]
	at java.util.concurrent.ForkJoinTask$RunnableExecuteAction.exec(ForkJoinTask.java:1402) ~[?:1.8.0_242]
	at java.util.concurrent.ForkJoinTask.doExec(ForkJoinTask.java:289) ~[?:1.8.0_242]
	at java.util.concurrent.ForkJoinPool$WorkQueue.runTask(ForkJoinPool.java:1056) ~[?:1.8.0_242]
	at java.util.concurrent.ForkJoinPool.runWorker(ForkJoinPool.java:1692) ~[?:1.8.0_242]
	at java.util.concurrent.ForkJoinWorkerThread.run(ForkJoinWorkerThread.java:157) ~[?:1.8.0_242]
[05:31:47] [Server thread/ERROR]: 	Cause of unexpected exception was
java.lang.RuntimeException: File plugins/custom-ore-generator/data/world-config/world13_subterra.yml does not have a WorldConfig under the key 'value'
	at de.derfrzocker.custom.ore.generator.impl.dao.LazyWorldConfigCache.getWorldConfig(LazyWorldConfigCache.java:127) ~[?:?]
	at de.derfrzocker.custom.ore.generator.impl.dao.WorldConfigYamlDao.get(WorldConfigYamlDao.java:65) ~[?:?]
	at de.derfrzocker.custom.ore.generator.impl.dao.WorldConfigYamlDao.get(WorldConfigYamlDao.java:37) ~[?:?]
	at de.derfrzocker.custom.ore.generator.impl.CustomOreGeneratorServiceImpl.getWorldConfig(CustomOreGeneratorServiceImpl.java:191) ~[?:?]
	at de.derfrzocker.custom.ore.generator.impl.v1_15_R1.ChunkOverrider.addDecorations(ChunkOverrider.java:109) ~[?:?]
	at net.minecraft.server.v1_15_R1.ChunkStatus.c(SourceFile:84) ~[spigot-1.15.2.jar:git-Spigot-c574e08-708be69]
	at net.minecraft.server.v1_15_R1.ChunkStatus.a(SourceFile:214) ~[spigot-1.15.2.jar:git-Spigot-c574e08-708be69]
	at net.minecraft.server.v1_15_R1.PlayerChunkMap.lambda$26(PlayerChunkMap.java:524) ~[spigot-1.15.2.jar:git-Spigot-c574e08-708be69]
	at com.mojang.datafixers.util.Either$Left.map(Either.java:38) ~[spigot-1.15.2.jar:git-Spigot-c574e08-708be69]
	at net.minecraft.server.v1_15_R1.PlayerChunkMap.lambda$24(PlayerChunkMap.java:522) ~[spigot-1.15.2.jar:git-Spigot-c574e08-708be69]
	at java.util.concurrent.CompletableFuture.uniCompose(CompletableFuture.java:966) ~[?:1.8.0_242]
	at java.util.concurrent.CompletableFuture$UniCompose.tryFire(CompletableFuture.java:940) ~[?:1.8.0_242]
	at java.util.concurrent.CompletableFuture$Completion.run(CompletableFuture.java:456) ~[?:1.8.0_242]
	at net.minecraft.server.v1_15_R1.ChunkTaskQueueSorter.b(SourceFile:58) ~[spigot-1.15.2.jar:git-Spigot-c574e08-708be69]
	at net.minecraft.server.v1_15_R1.ThreadedMailbox.e(SourceFile:83) ~[spigot-1.15.2.jar:git-Spigot-c574e08-708be69]
	at net.minecraft.server.v1_15_R1.ThreadedMailbox.a(SourceFile:123) ~[spigot-1.15.2.jar:git-Spigot-c574e08-708be69]
	at net.minecraft.server.v1_15_R1.ThreadedMailbox.run(SourceFile:91) ~[spigot-1.15.2.jar:git-Spigot-c574e08-708be69]
	at java.util.concurrent.ForkJoinTask$RunnableExecuteAction.exec(ForkJoinTask.java:1402) ~[?:1.8.0_242]
	at java.util.concurrent.ForkJoinTask.doExec(ForkJoinTask.java:289) ~[?:1.8.0_242]
	at java.util.concurrent.ForkJoinPool$WorkQueue.runTask(ForkJoinPool.java:1056) ~[?:1.8.0_242]
	at java.util.concurrent.ForkJoinPool.runWorker(ForkJoinPool.java:1692) ~[?:1.8.0_242]
	at java.util.concurrent.ForkJoinWorkerThread.run(ForkJoinWorkerThread.java:157) ~[?:1.8.0_242]
[05:31:47] [Server thread/ERROR]: This crash report has been saved to: /mc_servers/main_server/./crash-reports/crash-2020-04-04_05.31.47-server.txt
[05:31:47] [Server thread/INFO]: Stopping server
[05:31:48] [Server thread/INFO]: Saving chunks for level 'world13_subterra'/minecraft:world13_subterra
[05:31:49] [Server thread/ERROR]: Exception stopping the server
java.util.concurrent.CompletionException: net.minecraft.server.v1_15_R1.ReportedException: Exception generating new chunk
	at java.util.concurrent.CompletableFuture.encodeThrowable(CompletableFuture.java:273) ~[?:1.8.0_242]
	at java.util.concurrent.CompletableFuture.completeThrowable(CompletableFuture.java:280) ~[?:1.8.0_242]
	at java.util.concurrent.CompletableFuture.uniCompose(CompletableFuture.java:975) ~[?:1.8.0_242]
	at java.util.concurrent.CompletableFuture$UniCompose.tryFire(CompletableFuture.java:940) ~[?:1.8.0_242]
	at java.util.concurrent.CompletableFuture$Completion.run(CompletableFuture.java:456) ~[?:1.8.0_242]
	at net.minecraft.server.v1_15_R1.ChunkTaskQueueSorter.b(SourceFile:58) ~[spigot-1.15.2.jar:git-Spigot-c574e08-708be69]
	at net.minecraft.server.v1_15_R1.ThreadedMailbox.e(SourceFile:83) ~[spigot-1.15.2.jar:git-Spigot-c574e08-708be69]
	at net.minecraft.server.v1_15_R1.ThreadedMailbox.a(SourceFile:123) ~[spigot-1.15.2.jar:git-Spigot-c574e08-708be69]
	at net.minecraft.server.v1_15_R1.ThreadedMailbox.run(SourceFile:91) ~[spigot-1.15.2.jar:git-Spigot-c574e08-708be69]
	at java.util.concurrent.ForkJoinTask$RunnableExecuteAction.exec(ForkJoinTask.java:1402) ~[?:1.8.0_242]
	at java.util.concurrent.ForkJoinTask.doExec(ForkJoinTask.java:289) ~[?:1.8.0_242]
	at java.util.concurrent.ForkJoinPool$WorkQueue.runTask(ForkJoinPool.java:1056) ~[?:1.8.0_242]
	at java.util.concurrent.ForkJoinPool.runWorker(ForkJoinPool.java:1692) ~[?:1.8.0_242]
	at java.util.concurrent.ForkJoinWorkerThread.run(ForkJoinWorkerThread.java:157) ~[?:1.8.0_242]
Caused by: net.minecraft.server.v1_15_R1.ReportedException: Exception generating new chunk
	at net.minecraft.server.v1_15_R1.PlayerChunkMap.lambda$26(PlayerChunkMap.java:537) ~[spigot-1.15.2.jar:git-Spigot-c574e08-708be69]
	at com.mojang.datafixers.util.Either$Left.map(Either.java:38) ~[spigot-1.15.2.jar:git-Spigot-c574e08-708be69]
	at net.minecraft.server.v1_15_R1.PlayerChunkMap.lambda$24(PlayerChunkMap.java:522) ~[spigot-1.15.2.jar:git-Spigot-c574e08-708be69]
	at java.util.concurrent.CompletableFuture.uniCompose(CompletableFuture.java:966) ~[?:1.8.0_242]
	... 11 more
Caused by: java.lang.RuntimeException: File plugins/custom-ore-generator/data/world-config/world13_subterra.yml does not have a WorldConfig under the key 'value'
	at de.derfrzocker.custom.ore.generator.impl.dao.LazyWorldConfigCache.getWorldConfig(LazyWorldConfigCache.java:127) ~[?:?]
	at de.derfrzocker.custom.ore.generator.impl.dao.WorldConfigYamlDao.get(WorldConfigYamlDao.java:65) ~[?:?]
	at de.derfrzocker.custom.ore.generator.impl.dao.WorldConfigYamlDao.get(WorldConfigYamlDao.java:37) ~[?:?]
	at de.derfrzocker.custom.ore.generator.impl.CustomOreGeneratorServiceImpl.getWorldConfig(CustomOreGeneratorServiceImpl.java:191) ~[?:?]
	at de.derfrzocker.custom.ore.generator.impl.v1_15_R1.ChunkOverrider.addDecorations(ChunkOverrider.java:109) ~[?:?]
	at net.minecraft.server.v1_15_R1.ChunkStatus.c(SourceFile:84) ~[spigot-1.15.2.jar:git-Spigot-c574e08-708be69]
	at net.minecraft.server.v1_15_R1.ChunkStatus.a(SourceFile:214) ~[spigot-1.15.2.jar:git-Spigot-c574e08-708be69]
	at net.minecraft.server.v1_15_R1.PlayerChunkMap.lambda$26(PlayerChunkMap.java:524) ~[spigot-1.15.2.jar:git-Spigot-c574e08-708be69]
	at com.mojang.datafixers.util.Either$Left.map(Either.java:38) ~[spigot-1.15.2.jar:git-Spigot-c574e08-708be69]
	at net.minecraft.server.v1_15_R1.PlayerChunkMap.lambda$24(PlayerChunkMap.java:522) ~[spigot-1.15.2.jar:git-Spigot-c574e08-708be69]
	at java.util.concurrent.CompletableFuture.uniCompose(CompletableFuture.java:966) ~[?:1.8.0_242]
	... 11 more

Cynadyde avatar Apr 04 '20 09:04 Cynadyde

Is there also an IllegalArgumentException error message?

Like this one:

java.lang.IllegalArgumentException: CustomOreGeneratorService can not be null
	at org.apache.commons.lang.Validate.notNull(Validate.java:192) ~[spigot-1.15.2.jar:git-Spigot-a03b1fd-5838285]
	at de.derfrzocker.custom.ore.generator.impl.WorldConfigYamlImpl.deserialize(WorldConfigYamlImpl.java:65) ~[?:?]
	at jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:?]
	at jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[?:?]
	at jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:?]
	at java.lang.reflect.Method.invoke(Method.java:567) ~[?:?]
...

DerFrZocker avatar Apr 05 '20 08:04 DerFrZocker

Nope. Just two RuntimeExceptions that had the same cause. I've edited my post to include both of them, anyways.

Cynadyde avatar Apr 06 '20 07:04 Cynadyde

Can you test this development version? And see if the Error still persists. Since I can not reproduce the Issues I can not test it my self.

custom-ore-generator-dev-SNAPSHOT.zip

DerFrZocker avatar Apr 11 '20 09:04 DerFrZocker

This issue happened twice on the production server, both following these steps below. However, I just retraced my steps on a test server with custom-ore-generator 2020.02.29 and could not reproduce the issue, either.

  • I used the "add" command to add two ore-configs to a world that previously had none.
  • the world config was not immediately generated
  • I generated new chunks in that world
  • I restarted the server
  • the world config was generated
  • I attempted to generate additional chunks in that world
  • The error was thrown

Anyways, the snapshot appears to work so far. Hopefully, the bug will no longer trouble you or I. Thank you for responding and sorry for the troubles!

Cynadyde avatar Apr 11 '20 21:04 Cynadyde