PorkStudios / Pork2b2tBot

A minecraft bot thing, also works as a proxy!
https://www.daporkchop.net/pork2b2tbot
Other
46 stars 16 forks source link

NPE and Crash when trying to sleep in bed during day #46

Open VADemon opened 3 years ago

VADemon commented 3 years ago

Server: our favourite

[08/01/2021 23:38:57] [Client] [ALERT] ****************************************
[08/01/2021 23:38:57] [Client] [ALERT] *
[08/01/2021 23:38:57] [Client] [ALERT] * java.lang.NullPointerException
[08/01/2021 23:38:57] [Client] [ALERT] *     at net.daporkchop.lib.minecraft.text.parser.JsonTextParser.doParseJson(JsonTextParser.java:130)
[08/01/2021 23:38:57] [Client] [ALERT] *     at net.daporkchop.lib.minecraft.text.parser.JsonTextParser.parse(JsonTextParser.java:98)
[08/01/2021 23:38:57] [Client] [ALERT] *     at net.daporkchop.lib.minecraft.text.parser.AutoMCFormatParser.parse(AutoMCFormatParser.java:59)
[08/01/2021 23:38:57] [Client] [ALERT] *     at net.daporkchop.lib.minecraft.text.parser.AutoMCFormatParser.parse(AutoMCFormatParser.java:39)
[08/01/2021 23:38:57] [Client] [ALERT] *     at net.daporkchop.lib.logging.impl.SimpleLogger.doLog(SimpleLogger.java:91)
[08/01/2021 23:38:57] [Client] [ALERT] *     at net.daporkchop.lib.logging.impl.SimpleLogger$ChannelLogger.log(SimpleLogger.java:158)
[08/01/2021 23:38:57] [Client] [ALERT] *     at net.daporkchop.lib.logging.Logger.info(Logger.java:102)
[08/01/2021 23:38:57] [Client] [ALERT] *     at net.daporkchop.toobeetooteebot.client.handler.incoming.ChatHandler.apply(ChatHandler.java:38)
[08/01/2021 23:38:57] [Client] [ALERT] *     at net.daporkchop.toobeetooteebot.client.handler.incoming.ChatHandler.apply(ChatHandler.java:35)
[08/01/2021 23:38:57] [Client] [ALERT] *     at net.daporkchop.toobeetooteebot.util.handler.HandlerRegistry.handleInbound(HandlerRegistry.java:64)
[08/01/2021 23:38:57] [Client] [ALERT] *     at net.daporkchop.toobeetooteebot.client.ClientListener.packetReceived(ClientListener.java:57)
[08/01/2021 23:38:57] [Client] [ALERT] *     at com.github.steveice10.packetlib.event.session.PacketReceivedEvent.call(PacketReceivedEvent.java:51)
[08/01/2021 23:38:57] [Client] [ALERT] *     at com.github.steveice10.packetlib.tcp.TcpSession.callEvent(TcpSession.java:143)
[08/01/2021 23:38:57] [Client] [ALERT] *     at com.github.steveice10.packetlib.tcp.TcpSession$3.run(TcpSession.java:343)
[08/01/2021 23:38:57] [Client] [ALERT] *     at java.lang.Thread.run(Thread.java:748)
[08/01/2021 23:38:57] [Client] [ALERT] *
[08/01/2021 23:38:57] [Client] [ALERT] ****************************************
[08/01/2021 23:38:57] [Client] [INFO] Disconnecting from server...
[08/01/2021 23:38:57] [Client] [INFO] Disconnected.
[08/01/2021 23:38:57] [Server] [INFO] Player disconnected: null
[08/01/2021 23:38:57] [Client] [ALERT] ****************************************
[08/01/2021 23:38:57] [Client] [ALERT] *
[08/01/2021 23:38:57] [Client] [ALERT] * java.lang.NullPointerException
[08/01/2021 23:38:57] [Client] [ALERT] *     at net.daporkchop.lib.minecraft.text.parser.JsonTextParser.doParseJson(JsonTextParser.java:130)
[08/01/2021 23:38:57] [Client] [ALERT] *     at net.daporkchop.lib.minecraft.text.parser.JsonTextParser.parse(JsonTextParser.java:98)
[08/01/2021 23:38:57] [Client] [ALERT] *     at net.daporkchop.lib.minecraft.text.parser.AutoMCFormatParser.parse(AutoMCFormatParser.java:59)
[08/01/2021 23:38:57] [Client] [ALERT] *     at net.daporkchop.lib.minecraft.text.parser.AutoMCFormatParser.parse(AutoMCFormatParser.java:39)
[08/01/2021 23:38:57] [Client] [ALERT] *     at net.daporkchop.lib.logging.impl.SimpleLogger.doLog(SimpleLogger.java:91)
[08/01/2021 23:38:57] [Client] [ALERT] *     at net.daporkchop.lib.logging.impl.SimpleLogger$ChannelLogger.log(SimpleLogger.java:158)
[08/01/2021 23:38:57] [Client] [ALERT] *     at net.daporkchop.lib.logging.Logger.info(Logger.java:102)
[08/01/2021 23:38:57] [Client] [ALERT] *     at net.daporkchop.toobeetooteebot.client.handler.incoming.ChatHandler.apply(ChatHandler.java:38)
[08/01/2021 23:38:57] [Client] [ALERT] *     at net.daporkchop.toobeetooteebot.client.handler.incoming.ChatHandler.apply(ChatHandler.java:35)
[08/01/2021 23:38:57] [Client] [ALERT] *     at net.daporkchop.toobeetooteebot.util.handler.HandlerRegistry.handleInbound(HandlerRegistry.java:64)
[08/01/2021 23:38:57] [Client] [ALERT] *     at net.daporkchop.toobeetooteebot.client.ClientListener.packetReceived(ClientListener.java:57)
[08/01/2021 23:38:57] [Client] [ALERT] *     at com.github.steveice10.packetlib.event.session.PacketReceivedEvent.call(PacketReceivedEvent.java:51)
[08/01/2021 23:38:57] [Client] [ALERT] *     at com.github.steveice10.packetlib.tcp.TcpSession.callEvent(TcpSession.java:143)
[08/01/2021 23:38:57] [Client] [ALERT] *     at com.github.steveice10.packetlib.tcp.TcpSession$3.run(TcpSession.java:343)
[08/01/2021 23:38:57] [Client] [ALERT] *     at java.lang.Thread.run(Thread.java:748)
[08/01/2021 23:38:57] [Client] [ALERT] *
[08/01/2021 23:38:57] [Client] [ALERT] ****************************************
[08/01/2021 23:38:57] [Client] [INFO] Disconnected. Reason: java.util.concurrent.ExecutionException: java.lang.NullPointerException

It probably tried to parse the plaintext bed message as JSON?

Shame, I wanted to afk during the night. Good night!..

lordmahan commented 3 years ago

same thing with same exception and stacktrace also happens when running some default in-game commands. like /help and /summon. or /tp when there is no perms. tested on a vanilla server and a paperspigot server. probably has something to do with handling chat packets since bed message is also the same thing.