[SPIGOT-5538] "java.io.IOException: The handle is invalid" when running spigot with vanilla GUI and no console (javaw.exe) on Windows Created: 23/Jan/20 Updated: 27/Jan/20 Resolved: 27/Jan/20 |
|
Status: | Resolved |
Project: | Spigot |
Component/s: | None |
Affects Version/s: | None |
Fix Version/s: | None |
Type: | Bug | Priority: | Minor |
Reporter: | Marc Baloup | Assignee: | Unassigned |
Resolution: | Fixed | Votes: | 0 |
Labels: | None | ||
Environment: |
Windows 10 Pro, Version 1903 (build 18362.592) java version "1.8.0_192" |
Attachments: |
![]() |
Version: | This server is running CraftBukkit version git-Spigot-800b93f-a0e88fb (MC: 1.15.2) (Implementing API version 1.15.2-R0.1-SNAPSHOT) |
Guidelines Read: | Yes |
Description |
When running spigot by double clicking on the jar file, the vanilla GUI shows up, and the server starts as intended, but with an error message with an exception. I put the java command line (as it appears in the task mananger) in the attachment. [16:28:36 INFO]: Starting minecraft server version 1.15.2 [16:28:36 INFO]: Loading properties [16:28:36 ERROR]: Exception handling console input java.io.IOException: The handle is invalid at java.io.FileInputStream.readBytes(Native Method) ~[?:1.8.0_192] at java.io.FileInputStream.read(Unknown Source) ~[?:1.8.0_192] at java.io.BufferedInputStream.fill(Unknown Source) ~[?:1.8.0_192] at java.io.BufferedInputStream.read(Unknown Source) ~[?:1.8.0_192] at org.bukkit.craftbukkit.libs.jline.internal.NonBlockingInputStream.read(NonBlockingInputStream.java:248) ~[spigot-1.15.2.jar:git-Spigot-800b93f-a0e88fb] at org.bukkit.craftbukkit.libs.jline.internal.InputStreamReader.read(InputStreamReader.java:261) ~[spigot-1.15.2.jar:git-Spigot-800b93f-a0e88fb] at org.bukkit.craftbukkit.libs.jline.internal.InputStreamReader.read(InputStreamReader.java:198) ~[spigot-1.15.2.jar:git-Spigot-800b93f-a0e88fb] at org.bukkit.craftbukkit.libs.jline.console.ConsoleReader.readCharacter(ConsoleReader.java:2145) ~[spigot-1.15.2.jar:git-Spigot-800b93f-a0e88fb] at org.bukkit.craftbukkit.libs.jline.console.ConsoleReader.readLineSimple(ConsoleReader.java:3183) ~[spigot-1.15.2.jar:git-Spigot-800b93f-a0e88fb] at org.bukkit.craftbukkit.libs.jline.console.ConsoleReader.readLine(ConsoleReader.java:2333) ~[spigot-1.15.2.jar:git-Spigot-800b93f-a0e88fb] at org.bukkit.craftbukkit.libs.jline.console.ConsoleReader.readLine(ConsoleReader.java:2269) ~[spigot-1.15.2.jar:git-Spigot-800b93f-a0e88fb] at org.bukkit.craftbukkit.libs.jline.console.ConsoleReader.readLine(ConsoleReader.java:2257) ~[spigot-1.15.2.jar:git-Spigot-800b93f-a0e88fb] at net.minecraft.server.v1_15_R1.DedicatedServer$2.run(DedicatedServer.java:98) [spigot-1.15.2.jar:git-Spigot-800b93f-a0e88fb] [16:28:36 INFO]: This server is running CraftBukkit version git-Spigot-800b93f-a0e88fb (MC: 1.15.2) (Implementing API version 1.15.2-R0.1-SNAPSHOT) [16:28:36 INFO]: Debug logging is disabled [16:28:36 INFO]: Server Ping Player Sample Count: 12 [16:28:36 INFO]: Using 2 threads for Netty based IO [16:28:36 INFO]: Default game type: SURVIVAL [16:28:36 INFO]: Generating keypair [16:28:36 INFO]: Starting Minecraft server on *:25566 [16:28:36 INFO]: Using default channel type Maybe Spigot should hide the error when the vanilla GUI is enabled and there is no stdin detected. |
Comments |
Comment by md_5 [ 27/Jan/20 ] |
Should be fixed anyway |
Comment by Marc Baloup [ 27/Jan/20 ] |
It turns out this is in fact a vanilla bug. I just tested it with the vanilla 1.15.2 server and there is the same error message. There is already a bug reported here https://bugs.mojang.com/browse/MC-33041 I originaly though it was a spigot bug because I had the error message when you reactivated the GUI by default on spigot 1.15.2, and knowing that, I started just double clicking on the jar file (no need for .bat file anymore). |
Comment by Marc Baloup [ 27/Jan/20 ] |
Thanks for the link. I already knew about the difference between `java.exe` and `javaw.exe`. I was just pointing out that the error message could be hidden from the logs when the vanilla GUI is opened, because this is not really an error in this situation. (or maybe replacing this error with a one-line warning ?) I know this is a pretty minor "bug", and does not affect at all how the server works. So I am not expecting a quick fix |
Comment by TheCreeperCow [ 27/Jan/20 ] |
Read this |
Comment by Marc Baloup [ 27/Jan/20 ] |
As you can see on the screenshot, there is no argument except the -jar |
Comment by TheCreeperCow [ 27/Jan/20 ] |
What are your command line arguments? |