TVPT / VoxelSniper

The premiere long-distance brush editor for Minecraft
Other
128 stars 115 forks source link

VoxelSniper commands not working, null & NPE. #191

Closed mibby closed 10 years ago

mibby commented 10 years ago

Jenkins dev build 260.

Command: /v

[SEVERE] null
org.bukkit.command.CommandException: Unhandled exception executing command 'v' in plugin VoxelSniper v5.168.8-SNAPSHOT-jnks260
    at org.bukkit.command.PluginCommand.execute(PluginCommand.java:46)
    at org.bukkit.command.SimpleCommandMap.dispatch(SimpleCommandMap.java:192)
    at org.bukkit.craftbukkit.v1_6_R3.CraftServer.dispatchCommand(CraftServer.java:532)
    at net.minecraft.server.v1_6_R3.PlayerConnection.handleCommand(PlayerConnection.java:986)
    at net.minecraft.server.v1_6_R3.PlayerConnection.chat(PlayerConnection.java:897)
    at net.minecraft.server.v1_6_R3.PlayerConnection.a(PlayerConnection.java:838)
    at net.minecraft.server.v1_6_R3.Packet3Chat.handle(Packet3Chat.java:47)
    at org.spigotmc.netty.NettyNetworkManager.b(NettyNetworkManager.java:237)
    at net.minecraft.server.v1_6_R3.PlayerConnection.e(PlayerConnection.java:117)
    at net.minecraft.server.v1_6_R3.ServerConnection.b(SourceFile:37)
    at org.spigotmc.netty.NettyServerConnection.b(NettyServerConnection.java:131)
    at net.minecraft.server.v1_6_R3.MinecraftServer.t(MinecraftServer.java:604)
    at net.minecraft.server.v1_6_R3.DedicatedServer.t(DedicatedServer.java:240)
    at net.minecraft.server.v1_6_R3.MinecraftServer.s(MinecraftServer.java:493)
    at net.minecraft.server.v1_6_R3.MinecraftServer.run(MinecraftServer.java:425)
    at net.minecraft.server.v1_6_R3.ThreadServerApplication.run(SourceFile:583)
Caused by: java.lang.NullPointerException
    at com.thevoxelbox.voxelsniper.Sniper.getData(Sniper.java:315)
    at com.thevoxelbox.voxelsniper.LiteSniper.<init>(LiteSniper.java:17)
    at com.thevoxelbox.voxelsniper.SniperPermissionHelper.getSniperInstance(SniperPermissionHelper.java:51)
    at com.thevoxelbox.voxelsniper.VoxelSniperListener.commandSniperV(VoxelSniperListener.java:436)
    at com.thevoxelbox.voxelsniper.VoxelSniperListener.onCommand(VoxelSniperListener.java:106)
    at com.thevoxelbox.voxelsniper.VoxelSniper.onCommand(VoxelSniper.java:158)
    at org.bukkit.command.PluginCommand.execute(PluginCommand.java:44)
    ... 15 more

Command: /v 1

[SEVERE] null
org.bukkit.command.CommandException: Unhandled exception executing command 'v' in plugin VoxelSniper v5.168.8-SNAPSHOT-jnks260
    at org.bukkit.command.PluginCommand.execute(PluginCommand.java:46)
    at org.bukkit.command.SimpleCommandMap.dispatch(SimpleCommandMap.java:192)
    at org.bukkit.craftbukkit.v1_6_R3.CraftServer.dispatchCommand(CraftServer.java:532)
    at net.minecraft.server.v1_6_R3.PlayerConnection.handleCommand(PlayerConnection.java:986)
    at net.minecraft.server.v1_6_R3.PlayerConnection.chat(PlayerConnection.java:897)
    at net.minecraft.server.v1_6_R3.PlayerConnection.a(PlayerConnection.java:838)
    at net.minecraft.server.v1_6_R3.Packet3Chat.handle(Packet3Chat.java:47)
    at org.spigotmc.netty.NettyNetworkManager.b(NettyNetworkManager.java:237)
    at net.minecraft.server.v1_6_R3.PlayerConnection.e(PlayerConnection.java:117)
    at net.minecraft.server.v1_6_R3.ServerConnection.b(SourceFile:37)
    at org.spigotmc.netty.NettyServerConnection.b(NettyServerConnection.java:131)
    at net.minecraft.server.v1_6_R3.MinecraftServer.t(MinecraftServer.java:604)
    at net.minecraft.server.v1_6_R3.DedicatedServer.t(DedicatedServer.java:240)
    at net.minecraft.server.v1_6_R3.MinecraftServer.s(MinecraftServer.java:493)
    at net.minecraft.server.v1_6_R3.MinecraftServer.run(MinecraftServer.java:425)
    at net.minecraft.server.v1_6_R3.ThreadServerApplication.run(SourceFile:583)
