invalid permissions.yml file?
smmmadden opened this issue ยท 3 comments
Hi all,
I've got a weird issue that I'm not finding any help to fix it. On my Spigot 1.11.2 Windows Server, I have updated my bukkit.yml to point to D:\MC_ArtisticEndeavors\plugins\PermissionsEx\permissions.yml file (v1.23.4) and when the server starts up, it complains that the schema-version is invalid even if the version is placed in single quotes '1' or without. The permissions.yml appears to be valid and works, but startup thinks it isn't. Then if I reference a different name (e.g. groups.yml) which has nothing in it, the server startups up and says the file is empty, ignoring it. I've validated the file is properly formatted (using http://www.yamllint.com) and it returns Valid YAML! Any help is greatly appreciated.
[09:41:19 ERROR]: Permission node 'schema-version' in D:\MC_ArtisticEndeavors\plugins\PermissionsEx\permissions.yml is invalid
java.lang.ClassCastException: java.lang.Integer cannot be cast to java.util.Map
at org.bukkit.permissions.Permission.loadPermissions(Permission.java:233) [spigot-1.11.2.jar:git-Spigot-d4f98a3-cb61ac0]
at org.bukkit.craftbukkit.v1_11_R1.CraftServer.loadCustomPermissions(CraftServer.java:801) [spigot-1.11.2.jar:git-Spigot-d4f98a3-cb61ac0]
at org.bukkit.craftbukkit.v1_11_R1.CraftServer.enablePlugins(CraftServer.java:337) [spigot-1.11.2.jar:git-Spigot-d4f98a3-cb61ac0]
at net.minecraft.server.v1_11_R1.MinecraftServer.t(MinecraftServer.java:421) [spigot-1.11.2.jar:git-Spigot-d4f98a3-cb61ac0]
at net.minecraft.server.v1_11_R1.MinecraftServer.l(MinecraftServer.java:382) [spigot-1.11.2.jar:git-Spigot-d4f98a3-cb61ac0]
at net.minecraft.server.v1_11_R1.MinecraftServer.a(MinecraftServer.java:337) [spigot-1.11.2.jar:git-Spigot-d4f98a3-cb61ac0]
at net.minecraft.server.v1_11_R1.DedicatedServer.init(DedicatedServer.java:272) [spigot-1.11.2.jar:git-Spigot-d4f98a3-cb61ac0]
at net.minecraft.server.v1_11_R1.MinecraftServer.run(MinecraftServer.java:544) [spigot-1.11.2.jar:git-Spigot-d4f98a3-cb61ac0]
at java.lang.Thread.run(Unknown Source) [?:1.8.0_112]
If you're using PEX 1.x, the schema-version:
line should look like line 89 in this example.
If you're using PEX 2.x, you'll need zml to reply to this ticket as I haven't used PEX 2.x yet.
Typically, the bukkit.yml file does not need to be edited at all. The permissions.yml file that it is looking for is in the root folder, and is typically empty. To the best of my knowledge, those 2 files are only used on Vanilla servers that have no plugins at all. (Line 2 of the bukkit.yml on my 1.7.2 server says "As you can see, there's actually not that much to configure without any plugins.")
Thanks Stormbow for the quick response. The format of schema-version: 1 is as your example showed (no differences) and I've been experimenting with different paths in the bukkit.yml for the permissions-file parameter. I just removed the folder path and only referenced the plugin path & file and now, no warnings, no exceptions and it all seems happy (from a server startup perspective). I need to do a lot of user testing with different groups, but initial testing appears you only need to reference the inner location of the file as shown below. Would make sense if the function call doesn't have permission for a full file path reference and requires the child folder & yml file to load.
permissions-file: PermissionsEx\permissions.yml