[Bug] ByteBuddy agent attachment fails
PatchBukkit loads into Pumpkin, but its embedded Paper server fails to initialize on Windows.
ByteBuddy fails to attach to the JVM. Multiple compatibility hooks fail to install, followed by:
java.lang.IllegalStateException: WorldInitEvent may only be triggered synchronously.
Startup ends with:
Failed to initialize JVM: Failed to attach thread for JVM initialization: HeadlessPaperServer.boot returned false
Environment
- OS: Windows 11 x64 25H2
- Pumpkin: 0.2.1+26.3-26.51
- PatchBukkit: downloaded from release 0.2.1
- Java: Oracle JDK 25.0.4.1
- JAVA_HOME: C:\Program Files\Java\jdk-25.0.4.1
- Managed Paper: 26.3 build 205
- Launch method: executing pumpkin-X64-Windows.exe
Note: the console reports Loaded patchbukkit (0.1.0) despite using the newer release download.
Steps to reproduce
- Install Pumpkin and the Windows x64 PatchBukkit DLL
- Set JAVA_HOME to the JDK installation directory
- Launch Pumpkin
- ByteBuddy attachment warnings and headless Paper startup failure appear
Expected behavior
PatchBukkit initializes its embedded JVM, installs its compatibility hooks, and starts the Java plugin environment.
Actual behavior
Paper downloads and installs successfully, but ByteBuddy reports:
Could not self-attach to current VM using external process
This affects TickThread, WorldBridge, EntityBridge, PlayerBridge, InventoryBridge, ServerBridge, EventBridge, and CommandBridge.
Paper then fails while firing WorldInitEvent, and PatchBukkit initialization stops before plugin loading completes.