Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ConcurrentModificationException caused by async command sending patch #11101

Closed
test12345710 opened this issue Jul 17, 2024 · 11 comments
Closed
Labels
status: accepted Disputed bug is accepted as valid or Feature accepted as desired to be added. type: bug Something doesn't work as it was intended to. version: 1.21 Game version 1.21

Comments

@test12345710
Copy link

Expected behavior

No errors and a clean reload.

Observed/Actual behavior

A ConcurrentModificationException.

Steps/models to reproduce

Start server
Reload until you see the error. ( it's at the bottom kinda )

Plugin and Datapack List

Plugins (all Bukkit) : FacilisCommon, MultiWorld and SkinsRestorer
Datapacks: vanilla (built-in), file/bukkit (world), bundle (feature), paper (built-in)

Paper version

[19:56:32 INFO]: Checking version, please wait...
[19:56:32 INFO]: This server is running Paper version 1.21-83-master@967f98a (2024-07-17T14:55:35Z) (Implementing API version 1.21-R0.1-SNAPSHOT)
You are running the latest version
Previous version: 1.21-81-ceeb8c1 (MC: 1.21)

Other

I noticed that every time I start my server, reload it a couple of times ( because I am developing my own plugin ) and look at the console ( to check for bugs ), I see a ConcurrentModificationException with a number that increments every time I see the error ( not every time I reload ).

So, I remove my plugin from the list and I see that it's still happening every couple of reloads. So I test it a bit more and then it starts happening every 2 reloads.

@test12345710 test12345710 added status: needs triage type: bug Something doesn't work as it was intended to. labels Jul 17, 2024
@papermc-sniffer papermc-sniffer bot added the version: 1.21 Game version 1.21 label Jul 17, 2024
@papermc-projects papermc-projects bot moved this to 🕑 Needs Triage in Issues: Bugs Jul 17, 2024
@test12345710
Copy link
Author

test12345710 commented Jul 17, 2024

I noticed that it also says something about commands? Maybe Paper just doesn't support Bukkit commands that well?

EDIT: When I removed all plugins, it started happening every reload.
EDIT 2: When I restart the server, the number that increments goes back to 0.
EDIT 3: I am using the Bukkit reload also ( yes I know I am not supposed to but I can't restart my server for every minor change in my plugin.)

@electronicboy
Copy link
Member

There is a long known issue in the logic for sending commands to clients async, this is generally harmless and afaik, there is already issues open for this (or, at least, it's known about)

@test12345710
Copy link
Author

There is a long known issue in the logic for sending commands to clients async, this is generally harmless and afaik, there is already issues open for this (or, at least, it's known about)

So, it's known about. But can it be resolved or at least suppressed? I like a clean console.
Also there aren't any issues about this specific method of getting it. ( but there are about it existing )

@electronicboy
Copy link
Member

it's on my eternal todo list, however, I'm currently out of action as I just recently had eye surgery; I generally suggested that we just suppress and reshoot

@codebycam
Copy link

Can you please provide your entire latest.log?

@codebycam codebycam added the resolution: awaiting response Additional information is required from the issue reporter label Jul 17, 2024
@papermc-projects papermc-projects bot moved this to ⌛ Awaiting Response in Issues: Bugs Jul 17, 2024
@test12345710
Copy link
Author

So, upon further testing, I found out that this bug is really sketchy.

After I made the original post, I closed the server, along with my Minecraft client. ( I was on the server while this error was occurring)

So, after your reply, I fired up the server again ( because all the logs contained my custom plugin so I wanted to eliminate the possibility) and began testing and I realized that it doesn't happen when I'm not on the server ( or at least I didn't get it ). Then I restarted it (for a clean log) and logged on and after a couple reloads, it started happening again. Here's the log:

latest.log

@electronicboy
Copy link
Member

if there is no player online then there is nobody to send a commands packet to, and thus, the bug is not exposed. This is only an issue when something mutates the command system late when people are being sent info about commands

@test12345710
Copy link
Author

if there is no player online then there is nobody to send a commands packet to, and thus, the bug is not exposed. This is only an issue when something mutates the command system late when people are being sent info about commands

Can I do anything about it?

@test12345710
Copy link
Author

revive comment

@electronicboy
Copy link
Member

you will need to wait until we patch it, or, don't register commands outside of the expected lifecycle if you're a dev

@codebycam codebycam added status: accepted Disputed bug is accepted as valid or Feature accepted as desired to be added. and removed resolution: awaiting response Additional information is required from the issue reporter labels Sep 18, 2024
@papermc-projects papermc-projects bot moved this from ⌛ Awaiting Response to ✅ Accepted in Issues: Bugs Sep 18, 2024
@jpenilla jpenilla changed the title Getting this error every couple reloads: java.util.ConcurrentModificationException: null ConcurrentModificationException caused by async command sending patch Sep 18, 2024
@Warriorrrr
Copy link
Member

Resolved by 736c78c

@github-project-automation github-project-automation bot moved this from ✅ Accepted to Done in Issues: Bugs Jan 12, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
status: accepted Disputed bug is accepted as valid or Feature accepted as desired to be added. type: bug Something doesn't work as it was intended to. version: 1.21 Game version 1.21
Projects
Status: Done
Development

No branches or pull requests

4 participants