FastAsyncWorldEdit

FastAsyncWorldEdit

152k Downloads

Error when editing chunks without players

emil-x opened this issue · 7 comments

commented

Server Implementation

Paper

Server Version

1.20.1

Describe the bug

java.lang.NullPointerException: Cannot invoke "Object.getClass()" because "o" is null.

When editing a chunk without players, an error occurs starting from version 498 (works on version 497 and below)

To Reproduce

I have a plugin that loads a schema from a file on command for 30 seconds and then returns the blocks to the world as before. But now I get an error, if a player creates a scheme and exits the server, then after 30 seconds the scheme will not be deleted from the world and the server will give a bunch of errors.

  1. Create a schema file and run a task for 30 seconds to remove this schema
  2. Leave the server and wait for these 30 seconds
  3. Victory! You are getting a bunch of errors in the console and not a remote schema file

On version 497 and below, everything works without errors

Expected behaviour

The plugin should edit chunks without players, just like before.

Screenshots / Videos

No response

Error log (if applicable)

No response

Fawe Debugpaste

https://athion.net/ISPaster/paste/view/29ebea1cae1543cdb335cc0e38470281

Fawe Version

FastAsyncWorldEdit-Bukkit-2.6.5-SNAPSHOT-502

Checklist

Anything else?

No response

commented

Is this an issue on normal Paper? It may be a Purpur issue.

commented

Is this an issue on normal Paper? It may be a Purpur issue.

There are no bugs on version 497, the purple version has nothing to do with it (tested on different versions)

commented

It's not the Purpur version I'm interested by, it's if it's an issue that's caused by Purpur use at all. It has been known to cause issues before.

commented

This is most likely related to the commit “feat: implement removal of entities if they are in the block after…”

0554b31

commented

Okay, but is it also an issue on paper. Purpur and paper handle stuff differently.

commented

Checked on paper-1.20.1-59 same error.
Everything works on version 497, not higher

commented

added video
https://youtu.be/a3KcK0NCGJU

The error occurs here
try (EditSession newEditSession = plugin.getWorldEdit().newEditSession(plugin.getAdapterDefaultWorld())) {
lastEditSession.undo(newEditSession);
}

1 Schema file is created
2 Starts a timer to cancel pasting the schema
3 I am leaving the server
4 When the timer expires, the cancel operation does not fire

It is important to note that if you do not leave the server, then there will be no error. The error occurs when there are no players nearby