TabComplete does not work properly for some commands
EvilOlaf opened this issue ยท 7 comments
When using the TabComplete feature for /warn
, /dwarn
or /tempmute
with offlineAutoComplete: true
set all players regardless of being online or offline will be offered for auto completion. That is expected.
All other commands offer online players only.
Setting offlineAutoComplete
to false
will show only players for each command only as expected.
git-Spigot-ed3e3af-ee6d0fa
BanManager5.2.0
The behaviour you've described seems odd, as all the commands use the exact same code for tab completion. Therefore differing behaviour seems unlikely.
Can I get a list of plugins? It sounds like one of them may perhaps be interfering.
Sure
[17:12:24 INFO]: Plugins (43): AsyncWorldEditInjector, dynmap, WorldEdit, VoteRoulette, Essentials, TuxTwoLib, BukkitSpeak, ChatControl, AutoMessage, WorldBorder, Modifyworld, Votifier, BanManager, WorldGuard, Multiverse-Core, AntiLog, AsyncWorldEdit, PermissionsEx, iConomy, AnimalProtect, mcMMO, ProtectionStones, Vault, Prism, EssentialsSpawn, MyCommand, EnderSpawn, ChestShop, MultiInv, CompatNoCheatPlus, LiftSign, PlotSquared, Scavenger, Dynmap-WorldGuard, ProtocolLib, NoCheatPlus, VanishNoPacket, Plot2Dynmap, ServerSigns, RandomLocation, ScoreboardStats, HolographicDisplays, TouchscreenHolograms
Tabcompletion has been blocked by Spigot. NCP offers this option as well but it's disabled there
Yep.
This is what happens when I tried to use tab on /warn.
/ban still showes online players only.
[07:28:21 ERROR]: Exception when Olaf attempted to tab complete /warn
org.bukkit.command.CommandException: Unhandled exception during tab completion for command '/warn ' in plugin BanManager v5.2.0
at org.bukkit.command.PluginCommand.tabComplete(PluginCommand.java:144) ~[spigot-1.8.jar:git-Spigot-ed3e3af-ee6d0fa]
at org.bukkit.command.SimpleCommandMap.tabComplete(SimpleCommandMap.java:213) ~[spigot-1.8.jar:git-Spigot-ed3e3af-ee6d0fa]
at org.bukkit.craftbukkit.v1_8_R1.CraftServer.tabCompleteCommand(CraftServer.java:1586) [spigot-1.8.jar:git-Spigot-ed3e3af-ee6d0fa]
at org.bukkit.craftbukkit.v1_8_R1.CraftServer.tabComplete(CraftServer.java:1570) [spigot-1.8.jar:git-Spigot-ed3e3af-ee6d0fa]
at net.minecraft.server.v1_8_R1.MinecraftServer.tabCompleteCommand(MinecraftServer.java:1116) [spigot-1.8.jar:git-Spigot-ed3e3af-ee6d0fa]
at net.minecraft.server.v1_8_R1.PlayerConnection.a(PlayerConnection.java:1869) [spigot-1.8.jar:git-Spigot-ed3e3af-ee6d0fa]
at net.minecraft.server.v1_8_R1.PacketPlayInTabComplete.a(SourceFile:46) [spigot-1.8.jar:git-Spigot-ed3e3af-ee6d0fa]
at net.minecraft.server.v1_8_R1.PacketPlayInTabComplete.a(SourceFile:10) [spigot-1.8.jar:git-Spigot-ed3e3af-ee6d0fa]
at net.minecraft.server.v1_8_R1.PacketHandleTask.run(SourceFile:13) [spigot-1.8.jar:git-Spigot-ed3e3af-ee6d0fa]
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) [?:1.8.0_40]
at java.util.concurrent.FutureTask.run(FutureTask.java:266) [?:1.8.0_40]
at net.minecraft.server.v1_8_R1.MinecraftServer.z(MinecraftServer.java:696) [spigot-1.8.jar:git-Spigot-ed3e3af-ee6d0fa]
at net.minecraft.server.v1_8_R1.DedicatedServer.z(DedicatedServer.java:316) [spigot-1.8.jar:git-Spigot-ed3e3af-ee6d0fa]
at net.minecraft.server.v1_8_R1.MinecraftServer.y(MinecraftServer.java:634) [spigot-1.8.jar:git-Spigot-ed3e3af-ee6d0fa]
at net.minecraft.server.v1_8_R1.MinecraftServer.run(MinecraftServer.java:537) [spigot-1.8.jar:git-Spigot-ed3e3af-ee6d0fa]
at java.lang.Thread.run(Thread.java:745) [?:1.8.0_40]
Caused by: java.lang.NullPointerException
at me.confuser.banmanager.commands.AutoCompleteNameTabCommand.onTabComplete(AutoCompleteNameTabCommand.java:45) ~[?:?]
at org.bukkit.command.PluginCommand.tabComplete(PluginCommand.java:132) ~[spigot-1.8.jar:git-Spigot-ed3e3af-ee6d0fa]
... 15 more
Actually I don't need tab completion for offline players and offlineAutoComplete: false
works perfectly, but I think this might be interesting what his issue causes.
The stack trace you posted is related to #210
I can't seem to reproduce this. If you're able to test this, does this issue still occur with only BanManager on the server and no other plugins?