#folia

1 messages · Page 1 of 1 (latest)

unique yacht
coarse tokenBOT
#

Expected behavior

Exprected that PlayerDeathEvent would be called when cancelling EntityResurrectEvent but this is not the case.

Observed/Actual behavior

I tested on a barebones paper server and folia server with the same plugin and on paper the PlayerDeathEvent is called after cancelling the EntityResurrectEvent but on folia it was not the case.

Tested on 1.21.4 latest release from folia and paper for each test server

Steps/models to reproduce

@EventHandler
public void onDeath(PlayerDeathEvent e) {
    getLogger().info(e.getEventName());
}
@EventHandler
public void onResurrect(EntityResurrectEvent e) {
    e.setCancelled(true);
}

Plugin and Datapack List

no plugins but what i showed in the steps to reproduce

Folia version

1.21.4 latest folia release

Other

No response

coarse tokenBOT
#

I'm using the bundler jar which was built with the paper recommended method

./gradlew applyPatches
./gradlew createMojmapBundlerJar

This server is running Folia version 1.21.4-DEV-master@8af1aef (2025-02-22T21:14:25Z) (Implementing API version 1.21.4-R0.1-SNAPSHOT)
You are running the latest version
Previous version: 1.21.4-DEV-1c0ecd3 (MC: 1.21.4)

I rebuilt it twice now from scratch, deleted the github clone and started over. Same results.

Cancelling the resurrect event is making a keep inventory happen.

I can send a video if you don't believe me.

The only plugin is a plugin which uses this code in the main class

When i swap to the latest paper version the problem does not happen. I also tried the reobfuscated version but that is not compatible with basically any plugins these days so I have to use the mojang mappings, which from my understanding is what paper switched to in 1.21.

