User caching rarely causes perm checks to fail
The plugin randomly tells a random player that he doesn't have any permission to run any commands of huskclaim, even for server operators. After rejoining the server the permission issue gets fixed but it still happens after sometime randomly.
I couldn't find any steps to reproduce this.
I edited the no permission message. so players can understand and rejoin the server.
Server version 1.21.3
Luckperms Version 5.4.153
I have had this issue before (and still do sometimes). Honestly I thought it had nothing to do with huskclaims but I’m glad someone else has this issue so I’m not going insane trying to find a reason why it happens haha.
Hey, any updates on this? Happens quite frequently for players…
Same problem here, still didnt find an reason and how to reproduce
+1, same issue
This happens too frequently and players complaining about it. Why this issue is ignored for months?
Sometimes player relog doesn't solve the problem and it requires server reboot.
I did some testing and I found Player#hasPermission and bukkitPlayer#hasPermission gives different results with Bukkit's API.
The test code I've used (Skript):
command /haspermtest <player>:
permission: op
trigger:
set {_player} to arg 1
send "{_player} class: %({_player}).toString()%"
send ({_player}).hasPermission("huskclaims.inspect")
set {_user} to ({API::BukkitHuskClaims}).getOnlineUser({_player})
send "&b%({_user}).bukkitPlayer.toString()%"
send "&a%({_user}).bukkitPlayer% / %({_user}).bukkitPlayer.getClass()%"
send "&e%({_user}).bukkitPlayer.hasPermission("huskclaims.inspect")%"
send "&c%({_user}).bukkitPlayer.hashCode()% &8/ &c%({_player}).hashCode()%"
send hasPermission(({_user}).bukkitPlayer, "huskclaims.inspect", true)
LuckPerms's hasPermission check returns true as expected but bukkit's hasPermission returns false. You should follow the "send" messages in order to understand debug even if you don't know Skript.
bukkitPlayer#hasPermission should give same result with Player#hasPermission. But it doesn't.
This is another player, this works as expected. Even bukkitPlayer's hasPermission returns true (same result with Player#hasPermission().).
@WiIIiam278
+1 Same issue
Why is this still a problem? This has been open for over 8 months now...