Null pointer exception with the latest jenkins build (Build #42)
Karmaflute opened this issue ยท 6 comments
Player is trying to /sethome with the following permissions:
- hsp.command.home
- hsp.command.sethome
- hsp.command.spawn
This seems to affect players at random. Only some players with the same permissions experience this issue.
2013-07-22 00:17:53 [WARNING] [HomeSpawnPlus] Caught exception in command /sethome
java.lang.NullPointerException
at com.andune.minecraft.hsp.manager.HomeLimitsManager.getInheritedWorld(HomeLimitsManager.java:101)
at com.andune.minecraft.hsp.manager.HomeLimitsManager.getHomeCount(HomeLimitsManager.java:189)
at com.andune.minecraft.hsp.manager.HomeLimitsManager.limitCheck(HomeLimitsManager.java:74)
at com.andune.minecraft.hsp.manager.HomeLimitsManager.canPlayerAddHome(HomeLimitsManager.java:149)
at com.andune.minecraft.hsp.util.HomeUtil.setHome(HomeUtil.java:303)
at com.andune.minecraft.hsp.commands.SetHome.execute(SetHome.java:114)
at com.andune.minecraft.hsp.command.BaseCommand.execute(BaseCommand.java:124)
at com.andune.minecraft.hsp.server.bukkit.command.BukkitCommandRegister$1.onCommand(BukkitCommandRegister.java:146)
at org.bukkit.command.PluginCommand.execute(PluginCommand.java:44)
at org.bukkit.command.SimpleCommandMap.dispatch(SimpleCommandMap.java:190)
at org.bukkit.craftbukkit.v1_6_R2.CraftServer.dispatchCommand(CraftServer.java:527)
at net.minecraft.server.v1_6_R2.PlayerConnection.handleCommand(PlayerConnection.java:981)
at net.minecraft.server.v1_6_R2.PlayerConnection.chat(PlayerConnection.java:892)
at net.minecraft.server.v1_6_R2.PlayerConnection.a(PlayerConnection.java:839)
at net.minecraft.server.v1_6_R2.Packet3Chat.handle(SourceFile:49)
at org.spigotmc.netty.NettyNetworkManager.b(NettyNetworkManager.java:230)
at net.minecraft.server.v1_6_R2.PlayerConnection.e(PlayerConnection.java:118)
at net.minecraft.server.v1_6_R2.ServerConnection.b(SourceFile:37)
at org.spigotmc.netty.NettyServerConnection.b(NettyServerConnection.java:125)
at net.minecraft.server.v1_6_R2.MinecraftServer.t(MinecraftServer.java:592)
at net.minecraft.server.v1_6_R2.DedicatedServer.t(DedicatedServer.java:239)
at net.minecraft.server.v1_6_R2.MinecraftServer.s(MinecraftServer.java:481)
at net.minecraft.server.v1_6_R2.MinecraftServer.run(MinecraftServer.java:413)
at net.minecraft.server.v1_6_R2.ThreadServerApplication.run(SourceFile:582)
That is an HSP 2.0 stack trace. Which I'm more than happy to look into and am actually glad if some folks are starting to use it and report feedback. But if you were looking for HSP 1.7.7-SNAPSHOT build #42, I think you grabbed the wrong JAR. Or the wires got severely crossed on Jenkins. Can you paste the startup output from HSP, where it displays it's version info and build numbers?
Yes, this is for HSP 2.0; I wanted to try it out. Is this not the appropriate place to submit bug reports?
Also, /home does not work for named homes. It simply brings up the help listing suggesting it doesn't recognize the command.
I pulled up the wrong jenkins build while writing the post. I pulled the correct build for what I used from the jar directly this time:
Sun Jul 07 13:31:02 PDT 2013
build.number=92
Yes this is a fine place to report bugs. And using HSP 2.0 is great, glad to have some people testing it. Your title had the build number for HSP 1.7.7 builds so I wanted to be sure you were using the version you thought you were.
Please be aware there are likely to be bugs in HSP 2.0, though it's certainly come a long way since the original refactor and works very well in all of my local testing. But it's also my active dev environment so things might break from time to time as I change stuff, though I'm trying to keep that to a minimum now as I gear up for finally getting a beta release out soon.
As long as you're willing to live with some bugs or are using it on a test server where a show-stopping bug isn't breaking everything for all your users, then I'm happy to have the bug reports and feedback and will do my best to get them resolved as I can.
Last, commenting on named homes: please open a separate ticket, it will be very hard to manage and fix bugs if I get multiple ones thrown into comments in a single report. But I'd say be aware HSP 2.0 has an uberCommand feature, which you can turn on by setting commands.useUberCommands to true; it might even be on by default. In which case you can use "/home help" or optionally "/home tp " to to a named home. Just typing "/home name" should still work also, but that is super recent code and I may not have fully tested all scenarios yet.
The latest build on Jenkins shouldn't have this stacktrace/NPE, however from my review of the code the situation shouldn't be able to happen in the first place. So instead, when this (unexpected) situation occurs, it will print an error to the log with the string "but no such world was found on the server". If you could look for that message and c&p it here along with your world list (/mvp list if you have Multiverse), that would be helpful for me figuring out what was triggering this to begin with.