@EventHandler
public void onDeath(PlayerDeathEvent e) {
getLogger().info(e.getEventName(...

coarse tokenBOT
#

Expected behavior

In Minecraft 1.21.4 Mojang added that ender pearls can load chunks. Unfortunately, this does not work as intended.

Observed/Actual behavior

Chunks are not loaded by ender pearls.

Steps/models to reproduce

I tested the error by building an ender bead chunk loader and leaving the area. I was shown that the region was completely unloaded. I carried out a second test by filling a launcher with 10 crates full of items. The items from the launcher or the crates were not consumed, or the redstion was inactive and the chunk was unloaded. If possible, please fix the error.

Plugin and Datapack List

None

Folia version

1.21.4-1-master@8af1aef

Other

No response

coarse tokenBOT
coarse tokenBOT
coarse tokenBOT
#

After all this time, I've come to a rough correlation—it seems to be related to the number of players and their locations.
For a long time, I've been trying to reproduce this bug on a local server. Previously, it was only a probabilistic event on the server, so it was difficult to gather information.
But recently, a coordinate appeared on the server where this issue occurs 100% of the time, without any reason—it's always 100%.
It's almost certain that as long as that chunk is loaded, ghost pistons will appear.
I thought I had found the decisive key factor, until I perfectly replicated the chunk data to my local server.
Everything worked fine... I tried to reproduce the bug locally and then report it. But I failed. Does anyone have any ideas?

coarse tokenBOT
#

After all this time, I've come to a rough correlation—it seems to be related to the number of players and their locations.
For a long time, I've been trying to reproduce this bug on a local server. Previously, it was only a probabilistic event on the server, so it was difficult to gather information.
But recently, a coordinate appeared on the server where this issue occurs 100% of the time, without any reason—it's always 100%.
It's almost certain that as long as that chunk is loaded, ghost pistons will appear.
I thought I had found the decisive key factor, until I perfectly replicated the chunk data to my local server.
Everything worked fine... I tried to reproduce the bug locally and then report it. But I failed. Does anyone have any ideas?

I have a fix but it's not really fix that(Just simply reverted a bug fix of mojang in 1.21.2)
I think this issue is caused by something of the chunk system which downgraded the chunk ticket level earlier than vanilla an caused that ...

coarse tokenBOT
coarse tokenBOT
#

After all this time, I've come to a rough correlation—it seems to be related to the number of players and their locations.
For a long time, I've been trying to reproduce this bug on a local server. Previously, it was only a probabilistic event on the server, so it was difficult to gather information.
But recently, a coordinate appeared on the server where this issue occurs 100% of the time, without any reason—it's always 100%.
It's almost certain that as long as that chunk is loaded, ghost pistons will appear.
I thought I had found the decisive key factor, until I perfectly replicated the chunk data to my local server.
Everything worked fine... I tried to reproduce the bug locally and then report it. But I failed. Does anyone have any ideas?

You could see #311

#

After all this time, I've come to a rough correlation—it seems to be related to the number of players and their locations.
For a long time, I've been trying to reproduce this bug on a local server. Previously, it was only a probabilistic event on the server, so it was difficult to gather information.
But recently, a coordinate appeared on the server where this issue occurs 100% of the time, without any reason—it's always 100%.
It's almost certain that as long as that chunk is loaded, ghost pistons will appear.
I thought I had found the decisive key factor, until I perfectly replicated the chunk data to my local server.
Everything worked fine... I tried to reproduce the bug locally and then report it. But I failed. Does anyone have any ideas?

You could see #311

There have been given a stable way to reproduce that bug

coarse tokenBOT
#

After all this time, I've come to a rough correlation—it seems to be related to the number of players and their locations.
For a long time, I've been trying to reproduce this bug on a local server. Previously, it was only a probabilistic event on the server, so it was difficult to gather information.
But recently, a coordinate appeared on the server where this issue occurs 100% of the time, without any reason—it's always 100%.
It's almost certain that as long as that chunk is loaded, ghost pistons will appear.
I thought I had found the decisive key factor, until I perfectly replicated the chunk data to my local server.
Everything worked fine... I tried to reproduce the bug locally and then report it. But I failed. Does anyone have any ideas?

You could see #311

There have been given a stable way to reproduce that bug

It looks like all the reasons can be explained with [#311](https:/...

coarse tokenBOT
coarse tokenBOT
#

World loading is relatively stable even during runtime (you just have to tweak the load code a bit)
World unloading kills the server though
I haven't had any significant success with it
The best result I had was not crashing the entire server but the world was technically still loaded even though not accessible

coarse tokenBOT
coarse tokenBOT
coarse tokenBOT
#

Expected behavior

The "28w Pork Tower" should operate without triggering any thread safety errors.
All entity state updates and accesses should occur on the correct (owning) region thread, ensuring smooth operation and adherence to Folia's threading.

Observed/Actual behavior

When the "28w Pork Tower" is activated by a player, the server logs display errors such as:
Thread failed main thread check: Accessing entity state off owning region's thread...

errorlog:
log.txt

Steps/models to reproduce

Since litematic files cannot be uploaded they are modified to have a txt file extension.

28w.txt
28wcollects.txt

Plugin and Datapack List

[19:41:30] [Region Scheduler Thread #9/INFO]: ℹ Server Plugins (25):
[19:41:30] [Region Scheduler Thread #9/INFO]: Paper Plugins (1):
[19:41...

coarse tokenBOT
coarse tokenBOT
#

Stack trace

NullPointerException
Cannot invoke "net.minecraft.core.component.DataComponentType.isTransient()" because "dataComponentType" is null

net.minecraft.core.component.DataComponentPatch in lambda$static$1 at line 45
com.mojang.serialization.Encoder$1 in encode at line 25
com.mojang.serialization.Codec$2 in encode at line 80
com.mojang.serialization.Encoder in encodeStart at line 14
com.mojang.serialization.codecs.OptionalFieldCodec in encode at line 44
com.mojang.serialization.codecs.OptionalFieldCodec in encode at line 17
com.mojang.serialization.MapEncoder$1 in encode at line 26
com.mojang.serialization.MapCodec$2 in encode at line 82
com.mojang.serialization.codecs.RecordCodecBuilder$Instance$6 in encode at line 297
com.mojang.serialization.codecs.RecordCodecBuilder$2 in encode at line 112
com.mojang.serialization.MapCodec$MapCodecCodec in encode at line 163
com.mojang.serialization.Codec$RecursiveCodec in encode at line 217
com.mojang.serialization.Encoder in e...
#

I have an other stacktrace for a serialization

ClassCastException

class java.lang.Integer cannot be cast to class net.minecraft.world.item.enchantment.ItemEnchantments (java.lang.Integer is in module java.base of loader 'bootstrap'; net.minecraft.world.item.enchantment.ItemEnchantments is in unnamed module of loader java.net.URLClassLoader @736e9adb)

com.mojang.serialization.codecs.RecordCodecBuilder$Instance in lambda$ap2$4 at line 215
com.mojang.serialization.codecs.RecordCodecBuilder$2 in encode at line 112
com.mojang.serialization.MapCodec$MapCodecCodec in encode at line 163
com.mojang.serialization.codecs.EitherCodec in lambda$encode$3 at line 34
com.mojang.datafixers.util.Either$Left in map at line 38
com.mojang.serialization.codecs.EitherCodec in encode at line 33
com.mojang.serialization.codecs.EitherCodec in encode at line 11
com.mojang.serialization.Encoder$1 in encode at line 25
com.mojang.serialization.Codec$2 in encode at line 80
com.mojang.serialization.Enc...
coarse tokenBOT
#

Oh yeah sorry, this was some Sentry stacktraces.

Well I found more relevant stacktrace. The players are using some inventory sorter mods and causes issues.
I have a i9-12900k CPU and the server has 22gigs of ram allocated

[20:52:36] [Region Scheduler Thread #2/ERROR]: [CustomItemEventsListener] Le joueur YOUENN_ll à délenché une erreur avec un item custom lors d'un event BlockBreakEvent
java.lang.NullPointerException: null
	at java.base/java.util.Objects.requireNonNull(Objects.java:233) ~[?:?]
	at java.base/java.util.ImmutableCollections$SetN.contains(ImmutableCollections.java:944) ~[?:?]
	at org.bukkit.craftbukkit.inventory.CraftMetaItem.updateFromPatch(CraftMetaItem.java:543) ~[folia-1.21.4.jar:1.21.4-DEV-d3969cd]
	at org.bukkit.craftbukkit.inventory.CraftMetaItem.<init>(CraftMetaItem.java:399) ~[folia-1.21.4.jar:1.21.4-DEV-d3969cd]
	at org.bukkit.craftbukkit.inventory.CraftItemMetas.lambda$static$2(CraftItemMetas.java:52) ~[folia-1.21.4.jar:1.21.4-DEV-d3969cd]
	at org.b...
coarse tokenBOT
#
[PaperMC/Folia] New branch created: beta/new-scheduler
coarse tokenBOT
coarse tokenBOT
#

Expected behavior

When player.setRespawnLocation() is used, player's respawn point should be set to the location provided in ()

Observed/Actual behavior

When player.setRespawnLocation() is used, player's respawn point is cleared, regardless of what is in ()

Steps/models to reproduce

Use player.setRespawnLocation() in a plugin

Plugin and Datapack List

Only a test plugin

Folia version

version
[14:32:39 INFO]: Checking version, please wait...
[14:32:39 INFO]: This server is running Folia version 1.21.4-DEV-master@8af1aef (2024-12-16T21:50:00Z) (Implementing API version 1.21.4-R0.1-SNAPSHOT)
You are running the latest version

Other

No response

coarse tokenBOT
#

Expected behavior

The tickthreads should be unparked after the flag shutdown is set to true so that they can terminate gracefully

Observed/Actual behavior

The tickthreads are not unparked after the shutdown flag is set to false and it then failed to termiante gracefully

Stack trace of some tickthreads:

[03:33:34] [Region shutdown thread/INFO]: [RegionShutdownThread] Awaiting scheduler termination for 60s...
[03:34:34] [Region shutdown thread/WARN]: [RegionShutdownThread] Scheduler did not terminate within 60s, proceeding with shutdown anyways
[03:34:34] [Region shutdown thread/WARN]: Region Scheduler Thread #3: Did not shut down in time
[03:34:34] [Region shutdown thread/WARN]: 	at java.base/jdk.internal.misc.Unsafe.park(Native Method)
[03:34:34] [Region shutdown thread/WARN]: 	at java.base/java.util.concurrent.locks.LockSupport.park(LockSupport.java:221)
[03:34:34] [Region shutdown thread/WARN]: 	at io.papermc.paper.threadedregions.ScheduledTaskThreadPool$TickThr...
coarse tokenBOT
#

Expected behavior

The command always processes without an unanticipated exception.

Observed/Actual behavior

https://pastebin.com/0cW2X4kz

Issue began in: https://github.com/PaperMC/Folia/commit/1934a00bdc40d488f58c1d5d9d6fce73fb25b80c (new scheduler branch)

Steps/models to reproduce

Run /tps in any region. Issue occurs when console executes said command at times, as well.

Plugin and Datapack List

Terralith & Nullscape

Folia version

[18:50:09 INFO]: This server is running Folia version 1.21.4-DEV-beta/new-scheduler@bb12eee (1970-01-01T00:00:00Z) (Implementing API version 1.21.4-R0.1-SNAPSHOT)
You are running the latest version
Previous version: 1.21.4-DEV-23ed084 (MC: 1.21.4)```

### Other

_No response_
coarse tokenBOT
coarse tokenBOT
coarse tokenBOT
#

Stack trace

paste your stack trace or a paste.gg link here!

No stack trace was thrown even the watchdog

Plugin and Datapack List

None

Actions to reproduce (if known)

No response

Folia version

Commit bb12eee2bdc68452dd643dd6e4efe8ecf68df3ce

Other

It seems that the tick threads are not blocked and the tick task of globalregion got lost.(I will provide more further information if I have time(There is actually a thread dump but it's on my computer and I cannot access it currently))

coarse tokenBOT
coarse tokenBOT
#

final long scheduleTime = Math.max(tick.getScheduledStart(), System.nanoTime());
This is "fixing" the issue, you can replicate the bug by copying teh entire scheduled class and running something like this:



package io.papermc.paper.threadedregions;

import java.util.*;
import java.util.concurrent.ThreadFactory;
import java.util.concurrent.TimeUnit;
import java.util.concurrent.atomic.AtomicInteger;
import java.util.function.BooleanSupplier;

public class Main {

    public static class BenchmarkRegion extends ScheduledTaskThreadPool.SchedulableTick {

        private long lastPeriod = System.nanoTime();

        public long getLastPeriod(){
            return new Long(lastPeriod);
        }

        private final long id;

        public BenchmarkRegion(long id) {
            this.id = id;
        }

        @Override
        public String toDump() {
            return String.valueOf(id);
        }


        private boolean cleaned = false;

        public void markCleaned(...
coarse tokenBOT
#

Expected behavior

In Minecraft 1.21 updates, Mojang officially specified that TNT should not be able to destroy Nether portals after passing through them into another dimension.

Observed/Actual behavior

In Folia, the TNT still destroys the portal after passing through.

Steps/models to reproduce

Activate a TNT and cause it to be transported through a Nether portal.

Plugin and Datapack List

No plugins and datapacks.

Folia version

All version

Other

No response

coarse tokenBOT
coarse tokenBOT
coarse tokenBOT
#

The clients are in survival mode, I can send you the code to generate custom items that I am using, maybe I am doing something wrong :

    private static ItemStack generateItemAndAddId(final CustomItemBuilder builder, final UUID uuid, final MinecraftPlugin minecraftPlugin) {
        builder.setPersistentData(CustomItemEventsListener.METADATA_KEY, uuid.toString());
        return builder.toItemStack();
    }
public class CustomItemBuilder {

    private NamespacedKey namespacedKey;
    private String nameSpaceData;

    public void setPersistentData(@NonNull final NamespacedKey namespacedKey, @NonNull final String value) {
        this.namespacedKey = namespacedKey;
        this.nameSpaceData = value;
    }

    public ItemStack toItemStack() {
        final ItemStack item = new ItemStack(material, amount);
        final ItemMeta meta = item.getItemMeta();

        if (meta != null) {
            if (name != null) {
                meta.displayName(name);
      ...
coarse tokenBOT
#

I got a new exception using the branch beta

[18:11:55 ERROR]: Error sending packet clientbound/minecraft:container_set_slot
io.netty.handler.codec.EncoderException: Failed to encode packet 'clientbound/minecraft:container_set_slot'
        at net.minecraft.network.codec.IdDispatchCodec.encode(IdDispatchCodec.java:55) ~[folia-1.21.4.jar:1.21.4-DEV-bb12eee]
        at net.minecraft.network.codec.IdDispatchCodec.encode(IdDispatchCodec.java:13) ~[folia-1.21.4.jar:1.21.4-DEV-bb12eee]
        at net.minecraft.network.PacketEncoder.encode(PacketEncoder.java:27) ~[folia-1.21.4.jar:1.21.4-DEV-bb12eee]
        at net.minecraft.network.PacketEncoder.encode(PacketEncoder.java:12) ~[folia-1.21.4.jar:1.21.4-DEV-bb12eee]
        at io.netty.handler.codec.MessageToByteEncoder.write(MessageToByteEncoder.java:107) ~[netty-codec-4.1.115.Final.jar:4.1.115.Final]
        at io.netty.channel.AbstractChannelHandlerContext.invokeWrite0(AbstractChannelHandlerContext.java:893) ~[netty-transport-4.1....
coarse tokenBOT
#

Stack trace

[Incident](https://paste.gg/p/anonymous/095e54a2507b4a21958aa9578b963f21)

Plugin and Datapack List

Terralith & Icendium

Actions to reproduce (if known)

Not known/certain. It seems to occur when a user is near the end portal gateway.

Folia version

This server is running Folia version 1.21.4-DEV-beta/new-scheduler@bb12eee (1970-01-01T00:00:00Z) (Implementing API version 1.21.4-R0.1-SNAPSHOT)
You are running the latest version
Previous version: 1.21.4-DEV-23ed084 (MC: 1.21.4)

### Other

_No response_
coarse tokenBOT
#

Expected behavior

The player is going inside the portal from the overworld and spawn in a appropriate location in the nether

Observed/Actual behavior

The player when passing inside the portal, the portal spawned under the map and the player is dead in the void.

Steps/models to reproduce

Go inside a portal and prey to reproduce the issue x) it seems to be random

Plugin and Datapack List

[16:46:19 INFO]: ℹ Server Plugins (5):
[16:46:19 INFO]: Bukkit Plugins:
[16:46:19 INFO]: - CoreProtect, PacifistaPlugin, spark, ViaVersion, voicechat

Folia version

[16:46:41 INFO]: Checking version, please wait...
[16:46:41 INFO]: This server is running Folia version 1.21.4-DEV-beta/new-scheduler@80ab57d (1970-01-01T00:00:00Z) (Implementing API version 1.21.4-R0.1-SNAPSHOT)
You are running the latest version
Previous version: 1.21.4-DEV-bb12eee (MC: 1.21.4)

Other

No response

coarse tokenBOT
coarse tokenBOT
#

Expected behavior

I expect to see lower ping.

Observed/Actual behavior

Folia seems to have an issue with ping, causing players with a ping of 10-20 to experience a rise to 35-40. While this doesn't significantly affect gameplay, it can be slightly noticeable in PvP due to the ping difference. I honestly believe this should be looked into. This issue was resolved in one of Folia's forks called ShreddedPaper. Here's the link to the fix they implemented: https://github.com/MultiPaper/ShreddedPaper/commit/2bb7a49bab464347a9878717a00563fe95cea9d9

Steps/models to reproduce

It's really random; not everyone experiences the problem, usually players with low MS

Plugin and Datapack List

Not caused by any plugins or datapacks.

Folia version

This server is running Folia version 1.21.4-DEV-beta/new-scheduler-oldmodules@4ed107d (1970-01-01T00:00:00Z) (Implementing API version 1.21.4-R0.1-SNAPSHOT)
Unknown version
Previous version: 1.21.1-438fbd4 (MC: 1.21.1)

Other...

coarse tokenBOT
coarse tokenBOT
#

Also happens on the latest version of new-scheduler branch (as of this comment).

As Pedro said, it happens when you cancel the teleport event.
(In the video, we cancel teleport event whent the user is in combat.)

https://github.com/user-attachments/assets/ad31ae7d-d004-4071-8fcd-c8806dba9fac

[10:36:10] [Region Scheduler Thread #65/ERROR]: [ca.spottedleaf.moonrise.common.util.TickThread] Thread failed main thread check: Cannot move entity off-main, context=[thread=Region Scheduler Thread #65,class=io.papermc.paper.threadedregions.TickRegionScheduler$TickThreadRunner,region={center=[1249, 836],world=world}], world=world, chunk_pos=[2498, 1671]
java.lang.Throwable: null
   at ca.spottedleaf.moonrise.common.util.TickThread.ensureTickThread(TickThread.java:88) ~[lsfolia-1.21.4.jar:1.21.4-DEV-d8d5805]
   at ca.spottedleaf.moonrise.patches.chunk_system.level.entity.server.ServerEntityLookup.checkThread(ServerEntityLookup.java:39) ~[lsfolia-1.21.4.jar:1.21.4-DEV-d8d5805]
   at ca.spottedl...
coarse tokenBOT
#

Expected behavior

Players should be able to join the server at any time.

Observed/Actual behavior

There is a very odd bug with the new scheduler where randomly during server uptime, Folia wont allow any players to join after the bug happens. It can happen within an hour or within 3 days, it seems to be random.

This is not plugin-induced as reverting to hard-fork branch fixes the problem. There are no errors in console (both backend and velocity) and everything seems fine, but no new players can join the server.

Steps/models to reproduce

  1. Compile the folia jar from new-scheduler branch.
  2. Have 200+ players (seems to happen more frequently with higher playercounts).
  3. Wait until the bug happens.

Plugin and Datapack List

.

Folia version

Latest version of new-scheduler branch as of this writing.

Other

The only fix for now is reverting to hard-fork branch. Temporary solution is to restart the server when it happens.
We are not knowledgeable enough...

coarse tokenBOT
#

Expected behavior

Players should be able to join the server at any time.

Observed/Actual behavior

There is a very odd bug with the new scheduler where randomly during server uptime, Folia wont allow any players to join after the bug happens. It can happen within an hour or within 3 days, it seems to be random.

This is not plugin-induced as reverting to hard-fork branch fixes the problem. There are no errors in console (both backend and velocity) and everything seems fine, but no new players can join the server.

Steps/models to reproduce

  1. Compile the folia jar from new-scheduler branch.
  2. Have 200+ players (seems to happen more frequently with higher playercounts).
  3. Wait until the bug happens.

Plugin and Datapack List

.

Folia version

Latest version of new-scheduler branch as of this writing.

Other

The only fix for now is reverting to hard-fork branch. Temporary solution is to restart the server when it happe...

coarse tokenBOT
#

Is your feature request related to a problem?

As of now, there is no way to get all regions that are active on a server, nor a way to run scheduled code once per region.

In my plugin, I have players creating abilities that run on the region they are in. But as of now, there is no good way to check if the location of each ability overlaps to create a collision.

Right now, each ability creates a task timer in the current location. And this timer cancels itself when needed. However, I see no way to safely check other ability locations.

  1. If I loop over every single location, most of these locations may not even be in the same region
  2. Getting every ability to check other ability locations every tick is highly inefficient. It would much better to do a single loop per region.

Describe the solution you'd like.

I believe there should be a class used as a reference to each threaded region.

public interface ThreadedRegion extends RegionAccessor {

    List<Player...
coarse tokenBOT
coarse tokenBOT
#

Expected behavior

Not being able to jump after pearling.

Observed/Actual behavior

Whenever you throw an Ender Pearl at a player or any living entity, if you jump at the same time the pearl lands, it lets you jump in the air, causing weird bug behavior. Here's a clip: https://streamable.com/wqu2uk

Steps/models to reproduce

Throw an ender pearl to a player & jump at the same time the pearl lands.

Plugin and Datapack List

NaN

Folia version

This server is running Folia version 1.21.4-DEV-beta/new-scheduler@80ab57d (1970-01-01T00:00:00Z) (Implementing API version 1.21.4-R0.1-SNAPSHOT)
You are running the latest version
Previous version: 1.21.4-DEV-4ed107d (MC: 1.21.4)

Other

No response

coarse tokenBOT
#

Expected behavior

if I use the normal /teleport <player> <player> command, and the player has a passenger set on which he is sitting, he cannot be teleported. Teleportation with coordinates, in my test with relative coordinates (/teleport <player> ~ ~10 ~) is possible again.

Observed/Actual behavior

The player will not be teleported, if an passenger is set.

Steps/models to reproduce

I have the following code as an example for reconstruction:

/*
 * Copyright (c) 2024-2025 LimitMedia
 */

package net.playunlimited.limitattack.commands;

import com.mojang.brigadier.Command;
import com.mojang.brigadier.context.CommandContext;
import com.mojang.brigadier.tree.LiteralCommandNode;
import io.papermc.paper.command.brigadier.CommandSourceStack;
import io.papermc.paper.command.brigadier.Commands;
import lombok.AllArgsConstructor;
import net.kyori.adventure.text.Component;
import net.playunlimited.limitattack.config.MessagesConfig;
import net.playunlimited.limitcore.ap...
coarse tokenBOT
#

Expected behavior

N/A

Observed/Actual behavior

The region ticker disables before plugins, preventing any further ticks while shutting down.

For some plugins, who spawn entities or block modifications in the world, normally they can run cleanups in onDisable(). However, because synchronous tasks on disable cannot be done due to the lack of main thread, they have to pend this task to RegionScheduler. Which is disabled at the time onDisable() occurs.

This means some plugins cannot run their cleanup, such as removing entities, reverting block changes, etc.

Steps/models to reproduce

  1. Set a block in the world with a task
  2. Set a task to revert that block change in onDisable()
  3. Stop the server
  4. The block will not be reverted

Plugin and Datapack List

BetterScoreboard, packetevents, PlaceholderAPI, ProjectKorra, ViaBackwards, ViaVersion

Folia version

1.21.4-DEV-master@8af1aef (2025-04-11T00:37:47Z) (Implementing API version 1.21.4-R0.1-SNAPSHOT...

coarse tokenBOT
#

Expected behavior

If you leave spectator mode, it should not kick you from the server with errors.

Observed/Actual behavior

Console log

[17:38:45 INFO]: StrangeOne101 issued server command: /gamemode survival
[17:38:45 INFO]: [StrangeOne101: Set own game mode to Survival Mode]
[17:38:45 ERROR]: [ca.spottedleaf.moonrise.common.util.TickThread] Thread Region Scheduler Thread #1 failed main thread check: Cannot asynchronously load chunks
java.lang.Throwable: null
        at ca.spottedleaf.moonrise.common.util.TickThread.ensureTickThread(TickThread.java:51) ~[folia-1.21.4.jar:1.21.4-DEV-8af1aef]
        at net.minecraft.server.level.ServerChunkCache.syncLoad(ServerChunkCache.java:100) ~[?:?]
        at net.minecraft.server.level.ServerChunkCache.getChunkFallback(ServerChunkCache.java:153) ~[?:?]
        at net.minecraft.server.level.ServerChunkCache.getChunk(ServerChunkCache.java:296) ~[?:?]
        at net.minecraft.world.level.Level.getChunk(Level.java:1095) ~[?:?]
     ...
coarse tokenBOT
coarse tokenBOT
coarse tokenBOT
coarse tokenBOT
#

Expected behavior

The flying machine should either be paused correctly or the blocks should not become phantom air blocks after chunk unloads.

Observed/Actual behavior

When creating a piston-based flying machine using slime blocks and pistons, if the player teleports away (or otherwise leaves the chunk) while the flying machine is moving, sometimes the location where a piston was gets replaced with an invisible air block.
This air block cannot be replaced by placing another block manually, nor by using the /setblock command.
If you drop a falling block entity like sand onto the affected area, the sand appears to fall normally and fill the gap visually, but the block remains non-solid and acts like a falling entity on the client.
From the client's perspective, it appears as if the sand is still falling even after settling.

Steps/models to reproduce

Build a simple machine using pistons and slime blocks. (It doesn't have to be a flying machine. Use sticky pistons to...

coarse tokenBOT
#

Stack trace

[00:28:16] [Region Scheduler Thread #0/WARN]: [io.papermc.paper.threadedregions.RegionizedWorldData] Failed to handle packet for /188.192.213.216:46050
net.minecraft.ReportedException: Ticking player
at net.minecraft.server.level.ServerPlayer.doTick(ServerPlayer.java:1296) ~[folia-1.21.4.jar:1.21.4-DEV-8af1aef]
at net.minecraft.server.network.ServerGamePacketListenerImpl.tick(ServerGamePacketListenerImpl.java:371) ~[folia-1.21.4.jar:1.21.4-DEV-8af1aef]
at net.minecraft.network.Connection.tick(Connection.java:694) ~[folia-1.21.4.jar:1.21.4-DEV-8af1aef]
at io.papermc.paper.threadedregions.RegionizedWorldData.tickConnections(RegionizedWorldData.java:521) ~[folia-1.21.4.jar:1.21.4-DEV-8af1aef]
at net.minecraft.server.MinecraftServer.tickChildren(MinecraftServer.java:2000) ~[folia-1.21.4.jar:1.21.4-DEV-8af1aef]
at net.minecraft.server.MinecraftServer.tickServer(MinecraftServer.java:1804) ~[folia-1.21.4.jar:1.21.4-DEV-8af1aef]
at io.papermc.paper.threadedregions.Ti...

coarse tokenBOT
coarse tokenBOT
#

Expected behavior

Player's food level should be synced after each portal teleportation

Observed/Actual behavior

Player's food level didn'tt get synced until they eat something or did something triggers the sync

Steps/models to reproduce

Leave any non full food level and go through the portal then teleport to another dimension then you'll found the food level turned back to full

Plugin and Datapack List

no plugins and datapack installed

Folia version

Any latest branch of mc1.21.4 of folia

Other

No response

coarse tokenBOT
coarse tokenBOT
coarse tokenBOT
#

For your usage, you should be creating an Interaction entity for each ability, then do something like

// <...> - Move the ability to new location
List<Entity> collided = world.getNearbyEntities(entity.getBoundingBox().expand(0.1), e -> e instanceof Interaction interaction && interaction.getPersistentDataContainer().has(new NamespacedKey("test", "key")));
if (!collided..isEmpty()) {
    // Run logic of destroying this ability and the collided abilities
}

each tick in the entity scheduler of the spawned interaction entity

World#getNearbyEntities should be really efficient and Interaction entities don't tick so they're quite cheap to spam with.

coarse tokenBOT
#

For your usage, you should be creating an Interaction entity for each ability, then do something like

// <...> - Move the ability to new location
List<Entity> collided = world.getNearbyEntities(entity.getBoundingBox().expand(0.1), e -> e instanceof Interaction interaction && interaction.getPersistentDataContainer().has(new NamespacedKey("test", "key")));
if (!collided..isEmpty()) {
// Run logic of destroying this ability and the collided abilities
}
each tick in the entity scheduler of the spawned interaction entity

World#getNearbyEntities should be really efficient and Interaction entities don't tick so they're quite cheap to spam with.

I will try this, and let you know. Thank you!

coarse tokenBOT
#

@masmc05 I have already tried using this before, but due to #353, it leaves entities everywhere in the world that are not cleaned up.

At best, it performs half as well as location vs location collisions, due to the nature of how everything is setup (and changing everything isn't in the cards right now). If there was at least an object to reference regions as well as a way to see what region you are currently in, I could sort them into maps and then try collide them that way.

#

@masmc05 I have already tried using this before, but due to #353, it leaves entities everywhere in the world that are not cleaned up.

At best, it performs half as well as location vs location collisions, due to the nature of how everything is setup (and changing everything isn't in the cards right now). If there was at least an object to reference regions as well as a way to see what region you are currently in, I could sort them into maps and then try collide them that way.

I can't test right now to confirm, but I'm pretty sure that shutdown thread is separate from other ticking threads, and it safely acts as the owner of all regions due to other threads not existing at that point. Are you sure you can't kill all the entities from all the regions in onDisable?

coarse tokenBOT
#

I can't test right now to confirm, but I'm pretty sure that shutdown thread is separate from other ticking threads, and it safely acts as the owner of all regions due to other threads not existing at that point. Are you sure you can't kill all the entities from all the regions in onDisable?

Are you saying it is safe to kill entities, as well as do other things like revert blocks in the standard shutdown thread?

coarse tokenBOT
coarse tokenBOT
coarse tokenBOT
#
[PaperMC/Folia] New branch created: ver/1.21.4
#
[PaperMC/Folia] branch deleted: dev/hard-fork
coarse tokenBOT
#

Expected behavior

When the server shuts down, no error should occur.

Observed/Actual behavior

When the server is shutting down, code that calls Block#getBlockData() can cause an exception.

[17:49:31 INFO]: StrangeOne101 joined the game
[17:49:31 INFO]: StrangeOne101[/127.0.0.1:52720] logged in with entity id 9 at ([world]-600.7353606258057, 74.0, 2204.650718295526)
> stop
[17:50:18 INFO]: Stopping the server
[17:50:18 INFO]: [RegionShutdownThread] Awaiting scheduler termination for 60s...
[17:50:18 INFO]: [RegionShutdownThread] Scheduler halted
[17:50:18 INFO]: Stopping server
[17:50:18 INFO]: [BetterScoreboard] Disabling BetterScoreboard v2.2.2
[17:50:18 INFO]: [ProjectKorra] Disabling ProjectKorra v1.12.1
[17:50:18 WARN]: java.lang.NullPointerException: Cannot read field "captureTreeGeneration" because the return value of "net.minecraft.world.level.World.getCurrentWorldData()" is null
[17:50:18 WARN]:        at net.minecraft.world.level.World.a_(World.java:1386)
...
coarse tokenBOT
coarse tokenBOT
coarse tokenBOT
coarse tokenBOT
coarse tokenBOT
#

Expected behavior

server run normally

Observed/Actual behavior

server crash

Steps/models to reproduce

no clue

Plugin and Datapack List

[21:05:44 INFO]: ℹ Server Plugins (40):
[21:05:44 INFO]: Paper Plugins (2):
[21:05:44 INFO]: - FancyHolograms, FancyNpcs
[21:05:44 INFO]: Bukkit Plugins (38):
[21:05:44 INFO]: - AFKReward, AuctionHouse, Bounty, CelestCombat, Chunky, ChunkyBorder, CMILib, CoreProtect, CrossServer, DeluxeMenus
[21:05:44 INFO]: DiscordSRV, Essentials, FCBank, FCCore, FCInvinsibleItemframe, FCMiner, FCOptimizer, FCSign, FCWelcome, floodgate
[21:05:44 INFO]: GSit, HereTheData, LuckPerms, PlaceholderAPI, PlayerPoints, ProtocolLib, QuickShop-Hikari, RegionExcluder, ResCoins, Residence
[21:05:44 INFO]: SafariNet, spark, TAB-Bridge, Vault, VentureChat, ViaBackwards, ViaVersion, WorldEdit

Folia version

This server is running Luminol version 1.21.4-DEV-dev/1.21.4-hardfork@61c3cc8 (2025-05-20T08:34:44Z) (Implementing API version 1.21.4-R0.1-SNAP...

coarse tokenBOT
#
[PaperMC/Folia] New branch created: ver/1.21.5
#
[PaperMC/Folia] branch deleted: beta/new-scheduler
coarse tokenBOT
#

Expected behavior

Pistons can operate normally after zombie pigmen are killed.

Observed/Actual behavior

The pistons are not working, and the blocks pushed by the pistons have become transparent. I cannot delete or place blocks on them. The only way to make them work normally is to use the fill command to replace them with air.

Steps/models to reproduce

Here is the recorded process of the error.

log.txt
This is the log file of the error.

2025-05-24-3.log
Here's the complete log.

Plugin and Datapack List

This was tested in my built test environment without any plugins.

Folia version

This server is running Folia version 1.21.4-DEV-master@8af1aef (2025-04-19T06:17:55Z) (Implementing API version 1.21.4-R0.1-SNAPSHOT)
You are running the latest version

Other

No response

coarse tokenBOT
coarse tokenBOT
#

Stack trace

[03:13:54] [Region Scheduler Thread #0/ERROR]: [io.papermc.paper.threadedregions.TickRegionScheduler] Region #25 centered at chunk [-122, 45] in world 'world_nether' failed to tick:
net.minecraft.ReportedException: Exception ticking world
	at net.minecraft.server.MinecraftServer.tickChildren(MinecraftServer.java:1836) ~[folia-1.21.5.jar:1.21.5-DEV-c299a7e]
	at net.minecraft.server.MinecraftServer.tickServer(MinecraftServer.java:1666) ~[folia-1.21.5.jar:1.21.5-DEV-c299a7e]
	at io.papermc.paper.threadedregions.TickRegions$ConcreteRegionTickHandle.tickRegion(TickRegions.java:407) ~[folia-1.21.5.jar:1.21.5-DEV-c299a7e]
	at io.papermc.paper.threadedregions.TickRegionScheduler$RegionScheduleHandle.runTick(TickRegionScheduler.java:418) ~[folia-1.21.5.jar:1.21.5-DEV-c299a7e]
	at ca.spottedleaf.concurrentutil.scheduler.SchedulerThreadPool$TickThreadRunner.run(SchedulerThreadPool.java:546) ~[concurrentutil-0.0.3.jar:?]
	at java.base/java.lang.Thread.run(Thread.java:1583) ...
coarse tokenBOT
#

Use this branch : https://github.com/PaperMC/Folia/tree/ver/1.21.4

Le sam. 24 mai 2025 à 09:09, LaoMaoBoss @.***> a écrit :

LaoMaoBoss left a comment (PaperMC/Folia#362)
https://github.com/PaperMC/Folia/issues/362#issuecomment-2906528902

它不是 Folia 的最新版本 1.21.4
I just rebuilt it, and I'm sure I'm using the latest version.
This server is running Folia version @.***
(2025-05-24T06:57:49Z) (Implementing API version 1.21.4-R0.1-SNAPSHOT)
You are running the latest version


Reply to this email directly, view it on GitHub
https://github.com/PaperMC/Folia/issues/362#issuecomment-2906528902, or
unsubscribe
https://github.com/notifications/unsubscribe-auth/AGJ4JPL5DNQOBEGRCPY23GT3AALI3AVCNFSM6AAAAAB5ZOAE5SVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDSMBWGUZDQOJQGI
.
You are receiving this because you commented.Message ID:
@.***>

coarse tokenBOT
coarse tokenBOT
coarse tokenBOT
#

Yes, the latest build of 1.21.4 works fine. However, I also tested the build of 1.21.5, and while there were no issues with pistons, zombie pigmen encounter an error when teleporting from the Nether to the Overworld. Testing with the latest build of 1.21.4 shows everything works normally, so I believe this is a new bug in 1.21.5. The log for this error is attached.

log.txt

Open a new issue, because this is a different problem.

coarse tokenBOT
#

Stack trace

[10:26:07 ERROR]: [ca.spottedleaf.moonrise.common.util.TickThread] Thread failed main thread check: Accessing poi chunk off-main, context=[thread=Region Scheduler Thread #0,class=io.papermc.paper.threadedregions.TickRegionScheduler$TickThreadRunner,region={center=[672, -1120],world=world}], world=world, chunk_pos=[42, -70]
java.lang.Throwable: null
        at ca.spottedleaf.moonrise.common.util.TickThread.ensureTickThread(TickThread.java:88) ~[folia-1.21.5.jar:1.21.5-DEV-c299a7e]
        at net.minecraft.world.entity.ai.village.poi.PoiManager.getOrLoad(PoiManager.java:89) ~[folia-1.21.5.jar:1.21.5-DEV-c299a7e]
        at net.minecraft.world.entity.ai.village.poi.PoiManager.exists(PoiManager.java:338) ~[folia-1.21.5.jar:1.21.5-DEV-c299a7e]
        at net.minecraft.server.level.ServerLevel.lambda$updatePOIOnBlockStateChange$21(ServerLevel.java:2343) ~[folia-1.21.5.jar:1.21.5-DEV-c299a7e]
        at io.papermc.paper.threadedregions.RegionizedTaskQueue$PrioritisedQu...
coarse tokenBOT
coarse tokenBOT
coarse tokenBOT
#

Yes, the latest build of 1.21.4 works fine. However, I also tested the build of 1.21.5, and while there were no issues with pistons, zombie pigmen encounter an error when teleporting from the Nether to the Overworld. Testing with the latest build of 1.21.4 shows everything works normally, so I believe this is a new bug in 1.21.5. The log for this error is attached.

log.txt

https://github.com/PaperMC/Folia/commit/06ace91ba91c18451404516eced1a9c05f4e3f69

coarse tokenBOT
coarse tokenBOT
#

Stack trace

https://mclo.gs/voJjfia#L1023

Plugin and Datapack List

pl
[13:21:13 INFO]: ℹ Server Plugins (57):
[13:21:13 INFO]: Paper Plugins (5):
[13:21:13 INFO]: - CarbonChat, emotecraft, EnchantedBook, FancyNpcs, MoreFoWorld
[13:21:13 INFO]: Bukkit Plugins (52):
[13:21:13 INFO]: - ArmorStandEditor, AutoWhitelistRemove, CoreProtect, CoreProtectTNT, Craftorithm, DeluxeMenus, EasyPayments, Essentials, EssentialsSpawn, FlagsH
[13:21:13 INFO]: GSit, HeadDatabase, InventoryRollbackPlus, InvisibleFrames, LevelledMobs, LiteBans, LuckPerms, Maintenance, mclogs, MilkyPixelart
[13:21:13 INFO]: NBTAPI, OreAnnouncer, packetevents, PlaceholderAPI, PlasmoVoice, PlayerHeads, ProtocolLib, pv-addon-discs, pv-addon-groups, pv-addon-lavaplayer-lib
[13:21:13 INFO]: pv-addon-sculk, pv-addon-spectator, rpchat, spark, squaremap, squaremap-worldguard, squaremarker, StonecuttersPLUS, TAB, TabTPS
[13:21:13 INFO]: Terra, TWSAdmin, TWSCheck, TWSCore, UltimateAutoRestart, UltraCosme...

coarse tokenBOT
coarse tokenBOT
#
[PaperMC/Folia] branch deleted: master
coarse tokenBOT
coarse tokenBOT
#

A region only is stable when it is being ticked. That's why you really can't fetch all regions that exist. That's also why you can't just "do something per region." What you really should be doing is having these abilities affect an area, after which point you can easily build a system that detects overlap in these areas.

If the ability is tied to a player you should probably be using the player scheduler.

coarse tokenBOT
coarse tokenBOT
coarse tokenBOT
coarse tokenBOT
coarse tokenBOT
coarse tokenBOT
#

Im having the exact same issue. Hopefully we can get an update on this.
`[17:33:46] [ERROR]: [io.papermc.paper.threadedregions.TickRegionScheduler]: Region #25 centered at chunk [234, -377] in world 'world' failed to tick:
net.minecraft.ReportedException: Exception ticking world
at net.minecraft.server.MinecraftServer.tickChildren(MinecraftServer.java:1836) ~[folia-1.21.5.jar:1.21.5-DEV-4f64c32]
at net.minecraft.server.MinecraftServer.tickServer(MinecraftServer.java:1666) ~[folia-1.21.5.jar:1.21.5-DEV-4f64c32]
at io.papermc.paper.threadedregions.TickRegions$ConcreteRegionTickHandle.tickRegion(TickRegions.java:407) ~[folia-1.21.5.jar:1.21.5-DEV-4f64c32]
at io.papermc.paper.threadedregions.TickRegionScheduler$RegionScheduleHandle.runTick(TickRegionScheduler.java:418) ~[folia-1.21.5.jar:1.21.5-DEV-4f64c32]
at ca.spottedleaf.concurrentutil.scheduler.SchedulerThreadPool$TickThreadRunner.run(SchedulerThreadPool.java:546) ~[concurrentutil-0.0.3.jar:?]
at java.base/java.lang.Thread.r...

coarse tokenBOT
#

Im having the exact same issue. Hopefully we can get an update on this. `[17:33:46] [ERROR]: [io.papermc.paper.threadedregions.TickRegionScheduler]: Region #25 centered at chunk [234, -377] in world 'world' failed to tick: net.minecraft.ReportedException: Exception ticking world at net.minecraft.server.MinecraftServer.tickChildren(MinecraftServer.java:1836) ~[folia-1.21.5.jar:1.21.5-DEV-4f64c32] at net.minecraft.server.MinecraftServer.tickServer(MinecraftServer.java:1666) ~[folia-1.21.5.jar:1.21.5-DEV-4f64c32] at io.papermc.paper.threadedregions.TickRegions$ConcreteRegionTickHandle.tickRegion(TickRegions.java:407) ~[folia-1.21.5.jar:1.21.5-DEV-4f64c32] at io.papermc.paper.threadedregions.TickRegionScheduler$RegionScheduleHandle.runTick(TickRegionScheduler.java:418) ~[folia-1.21.5.jar:1.21.5-DEV-4f64c32] at ca.spottedleaf.concurrentutil.scheduler.SchedulerThreadPool$TickThreadRunner.run(SchedulerThreadPool.java:546) ~[concurrentutil-0.0.3.jar:?] at java.base/java.lang.Thread.run(Th...

coarse tokenBOT
#

i have this error

[22:59:11 ERROR]: [io.papermc.paper.threadedregions.TickRegionScheduler] Region #1 centered at chunk [-27, -26] in world '2B2TUA' failed to tick:
net.minecraft.ReportedException: Exception ticking world
at net.minecraft.server.MinecraftServer.tickChildren(MinecraftServer.java:1836) ~[folia-1.21.5.jar:1.21.5-DEV-c9ed45f]
at net.minecraft.server.MinecraftServer.tickServer(MinecraftServer.java:1666) ~[folia-1.21.5.jar:1.21.5-DEV-c9ed45f]
at io.papermc.paper.threadedregions.TickRegions$ConcreteRegionTickHandle.tickRegion(TickRegions.java:407) ~[folia-1.21.5.jar:1.21.5-DEV-c9ed45f]
at io.papermc.paper.threadedregions.TickRegionScheduler$RegionScheduleHandle.runTick(TickRegionScheduler.java:418) ~[folia-1.21.5.jar:1.21.5-DEV-c9ed45f]
at ca.spottedleaf.concurrentutil.scheduler.SchedulerThreadPool$TickThreadRunner.run(SchedulerThreadPool.java:546) ~[concurrentutil-0.0.3.jar:?]
at java.base/java.lang.Thread.run(Thread.java:14...

coarse tokenBOT
coarse tokenBOT
#

Latest 1.21.5 beta using folia

using anti xray too if that matters

[17:02:45 ERROR]: [io.papermc.paper.threadedregions.TickRegionScheduler] Region #1 centered at chunk [24, 3] in world 'world' failed to tick:
net.minecraft.ReportedException: Exception ticking world
at net.minecraft.server.MinecraftServer.tickChildren(MinecraftServer.java:1836) ~[folia-1.21.5.jar:1.21.5-DEV-4f64c32]
at net.minecraft.server.MinecraftServer.tickServer(MinecraftServer.java:1666) ~[folia-1.21.5.jar:1.21.5-DEV-4f64c32]
at io.papermc.paper.threadedregions.TickRegions$ConcreteRegionTickHandle.tickRegion(TickRegions.java:407) ~[folia-1.21.5.jar:1.21.5-DEV-4f64c32]
at io.papermc.paper.threadedregions.TickRegionScheduler$RegionScheduleHandle.runTick(TickRegionScheduler.java:418) ~[folia-1.21.5.jar:1.21.5-DEV-4f64c32]
at ca.spottedleaf.concurrentutil.scheduler.SchedulerThreadPool$TickThreadRunner.run(SchedulerThreadPool.java:546) ~[concurrentutil-0.0.3.jar:?]
at...

coarse tokenBOT
coarse tokenBOT
coarse tokenBOT
#

Please run paper debug chunks --async from the console (note: --async only works from the console), and provide the console output and the chunk debug. Please also note that the chunk debug will show all online players locations and all loaded chunks.

Also, please run that from 1.21.3 - there are chunk system changes since 1.21.1.

Can confirm fixed in https://github.com/PaperMC/Folia/commit/2e7bc0721af95196c85500c7bb136aeea0bc12ce

coarse tokenBOT
#

Why not check if the chunk is null before running tickChunk? That way we can continue executing mid tick tasks, and prevent the throw.

-            world.tickChunk(raw[i], randomTickSpeed);
+            LevelChunk chunk = raw[i]; if (chunk == null) continue; world.tickChunk(chunk, randomTickSpeed); // Folia - ensure non null

Please read the comment above the for loop. I wrote it there for a reason.

coarse tokenBOT
#

Stack trace

[22:13:30] [Region Scheduler Thread #11/ERROR]: [ca.spottedleaf.moonrise.common.util.TickThread] Thread failed main thread check: Accessing poi chunk off-main, context=[thread=Region Scheduler Thread #11,class=io.papermc.paper.threadedregions.TickRegionScheduler$TickThreadRunner,region={center=[1153, 604],world=world}], world=world, chunk_pos=[-2591, -2686]
java.lang.Throwable: null
	at ca.spottedleaf.moonrise.common.util.TickThread.ensureTickThread(TickThread.java:88) ~[folia-1.21.5.jar:1.21.5-DEV-da0d7cd]
	at net.minecraft.world.entity.ai.village.poi.PoiManager.getOrLoad(PoiManager.java:89) ~[folia-1.21.5.jar:1.21.5-DEV-da0d7cd]
	at net.minecraft.world.entity.ai.village.poi.PoiManager.lambda$getInChunk$5(PoiManager.java:230) ~[folia-1.21.5.jar:1.21.5-DEV-da0d7cd]
	at java.base/java.util.stream.ReferencePipeline$3$1.accept(ReferencePipeline.java:197) ~[?:?]
	at java.base/java.util.stream.IntPipeline$1$1.accept(IntPipeline.java:180) ~[?:?]
	at java.base/java.uti...
coarse tokenBOT
#

I have the same problem on my server

[17:38:26] [Region Scheduler Thread #4/ERROR]: [ca.spottedleaf.moonrise.common.util.TickThread] Thread failed main thread check: Accessing poi chunk off-main, context=[thread=Region Scheduler Thread #4,class=io.papermc.paper.threadedregions.TickRegionScheduler$TickThreadRunner,region={center=[20992, -43992],world=world}], world=world, chunk_pos=[1312, -2750]
java.lang.Throwable: null
	at ca.spottedleaf.moonrise.common.util.TickThread.ensureTickThread(TickThread.java:88) ~[folia-1.21.5.jar:1.21.5-DEV-c299a7e]
	at net.minecraft.world.entity.ai.village.poi.PoiManager.getOrLoad(PoiManager.java:89) ~[folia-1.21.5.jar:1.21.5-DEV-c299a7e]
	at net.minecraft.world.entity.ai.village.poi.PoiManager.exists(PoiManager.java:338) ~[folia-1.21.5.jar:1.21.5-DEV-c299a7e]
	at net.minecraft.server.level.ServerLevel.lambda$updatePOIOnBlockStateChange$21(ServerLevel.java:2343) ~[folia-1.21.5.jar:1.21.5-DEV-c299a7e]
	at io.papermc.paper.threadedregions.RegionizedT...
coarse tokenBOT
#

Villagers disappear when transported through a portal, as do other mobs (phantoms, armadillos, horses). If they are transported in a boat, the boat disappears along with them. This occurs both when traveling from the Nether to the Overworld and vice versa. Additionally, there was an issue where a horse could disappear during long-distance travel in the world

`[09:07:06] [Region Scheduler Thread #2/ERROR]: [ca.spottedleaf.moonrise.common.util.TickThread] Thread Region Scheduler Thread #2 failed main thread check: Accessing poi chunk off-main
java.lang.Throwable: null
at ca.spottedleaf.moonrise.common.util.TickThread.ensureTickThread(TickThread.java:51) ~[folia-1.21.4.jar:1.21.4-1-8af1aef]
at net.minecraft.world.entity.ai.village.poi.PoiManager.getOrLoad(PoiManager.java:89) ~[folia-1.21.4.jar:1.21.4-1-8af1aef]
at net.minecraft.world.entity.ai.village.poi.PoiManager.getType(PoiManager.java:340) ~[folia-1.21.4.jar:1.21.4-1-8af1aef]
at net.minecraft.world.entity.ai.behavior.YieldJob...

coarse tokenBOT
coarse tokenBOT
#

Villagers disappear when transported through a portal, as do other mobs (phantoms, armadillos, horses). If they are transported in a boat, the boat disappears along with them. This occurs both when traveling from the Nether to the Overworld and vice versa. Additionally, there was an issue where a horse could disappear during long-distance travel in the world

[09:07:06] [Region Scheduler Thread #2/ERROR]: [ca.spottedleaf.moonrise.common.util.TickThread] Thread Region Scheduler Thread #2 failed main thread check: Accessing poi chunk off-main
java.lang.Throwable: null
	at ca.spottedleaf.moonrise.common.util.TickThread.ensureTickThread(TickThread.java:51) ~[folia-1.21.4.jar:1.21.4-1-8af1aef]
	at net.minecraft.world.entity.ai.village.poi.PoiManager.getOrLoad(PoiManager.java:89) ~[folia-1.21.4.jar:1.21.4-1-8af1aef]
	at net.minecraft.world.entity.ai.village.poi.PoiManager.getType(PoiManager.java:340) ~[folia-1.21.4.jar:1.21.4-1-8af1aef]
	at net.minecraft.world.entity...
coarse tokenBOT
#

Temporary fix

run ./gradlew applyAllPatches first

Create new file Folia\folia-server\minecraft-patches\sources\net\minecraft\world\entity\npc\CatSpawner.java.patch

--- a/net/minecraft/world/entity/npc/CatSpawner.java
+++ b/net/minecraft/world/entity/npc/CatSpawner.java
@@ -36,7 +_,7 @@
                     if (level.hasChunksAt(blockPos.getX() - 10, blockPos.getZ() - 10, blockPos.getX() + 10, blockPos.getZ() + 10)) {
                         if (SpawnPlacements.isSpawnPositionOk(EntityType.CAT, level, blockPos)) {
                             if (level.isCloseToVillage(blockPos, 2)) {
-                                this.spawnInVillage(level, blockPos);
+                                // this.spawnInVillage(level, blockPos);
                             } else if (level.structureManager().getStructureWithPieceAt(blockPos, StructureTags.CATS_SPAWN_IN).isValid()) {
                                 this.spawnInHut(level, blockPos);
                             }

`./...

#

I have the same problem on my server

[17:38:26] [Region Scheduler Thread #4/ERROR]: [ca.spottedleaf.moonrise.common.util.TickThread] Thread failed main thread check: Accessing poi chunk off-main, context=[thread=Region Scheduler Thread #4,class=io.papermc.paper.threadedregions.TickRegionScheduler$TickThreadRunner,region={center=[20992, -43992],world=world}], world=world, chunk_pos=[1312, -2750]
java.lang.Throwable: null
	at ca.spottedleaf.moonrise.common.util.TickThread.ensureTickThread(TickThread.java:88) ~[folia-1.21.5.jar:1.21.5-DEV-c299a7e]
	at net.minecraft.world.entity.ai.village.poi.PoiManager.getOrLoad(PoiManager.java:89) ~[folia-1.21.5.jar:1.21.5-DEV-c299a7e]
	at net.minecraft.world.entity.ai.village.poi.PoiManager.exists(PoiManager.java:338) ~[folia-1.21.5.jar:1.21.5-DEV-c299a7e]
	at net.minecraft.server.level.ServerLevel.lambda$updatePOIOnBlockStateChange$21(ServerLevel.java:2343) ~[folia-1.21.5.jar:1.21.5-DEV-c299a7e]
	at io.papermc.paper.threade...
coarse tokenBOT
#

I have the same problem on my server

[17:38:26] [Region Scheduler Thread #4/ERROR]: [ca.spottedleaf.moonrise.common.util.TickThread] Thread failed main thread check: Accessing poi chunk off-main, context=[thread=Region Scheduler Thread #4,class=io.papermc.paper.threadedregions.TickRegionScheduler$TickThreadRunner,region={center=[20992, -43992],world=world}], world=world, chunk_pos=[1312, -2750]
java.lang.Throwable: null
	at ca.spottedleaf.moonrise.common.util.TickThread.ensureTickThread(TickThread.java:88) ~[folia-1.21.5.jar:1.21.5-DEV-c299a7e]
	at net.minecraft.world.entity.ai.village.poi.PoiManager.getOrLoad(PoiManager.java:89) ~[folia-1.21.5.jar:1.21.5-DEV-c299a7e]
	at net.minecraft.world.entity.ai.village.poi.PoiManager.exists(PoiManager.java:338) ~[folia-1.21.5.jar:1.21.5-DEV-c299a7e]
	at net.minecraft.server.level.ServerLevel.lambda$updatePOIOnBlockStateChange$21(ServerLevel.java:2343) ~[folia-1.21.5.jar:1.21.5-DEV-c299a7e]
	at io.papermc.paper.threade...
#

Villagers disappear when transported through a portal, as do other mobs (phantoms, armadillos, horses). If they are transported in a boat, the boat disappears along with them. This occurs both when traveling from the Nether to the Overworld and vice versa. Additionally, there was an issue where a horse could disappear during long-distance travel in the world

[09:07:06] [Region Scheduler Thread #2/ERROR]: [ca.spottedleaf.moonrise.common.util.TickThread] Thread Region Scheduler Thread #2 failed main thread check: Accessing poi chunk off-main
java.lang.Throwable: null
	at ca.spottedleaf.moonrise.common.util.TickThread.ensureTickThread(TickThread.java:51) ~[folia-1.21.4.jar:1.21.4-1-8af1aef]
	at net.minecraft.world.entity.ai.village.poi.PoiManager.getOrLoad(PoiManager.java:89) ~[folia-1.21.4.jar:1.21.4-1-8af1aef]
	at net.minecraft.world.entity.ai.village.poi.PoiManager.getType(PoiManager.java:340) ~[folia-1.21.4.jar:1.21.4-1-8af1aef]
	at net.minecraft...
coarse tokenBOT
coarse tokenBOT
coarse tokenBOT
coarse tokenBOT
#

Expected behavior

Players being able to place blocks normally

Observed/Actual behavior

Players being unable to place blocks at some locations, observed locations include

  1. random blocks which have never been touched
  2. blocks where a piston (normal as well as sticky) once was. (the piston also tends to sometimes randomly disappear and not come back)

Steps/models to reproduce

exact steps to replicate are unknown; assumption is some error in the behavior of pistons

Plugin and Datapack List

AFCMS, BlueMap, *ChatMentions, LessSleep-Folia, LuckPerms, LuckPermsTab, ViaVersion

Folia version

This server is running Folia version 1.21.4-DEV-dev/1.21.4@8af1aef (2024-12-14T12:28:31Z) (Implementing API version 1.21.4-R0.1-SNAPSHOT)
Unknown version
Previous version: 1.21.1-DEV-88e0907 (MC: 1.21.1)

[downgraded from 1.21.5 due to crashes; see https://github.com/PaperMC/Folia/issues/363)

Other

video displaying the issue: https://workupload.com/start/DndF7MrXdx7

coarse tokenBOT
coarse tokenBOT
coarse tokenBOT
coarse tokenBOT
coarse tokenBOT
coarse tokenBOT
#

[10:26:27 ERROR]: [io.papermc.paper.threadedregions.FoliaWatchdogThread] Tick region located in world 'world' around chunk '[578, -635]' has not responded in 10.650182044s:
[10:26:27 ERROR]: ------------------------------
[10:26:27 ERROR]: Current Thread: Region Scheduler Thread #3
[10:26:27 ERROR]: PID: 96 | Suspended: false | Native: false | State: WAITING
[10:26:27 ERROR]: Stack:
[10:26:27 ERROR]: java.base@21.0.7/jdk.internal.misc.Unsafe.park(Native Method)
[10:26:27 ERROR]: java.base@21.0.7/java.util.concurrent.locks.LockSupport.park(LockSupport.java:371)
[10:26:27 ERROR]: ca.spottedleaf.concurrentutil.lock.ReentrantAreaLock.lock(ReentrantAreaLock.java:169)
[10:26:27 ERROR]: ca.spottedleaf.moonrise.patches.chunk_system.scheduling.ChunkHolderManager.addTicketAtLevel(ChunkHolderManager.java:706)
[10:26:27 ERROR]: ca.spottedleaf.moonrise.patches.chunk_system.scheduling.ChunkHolderManager.addTicketAtLeve...

coarse tokenBOT
#

https://pastebin.com/2FFWnwMv https://pastebin.com/jKpgBc9H

This is the only thing that occurs before the entire server restarts.

We are on the latest commit: dfa3ca4

Would doing /gamerule randomTickSpeed 0 prevent this for now?

I "resolved" this issue (kind of like @Dueris said) by modifying the ServerChunkCache. This is by no means a proficient solution but I can't have my servers crashing. Things also have been stable for multiple days with said implementation:

    // Paper end - rewrite chunk system
    // Paper start - chunk tick iteration optimisations
    private final ca.spottedleaf.moonrise.common.util.SimpleThreadUnsafeRandom shuffleRandom = new ca.spottedleaf.moonrise.common.util.SimpleThreadUnsafeRandom(0L);
    private void iterateTickingChunksFaster() {
        final ca.spottedleaf.leafprofiler.RegionizedProfiler.Handle foliaProfiler = io.papermc.paper.threadedregions.TickRegionScheduler.getProfiler(); // Folia - profiler
        foliaProfiler.star...
coarse tokenBOT
#

https://pastebin.com/2FFWnwMv https://pastebin.com/jKpgBc9H
Это единственное, что происходит перед перезагрузкой всего сервера.
Мы находимся на последнем коммите: dfa3ca4
Будет ли делать /gamerule randomTickSpeed 0предотвратить это сейчас?

Я «решил» эту проблему (вроде как @Duerisсказал) путем изменения ServerChunkCache. Это ни в коем случае не эффективное решение, но я не могу допустить падения моих серверов. С этой реализацией все также было стабильно в течение нескольких дней:

// Paper end - rewrite chunk system
// Paper start - chunk tick iteration optimisations
private final ca.spottedleaf.moonrise.common.util.SimpleThreadUnsafeRandom shuffleRandom = new ca.spottedleaf.moonrise.common.util.SimpleThreadUnsafeRandom(0L);
private void iterateTickingChunksFaster() {
    final ca.spottedleaf.leafprofiler.RegionizedProfiler.Handle foliaProfiler = io.papermc.paper.threadedregions.TickRegionScheduler.getProfiler(); // Folia - pro...
coarse tokenBOT
coarse tokenBOT
#

pastebin.com/2FFWnwMv pastebin.com/jKpgBc9H
This is the only thing that occurs before the entire server restarts.
We are on the latest commit: dfa3ca4
Would doing /gamerule randomTickSpeed 0 prevent this for now?

Looks like I need to prioritise fixing the underlying issue. No, the gamerule will not fix it.

I am a player on a server with this issue and I can confirm; the gamerule appears to have fixed the issue. However, I am not a developer there so I cannot really explain beyond this. Quantura will be able to.

coarse tokenBOT
#
[PaperMC/Folia] New branch created: ver/1.21.6
coarse tokenBOT
coarse tokenBOT
#

Expected behavior

/gamerule locatorBar true no working 1.21.6

Observed/Actual behavior

/gamerule locatorBar true no working 1.21.6

Steps/models to reproduce

/gamerule locatorBar true no working 1.21.6

Plugin and Datapack List

clear Folia

Folia version

This server is running Folia version 1.21.6-DEV-ver/1.21.6@3ef3a4e (1970-01-01T00:00:00Z) (Implementing API version 1.21.6-R0.1-SNAPSHOT)
You are running the latest version

Other

No response

coarse tokenBOT
coarse tokenBOT
#

Expected behavior

Thread failed main thread check:

latest.log

Observed/Actual behavior

Thread failed main thread check:

latest.log

Steps/models to reproduce

  1. Spawn wither, enderdragon and other mobs in world_the_end or world

latest.log

Plugin and Datapack List

[20:35:34 INFO]: ℹ Server Plugins (9):
[20:35:34 INFO]: Bukkit Plugins:
[20:35:34 INFO]: - ArmorStand-Limiter, CommandWhitelist, FarmControl, Lootin, LuckPerms, MiniMOTD, PlaceholderAPI, SpawnerProtect, TAB

Folia version

This server is running Folia version 1.21.6-DEV-ver/1.21.6@3ef3a4e (1970-01-01T00:00:00Z) (Implementing API version 1.21.6-R0.1-SNAPSHOT)
You are running the latest version

Other

No response

coarse tokenBOT
#

Expected behavior

map data do not flush to disk with autosave

Observed/Actual behavior

Playerdata and chunk data are saved properly to disk with autosave, but map data only save to disk on proper shutdown. Map data can be saved with autosave on Paper. If the folia server crashes, all the map data will be lost.

Steps/models to reproduce

It can be reproduce everytime as server crash or unexpected power off

Plugin and Datapack List

None

Folia version

Folia version 1.21.4-DEV-dev/hard-fork@cd49d65 (1970-01-01T00:00:00Z) (Implementing API version 1.21.4-R0.1-SNAPSHOT)

Other

No response

coarse tokenBOT
coarse tokenBOT
coarse tokenBOT
#

Stack trace

https://mclo.gs/ekUkNla#L3634

Plugin and Datapack List

pl
[05:13:34 INFO]: ℹ Server Plugins (59):
[05:13:34 INFO]: Paper Plugins (5):
[05:13:34 INFO]: - CarbonChat, emotecraft, EnchantedBook, FancyNpcs, MoreFoWorld
[05:13:34 INFO]: Bukkit Plugins (54):
[05:13:34 INFO]: - AntiHealthIndicator, ArmorStandEditor, AutoWhitelistRemove, AxInventoryRestore, BreweryX, CoreProtect, CoreProtectTNT, Craftorithm, DeluxeMenus, EasyPayments
[05:13:34 INFO]: Essentials, EssentialsSpawn, fast-leaf-decay, FlagsH, GSit, HeadDatabase, InvisibleFrames, LevelledMobs, LiteBans, LuckPerms
[05:13:34 INFO]: Maintenance, mclogs, MilkyPixelart, OreAnnouncer, packetevents, PlaceholderAPI, PlasmoVoice, PlayerHeads, ProtocolLib, pv-addon-discs
[05:13:34 INFO]: pv-addon-groups, pv-addon-lavaplayer-lib, pv-addon-sculk, pv-addon-spectator, rpchat, spark, squaremap, squaremap-worldguard, squaremarker, StonecuttersPLUS
[05:13:34 INFO]: TAB, Terra, TWSAdmin, TWSCheck, TWSCore, UltimateAutoRe...

coarse tokenBOT
#

Expected behavior

Should be called for nether portals

Observed/Actual behavior

Not called anymore

Steps/models to reproduce

Listen to the EntityPortalReadyEvent

Plugin and Datapack List

[16:40:03 INFO]: ℹ Server Plugins (3):
[16:40:03 INFO]: Paper Plugins:
[16:40:03 INFO]: - Commander, Tweaks, Worlds

Folia version

[16:40:19 INFO]: This server is running Folia version 1.21.6-DEV-ver/1.21.6@3ef3a4e (1970-01-01T00:00:00Z) (Implementing API version 1.21.6-R0.1-SNAPSHOT)
You are 3 version(s) behind
Download the new version at: https://papermc.io/downloads/paper
Previous version: 1.21.6-27-5edcf6d (MC: 1.21.6)

Other

The event was called normally in 1.21.5

coarse tokenBOT
coarse tokenBOT
coarse tokenBOT
#

1.21.5 Folia

[11:07:27 ERROR]: [ca.spottedleaf.moonrise.common.util.TickThread] Thread failed main thread check: Cannot asynchronously load chunks, context=[thread=Region Scheduler Thread #1,class=io.papermc.paper.threadedregions.TickRegionScheduler$TickThreadRunner,region={center=[-17, -5],world=World_the_end}], world=World_the_end, chunk_pos=[77, 0]
java.lang.Throwable: null
        at ca.spottedleaf.moonrise.common.util.TickThread.ensureTickThread(TickThread.java:88) ~[folia-1.21.5.jar:1.21.5-DEV-dfa3ca4]
        at net.minecraft.server.level.ServerChunkCache.syncLoad(ServerChunkCache.java:103) ~[folia-1.21.5.jar:1.21.5-DEV-dfa3ca4]
        at net.minecraft.server.level.ServerChunkCache.getChunkFallback(ServerChunkCache.java:156) ~[folia-1.21.5.jar:1.21.5-DEV-dfa3ca4]
        at net.minecraft.server.level.ServerChunkCache.getChunk(ServerChunkCache.java:330) ~[folia-1.21.5.jar:1.21.5-DEV-dfa3ca4]
        at net.minecraft.world.level.Level.getChunk(Level.java:1093) ~[folia-1.21.5.jar:1.```...
coarse tokenBOT
coarse tokenBOT
coarse tokenBOT
#

Expected behavior

Display player direction in XP

Observed/Actual behavior

The direction indicator in the XP bar isn't showing.

Steps/models to reproduce

The direction indicator in the XP bar isn't showing.

Plugin and Datapack List

[22:44:14 INFO]: Bukkit Plugins:
[22:44:14 INFO]: - AutoTreeChop, BetterRTP, Chunky, CoreProtect, Essentials, EssentialsSpawn, GSit, LiteSignIn, LuckPerms, PlaceholderAPI
[22:44:14 INFO]: TAB, TrChat, Vault, ViaBackwards, ViaVersion

Folia version

This server is running Folia version 1.21.6-DEV-ver/1.21.6@ac8f05f (1970-01-01T00:00:00Z) (Implementing API version 1.21.6-R0.1-SNAPSHOT)

Other

No response

coarse tokenBOT
coarse tokenBOT
coarse tokenBOT
coarse tokenBOT
coarse tokenBOT
#
[PaperMC/Folia] New branch created: ver/1.21.7
coarse tokenBOT
#

Expected behavior

[10:04:30] [Region Scheduler Thread #0/ERROR]: [io.papermc.paper.threadedregions.TickRegionScheduler] Region #-1 centered at chunk null in world 'null' failed to tick:
java.lang.UnsupportedOperationException: Configuration mode is not supported in its current state
	at net.minecraft.server.network.ServerCommonPacketListenerImpl.onDisconnect(ServerCommonPacketListenerImpl.java:97) ~[folia-1.21.7.jar:1.21.7-DEV-0b53ab4]
	at net.minecraft.server.network.ServerConfigurationPacketListenerImpl.onDisconnect(ServerConfigurationPacketListenerImpl.java:73) ~[folia-1.21.7.jar:1.21.7-DEV-0b53ab4]
	at net.minecraft.network.Connection.handleDisconnection(Connection.java:923) ~[folia-1.21.7.jar:1.21.7-DEV-0b53ab4]
	at io.papermc.paper.threadedregions.RegionizedServer.tickConnections(RegionizedServer.java:376) ~[folia-1.21.7.jar:1.21.7-DEV-0b53ab4]
	at io.papermc.paper.threadedregions.RegionizedServer.globalTick(RegionizedServer.java:325) ~[folia-1.21.7.jar:1.21.7-DEV-0b53ab4]```...
coarse tokenBOT
coarse tokenBOT
#

Expected behavior

have player exit message

Observed/Actual behavior

no player exit message

Steps/models to reproduce

1.player leave server
2.no exit message

Plugin and Datapack List

[13:50:03 INFO]: ℹ Server Plugins (25):
[13:50:03 INFO]: Paper Plugins (3):
[13:50:03 INFO]: - CarbonChat, FancyHolograms, HuskHomes
[13:50:03 INFO]: Bukkit Plugins (22):
[13:50:03 INFO]: - BedrockPlayerSupport, BlockLocker, CoreProtect, floodgate, GSit, LightSuicide, LiteSignIn, LuckPerms, MapModCompanion, packetevents
[13:50:03 INFO]: PlaceholderAPI, PlayerHeads, ProtocolLib, QuickShop-Hikari, SkinsRestorer, TAB, Teh, Towny, Vault, ViaBackwards
[13:50:03 INFO]: ViaVersion, XConomy

Folia version

[13:54:21 INFO]: This server is running Folia version 1.21.7-DEV-ver/1.21.7@6cc7f5b (1970-01-01T00:00:00Z) (Implementing API version 1.21.7-R0.1-SNAPSHOT)
You are running the latest version
Previous version: 1.21.7-15-0cadaef (MC: 1.21.7)

Other

I removed all the plugins and st...

coarse tokenBOT
coarse tokenBOT
#

Is your feature request related to a problem?

On large SMP servers, players may go AFK for a considerable amount of time to farm items from their mob farms. Keeping these players in the standard consideration for region creation seems a bit unnecessary as these regions are sometimes far from other players. or otherwise can get unexpectedly merged with other regions and drastically impact performance.

Describe the solution you'd like.

If there was an API you could use on a Player to put them into a sort of region group, where all players in that group are prioritized to be put on the same "region" to be ticked together, and as a result only affect the performance of others also AFKing, that could be nice. This could also be helpful for giving something like giving players who are engaged in combat, low on health, etc, a priority region for higher TPS to help prevent their death.

Of course, this API wouldn't "force" the players to be grouped into a specific region, it would j...

coarse tokenBOT
coarse tokenBOT
coarse tokenBOT
coarse tokenBOT
coarse tokenBOT
#

This is ver

Expected behavior

Players should be able to join the server at any time.

Observed/Actual behavior

There is a very odd bug with the new scheduler where randomly during server uptime, Folia wont allow any players to join after the bug happens. It can happen within an hour or within 3 days, it seems to be random.
This is not plugin-induced as reverting to hard-fork branch fixes the problem. There are no errors in console (both backend and velocity) and everything seems fine, but no new players can join the server.

Steps/models to reproduce

  1. Compile the folia jar from new-scheduler branch.
  2. Have 200+ players (seems to happen more frequently with higher playercounts).
  3. Wait until the bug happens.

Plugin and Datapack List

.

Folia version

Latest version of new-scheduler branch as of this writing.

Other

The only fix for now is reverting to hard-fork branch. Temporary solution is to...

coarse tokenBOT
#

Expected behavior

https://mclo.gs/UuVhA6b#L1342

Observed/Actual behavior

https://mclo.gs/UuVhA6b#L1342

Steps/models to reproduce

just run server on folia 1.21.6 (maybe work on 1.21.7)

Plugin and Datapack List

[21:34:21 INFO]: ℹ Server Plugins (63):
[21:34:21 INFO]: Paper Plugins (6):
[21:34:21 INFO]: - CarbonChat, ChatDisplay, emotecraft, EnchantedBook, FancyNpcs, MoreFoWorld
[21:34:21 INFO]: Bukkit Plugins (57):
[21:34:21 INFO]: - AntiHealthIndicator, ArmorStandEditor, AutoWhitelistRemove, AxInventoryRestore, BreweryX, CoreProtect, CoreProtectTNT, Craftorithm, DeluxeMenus, EasyPayments
[21:34:21 INFO]: Essentials, EssentialsSpawn, fast-leaf-decay, FlagsH, GSit, HeadDatabase, InteractiveSigns, InvisibleFrames, LevelledMobs, LiteBans
[21:34:21 INFO]: LuckPerms, Maintenance, mclogs, MilkyPixelart, NBTAPI, OreAnnouncer, packetevents, PlaceholderAPI, PlasmoVoice, PlayerHeads
[21:34:21 INFO]: ProtocolLib, pv-addon-discs, pv-addon-groups, pv-addon-lavaplayer-lib,...

coarse tokenBOT
coarse tokenBOT
coarse tokenBOT
#
[PaperMC/Folia] New branch created: ver/1.21.8
coarse tokenBOT
#

Expected behavior

The player should not kick

Observed/Actual behavior

Sometimes players get kicked with this error. The player was afk.
I noticed that the operator is not kicking

Steps/models to reproduce

Start the server folia 1.21.6 + velocity.
join the server(not OP)
Wait

Plugin and Datapack List

Paper plugins (4):

  • HuskHomes (4.9.9), PrefiX (7.5), Veinminer (2.4.8), emotecraft (2.6.1)
    Bukkit plugins (39):
  • AFKPlus (3.4.9), AnarchyExploitFixes (2.7.11), ArmorStandEditor (1.21.7-49), AxInventoryRestore (3.8.2), BlueMap (5.9), BreweryX (3.5.0;HEAD), ChatManager (1.21.5-0e26c74), Chunky (1.4.40), ComfyWhitelist (1.3.0), CoreProtect (23.2-RC5), FarmControl (1.3.0), GSit (2.4.3), HeadDrop (5.4.5), ImageFrame (1.8.5.0), InvSeePlusPlus_Clear (0.30.4), InvSeePlusPlus_Give (0.30.4), LibertyBans (1.1.1), LightAntiCheat (1.2.6), LightCatcher (0.0.0), LiteBans (2.17.2), LuckPerms (5.4.159), NoCheatPlus (3.17.1-SNAPSHOT-Updated-b198), OpenInv (5.1.12), PlaceholderAPI (2....
coarse tokenBOT
#

Expected behavior

I built a mobswitch and stacked 140 Warden mob in it. I'm the only player on the server and I'm using a nether portal chunk loader to keep it loaded.

Mob spawning should be disabled when mobcap is reached

Observed/Actual behavior

However, when I move to other areas, mobs continue to spawn despite the mobswitch being active.

This appears to be related to how Folia handles mob spawning calculations across different regions/threads, as the mobswitch works correctly on Paper servers.

Steps/models to reproduce

<img width="2560" height="1369" alt="Image" src="https://github.com/user-attachments/assets/d33c9f21-8e81-4a4a-8ff5-506251697240" />

open mobswitch and teleport 100,000 blocks away

Plugin and Datapack List

no

Folia version

1.21.6

Other

No response

coarse tokenBOT
coarse tokenBOT
#

Stack trace

[12:44:28] [Region Scheduler Thread #10/ERROR]: Failed to handle packet net.minecraft.network.protocol.game.ServerboundContainerClosePacket@1b2e8eca, suppressing error
java.lang.ArrayIndexOutOfBoundsException: Index -1 out of bounds for length 10
	at java.base/java.util.ArrayList.add(ArrayList.java:484) ~[?:?]
	at java.base/java.util.ArrayList.add(ArrayList.java:496) ~[?:?]
	at net.minecraft.world.inventory.TransientCraftingContainer.onOpen(TransientCraftingContainer.java:30) ~[folia-1.21.6.jar:1.21.6-DEV-e4b0ae9]
	at net.minecraft.world.inventory.AbstractContainerMenu.transferTo(AbstractContainerMenu.java:76) ~[folia-1.21.6.jar:1.21.6-DEV-e4b0ae9]
	at org.bukkit.craftbukkit.event.CraftEventFactory.handleInventoryCloseEvent(CraftEventFactory.java:1465) ~[folia-1.21.6.jar:1.21.6-DEV-e4b0ae9]
	at net.minecraft.server.network.ServerGamePacketListenerImpl.handleContainerClose(ServerGamePacketListenerImpl.java:2983) ~[folia-1.21.6.jar:1.21.6-DEV-e4b0ae9]
	at net.minecraft.```...
coarse tokenBOT
coarse tokenBOT
coarse tokenBOT
coarse tokenBOT
coarse tokenBOT
#

Stack trace

https://mclo.gs/3esxcqP#L1728

Plugin and Datapack List

pl
[14:54:34 INFO]: ℹ Server Plugins (62):
[14:54:34 INFO]: Paper Plugins (5):
[14:54:34 INFO]: - CarbonChat, emotecraft, EnchantedBook, FancyNpcs, MoreFoWorld
[14:54:34 INFO]: Bukkit Plugins (57):
[14:54:34 INFO]: - AntiHealthIndicator, ArmorStandEditor, AutoWhitelistRemove, AxInventoryRestore, BreweryX, Chunky, CoreProtect, CoreProtectTNT, Craftorithm, DeluxeMenus
[14:54:34 INFO]: EasyPayments, Essentials, EssentialsSpawn, FlagsH, GSit, HeadDatabase, InteractiveSigns, InvisibleFrames, LiteBans, LuckPerms
[14:54:34 INFO]: Maintenance, mclogs, MilkyPixelart, NBTAPI, OreAnnouncer, packetevents, PlaceholderAPI, PlasmoVoice, PlayerHeads, ProtocolLib
[14:54:34 INFO]: pv-addon-discs, pv-addon-groups, pv-addon-lavaplayer-lib, pv-addon-sculk, pv-addon-spectator, rpchat, ShapelessPortals, spark, squaremap, squaremap-worldguard
[14:54:34 INFO]: squaremarker, StonecuttersPLUS, TAB, Terra, ToolStats, TWSAdmin,...

coarse tokenBOT
#

What tick is this being run on? A region tick or the global tick? And if it's the region tick, are you(the player) in a different region or the same region?

public boolean onCommand(@NotNull CommandSender sender,
                             @NotNull Command cmd,
                             @NotNull String label,
                             String @NotNull [] args) {
                Bukkit.broadcastMessage("test 1");
                Bukkit.getServer().getGlobalRegionScheduler().run(Ranmc.getInstance(), _ -> {
                    Bukkit.broadcastMessage("test 2");
                });
                Bukkit.getServer().getAsyncScheduler().runNow(Ranmc.getInstance(), _ -> {
                    Bukkit.broadcastMessage("test 3");
                });

<img width="1066" height="130" alt="Image" src="https://github.com/user-attachments/assets/35bfe64f-3a7e-4ddb-a4cc-cd2190d7bf7b" />

coarse tokenBOT
coarse tokenBOT
coarse tokenBOT
coarse tokenBOT
coarse tokenBOT
coarse tokenBOT
#

Is your feature request related to a problem?

I switched from Paper to Folia yesterday because Folia servers are multi-threaded and run better. After installing and joining the server, I noticed how well it's running, going from about 30 MSPT (Paper) to about 4-7 MSPT (Folia). The server runs perfectly, and pretty much all the plugins I use work on Folia (even my players said it runs better), but I quickly noticed one problem: command blocks aren't working. I immediately searched the internet for this problem, and the last post I saw about it was from 2023: it said that command blocks are hard-disabled. I immediately looked for plugin solutions to re-enable them, but unfortunately, there aren't any. I don't know exactly why they were disabled back then, but I would love it if they worked again. I think plugins are more reliable than command blocks, but there aren't plugins for everything. And I think it's a solvable problem now. xD

Describe the solution you'd like.

It would...

coarse tokenBOT
#

Not a Folia Dev, but I will say don't get your hopes up. Command Blocks present a nightmare for a concurrent server like Folia. They would be run on one region, but have to effect multiple (potentially all) regions, and the way those regions are effected would be different for different commands, necessitating reworking a lot of commands to properly schedule the effects.

But this gets worse when you consider that command blocks are blocking, meaning the region where the command block is located has to stop ticking while it waits for effects to happen in the other regions, meaning you lose a lot of the performance Folia offers. There are ways you would work around this, but it would mean changing the behavior of Command Blocks.

Paper and in turn Folia generally only care about things like Datapacks and Command Blocks to a limited extent, you are better off creating a plugin to do whatever it is you need.

coarse tokenBOT
#

Just wanna throw in my own two cents. I haven't worked on Folia but I have a pretty good idea of the complexities it faces as a piece of software.

This is just nit-picking but I saw you mention "Folia is multi-threaded and runs better", which is technically true, but with a very very massive caveat. Folia doesn't just magically "run better" there's very specific criteria that allows it to run more efficiently than Paper (player spread, beefed up hardware etc). It can actually run WORSE than a Paper server would if you aren't using it for the right use-case.

I just don't want you to have the false idea that Folia will just magically fix all your performance issues, because it can very much bite you in the butt. If you haven't read up on the reading materials for how it works, please do that, because depending on your setup you might be shooting yourself in the foot, which nobody wants! At least read the ENTIRE FAQ if you haven't

I won't repeat what Astralchroma already said, but it w...

coarse tokenBOT
coarse tokenBOT
#

Expected behavior

When killing a mob with a wither's head flying through the portal, a wither rose drops out.

Observed/Actual behavior

When killing a mob with a wither's head flying through the portal, a wither rose NOT drop out.

Steps/models to reproduce

Build a wither rose farm using portals or kill a mob with a wither's head flying through the portal.

Plugin and Datapack List

I tested it on a server without plugins and datapacks.

Folia version

This server is running Folia version 1.21.6-6-ver/1.21.6@e4b0ae9 (2025-06-29T03:17:11Z) (Implementing API version 1.21.6-R0.1-SNAPSHOT)

Other

This bug does not exist on the Paper core, it is a bug of the Folia core. I checked it on the Paper version 1.21.7.

coarse tokenBOT
coarse tokenBOT
coarse tokenBOT
#

Expected behavior

When a player enters a natural end portal in the overworld they are teleported to the end.

Observed/Actual behavior

No message, no error, no teleport action. Unsure the reason why the event is not firing.

Steps/models to reproduce

  • Run 1.21.8 Folia
  • Locate Stronghold
  • Activate the portal
  • Enter the Portal

No event fired.

Plugin and Datapack List

[21:36:15 INFO]: ℹ Server Plugins (69):
[21:36:15 INFO]: Paper Plugins (12):
[21:36:15 INFO]:  - CrazyCrates, EconomyShopGUI-Premium, ExtraGreetings, FancyHolograms, FancyNpcs, FeatherMorph, Nexo, NexoAddon, ServiceIO, UltimateMobCoins
[21:36:15 INFO]:  Worlds, ZealousChat
[21:36:15 INFO]: Bukkit Plugins (57):
[21:36:15 INFO]:  - ajLeaderboards, AuraSkills, Aurora, AuroraCollections, AuroraLevels, AuroraQuests, AxAFKZone, AxEnvoy, AxGraves, AxPlayerWarps
[21:36:15 INFO]:  AxRewards, AxTrade, AxVaults, BetterModel, BetterRTP, BreweryX, ChunkEntityLimiter, Chunker, CrazyAuctions, CrazyEnchantments
[2```...
coarse tokenBOT
#

Is your feature request related to a problem?

In the current spark report, we can see that each region thread has its own ID (just add --not-combined)

<img width="576" height="132" alt="Image" src="https://github.com/user-attachments/assets/6bbe45dc-7244-4a13-96ce-fd4c817ac8a6" />

But we cannot know which region the thread belongs to, this is very inconvenient for viewing the analysis report of a single region, we can only guess (maybe there is another way but idk)

Describe the solution you'd like.

It would be nice if the thread id to every region could be added to the /tps command output
This allows the server owner to know which thread are used in each region, and then use spark to look the analysis report of the region

Describe alternatives you've considered.

Well, I don't know, but add id to tps output should be the easiest way

Other

No response

coarse tokenBOT
coarse tokenBOT
#

But if the region hops between threads, how will this be manageable? Lets say it hops between threads every tick, with another 30 regions doing the same, how would you be able to differentiate between the region you are tracking and the other regions? And keep in mind, regions dont have dedicated threads, meaning other regions still can share the same thread as the region you are tracking, meaning even if the region is staying on 1 single thread for some reason(like a 1/billion chance), then the performance report will be merged with the other regions being ticked on that thread.

Its just not reliable. If you want to track performance issues, isolate the region off-production, like copy the world and track it in a development server where that region is the only region loaded.

coarse tokenBOT
coarse tokenBOT
#

I made a fork to reactivate most vanilla commands here: https://github.com/luigiofthebakery/Folia
I have tried to use the schedulers as much as possible, but there are likely still issues with it as I haven't tested it much. Scoreboard uses synchronised maps, and most likely if a command block tries to retrieve data from other regions it won't work, so it doesn't block the thread and won't be harmful to performance. There is also of course no guarantee of the sequence with which commands perform actions on other regions, even if they are part of a sequential function defined in a datapack.

coarse tokenBOT
coarse tokenBOT
coarse tokenBOT
coarse tokenBOT
#

This PR includes methods to get MSPT per region.
I tried using the same naming as in Bukkit but adapted for the region logic like the TPS API was.

This re-uses the same logic as CraftServer#getTPSFromRegion and javadocs, which means a possible improvement would be to make a separate function to get the RegionScheduleHandle to re-use in both. However, I decided against this approach since idk if that would make it less likely of getting merged.

This API is useful for monitoring tools that take samples in regular intervals.

coarse tokenBOT
coarse tokenBOT
#

Stack trace

[21:13:23] [Region Scheduler Thread #16/ERROR]: [ca.spottedleaf.moonrise.common.util.TickThread] Thread failed main thread check: Cannot asynchronously load chunks, context=[thread=Region Scheduler Thread #16,class=io.papermc.paper.threadedregions.TickRegionScheduler$TickThreadRunner,region={center=[-962, 144],world=world}], world=world, chunk_pos=[-640, 88]
java.lang.Throwable: null
	at ca.spottedleaf.moonrise.common.util.TickThread.ensureTickThread(TickThread.java:88) ~[lsfolia-1.21.8.jar:1.21.8-DEV-e49fe2f]
	at net.minecraft.server.level.ServerChunkCache.syncLoad(ServerChunkCache.java:103) ~[lsfolia-1.21.8.jar:1.21.8-DEV-e49fe2f]
	at net.minecraft.server.level.ServerChunkCache.getChunkFallback(ServerChunkCache.java:156) ~[lsfolia-1.21.8.jar:1.21.8-DEV-e49fe2f]
	at net.minecraft.server.level.ServerChunkCache.getChunk(ServerChunkCache.java:330) ~[lsfolia-1.21.8.jar:1.21.8-DEV-e49fe2f]
	at net.minecraft.world.level.Level.getChunk(Level.java:1028) ~[lsfolia-1.21.8.jar:```...
#

Expected behavior

Upon death, all items are dropped.

Observed/Actual behavior

When you put items in your inventory inside crafting slots and die (such as with /kill), the items inside crafting slots will be kept upon death and not dropped.

Steps/models to reproduce

  1. Put item inside inventory to crafting slots
  2. /kill (your name)
  3. Items inside crafting slots will stay in your inventory even upon death.

Plugin and Datapack List

None.

Folia version

Tested with latest Folia from https://github.com/PaperMC/Folia/commit/7a1c5c7c7c86a0071654e03d7bf82120d113ef38

Other

No response

#

Stack trace

[00:37:09] [Region Scheduler Thread #11/ERROR]: [ca.spottedleaf.moonrise.common.util.TickThread] Thread failed main thread check: Accessing entity state off owning region's thread, context=[thread=Region Scheduler Thread #11,class=io.papermc.paper.threadedregions.TickRegionScheduler$TickThreadRunner,region={center=[-677, 671],world=world}], entity={root=[{type=Skeleton,id=10223612,uuid=09433542-54bb-4e92-aef8-7a5cab04721e,pos=(-11,164.768,63.000,10,739.244),mot=(-0.174,-0.078,-0.077),aabb=AABB[-11165.067996276393, 63.0, 10738.944177231802] -> [-11164.467996252552, 64.99000000953674, 10739.544177255644],removed=null,has_vehicle=false,passenger_count=0], vehicle=[{null}], passengers=[]
java.lang.Throwable: null
	at ca.spottedleaf.moonrise.common.util.TickThread.ensureTickThread(TickThread.java:97) ~[lsfolia-1.21.8.jar:1.21.8-DEV-e49fe2f]
	at org.bukkit.craftbukkit.entity.CraftSkeleton.getHandle(CraftSkeleton.java:15) ~[lsfolia-1.21.8.jar:1.21.8-DEV-e49fe2f]
	at org.bukkit```...
coarse tokenBOT
coarse tokenBOT
#

When using the teleport command, rotation (pitch and yaw) was not preserved when teleporting to an entity, or in any situation where it wasn't explicitly specified in the command parameters. The first commit fixes that.
The second commit adds back PlayerChangedWorldEvent to fire after teleportAsync is called, if the entity is a player and they are teleporting to a new world.

#

Expected behavior

I tried to make a spigot plugin compatible with Folia, but the world creation failed and the corresponding worlds content was explicitly added in bukkit.yml, but I couldn't do it

What I expected to see: the world is correctly generated

Observed/Actual behavior

World folder generated but not initialized

Steps/models to reproduce

no

Plugin and Datapack List

only my test plugin

Folia version

version
[16:09:15 INFO]: Checking version, please wait...
[16:09:16 INFO]: This server is running Folia version 1.21.8-5-ver/1.21.8@7a1c5c7 (2025-09-04T12:50:30Z) (Implementing API version 1.21.8-R0.1-SNAPSHOT)
You are running the latest version
Previous version: 1.21.4-6-b785bcc (MC: 1.21.4)

Other

No response

#

World creation is not officially supported on folia _yet_folia 尚未正式支持世界创建 The official recommended way of creating worlds is through data packs官方推荐的创建世界的方式是通过数据包

oh thank you i will learn ( •̀ ω •́ )✧

coarse tokenBOT
#

Stack trace

[02:43:27] [Region Scheduler Thread #7/WARN]: Unknown target reason, please report on the issue tracker
java.lang.Exception: null
	at net.minecraft.world.entity.Mob.setTarget(Mob.java:283) ~[lsfolia-1.21.8.jar:1.21.8-DEV-e49fe2f]
	at net.minecraft.world.entity.Mob.setTarget(Mob.java:271) ~[lsfolia-1.21.8.jar:1.21.8-DEV-e49fe2f]
	at net.minecraft.world.entity.monster.Shulker.teleportSomewhere(Shulker.java:415) ~[lsfolia-1.21.8.jar:1.21.8-DEV-e49fe2f]
	at net.minecraft.world.entity.monster.Shulker.hitByShulkerBullet(Shulker.java:464) ~[lsfolia-1.21.8.jar:1.21.8-DEV-e49fe2f]
	at net.minecraft.world.entity.monster.Shulker.hurtServer(Shulker.java:449) ~[lsfolia-1.21.8.jar:1.21.8-DEV-e49fe2f]
	at net.minecraft.world.entity.Entity.hurtOrSimulate(Entity.java:2308) ~[lsfolia-1.21.8.jar:1.21.8-DEV-e49fe2f]
	at net.minecraft.world.entity.projectile.ShulkerBullet.onHitEntity(ShulkerBullet.java:306) ~[lsfolia-1.21.8.jar:1.21.8-DEV-e49fe2f]
	at net.minecraft.world.entity.projectile```...
coarse tokenBOT
#

Is your feature request related to a problem?

Paper allows for enabling JMX monitoring using the enable-jmx-monitoring flag. This is very helpful for setting up dashboards to externally view the performance of the server. However, in Folia, this has been disabled. These MBeans are still exposed, though, resulting in consistently empty or 0 values.

Describe the solution you'd like.

Since the existing metrics averageTickTime and tickTimes aren't helpful as global fields anymore, it would be neat to have data available for region information by editing net\minecraft\util\monitoring\jmx\MinecraftServerStatistics.java to include TabularData metrics, with a row for each region and columns for the region identifier, average tick rate, and also some other helpful things in folia-server\src\minecraft\java\io\papermc\paper\threadedregions\TickRegions$RegionStats like entityCount, playerCount, and chunkCount.

Describe alternatives you've considered.

Some plugins try to expose th...

coarse tokenBOT
#

Expected behavior

The map created by the player lives forever and happily

Observed/Actual behavior

Players report that cards often break and become "unknown cards"

Steps/models to reproduce

i do not have 100% repro, but maps often breaks in time, maybe hard reset is trigger (server power lost)

Plugin and Datapack List

Server Plugins (21):
Paper Plugins (1):

  • PlugManX
    Bukkit Plugins (20):
  • AuthMe, AutoTreeChop, BlueBridgeCore, BlueBridgeWG, BlueMap, Chunky, CoreProtect, EasyPayments, Essentials, LuckPerms
    PlaceholderAPI, ProtocolLib, SkinsRestorer, spark, TAB, tgbridge, Vault, voicechat, WorldEdit, WorldGuard

Folia version

This server is running Folia version 1.21.8-2-ver/1.21.8@4ed5b66 (2025-08-10T00:33:31Z) (Implementing API version 1.21.8-R0.1-SNAPSHOT)
You are 3 version(s) behind
Download the new version at: https://papermc.io/downloads/paper
Previous version: 1.21.4-DEV-8af1aef (MC: 1.21.4)

Other

I have this problem over year, folia runs on 1...

coarse tokenBOT
#

Found that running the following caused maps to save

I am quite new to working with Folia so this may have unforseen implications regarding multithreading. It will probably be safer to run them inside the .globalRegionScheduler()

1.20 and below

Kotlin

(Bukkit.getServer() as CraftServer).server.overworld().dataStorage.save(true)

Java

((CraftServer) Bukkit.getServer()).getServer().overworld().getDataStorage().save(true);

1.21 and above

Kotlin

(Bukkit.getServer() as CraftServer).server.overworld().dataStorage.saveAndJoin()

Java

((CraftServer) Bukkit.getServer()).getServer().overworld().getDataStorage().saveAndJoin();

Likely to be caused by the mentioned patch file, although the original reason for disabling incremental saving in this circumstance seems to have been lost to time as the file has been renamed numerous times.

https://github.com/PaperMC/Folia/blob/ver/1.21.8/folia-server/minecraft-patches/features/0001-Region-Threading-Base.patch#L8697-L8698...

coarse tokenBOT
#

My temporary solution is to revert the line change mentioned above and add the following to the top of saveIncrementally()

if (doFull) {
    this.getChunkSource().getDataStorage().scheduleSave();
    return;
}

Similarly, only save DimensionDataStorage to avoid some unexpected problems

Also, if you get ConcurrentModificationException, you can add sync lock in collectDirtyTagsToSave() when looping this.cache

It has been running on my server for a few weeks, and the map data is auto saved normally. I haven't encountered any problems yet, but as mentioned above this is just my temporary solution

coarse tokenBOT
coarse tokenBOT
coarse tokenBOT
#

Expected behavior

When the /gamerule spawnRadius is 0 and /setworldspawn ~ ~ ~ is set to another coordinate than the normal starter World Spawn the players with no respawnpoint should respawn on the exact Block wich will be set with /setworldspawn ~ ~ ~. But if the /gamerule spawnRadius is 0 players respawn at the first world spawn.

Observed/Actual behavior

If you change the /setworldspawn ~ ~ ~ and do /gamerule spawnRadius 0 you should spawn at the befor set world spawnpoint.
When /gamerule spawnRadius is 0 the game spawns you somewhere else than the set Respawn Point.
When /gamerule spawnRadius is 1 or more the game spawns you at the world spawnpoint wich was changed bevor.

Steps/models to reproduce

  1. Mark the normal World Spawnpoint.
  2. Go to another location. Mark and set the World Respawnpoint with /setworldspawn
  3. Now set the Respawnradius with /gamerule spawnRadius to 0 and move away a bit.
  4. Do /kill and you should spawn at the Normal World Spawnpoint.
  5. No...
coarse tokenBOT
#

Occurs on 1.21.8-DEV-ver/1.21.8@612d9bd with a minimal plugin list:

[17:54:21 INFO]: ℹ Server Plugins (11):
[17:54:21 INFO]: Paper Plugins (3):
[17:54:21 INFO]:  - BlueSlimeCore, FancyHolograms, MiniPlaceholders
[17:54:21 INFO]: Bukkit Plugins (8):
[17:54:21 INFO]:  - CombatLogX, FasterCrystals, GlowingTest, PacketBoard, packetevents, ProtocolLib, ViaBackwards, ViaVersion

Notably also only occured to us with Happy Ghasts. From looking at the code, I'm guessing happy ghasts move too quickly

@Override
    public void travel(Vec3 travelVector) {
        float f = (float)this.getAttributeValue(Attributes.FLYING_SPEED) * 5.0F / 3.0F;
        this.travelFlying(travelVector, f, f, f);
    }

The hitbox in which to look for entities to collide with is resized to be big enough to fit the travelVector, but this ends up being outside of the Region ticking that Ghast. However it appears to me it would require Absurdly high speeds for the hitboxes to expand this rapidly, in the provided logs i...

coarse tokenBOT
#

Stack trace

[13:44:05] [lpx-packet-logger-0/INFO]: [LPX] heu_gm sent PLAYER_INPUT (37.020ms) (20 bytes) [input=Input[forward=false, backward=false, left=false, right=false, jump=false, shift=false, sprint=true], STREAM_CODEC=net.minecraft.network.codec.StreamCodec$7@3cdd47a0]
[13:44:05] [Region Scheduler Thread #0/ERROR]: [ca.spottedleaf.moonrise.common.util.TickThread] Thread failed main thread check: Cannot move entity off-main, context=[thread=Region Scheduler Thread #0,class=io.papermc.paper.threadedregions.TickRegionScheduler$TickThreadRunner,region={center=[-47, -12],world=world}], world=world, chunk_pos=[-153, -63]
java.lang.Throwable: null
at ca.spottedleaf.moonrise.common.util.TickThread.ensureTickThread(TickThread.java:88) ~[folia-1.21.4.jar:1.21.4-6-b785bcc]
at ca.spottedleaf.moonrise.patches.chunk_system.level.entity.server.ServerEntityLookup.checkThread(ServerEntityLookup.java:39) ~[folia-1.21.4.jar:1.21.4-6-b785bcc]
at ca.spottedleaf.moonrise.patches.chunk_system.le...

coarse tokenBOT
coarse tokenBOT
#

This is also happening on our sever as well, we have pretty much the same setup as Teslicek's server, here is out stack trace as well, I think they are the same.

From what I gathered our cause was from when a player logged into to the server this would happen and the server would crash
``
[07:32:47 ERROR]: [ca.spottedleaf.moonrise.common.util.TickThread] Thread failed main thread check: Cannot add entity off-main thread, context=[thread=Region Scheduler Thread #0,class=io.papermc.paper.threadedregions.TickRegionScheduler$TickThreadRunner,region={center=[-7, -2],world=world}], world=world, chunk_pos=[255, -151]
java.lang.Throwable: null
at ca.spottedleaf.moonrise.common.util.TickThread.ensureTickThread(TickThread.java:88) ~[folia-1.21.8.jar:1.21.8-5-7a1c5c7]
at ca.spottedleaf.moonrise.patches.chunk_system.level.entity.server.ServerEntityLookup.checkThread(ServerEntityLookup.java:52) ~[folia-1.21.8.jar:1.21.8-5-7a1c5c7]
at ca.spottedleaf.moonrise.patches.chunk_syst...

coarse tokenBOT
coarse tokenBOT
#

Is your feature request related to a problem?

Hello,

For the use case of running a single small map server, I would like to be able to decrease the region size via the config, in order to increase region tps when there is a lot of player/entity.

Even if it incurrs disabling vanilla features in order to be able to run smaller region.

This will increase usability of Folia for concentrated player numbers across few chunks (e.g: for gamemode such as Factions)

Thanks

Describe the solution you'd like.

A regionSize parameter, and if any, other relevent parameters.

Also if needed, a way to disable vanilla features that could have an impact on smaller region size.

Describe alternatives you've considered.

Manually modifying regionizer implementation variables.

Other

No response

coarse tokenBOT
coarse tokenBOT
#

Expected behavior

I expected to see that my note block on the server would produce a redstone signal.

Observed/Actual behavior

In fact, the notes block does not work on my server, despite the fact that I enabled the note block update in the configuration, and I also have vanilla redstone enabled.

Steps/models to reproduce

https://drive.google.com/file/d/1JUKD4PbkYq8TTcMFclVHsIl0E_mLyMM2/view?usp=sharing

Plugin and Datapack List

<img width="986" height="325" alt="Image" src="https://github.com/user-attachments/assets/09b15f1e-0a31-4e05-a3bf-45d564abb1f8" />

Folia version

<img width="890" height="137" alt="Image" src="https://github.com/user-attachments/assets/48dde4b7-c229-46fb-92df-b5364543c03c" />

Other

No response

coarse tokenBOT
#

Stack trace

https://pastebin.com/raw/BtnpEjZM

Since paste.gg was down, I'm sending it by PasteBin.

Plugin and Datapack List

<img width="1312" height="444" alt="Image" src="https://github.com/user-attachments/assets/4254e619-bea5-4199-84fb-ccf19e51377c" />

Actions to reproduce (if known)

It occurred when I joined the server.
However, it also happens randomly while playing even after joining.

Folia version

This server is running Folia version 1.21.8-5-ver/1.21.8@7a1c5c7 (2025-09-04T12:50:30Z) (Implementing API version 1.21.8-R0.1-SNAPSHOT)

Other

No response

coarse tokenBOT
coarse tokenBOT
coarse tokenBOT
coarse tokenBOT
coarse tokenBOT
#

Stack trace

Region #~ centered at chunk [~, ~] in world 'world_nether' failed to tick:                               
net.minecraft.ReportedException: Exception ticking world                                                                                                                                  
        at net.minecraft.server.MinecraftServer.tickChildren(MinecraftServer.java:1878) ~[server-1.21.8.jar]                                                             
        at net.minecraft.server.MinecraftServer.tickServer(MinecraftServer.java:1693) ~[server-1.21.8.jar]                                                               
        at io.papermc.paper.threadedregions.TickRegions$ConcreteRegionTickHandle.tickRegion(TickRegions.java:409) ~[server-1.21.8.jar]                                   
        at io.papermc.paper.threadedregions.TickRegionScheduler$RegionScheduleHandle.runTick(TickRegionScheduler.java:437) ~[server-1.21.8.jar]                          
        a```...
coarse tokenBOT
coarse tokenBOT
#

Stack trace

https://mclo.gs/tn57Kxh

https://mclo.gs/irmLGIY

Plugin and Datapack List

pl
[22:46:28 INFO]: ℹ Server Plugins (23):
[22:46:28 INFO]: Paper Plugins (1):
[22:46:28 INFO]: - AuthMeVelocity
[22:46:28 INFO]: Bukkit Plugins (22):
[22:46:28 INFO]: - AnarchyExploitFixes, AntiopByChaLiuCore, AuthMe, AxGraves, BetterRTP, ChatFilter, CoreProtect, IllegalStack, LuckPerms, Matrix
[22:46:28 INFO]: NBTAPI, packetevents, PlaceholderAPI, Plan, PlayerCulling, PlayerViewDistanceController, PvPManager, SkinsRestorer, TAB, TPA
[22:46:28 INFO]: ViaBackwards, ViaVersion
[22:46:28 INFO]: Command execution stopped due to limit (executed 1 commands)

Actions to reproduce (if known)

No response

Folia version

version
[22:46:08 INFO]: Checking version, please wait...
[22:46:08 INFO]: Command execution stopped due to limit (executed 1 commands)
[22:46:09 INFO]: This server is running Folia version 1.21.8-6-ver/1.21.8@612d9bd (2025-09-30T14:11:15Z) (Implementing API version 1.2...

coarse tokenBOT
#

Expected behavior

I expect to NOT be able to crawlphase, when phasing into blocks via pearls, you should not be able too when crawlhpasing, yet you can.

Observed/Actual behavior

Able to crawlphase when normally not able too.

Steps/models to reproduce

For steps to reproduce, ( i wasnt clear) you need
. Any MC client with the module " velocity" ( it will push you out of the block in vanilla if you dont example, meteor client. )
. Pearls
. No specifc block you should use, i personally use obsidian because its what im used too. But you can phase into any block.
. You must aim at the border of the block and then deploy the pearl, all you do is place a block, look at the bottom where it meets the block below it, and then deploy the pearl in the middle of them!
https://streamable.com/52yb1z

Plugin and Datapack List

Folia and papermc, thats it.

Folia version

im just a bystander who plays on a server( 2b2tpractice.org 2b2t.org)who observed this issue, im not the...

coarse tokenBOT
coarse tokenBOT
coarse tokenBOT
#

Is your feature request related to a problem?

is this project dead?

Describe the solution you'd like.

Last commit was 3 months ago

Describe alternatives you've considered.

Need volunteeer. Not me, im not good.

Other

No response

#

Its not "not planned". It's "no estimated time of arrival". We are not an enterprise business, things get some when people find time in their life for free work, we just don't know when that is.

You either wait for someone to donate their free time to update folia or you update it yourself. Leaf will get to it at some point but when he finds the time for it is up in the air. Could be today. Could be in a week. In a month. Who knows

coarse tokenBOT
coarse tokenBOT
#
[PaperMC/Folia] New branch created: ver/1.21.11
coarse tokenBOT
coarse tokenBOT
coarse tokenBOT
#

Stack trace

[```
paste your stack trace or a paste.gg link here!

](https://mclo.gs/MQUE9S1)

### Plugin and Datapack List

> pl
[13:49:13 INFO]: ℹ Server Plugins (15):
[13:49:13 INFO]: Bukkit Plugins:
[13:49:13 INFO]:  - AnarchyExploitFixes, AntiopByChaLiuCore, AxGraves, BetterRTP, BetterTeams, ChatFilter, LuckPerms, Matrix, packetevents, Plan
[13:49:13 INFO]:  PlayerViewDistanceController, SkinsRestorer, TAB, ViaBackwards, ViaVersion

### Actions to reproduce (if known)

_No response_

### Folia version

This server is running Folia version 1.21.8-6-ver/1.21.8@612d9bd (2025-09-30T14:11:15Z) (Implementing API version 1.21.8-R0.1-SNAPSHOT)
You are running the latest version

### Other

Does this look like a tab completion issue?
coarse tokenBOT
#

你当时在聊天栏输入什么?

其次,这是一个离线模式服务器。

I didn’t discover this issue myself, and the player who did doesn’t want to tell me how to reproduce it.

After I asked the AI, it told me this error happens when using the Tab key. So I changed the tab-spam-limit value (from 500 to 50), and then I noticed the problem got better (players can't crash the server instantly anymore; it now takes a few seconds or they might get kicked out).

As for the server, it's actually offline mode since most players in my area don't have MOJANG accounts.

coarse tokenBOT
#

When using the /ride command in 1.21.11 on an entity in the same region, it works fine. However, when attempting to ride an entity out of region, it causes a crash due to how the Entity#startRiding command is written, making it not region threading safe when attempting to ride an entity out of the current region.

This was tested and is replicatable in the latest Folia 1.21.11 commit by forceloading a chunk(or chunks) far outside the current region, and then running the command:

/ride @s mount @e[limit=1,type=!player,sort=furthest]

This effectively tries to teleport the mounter -> mount target, where the mount target and mounter are not in the same region. The fix in this PR provides a fix for the entirety of the Entity#startRiding method, and also a thread check at the HEAD of the method to ensure that Entity#startRiding is called on the region of the mounter entity.

coarse tokenBOT
#

Expected behavior

The command ride, return, rotate and so on should be disabled on folia and the could be never executed

Observed/Actual behavior

They are not disabled and causing crashes when player or console executed them

And what in the Commands.java:

<img width="1198" height="530" alt="Image" src="https://github.com/user-attachments/assets/19a476d3-123b-470d-a7a3-bfe353f5c26c" />

Steps/models to reproduce

Call one of them, for example it could be found in PR https://github.com/PaperMC/Folia/pull/412

Plugin and Datapack List

no plugins and datapacks

Folia version

The latest commit of folia

Other

No response

coarse tokenBOT
#

Expected behavior

控制台没有任何错误但是一个四乘四的一个区块加载错误 第一张是在这个Folia创建的随机地图 第二张是是我在本地复制的种子在客户端上创建的世界

<img width="1920" height="1009" alt="Image" src="https://github.com/user-attachments/assets/5669ea09-ffe4-4663-a1b6-2612dc64b664" />

<img width="1920" height="1009" alt="Image" src="https://github.com/user-attachments/assets/205f26d6-89b9-411f-89d3-c0ea20695c57" />

Observed/Actual behavior

刚加入世界往右看就看到了

Steps/models to reproduce

往右看

Plugin and Datapack List

没有任何插件

Folia version

folia-1.21.11-2

Other

No response

coarse tokenBOT
coarse tokenBOT
#

Stack trace

[19:55:20 INFO]: Done (7.443s)! For help, type "help"
[19:55:29 INFO]: UUID of player beengoo is e1d52487-74fe-46db-948a-82ffa057a9b0
[19:55:30 INFO]: beengoo joined the game
[19:55:30 INFO]: beengoo[/127.0.0.1:53314] logged in with entity id 95 at ([world]-56.94311053857109, 85.49313574198008, 31.53544797766236)
[19:55:30 ERROR]: [io.papermc.paper.threadedregions.TickRegionScheduler] Region #1 centered at chunk [-4, 1] in world 'world' failed to tick:
net.minecraft.ReportedException: Exception ticking world
        at net.minecraft.server.MinecraftServer.tickChildren(MinecraftServer.java:1934) ~[folia-1.21.11.jar:1.21.11-3-eee7128]
        at net.minecraft.server.MinecraftServer.tickServer(MinecraftServer.java:1744) ~[folia-1.21.11.jar:1.21.11-3-eee7128]
        at net.minecraft.server.dedicated.DedicatedServer.tickServer(DedicatedServer.java:429) ~[folia-1.21.11.jar:1.21.11-3-eee7128]
        at io.papermc.paper.threadedregions.TickRegions$ConcreteRegionTickHandle.t```...
coarse tokenBOT
#

Stack trace

MCLO Log

Plugin and Datapack List

None, I tested this on a fresh install of a exaroton server.

Actions to reproduce (if known)

About 30 seconds after the server is online this error occurs and the server shuts down.

Folia version

=[13:03:02 INFO]:
Checking version, please wait...
[13:03:03 INFO]:
This server is running Folia version 1.21.11-3-ver/1.21.11@eee7128 (2025-12-21T23:35:28Z) (Implementing API version 1.21.11-R0.1-SNAPSHOT)
You are running the latest version

Other

No response

coarse tokenBOT
coarse tokenBOT
#

While technically region-threading safe, the rotate command should be scheduled to the target argument in the rotate command, rather than the command source. The target entity is the object we are modifying the rotation of, so we should schedule to that region if not in that region already.

This also adds a utility method, Entity#runAtOrScheduleToImmediately, which will run the Consumer<Entity> task immediately if it is the correct tick thread for the entity, otherwise, it will schedule to the entity scheduler immediately.

coarse tokenBOT
coarse tokenBOT
#

Trying to adjust the riding code to allow cross-region rides really doesn't make any sense. There are conditions to allowing a mount that can change if you delay the mount. For example, already being mounted.

The actual appropriate fix for cross-region rides is for the caller to teleport so that the mount is no longer cross-region. I've adjusted the command to not allow the mount unless they are in the same region.

coarse tokenBOT
coarse tokenBOT
#

Hi - please open any reports or make any replies in the future in English. That will make things much easier for us.

We are unable to reproduce this. Would recommend testing on the most recent build with a new seed. If you can reproduce it reliably please add reproduction steps and we will re-open this issue. Thanks!

coarse tokenBOT
coarse tokenBOT
coarse tokenBOT
coarse tokenBOT
#

While POI update scheduling works fine on Folia, it has a major flaw with how it works. In the region threading base patch, Folia replaces the method call BlockableEventLoop#execute with RegionizedTaskQueue#queueChunkTask. While this works fine in general gameplay, it does cause all POI updates to be scheduled to the next tick, which technically breaks vanilla behavior and also breaks a few things(videos and images bellow).

The BlockableEventLoop#execute method is as such:

    public void execute(Runnable task) {
        R runnable = this.wrapRunnable(task);
        if (this.scheduleExecutables()) {
            this.schedule(runnable);
        } else {
            this.doRunTask(runnable);
        }
    }

Essentially, it checks if it is the "main thread" or not(which no longer exists in Folia, but for this case we will assume the "main thread" is the region owning the BlockPos we are updating at), and if it is the "main thread", it will run the task immediately, oth...

coarse tokenBOT
coarse tokenBOT
coarse tokenBOT
#

The /dialog command is disabled in Folia, which this PR fixes. The command itself is relatively simple, and the entire dialog system is run on just packets(at least for the server side). The dialog system is only disabled, in Folia, from the command side. Plugins and signs can still execute dialog operations on Folia.

The dialog command only iterates over the target players, and sends a packet. The changes in this PR basically just schedule the sending of the packets to the target player scheduler, which while simple, fixes the dialog command functionality.

For testing purposes, I used the example dialog commands from the Minecraft Wiki:

/dialog show @a minecraft:server_links
/dialog show @a {type:"minecraft:notice",title:"Hello"}
/dialog show @a {type:"minecraft:confirmation",title:"Give yourself diamond?",yes:{label:"Yes please","action":{"type":"run_command","command":"give @s diamond"}},no:{label:"Nope"}}
/dialog clear @a
coarse tokenBOT
#

Expected behavior

Pearls should stay, for example, in a stasis chamber until a player dies if using the default gamerules.
Tested it on both Paper and Folia just to be sure.

Observed/Actual behavior

On PaperMC and vanilla Minecraft, the pearls do not get deleted when switching dimensions but on Folia 1.21.11 they do get deleted once the player leaves the dimension.

Steps/models to reproduce

Make a stasis chamber, put a pearl in the chamber and go through a portal to change dimensions.

Plugin and Datapack List

Tested with no additional plugins installed.

Folia version

1.21.11-6-ver/1.21.11@0795007

Other

No response

coarse tokenBOT
#

While probably not a necessary command to reimplement into Folia, it should probably be implemented for more Vanilla parity and such.

The fix introduced here essentially schedules the full method in a very similar way as the other command patches. The ServerPlayer#setCamera method is already patched to support off-region targets, so we schedule the method contents to the ServerPlayer spectator.

Ive tested this via the command below:

/spectate @e[limit=1,type=!player,sort=random] Dueris
coarse tokenBOT
#

The issue is caused by the ThrownEnderpeal#tick method, where it checks if the owner entity is alive, which calls isRemoved. In Folia, this is different, and causes ender pearls to vanish when switching dimensions.

The fix proposed is to replace the !isAlive() check(which is just isRemoved()) with getHealth() <= 0, which functions correctly with how it should work.

coarse tokenBOT
coarse tokenBOT
coarse tokenBOT
#

Expected behavior

seed: -4617748357806537589

<img width="1920" height="1009" alt="Image" src="https://github.com/user-attachments/assets/51ec5438-1e1e-4f97-a35a-ce89086a2188" />

Observed/Actual behavior

What I saw while running the map

Steps/models to reproduce

1

Plugin and Datapack List

No plugins that actually modify the world

Folia version

This server is running Folia version 1.21.11-6-ver/1.21.11@0795007 (2025-12-25T03:04:11Z) (Implementing API version 1.21.11-R0.1-SNAPSHOT)
You are running the latest version
Previous version: 1.21.11-2-39b4122 (MC: 1.21.11)

Other

No response

coarse tokenBOT
coarse tokenBOT
#

With Folia, teleporting a tamed animal, like a wolf, to a player that is now not in the same region, is technically thread-safe because of Folias current patch. However, there is a race condition where if the chunk the tamed animal is trying to teleport to isn't loaded yet, it crashes the server because when it is trying to check if it CAN teleport, it tries to check blocks in that chunk, but if the chunk isn't loaded, it tries to load it. Thus causing a crash since if the target location isn't in the same region, it will kill the server because of a bad access(trying to load chunk outside owning region).

The fix proposed here just checks if the chunk is loaded first, and if it is loaded, then it will proceed. Otherwise, returns false.

#

This is something I was trying to fix earlier today, however was unable to find a practical solution. This is however a very large issue.

My thought is to add a ConcurrentLinkedList as a queue for each CraftPlayer, which holds the entity uuids to remove, and drain the queue on each player tick.

The fix proposed here would probably not be the greatest way to resolve this. However the issue stems from the mere usage of the visibility API, and how Folia unsafely accesses this API. It isn't something that should really be synchronized, as that could create insane performance issues, and replacing the collection with a concurrent alternative isn't the greatest idea either. By simply using the API, even from the correct owning context, the server is at risk of crashing randomly whenever an entity is removed due to this unsafe access.

This is indeed a desperate issue and should be fixed ASAP, given the severity of the issue and just USING the API causing risk of this crash, and many popu...

coarse tokenBOT
coarse tokenBOT
#

Actually, the reason is quite specific to how Folia handles player data compared to Vanilla/Paper.

  1. The Persistence Issue (Why they vanish on restart): In Vanilla and Paper, active Ender Pearls are stored inside the player's NBT data. However, because accessing ServerPlayer across threads is unsafe in Folia, the logic for saving and loading pearls via player NBT was completely removed. This is why pearls do not reappear when a player logs back in—the data is simply never saved.

  2. The Dimension/Region Issue (Why they vanish on teleport): Regarding your observation about pearls getting deleted when switching dimensions: This is because Folia performs extensive owner != null checks. Since Folia is multi-threaded, once the player leaves the pearl's current region (or dimension), the local entity lookup returns owner = null. Consequently, the pearl is immediately discarded/killed by the system.

The Solution: To fix this, we need to solve two problems:

How to safely store pearl data i...

coarse tokenBOT
coarse tokenBOT
#

Expected behavior

Ender dragon spawns

Observed/Actual behavior

When using summon to summon a dragon far from 0,0, the dragon did not appear as expected; instead, it appeared briefly, was immediately deleted, and an error was thrown, but server not crashed.

Steps/models to reproduce

Go away from 0,0
Then wait for chunk 0,0 unload
Summon a ender dragon

Plugin and Datapack List

No plugin provided

Folia version

1.21.11-6-ver/1.21.11@0795007

Other

We have try almost main version of folia, this bug may can reproduced in all the folia versions.

Resolution from Luminol: https://github.com/LuminolMC/Luminol/blob/ver/1.21.11/luminol-server/minecraft-patches/features/0073-Sync-dragon-part-when-teleportation-or-firstly-creat.patch

Original issue: https://github.com/LuminolMC/Luminol/issues/167

coarse tokenBOT
coarse tokenBOT
#

Expected behavior

Enderpearl stay the same i nthe chunk without it being removed when chunk get unloaded.

Observed/Actual behavior

Enderpearl was removed when chunk unload.

Steps/models to reproduce

paper-world-defaults.yml
misc.legacy-ender-pearl-behavior: true
fixes.disable-unloaded-chunk-enderpearl-exploit: false

  1. Create a pearl statis out in the world (not near spawn sicne spawn chunk might be loaded all the time)
  2. fly or tp or logout from that location
  3. return, relog to that location
  4. observe pearl is gone

in Folia 1.21.8-6-612d9bd when doing everythign like above the pearl stay there and doesnt get removed.

Plugin and Datapack List

pl
[20:02:15 INFO]: ℹ Server Plugins (0):
datapack list
[20:02:18 INFO]: Unknown or incomplete command. See below for error
datapack list<--[HERE]

Folia version

ver
[20:01:58 INFO]: Checking version, please wait...
[20:01:58 INFO]: This server is running Folia version 1.21.11-10-ver/1.21.11@1aa7055 (2026-01...

coarse tokenBOT
#

<img width="2560" height="1369" alt="Image" src="https://github.com/user-attachments/assets/692d2f6d-c09a-4991-b2d4-4e7225257067" />
I was not able to reproduce this by flying to the location, then teleporting into the exact same position as the OP. Appears to work perfectly fine.

This server is running Folia version 1.21.11-10-ver/1.21.11@1aa7055 (2026-01-04T19:46:20Z) (Implementing API version 1.21.11-R0.1-SNAPSHOT)
Running on Windows 11 with Open JDK 22

coarse tokenBOT
coarse tokenBOT
#

Expected behavior

I expected to see normal command block work...

Observed/Actual behavior

I saw command blocks does nothing when using any commands (gamerule command_block_work set to true, option in server.properties is on true), command blocks saying "all is ok" but not working

Steps/models to reproduce

.

Plugin and Datapack List

Plugins: [16:57:19 INFO]: ℹ Server Plugins (32):
[16:57:19 INFO]: Paper Plugins (8):
[16:57:19 INFO]: - CrazyCrates, HuskHomes, MiniMOTD, PerfoBooster, PlugManX, SmartSpawner, Veinminer, Veinminer-Enchantment
[16:57:19 INFO]: Bukkit Plugins (24):
[16:57:19 INFO]: - AuthMe, Chunky, CommandBlocker, CoreProtect, CrazyEnchantments, Duels, GrimAC, ItemEdit, LagFixer, LevelledMobs
[16:57:19 INFO]: packetevents, PlaceholderAPI, PvPManager, SkinsRestorer, TAB, ToolStats, Towny, TPA, Vault, ViaBackwards
[16:57:19 INFO]: ViaRewind, ViaVersion, voicechat, voicemessages

Folia version

16:57:57 INFO]: Checking version, please wait...
[16:57:...

coarse tokenBOT
coarse tokenBOT
coarse tokenBOT
#

Command blocks are not supported and are fundementally disabled in Folia. Also, for the future, if you have an issue with Canvas(of which I'm the dev of), ask in our discord or open an issue in github, don't use the Folia repo. Even if it is a Folia issue though, they won't help you if you are using Canvas. Just letting you know so that nobody gets mad and everything stays nice and tidy 😁

Regardless, this should probably be closed as command blocks are relatively difficult to implement in their entirety, and this isn't planned to implement ATM as far as I know.

coarse tokenBOT
coarse tokenBOT
#

Expected behavior

Players shouldnt be able to travel through Nether portals while inside a boat (with or without a villager).

Observed/Actual behavior

When a player enters a Nether portal while riding a boat (sometimes transporting a villager), the screen turns completely black, as if the player is falling endlessly into the void.

After forcefully disconnecting, the player is unable to rejoin the server. The server behaves as if the player is still online, preventing login and effectively soft-locking the player until manual intervention (e.g. player data reset).

Steps/models to reproduce

  1. Place a Nether portal.
  2. Put a boat in front of or inside the portal.
  3. Sit in the boat (optionally with a villager inside).
  4. Enter the Nether portal while riding the boat.
  5. Observe the black screen / void-like behavior.
  6. Disconnect from the server.
  7. Attempt to reconnec, login fails because the server thinks the player is still connected.

Plugin and Datapack List

T...

coarse tokenBOT
#

I don't know if it's fixed or if something no longer appears

This server is running Folia version 1.21.11-10-ver/1.21.11@1aa7055 (2026-01-04T19:46:20Z) (Implementing API version 1.21.11-R0.1-SNAPSHOT)
You are -4 version(s) behind
Download the new version at: https://papermc.io/downloads/paper
Previous version: 1.21.11-6-0795007 (MC: 1.21.11)

<img width="1920" height="1040" alt="Image" src="https://github.com/user-attachments/assets/29ee0b7f-f9bb-4c89-9f8e-358cd1bcac78" />

coarse tokenBOT
#

Expected behavior

The Villager should safely teleport to the Nether, similar to other entities or players.

Observed/Actual behavior

The server throws an exception and the Villager fails to teleport:

Error Log
java.lang.IllegalStateException: World mismatch: expected world_nether but got world
at net.minecraft.world.level.Level.getCurrentWorldData(Level.java:830)
at net.minecraft.world.level.Level.getDayTime(Level.java:1914)
at net.minecraft.world.timeline.AttributeTrackSampler.applyTimeBased(AttributeTrackSampler.java:35)
at net.minecraft.world.attribute.EnvironmentAttributeSystem$ValueSampler.computeValueNotPositional(EnvironmentAttributeSystem.java:257)
at net.minecraft.world.attribute.EnvironmentAttributeSystem$ValueSampler.getDimensionValue(EnvironmentAttributeSystem.java:224)
at net.minecraft.world.attribute.EnvironmentAttributeSystem$ValueSampler.getValue(EnvironmentAttributeSystem.java:231)
at net.minecraft.world.attribute.EnvironmentAttri...

coarse tokenBOT
#

Stack trace

https://mclo.gs/63CIAQV

Plugin and Datapack List

[03:20:41 INFO]: ℹ Server Plugins (0):

Actions to reproduce (if known)

  1. open a client with minihud mod
  2. join server and make op
  3. open minihud settings, open renders>>debugDataMainToggle, and other any debug data which need op permission
  4. server crashed (not client crash)

Folia version

This server is running Folia version 1.21.11-10-ver/1.21.11@1aa7055 (2026-01-04T19:46:20Z) (Implementing API version 1.21.11-R0.1-SNAPSHOT)
You are -4 version(s) behind

Other

I believe a client-side mod shouldn't cause the server to crash, so I reported it.

coarse tokenBOT
#

Expected behavior

Having the allowEnteringNetherUsingPortals game rule set to false should disallow players from entering the Nether.

Observed/Actual behavior

Even when the game rule is set to false, the players are able to enter the Nether.

Steps/models to reproduce

  1. Execute /gamerule allowEnteringNetherUsingPortals false
  2. Build and Enter a Nether portal.
  3. You will be teleported to the nether.

Plugin and Datapack List

None

Folia version

Folia version 1.21.11-10-ver/1.21.11@1aa7055 (2026-01-04T19:46:20Z) (Implementing API version 1.21.11-R0.1-SNAPSHOT)

Other

This issue has already happened in Paper (https://github.com/PaperMC/Paper/issues/13261) and has already been fixed there (https://github.com/PaperMC/Paper/pull/13263), this means Folia just needs to be updated to the latest Paper version

coarse tokenBOT
#

Expected behavior

/dialogs doesn't exist in the current Folia 1.21.1-1 JAR. It should be present and open dialogs for players as expected.

Observed/Actual behavior

The command doesn't exist, it's recognized in game.

Steps/models to reproduce

Use /dialogs

Plugin and Datapack List

None

Folia version

1.21.11 (build: 1aa7055)

Other

No response

coarse tokenBOT
#

Expected behavior

### Expected behavior

After entering the Nether, the player should be teleported immediately, because the fishing bobber remains in the world, continues to hold down the pressure plate, the redstone signal stays active, and the trapdoor remains open.

Observed/Actual behavior

### Actual behavior

The fishing bobber is removed immediately after changing dimension, the redstone signal is lost, the trapdoor closes, and the teleportation does not occur.

Steps/models to reproduce

Steps to reproduce

  1. Join a server running Folia
  2. Build a stasis chamber using an ender pearl and place a trapdoor and a pressure plate next to it
  3. Throw an ender pearl into the stasis chamber and cast a fishing rod so the bobber lands on the pressure plate
  4. Enter a Nether portal

Plugin and Datapack List

Plugins None

Folia version

1.21.11(1aa7055)

Other

### Additional notes

I understand that this behavior may be related to Folia’s region-based mul...

coarse tokenBOT
#

Expected behavior

When a villager passes through the nether portal, he moves between worlds.

Observed/Actual behavior

If the villager tries to move through the nether portal, it will disappear and an error will appear. If the villager was in the boat with the player, then the player gets stuck and will no longer be able to log on to the server until the restart.

[12:40:53 ERROR]: Entity threw exception at world:-116.39333593048231,63.0,256.7907611771183
java.lang.IllegalStateException: World mismatch: expected world_nether but got world
        at net.minecraft.world.level.Level.getCurrentWorldData(Level.java:830) ~[folia-1.21.11.jar:1.21.11-10-1aa7055]
        at net.minecraft.world.level.Level.getDayTime(Level.java:1914) ~[folia-1.21.11.jar:1.21.11-10-1aa7055]
        at net.minecraft.world.timeline.AttributeTrackSampler.applyTimeBased(AttributeTrackSampler.java:35) ~[folia-1.21.11.jar:1.21.11-10-1aa7055]
        at net.minecraft.world.attribute.EnvironmentAttributeSyste```...
coarse tokenBOT
coarse tokenBOT
#

Stack trace

https://mclo.gs/BI1E4tl

Plugin and Datapack List

[14:05:18 INFO]: ℹ Server Plugins (118):
[14:05:18 INFO]: Paper Plugins (5):
[14:05:18 INFO]: - BlueSlimeCore, HuskHomes, HuskSync, nightcore, PlugManX
[14:05:18 INFO]: Bukkit Plugins (113):
[14:05:18 INFO]: - 40ServidoresMC, AFKZone, AntiAFKPlus, AntiAFKPlusAddon, AntiDnTEnchantments, Argus, AttributeFixer, AxInventoryRestore, AxPlayerWarps, AxSellwands
[14:05:18 INFO]: AxTrade, BetterClan, BetterRTP, BetterRTP-MultiServer-Instance, BetterRTP-MultiServer-Requester, Bitsy, BlackMarket, ChatControl, ChunkHoppers, Chunky
[14:05:18 INFO]: ChunkyBorder, CloseCommand, CMILib, CombatLogX, CombatTPAGuard, CommandSynchronizer, ConditionalEvents, ConsoleSpamFixReborn, CoreProtect, CoreProtectPurgeScheduler
[14:05:18 INFO]: CosmeticPlus, CustomDeathMessages, CustomNameplates, CustomServidoresMCMessages, DailyChallenges, DeluxeMenus, *DisableJoinMessage, DiscordSynchronizer-Minecraft, DropConfirmation, eco
[14:05:18 I...

#

It stops itself because it's in a consistent state, so a restart would be able to save as much as possible in normal state before it becomes so corrupted that it won't be able to do anything, and after the start the server should be ok again.

That is for sure a plugin issue. Folia isn't for everyone, and you should try to use less public plugins in order to have more control over knowing what may mess with stuff in an unsafe manner

coarse tokenBOT
#

It stops itself because it's in a inconsistent state, so a restart would be able to save as much as possible in normal state before it becomes so corrupted that it won't be able to do anything, and after the start the server should be ok again.

That is for sure a plugin issue. Folia isn't for everyone, and you should try to use less public plugins in order to have more control over knowing what may mess with stuff in an unsafe manner

Folia definitely isn’t for everyone, which is why nearly 60% of the plugins we use are custom. That said, there’s no need to reinvent the wheel. I’ve been thinking about plugins that might be manipulating entities, and the only ones that come to mind are TAB and possibly Floodgate.

Is there any way to get more detailed information about the error, maybe some kind of debug mode? With the information currently available, it’s going to be quite difficult to pinpoint the cause, especially since it only happens once every one or two weeks.

coarse tokenBOT
coarse tokenBOT
#

Expected behavior

EntityDamageByEntityEvent#getDamager() should return CraftEnderPearl.
Debugger shows this value for Paper:
<img width="1523" height="784" alt="Image" src="https://github.com/user-attachments/assets/aefec42b-220b-4491-be4b-0245e5f33049" />

Observed/Actual behavior

EntityDamageByEntityEvent#getDamager() returns Player.
<img width="1274" height="295" alt="Image" src="https://github.com/user-attachments/assets/8fcff754-8dce-4347-b3d7-9cfa776480c8" />

Steps/models to reproduce

  1. Catch event: EntityDamageByEntityEvent
  2. Check return value of event#getDamager()

Plugin and Datapack List

EternalCombat

Folia version

This server is running Folia version 1.21.11-11-ver/1.21.11@e112b00 (2026-01-20T18:53:05Z) (Implementing API version 1.21.11-R0.1-SNAPSHOT)
You are running the latest version
Previous version: 1.21.11-100-4873e3f (MC: 1.21.11)

Other

No response

coarse tokenBOT
#

It's not broken just that nobody had time to make it, as it's quite complex, especially the unloading part. You can open a pr with it if you want and you have time to make it. You can look at https://github.com/PaperMC/Folia/pull/63 for at least a few things to consider, but as a side note the internals changed in some ways for reasons like optimisations that makes it even harder now to make such a pr than when my pr was made

coarse tokenBOT
#

Expected behavior

calling entity.teleportAsync(destination, PlayerTeleportEvent.TeleportCause.PLUGIN, TeleportFlag.Relative.values()) should preserve the entity's motion after teleportation

Observed/Actual behavior

motion is not preserved

Steps/models to reproduce

  1. teleport an entity with relative teleport flags specified
    entity.teleportAsync(destination, PlayerTeleportEvent.TeleportCause.PLUGIN, TeleportFlag.Relative.values())
  2. motion is reset…

Plugin and Datapack List

unrelated

Folia version

[18:01:37 INFO]: Checking version, please wait...
[18:01:37 INFO]: This server is running Folia version 1.21.11-11-ver/1.21.11@e112b00 (2026-01-20T18:53:05Z) (Implementing API version 1.21.11-R0.1-SNAPSHOT)
You are running the latest version
Previous version: 1.21.11-100-4873e3f (MC: 1.21.11)

Other

No response

coarse tokenBOT
coarse tokenBOT
coarse tokenBOT
#

Expected behavior

Teleport in a boat with a villager in it

Observed/Actual behavior

[15:31:33] [ServerMain/INFO]: [bootstrap] Running Java 21 (OpenJDK 64-Bit Server VM 21.0.10+7; Arch Linux null) on Linux 6.18.7-zen1-1-zen (amd64)
[15:31:33] [ServerMain/INFO]: [bootstrap] Loading Folia 1.21.11-12-ver/1.21.11@6d795a8 (2026-02-08T00:47:27Z) for Minecraft 1.21.11
[15:31:33] [ServerMain/INFO]: [PluginInitializerManager] Initializing plugins...
[15:31:33] [ServerMain/INFO]: [PluginInitializerManager] Initialized 0 plugins
[15:31:35] [ServerMain/INFO]: Environment: Environment[sessionHost=https://sessionserver.mojang.com, servicesHost=https://api.minecraftservices.com, profilesHost=https://api.mojang.com, name=PROD]
[15:31:35] [Yggdrasil Key Fetcher/ERROR]: Got an error with a html body connecting to https://api.minecraftservices.com/publickeys: <!DOCTYPE html PUBLIC '-//W3C//DTD XHTML 1.0 Transitional//EN' 'http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd'>
<html xmlns='ht...

coarse tokenBOT
coarse tokenBOT
coarse tokenBOT
#

Summary

This PR adds a Photographer API to Folia so the server can record gameplay as .mcpr replays (ReplayMod-compatible). Plugins can create "photographer" entities that mirror a player, capture network packets, and write them to a .mcpr file when recording stops.

Motivation

  • Recording on Folia: Servers (e.g. anti-cheat, moderation, replay) need a way to record players as .mcpr without a client-side ReplayMod. Leaves and some other cores already provide a Photographer API; this brings the same capability to Folia.
  • Plugin compatibility: The API is aligned with the existing "photographer" concept (e.g. Leaves), so plugins like ISeeYou (Folia) can support Folia with minimal changes.

Main changes

Area Description
API (folia-api) New interfaces: PhotographerManager, Photographer, BukkitRecorderOption. Server exposes Server#getPhotographerManager().
Server implementation ServerPhotographer (fake player), Recorder, Replay...
coarse tokenBOT
#

⚠️ Security & License Concerns - Compiled .class Files Should Not Be Committed
To the maintainers (@PaperMC team):
I recommend not merging this PR in its current state due to serious concerns about binary files and GPL compliance.
To the PR author (@xiaofanforfabric):
Thank you for your contribution, but there are some critical issues that need to be addressed:
🔴 Problems:

24 compiled .class files are being committed to the repository

Binary files like .class should never be in version control
They are automatically generated during the build process
They belong in .gitignore, not in the repository

GPL License violation concern

The GPL requires source code transparency
Committing pre-compiled binaries without a verifiable build process contradicts open-source principles
Users cannot verify if the .class files actually match the provided .java source code

Security risk

Pre-compiled .class files could contain malicious bytecode not visible in the source
T...

coarse tokenBOT
#

Holy AI... both semi in code and in comments

This is out of scope of Folias intentions and goals, and most likely will not get merged, along with the fact that there are changes in the README too..??? And weird new MD files??? And compiled class files???

Out of scope, I don't think this would rly ever be merged, especially given this seems to be doing a lot more than just a Photographer API, like calling it a Folia fork in the unneeded README changes... when being PRed to merge with Folia?? And the insanely long debug file??

coarse tokenBOT
#

这本来就是一个错误的拉取请求,本意是要合并到我的项目,结果不知为何拉到了paperMC官方的项目,我了解不会合并的,我不在意
This was originally an erroneous pull request. The intention was to merge it into my own project, but for some reason it was submitted to the PaperMC official repository. I understand it won’t be merged, and I don’t mind.

coarse tokenBOT
#

Expected behavior

When a sticky piston extends and retracts in-game, both BlockPistonExtendEvent and BlockPistonRetractEvent should fire respectively.

Observed/Actual behavior

When a sticky piston extends and retracts in-game, only BlockPistonExtendEvent fires; BlockPistonRetractEvent never fires.

Steps/models to reproduce

minimal demo plugin:


import org.bukkit.event.EventHandler;
import org.bukkit.event.Listener;
import org.bukkit.event.block.BlockPistonExtendEvent;
import org.bukkit.event.block.BlockPistonRetractEvent;
import org.bukkit.plugin.java.JavaPlugin;


public final class PistonPlugin extends JavaPlugin implements Listener {

    @Override
    public void onEnable() {
        getServer().getPluginManager().registerEvents(this, this);
    }

    @EventHandler
    public void onPistonExtendEvent(final BlockPistonExtendEvent e) {
        System.out.println("a piston extend event occurred!");
    }

    @EventHandler
    public void onPistonRetractEvent(final```...
coarse tokenBOT
coarse tokenBOT
coarse tokenBOT
coarse tokenBOT
coarse tokenBOT
#

Summary

This PR fixes a Folia villager Nether portal bug where villager AI could be initialized before the destination world was fully applied during async portal teleportation.

As a result, Villager.makeBrain() and Brain.updateActivityFromSchedule() could run while the villager was still in a temporary world-mismatch state.

What changed

  • Deferred villager brain activity initialization when the entity is being restored through async teleport.
  • Prevented the initial schedule-based brain update from running before the destination world is actually available.
  • Added a retry path so that if the villager still has a world mismatch, brain initialization is attempted again on the next tick.
  • Rechecked the deferred brain initialization after dimension change so AI can resume as soon as the world switch is complete.

How it works

  • Entity.transformForAsyncTeleport(...) now exposes the destination world context during async teleport restore.
  • Villager.makeBrain...
coarse tokenBOT
#

Stack trace

I built a very large Guardian farm on a Minecraft Folia server that uses Nether portals to move Guardians to the Nether and then back to the Overworld.
The issue only occurs when entities are teleported back from the Nether to the Overworld.
After the farm enters the despawn sphere, the following happens:
A few seconds later, the server console starts spamming error messages (see logs below).
Nether portals completely stop working (for both players and entities).
After some more time (seconds to minutes), the server becomes even more unstable:
In creative mode, it is no longer possible to break or place blocks.
Entities cannot be interacted with or spawned properly.
Persistence:
The issue persists even after restarting the server.
The only way to fix it is to manually delete the affected Nether chunk entity files:
<world_name>/DIM-1/entities/<affected_chunk_file> (the area where the farm is located in the Nether), and then restart the server.

Additional...

coarse tokenBOT
coarse tokenBOT
coarse tokenBOT
coarse tokenBOT
coarse tokenBOT
coarse tokenBOT
coarse tokenBOT
coarse tokenBOT
#

It's not abt where the methods in the API are called, it's that it's accessing a system internally that isn't thread safe and is used for a lot of different states, so making it unguarded isn't the best idea bc then if people start accessing the internal synched entity data off the region context then it can cause crashes easily that make no sense(Ive seen a few before)

coarse tokenBOT
coarse tokenBOT
#

There is no ETA on 26.1.2 development release or progress. That should be handled by SpottedLeaf.

I do see in your branch though that you include extra patches alongside region threading, which wouldn't be accepted, and should be merged to the Region-Threading-Base patch if related. Alongside that, I do see some commits/patches and a few other changes were authored by Copilot, which I dont think is accepted ever at PaperMC.

Overall, no ETA, it may be a week, a month, or several months. You can use your own fork, or be patient for the official Folia release. AI-written code I dont think is accepted at PaperMC, so probably wouldn't be merged in the Folia repository, also given that there are multiple patches that should be part of the region threading base patch.

#

There is no ETA on 26.1.2 development release or progress. That should be handled by SpottedLeaf.

I do see in your branch though that you include extra patches alongside region threading, which wouldn't be accepted, and should be merged to the Region-Threading-Base patch if related. Alongside that, I do see some commits/patches and a few other changes were authored by Copilot, which I dont think is accepted ever at PaperMC.

Overall, no ETA, it may be a week, a month, or several months. You can use your own fork, or be patient for the official Folia release. AI-written code I dont think is accepted at PaperMC, so probably wouldn't be merged in the Folia repository, also given that there are multiple patches that should be part of the region threading base patch.

You are right, shouldn't introduced extra patches. I've already merged the extra patches into the existing.

#

We do not have any kind of "ban" on using AI tools for contributions, in fact most team members are not living under rocks and make use of these tools. But using AI does not mean low-quality submissions are OK. You are still expected to review and fully understand your submission and to take ownership of it (in a responsibility sense). This doesn't appear to be the case here, and the linked diff is basically unusable. It may compile but I would not advise using it.

#

We do not have any kind of "ban" on using AI tools for contributions, in fact most team members are not living under rocks and make use of these tools. But using AI does not mean low-quality submissions are OK. You are still expected to review and fully understand your submission and to take ownership of it (in a responsibility sense). This doesn't appear to be the case here, and the linked diff is basically unusable. It may compile but I would not advise using it.

Fair enough, I was unsure on what the stance was on AI in PaperMC, and def understand utilizing AI only if you do understand what it's changing and review it and such. Thank you for clearing that up tho, much appreciated!

#

We do not have any kind of "ban" on using AI tools for contributions, in fact most team members are not living under rocks and make use of these tools. But using AI does not mean low-quality submissions are OK. You are still expected to review and fully understand your submission and to take ownership of it (in a responsibility sense). This doesn't appear to be the case here, and the linked diff is basically unusable. It may compile but I would not advise using it.

I really hope that leaf can spilit his larrrrrggggge patch into some small one. It seems that the workload of each update is now no less than re-implementing a new folia.

coarse tokenBOT
#

Summary

This Pull Request introduces major architectural improvements and essential API additions tailored specifically for Folia's regionised multithreading environment. It addresses long-standing issues like global scoreboard synchronization and per-region performance stabilization.

Key Changes

  • Global Scoreboard API: Implemented GlobalScoreboardManager to provide a thread-safe way to interact with the global scoreboard from any region using the GlobalRegionScheduler.
  • Region Health Manager: Introduced RegionHealthManager to monitor per-region performance (MSPPT) and provide hooks for dynamic load mitigation.
  • Dynamic Ticking (TPS Stabilizer): Added FoliaPerformanceOptimizer which automatically throttles non-player entity AI/Physics in specific regions when they fall below performance thresholds (45ms+ MSPPT), ensuring stable 20 TPS.
  • 1.21.x Feature Support: Ported Creaking, CreakingHeart, and Breeze API extensions to Folia with full thread-safety and region-aware...
coarse tokenBOT
coarse tokenBOT
#
[PaperMC/Folia] New branch created: ver/26.1.x
coarse tokenBOT
coarse tokenBOT
coarse tokenBOT
#

Expected behavior

The version is specified, and it's the same as PaperMC

Observed/Actual behavior

The version is unspecified, and building it causes it to produce unspecified folder in the local .m2 repository.

Steps/models to reproduce

  1. Clone the Folia repo
  2. Run ./gradlew applyAllPatches
  3. Run ./gradlew -PpublishDevBundle publishToMavenLocal
  4. Check the local .m2 repository under dev/folia/dev-bundle and dev/folia/folia-api to see unspecified folders.

Plugin and Datapack List

None

Folia version

https://github.com/PaperMC/Folia/commit/de00a9486ffd69589d687dc152780fe013be4573

Other

I noticed that the version field in gradle.properties was removed, but Paper has these lines in its settings.gradle.kts

gradle.lifecycle.beforeProject {
    val mcVersion = providers.gradleProperty("mcVersion").get().trim()
    val paperVersionChannel = providers.gradleProperty("channel").get().trim()
    val paperBuildNumber = providers.environmentVariable("BUILD_NU```...
coarse tokenBOT
coarse tokenBOT
#

Expected behavior

When a player rides a vehicle (boat, minecart, mounted animal, etc.) and the vehicle enters an end portal in The End, the player should be returned to their personal respawn location (bed / respawn anchor / Player#setRespawnLocation), matching the behavior of a player walking into the end portal on foot.

At minimum, EntityPortalEvent (or PlayerPortalEvent for the passenger) should be fired so plugins can correct the destination.

Observed/Actual behavior

When a player is a passenger of any non-player vehicle (most easily reproduced with a boat that also carries another mob, since solo riders are dismounted automatically) and that vehicle hits an end portal block in The End:

The whole passenger tree, including the player, is teleported to the overworld world spawn, not the player's respawn location.
Neither EntityPortalEvent nor PlayerPortalEvent is fired for this teleport, so plugins cannot intercept and rewrite the destination.
A player walking into the s...

coarse tokenBOT
coarse tokenBOT
#

Stack trace

It can be an exploit or big mistake, I think its both. Basically the finish configuration packet makes the netty thread wait. Big mistake, this can be used by attackers and give micro lags for bad connections. Someone with bad connection joins -> half the server freezes for a moment. Exploiter joins -> entire server lags.

It seems like a design flaw:

  • I have solved it by not awaiting at all the netty thread and use a memory driven state pipeline processor instead to avoid relying on awaiting the netty thread and only soft-blocking the user instead.
  • Await is a cheap and wrong way to "wait until something happens" -> monitor state thread or task instead is more stable and better design and avoids locking a thread used for another thing.

message (5).txt

Plugin and Datapack List

[16:14:42 INFO]: ℹ Server Plugins (20):
[16:14:42 INFO]: Paper Plugins (1):
[16:14:42 INFO]: - PlugManX
[16:14:42 INFO]: Bukkit Plugins (19):
[16:14:42 INFO]: - AuthMe, AuthMePremiumBu...

#

I think it might be present on paper too, I recomemnd rolling up a fix on everywhere.

I made a build but I dont know how to contribute as it doesnt work like 1.8.8 or velocity and thats the only one I learned to make.

Here is a jar and source of my solution:
https://drive.google.com/file/d/14zngIAsl9HHaUFlqqiEHOtW89zTKHOjT/view?usp=drive_link
https://drive.google.com/file/d/1HjG4PhAxDQtTnte7_L4PCntk8JtIp2J4/view?usp=drive_link

#

Also sorry for sending a leaf stacktrace, Its because I lost my original stacktrace, but its the same one on all servers and same logic. It happened on my folia server -> made update and ignored it. Today I got report from someone using leaf and I think this should be rolled to everyone (Paper / Folia) so then it can be propagated by other authors (basicaly it currently affects folia confirmed by me) If you need the original folia stacktrace i can find it.

coarse tokenBOT
coarse tokenBOT
coarse tokenBOT
coarse tokenBOT
#

Leaf has 'async-switch-state' setting to not wait on main thread.

Probably what happened here is that some plugin called some bukkit method from netty thread what caused chunk loading, so netty thread started waiting for Server/Main thread (to finish chunk loading and do Future.complete(chunk)) while server thread started waiting for task finish scheduled to same netty thread what is waiting main thread.

So it basically deadlock.
Netty thread is waiting for main thread to do something and main thread is waiting for netty thread to do something.

its not an exploit unless attacker can send ServerboundFinishConfigurationPacket and then send some packets to overload netty thread (make netty to decode packets 100% time) so it will not execute that ConfigurationChange task.

coarse tokenBOT
coarse tokenBOT
#

I will be more specific but only based on symptoms as I fixed it on my server already thus I dont have to deal with this anymore.

  1. The issue happens usually on join and it doesn't happen all of the times. None of my plugins load chunks tho I understand it happened in a situation that a chunk was loaded but not by a plugin. Maybe the region thread froze and that froze contaminated netty and thats why the froze happen to all the players in same netty thread. This is a guess and there are the causes; There was an extremely laggy chunk, yet, that lone player joining on his own region should not affect other region's players, breaking Folia soul by syncing the netty thread into the main thread (madness).
  2. I doubt the issue has anything to do with plugins as the wait is not triggered by any pugins rather by the minecraft server code itself. Why it decided to wait might be interesting to understand, yet, it's also a fact that issue does not reliable happen all of the times so it might ju...
coarse tokenBOT
coarse tokenBOT
#

Expected behavior

in console 2 PRINTs
[TPtest] Enabling TPtest v1.0-SNAPSHOT
[TPtest] [STDOUT] TPtest enabled
[TPtest] [STDOUT] EVENT
[TPtest] [STDOUT] CANCEL
and dont let player teleport
(it works on latest paper)

Observed/Actual behavior

nothing just letting player teleport when it shoud be cancelled (yes plugin was working i made simple loop that prints test)

Steps/models to reproduce

Write simple plugin (

package org.kokosowy869.tPtest;

import org.bukkit.GameMode;
import org.bukkit.event.EventHandler;
import org.bukkit.event.Listener;
import org.bukkit.event.player.PlayerTeleportEvent;
import org.bukkit.plugin.java.JavaPlugin;

public final class TPtest extends JavaPlugin implements Listener {

@Override
public void onEnable() {

    getServer().getPluginManager().registerEvents(this, this);

    System.out.println("TPtest enabled");
}

@Override
public void onDisable() {

}

@EventHandler
public void onTp(PlayerTeleportEve...