Caused by: java.lang.NullPointerException
    at com.thevoxelbox.voxelsniper.Sniper.getData(Sniper.java:315)
    at com.thevoxelbox.voxelsniper.LiteSniper.<init>(LiteSniper.java:17)
    at com.thevoxelbox.voxelsniper.SniperPermissionHelper.getSniperInstance(SniperPermissionHelper.java:51)
    at com.thevoxelbox.voxelsniper.VoxelSniperListener.commandSniperV(VoxelSniperListener.java:436)
    at com.thevoxelbox.voxelsniper.VoxelSniperListener.onCommand(VoxelSniperListener.java:106)
    at com.thevoxelbox.voxelsniper.VoxelSniper.onCommand(VoxelSniper.java:158)
    at org.bukkit.command.PluginCommand.execute(PluginCommand.java:44)
    ... 15 more

Command: /b

[WARNING] [VoxelSniper] Command error from mibby
java.lang.NullPointerException
    at com.thevoxelbox.voxelsniper.Sniper.getData(Sniper.java:315)
    at com.thevoxelbox.voxelsniper.LiteSniper.<init>(LiteSniper.java:17)
    at com.thevoxelbox.voxelsniper.SniperPermissionHelper.getSniperInstance(SniperPermissionHelper.java:51)
    at com.thevoxelbox.voxelsniper.VoxelSniperListener.commandSniperB(VoxelSniperListener.java:191)
    at com.thevoxelbox.voxelsniper.VoxelSniperListener.onCommand(VoxelSniperListener.java:110)
    at com.thevoxelbox.voxelsniper.VoxelSniper.onCommand(VoxelSniper.java:158)
    at org.bukkit.command.PluginCommand.execute(PluginCommand.java:44)
    at org.bukkit.command.SimpleCommandMap.dispatch(SimpleCommandMap.java:192)
    at org.bukkit.craftbukkit.v1_6_R3.CraftServer.dispatchCommand(CraftServer.java:532)
    at net.minecraft.server.v1_6_R3.PlayerConnection.handleCommand(PlayerConnection.java:986)
    at net.minecraft.server.v1_6_R3.PlayerConnection.chat(PlayerConnection.java:897)
    at net.minecraft.server.v1_6_R3.PlayerConnection.a(PlayerConnection.java:838)
    at net.minecraft.server.v1_6_R3.Packet3Chat.handle(Packet3Chat.java:47)
    at org.spigotmc.netty.NettyNetworkManager.b(NettyNetworkManager.java:237)
    at net.minecraft.server.v1_6_R3.PlayerConnection.e(PlayerConnection.java:117)
    at net.minecraft.server.v1_6_R3.ServerConnection.b(SourceFile:37)
    at org.spigotmc.netty.NettyServerConnection.b(NettyServerConnection.java:131)
    at net.minecraft.server.v1_6_R3.MinecraftServer.t(MinecraftServer.java:604)
    at net.minecraft.server.v1_6_R3.DedicatedServer.t(DedicatedServer.java:240)
    at net.minecraft.server.v1_6_R3.MinecraftServer.s(MinecraftServer.java:493)
    at net.minecraft.server.v1_6_R3.MinecraftServer.run(MinecraftServer.java:425)
    at net.minecraft.server.v1_6_R3.ThreadServerApplication.run(SourceFile:583)
MikeMatrix commented 10 years ago

Thanks. Will patch this as soon as possible.

MikeMatrix commented 10 years ago

Also, what were you holding in your hand at that time?

mibby commented 10 years ago

Tested with both gunpowder and arrow in inventory. Didn't work. Also tried with nothing in my hand.

mibby commented 10 years ago

@MikeMatrix Still errors. Build 262. Using /b outputs nothing. Using arrow or gunpowder, normal default item behavior. Using /vs gives permission error, using /v gives internal error occurred. Using permission node voxelsniper.litesniper. No voxel info when logging in either, brush type / block /etc.

[SEVERE] null
org.bukkit.command.CommandException: Unhandled exception executing command 'v' in plugin VoxelSniper v5.168.8-SNAPSHOT-jnks262
    at org.bukkit.command.PluginCommand.execute(PluginCommand.java:46)
    at org.bukkit.command.SimpleCommandMap.dispatch(SimpleCommandMap.java:192)
    at org.bukkit.craftbukkit.v1_6_R3.CraftServer.dispatchCommand(CraftServer.java:532)
    at net.minecraft.server.v1_6_R3.PlayerConnection.handleCommand(PlayerConnection.java:986)
    at net.minecraft.server.v1_6_R3.PlayerConnection.chat(PlayerConnection.java:897)
    at net.minecraft.server.v1_6_R3.PlayerConnection.a(PlayerConnection.java:838)
    at net.minecraft.server.v1_6_R3.Packet3Chat.handle(Packet3Chat.java:47)
    at org.spigotmc.netty.NettyNetworkManager.b(NettyNetworkManager.java:237)
    at net.minecraft.server.v1_6_R3.PlayerConnection.e(PlayerConnection.java:117)
    at net.minecraft.server.v1_6_R3.ServerConnection.b(SourceFile:37)
    at org.spigotmc.netty.NettyServerConnection.b(NettyServerConnection.java:131)
    at net.minecraft.server.v1_6_R3.MinecraftServer.t(MinecraftServer.java:604)
    at net.minecraft.server.v1_6_R3.DedicatedServer.t(DedicatedServer.java:240)
    at net.minecraft.server.v1_6_R3.MinecraftServer.s(MinecraftServer.java:493)
    at net.minecraft.server.v1_6_R3.MinecraftServer.run(MinecraftServer.java:425)
    at net.minecraft.server.v1_6_R3.ThreadServerApplication.run(SourceFile:583)
Caused by: java.lang.NullPointerException
    at com.thevoxelbox.voxelsniper.Sniper.getData(Sniper.java:334)
    at com.thevoxelbox.voxelsniper.LiteSniper.<init>(LiteSniper.java:17)
    at com.thevoxelbox.voxelsniper.SniperPermissionHelper.getSniperInstance(SniperPermissionHelper.java:51)
    at com.thevoxelbox.voxelsniper.VoxelSniperListener.commandSniperV(VoxelSniperListener.java:428)
    at com.thevoxelbox.voxelsniper.VoxelSniperListener.onCommand(VoxelSniperListener.java:106)
    at com.thevoxelbox.voxelsniper.VoxelSniper.onCommand(VoxelSniper.java:158)
    at org.bukkit.command.PluginCommand.execute(PluginCommand.java:44)
    ... 15 more
[WARNING] [VoxelSniper] Command error from mibby
java.lang.NullPointerException
    at com.thevoxelbox.voxelsniper.Sniper.getData(Sniper.java:334)
    at com.thevoxelbox.voxelsniper.LiteSniper.<init>(LiteSniper.java:17)
    at com.thevoxelbox.voxelsniper.SniperPermissionHelper.getSniperInstance(SniperPermissionHelper.java:51)
    at com.thevoxelbox.voxelsniper.VoxelSniperListener.commandSniperB(VoxelSniperListener.java:191)
    at com.thevoxelbox.voxelsniper.VoxelSniperListener.onCommand(VoxelSniperListener.java:110)
    at com.thevoxelbox.voxelsniper.VoxelSniper.onCommand(VoxelSniper.java:158)
    at org.bukkit.command.PluginCommand.execute(PluginCommand.java:44)
    at org.bukkit.command.SimpleCommandMap.dispatch(SimpleCommandMap.java:192)
    at org.bukkit.craftbukkit.v1_6_R3.CraftServer.dispatchCommand(CraftServer.java:532)
    at net.minecraft.server.v1_6_R3.PlayerConnection.handleCommand(PlayerConnection.java:986)
    at net.minecraft.server.v1_6_R3.PlayerConnection.chat(PlayerConnection.java:897)
    at net.minecraft.server.v1_6_R3.PlayerConnection.a(PlayerConnection.java:838)
    at net.minecraft.server.v1_6_R3.Packet3Chat.handle(Packet3Chat.java:47)
    at org.spigotmc.netty.NettyNetworkManager.b(NettyNetworkManager.java:237)
    at net.minecraft.server.v1_6_R3.PlayerConnection.e(PlayerConnection.java:117)
    at net.minecraft.server.v1_6_R3.ServerConnection.b(SourceFile:37)
    at org.spigotmc.netty.NettyServerConnection.b(NettyServerConnection.java:131)
    at net.minecraft.server.v1_6_R3.MinecraftServer.t(MinecraftServer.java:604)
    at net.minecraft.server.v1_6_R3.DedicatedServer.t(DedicatedServer.java:240)
    at net.minecraft.server.v1_6_R3.MinecraftServer.s(MinecraftServer.java:493)
    at net.minecraft.server.v1_6_R3.MinecraftServer.run(MinecraftServer.java:425)
    at net.minecraft.server.v1_6_R3.ThreadServerApplication.run(SourceFile:583)
mibby commented 10 years ago

Could it be related to this commit? https://github.com/TVPT/VoxelSniper/commit/520ae7d9d141536080ae359ea979ec86b84f0213

if (arguments == null)
mibby commented 10 years ago

After further examination, it seems to be related to only having the permission node voxelsniper.litesniper. When granted voxelsniper.sniper, everything functions fine, no error. Is there something wrong with litesniper?

nristock commented 10 years ago

I guess the player reference in the Sniper class isn't set (that's the only thing that could possibly null in Sniper.java:334)

MikeMatrix commented 10 years ago

I'm gonna debug it later, but as far as I've seen it's calling getData() on init in Litesniper before initializing the player reference somewhere.

mibby commented 10 years ago

I'll be ready to test as soon as there is a supposed fix. :)

mibby commented 10 years ago

@MikeMatrix

Any update? If you need some assistance, I'm here anytime to help test.

MikeMatrix commented 10 years ago

@mibby I'm currently busy with work, so I can't work on the fix atm.

mibby commented 10 years ago

@MikeMatrix Take it easy. Just know, I'll be here whenever you do get a fix ready that needs testing.

mibby commented 10 years ago

Hopefully everything is alright. Just going to bump this ticket again.

MikeMatrix commented 10 years ago

Looks like @Deamon5550 already fixed this in SHA: 3027a6f15cb7b82de9d65be4f8cc6c5992a50bca

@mibby can you confirm this fixes it?

mibby commented 10 years ago

Seems to have worked, thanks. :)