PaperMC / PaperMC/Folia

Server crash - ConcurrentModificationException at ServerDebugSubscribers.tick (1.21.11)

Open
#472 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

status: needs triage
Dominant language
Shell
Stars
4.4k
Forks
623
PR merge metrics
No merged PRs in 30d

Description

Stack trace
[15:32:05] [Folia Region Scheduler Thread #7/ERROR]: [io.papermc.paper.threadedregions.TickRegionScheduler] Region #920922 centered at chunk [-752, -816] in world 'survival' failed to tick:
java.util.ConcurrentModificationException
	at java.base/java.util.HashMap$HashIterator.remove(HashMap.java:1620) ~[?:?]
	at java.base/java.util.Collection.removeIf(Collection.java:582) ~[?:?]
	at net.minecraft.util.debug.ServerDebugSubscribers.tick(ServerDebugSubscribers.java:35) ~[folia-1.21.11.jar:1.21.11-14-529aabc]
	at net.minecraft.server.MinecraftServer.tickChildren(MinecraftServer.java:1946) ~[folia-1.21.11.jar:1.21.11-14-529aabc]
	at net.minecraft.server.MinecraftServer.tickServer(MinecraftServer.java:1740) ~[folia-1.21.11.jar:1.21.11-14-529aabc]
	at net.minecraft.server.dedicated.DedicatedServer.tickServer(DedicatedServer.java:429) ~[folia-1.21.11.jar:1.21.11-14-529aabc]
	at io.papermc.paper.threadedregions.TickRegions$ConcreteRegionTickHandle.tickRegion(TickRegions.java:485) ~[folia-1.21.11.jar:1.21.11-14-529aabc]
	at io.papermc.paper.threadedregions.TickRegionScheduler$RegionScheduleHandle.runTick(TickRegionScheduler.java:481) ~[folia-1.21.11.jar:1.21.11-14-529aabc]
	at ca.spottedleaf.concurrentutil.scheduler.EDFSchedulerThreadPool$TickThreadRunner.run(EDFSchedulerThreadPool.java:526) ~[concurrentutil-0.0.8.jar:?]
	at java.base/java.lang.Thread.run(Thread.java:1474) ~[?:?]
[15:32:05] [Region shutdown thread/INFO]: [RegionShutdownThread] Awaiting scheduler termination for 60s...
[15:32:05] [Region shutdown thread/INFO]: [RegionShutdownThread] Scheduler halted
[15:32:05] [Region shutdown thread/INFO]: Stopping server
Plugin and Datapack List

[15:53:55 INFO]: ℹ Server Plugins (73):
[15:53:55 INFO]: Paper Plugins (8):
[15:53:55 INFO]: - BASZ-LimitDrop, BASZ-Shutdown, ChatGames, FancyHolograms, FancyNpcs, Nexo, NexoAddon, Worlds
[15:53:55 INFO]: Bukkit Plugins (65):
[15:53:55 INFO]: - ajLeaderboards, Apollo-Folia, AuraSkills, AxPlayerWarps, AxTrade, BASZ-AC, BASZ-AuctionHouse, BASZ-CHAT, BASZ-ChatLink, BASZ-CheckShort
[15:53:55 INFO]: BASZ-Coinflip, BASZ-COMBAT, BASZ-CORE, BASZ-CosmeticsSkin, BASZ-item-transaction, BASZ-Jail, BASZ-Label, BASZ-LINKDC-folia, BASZ-MC-Amethyst, BASZ-MC-BOSS
[15:53:55 INFO]: BASZ-MC-Orders, BASZ-MC-PsSetting, BASZ-MC-SELL, BASZ-MC-Shop, BASZ-MobCatcher, BASZ-NoMoreCollision, BASZ-Patch, BASZ-PlayerTexture, BASZ-PrivateChests, BASZ-Spawner
[15:53:55 INFO]: BASZCrossSync, BASZTeam, BetterBounty, BlueSpoof, ChatHeadFont, Chunky, CMILib, DonutCrates, Essentials, EssentialsSpawn
[15:53:55 INFO]: FakePlayer, floodgate, ItemEdit, LPC, LuckPerms, MailboxPlugin, ODailyQuests, packetevents, PhoenixCrates, PlaceholderAPI
[15:53:55 INFO]: PlugManX, ProtectionStones, PSAnvilGUI, QuickShop-Hikari, SkinsRestorer, spark, SpawnFix, TAB, Vault, ViaVersion
[15:53:55 INFO]: voicechat, WorldEdit, WorldGuard, WorldGuardExtraFlagsPlus, zMenu

Actions to reproduce (if known)

No response

Folia version

Folia 1.21.11-14

Other

No response

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start at net.minecraft.util.debug.ServerDebugSubscribers.tick, the entry point named in the stack trace, and inspect how the reported Collection.removeIf call is reached during MinecraftServer.tickChildren. Reproduce the crash with Folia 1.21.11-14 if possible using the supplied server context; done means the server no longer terminates with this ConcurrentModificationException and the failure path is covered by an appropriate regression check.

Written by the indexing model from the issue text.

Assessment

Tech stack
java
Domain
backend
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Quiet
Clarity
Needs clarification
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.