Closed GuazP closed 3 years ago
Have you tried using SuperPermissions (no permission system) to see if this is just what happens when you try to use the non-builtin permissions? PEX/LuckPerms might interact differently with Transient permission stuff.
The 'linked Vault code' referencing to the override has nothing to do with specific implementations for LuckPerms or PEX. The one you linked to is what is enabled by default if you do not have a permission plugin.
Also note, the reason why the Vault one uses an overridden method with no world is because bukkit has no concept of world-specific permissions.
Can you show logs of it not working with no permission system? ie: player permission value dumps.
Edit: I also remember some permission systems not handling transient perms with some server setups properly because of problems with the server not properly refreshing it's own player permission cache, I know this was a frustrating problem, and the recommendation was to always use a specific permission system to alleviate it. If other permission systems have problems with transient permissions then it could be that they don't recognize them properly either, this most likely means there's an issue in Bukkit itself, (It's kinda likely), or in how you're performing checks.
I didn't tried SuperPermissions, so far I didn't see version compatybile with version of my server. And generally this is incompatybility with DungeonsXL, because there I can allow my builders to build stuff in creative mode and I want them to have worldedit and few essentials commands like flyspeed. But allow them only on specific world created for edit without affecting survival gameplay.
Can you show logs of it not working with no permission system? ie: player permission value dumps.
I don't see any error in console related to this. About player permisssion value dumps idk how I could provide this or what do you mean, if you instruct me for sure I can provide that.
I know this was a frustrating problem, and the recommendation was to always use a specific permission system to alleviate it.
What would you recommend for 1.16.5 paper then?
My comments were targeted as if you were doing development to help debug the issue that way. If you're not doing development then I can't really help. Vault only calls existing proven bukkit APIs. If they don't work then it's probably an issue in your server software, or permission system. Unless you can dig into exactly what is happening and provide examples of something not working specifically outside of just saying the permission didn't get removed, then I wont be able to really help here. Sorry. I don't maintain the connectors for PEX or LuckPerms so I can't comment on how well they work, and the built-in bukkit permission system that Vault uses sounds like it just isn't compatible with what DungeonsXL is trying to do.
SuperPerms: https://bukkit.org/threads/superperms.37920/
I wanted to report a bug with method ,,playerRemoveTransient'' from there: https://github.com/MilkBowl/VaultAPI/blob/master/src/main/java/net/milkbowl/vault/permission/Permission.java#L372
Generally plugin which hooks to VaultAPI even when invoked can't by that hook remove permissions from player, granting them are fine.
Details: DungeonsXL uses the Vault transient permissions API: Game: Added: https://github.com/DRE2N/DungeonsXL/blob/master/core/src/main/java/de/erethon/dungeonsxl/player/DGamePlayer.java#L597 Removed: https://github.com/DRE2N/DungeonsXL/blob/master/core/src/main/java/de/erethon/dungeonsxl/player/DGamePlayer.java#L391 Edit: Added: https://github.com/DRE2N/DungeonsXL/blob/master/core/src/main/java/de/erethon/dungeonsxl/player/DEditPlayer.java#L67 Removed: https://github.com/DRE2N/DungeonsXL/blob/master/core/src/main/java/de/erethon/dungeonsxl/player/DEditPlayer.java#L95
Vault: Add: https://github.com/MilkBowl/VaultAPI/blob/master/src/main/java/net/milkbowl/vault/permission/Permission.java#L227 Remove: https://github.com/MilkBowl/VaultAPI/blob/master/src/main/java/net/milkbowl/vault/permission/Permission.java#L372
Players still have the permission after it's removed. This seems to happen with both PEX and LuckPerms and also without any permission plugin. So yes, it seems to be a Vault bug.
In case if someone wonder about number of parameters, this method is overloaded there: https://github.com/MilkBowl/VaultAPI/blob/master/src/main/java/net/milkbowl/vault/permission/Permission.java#L263
I hope that amount of info is sufficient to find bug and fix it. Thank you in advance!
Have a nice day, Maciej Gravestone