You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I added all the prerequisites for CommandAPI & everything is working besides receiving an unexpected error.
I joined, then ran the command.
An error appeared, but the command worked.
What actually happened
The command worked as it should. All that happened was an error appeared in the console.
What should have happened
No error
Server logs and CommandAPI config
[22:07:01 ERROR]: Caught previously unhandled exception :
[22:07:01 ERROR]: Caught previously unhandled exception :
[22:07:01 ERROR]: Paper Async Command Builder Thread Pool - 1
java.util.ConcurrentModificationException: null
at java.util.TreeMap$PrivateEntryIterator.nextEntry(TreeMap.java:1486) ~[?:?]
at java.util.TreeMap$ValueIterator.next(TreeMap.java:1531) ~[?:?]
at net.minecraft.commands.Commands.fillUsableCommands(Commands.java:483) ~[?:?]
at net.minecraft.commands.Commands.sendAsync(Commands.java:443) ~[?:?]
at net.minecraft.commands.Commands.lambda$sendCommands$5(Commands.java:422) ~[?:?]
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1136) ~[?:?]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635) ~[?:?]
at java.lang.Thread.run(Thread.java:833) ~[?:?]
[22:07:01 ERROR]: Paper Async Command Builder Thread Pool - 0
java.util.ConcurrentModificationException: null
at java.util.TreeMap$PrivateEntryIterator.nextEntry(TreeMap.java:1486) ~[?:?]
at java.util.TreeMap$ValueIterator.next(TreeMap.java:1531) ~[?:?]
at net.minecraft.commands.Commands.fillUsableCommands(Commands.java:483) ~[?:?]
at net.minecraft.commands.Commands.sendAsync(Commands.java:443) ~[?:?]
at net.minecraft.commands.Commands.lambda$sendCommands$5(Commands.java:422) ~[?:?]
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1136) ~[?:?]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635) ~[?:?]
at java.lang.Thread.run(Thread.java:833) ~[?:?]
[22:07:01 ERROR]: Caught previously unhandled exception :
[22:07:01 ERROR]: Paper Async Command Builder Thread Pool - 2
java.util.ConcurrentModificationException: null
at java.util.TreeMap$PrivateEntryIterator.nextEntry(TreeMap.java:1486) ~[?:?]
at java.util.TreeMap$ValueIterator.next(TreeMap.java:1531) ~[?:?]
at net.minecraft.commands.Commands.fillUsableCommands(Commands.java:483) ~[?:?]
at net.minecraft.commands.Commands.sendAsync(Commands.java:443) ~[?:?]
at net.minecraft.commands.Commands.lambda$sendCommands$5(Commands.java:422) ~[?:?]
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1136) ~[?:?]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635) ~[?:?]
at java.lang.Thread.run(Thread.java:833) ~[?:?]
[22:07:01 ERROR]: Caught previously unhandled exception :
[22:07:01 ERROR]: Paper Async Command Builder Thread Pool - 3
java.util.ConcurrentModificationException: null
at java.util.TreeMap$PrivateEntryIterator.nextEntry(TreeMap.java:1486) ~[?:?]
at java.util.TreeMap$ValueIterator.next(TreeMap.java:1531) ~[?:?]
at net.minecraft.commands.Commands.fillUsableCommands(Commands.java:483) ~[?:?]
at net.minecraft.commands.Commands.sendAsync(Commands.java:443) ~[?:?]
at net.minecraft.commands.Commands.lambda$sendCommands$5(Commands.java:422) ~[?:?]
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1136) ~[?:?]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635) ~[?:?]
at java.lang.Thread.run(Thread.java:833) ~[?:?]
[22:07:01 ERROR]: Caught previously unhandled exception :
[22:07:01 ERROR]: Paper Async Command Builder Thread Pool - 4
java.util.ConcurrentModificationException: null
at java.util.TreeMap$PrivateEntryIterator.nextEntry(TreeMap.java:1486) ~[?:?]
at java.util.TreeMap$ValueIterator.next(TreeMap.java:1531) ~[?:?]
at net.minecraft.commands.Commands.fillUsableCommands(Commands.java:483) ~[?:?]
at net.minecraft.commands.Commands.sendAsync(Commands.java:443) ~[?:?]
at net.minecraft.commands.Commands.lambda$sendCommands$5(Commands.java:422) ~[?:?]
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1136) ~[?:?]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635) ~[?:?]
at java.lang.Thread.run(Thread.java:833) ~[?:?]
This looks similar to #494. There is currently PR #501 that tries to fix #494. If you're able to, you could try using the CommandAPI branch for #501 and see if that resolves this problem. Unfortunately, #501 isn't ready for release yet since it does not resolve the issue on older versions of Paper, but I have tried it with 1.20.2 and it seems to help there.
Use some sneaky reflection to intercept `net.minecraft.server.CommandDispatcher`'s task scheduling and enforce our own read-write access
Updates #501Fixes#494 and #503
CommandAPI version
9.20
Minecraft version
1.20.1
Are you shading the CommandAPI?
Yes
What I did
What actually happened
The command worked as it should. All that happened was an error appeared in the console.
What should have happened
No error
Server logs and CommandAPI config
Other
The text was updated successfully, but these errors were encountered: