FlashyReese / CommandAliases

Alternate short commands for complex commands
MIT License
25 stars 6 forks source link

Keep getting Unsupported Schema Version message #40

Closed kmm569 closed 1 year ago

kmm569 commented 1 year ago

I am setting this up for the first time, and am running into this issue. Whenever I try to load my custom command, I keep getting the error message "Unsupported Schema Version":

commandaliases
└── spawn.json - Unsupported schema version

I cannot figure out what is going wrong. My spawn.json is listed below:

{
  "commandMode": "COMMAND_CUSTOM",
  "customCommand": {
    "parent": "spawn",
    "type": "literal",
    "permission": 0,
    "actions": [
      {
        "command": "execute in minecraft:overworld run tp $executor_name() 357.18 66.00 57.65 186.90 10.50",
        "commandType": "SERVER",
        "message": "Teleporting to spawn..."
      }
    ]
  }
}

I don't seem to be missing any brackets or commas or quotations, so I'm not sure where the issue is, or if it's my issue or not.


Note: While writing this, I tried something else to fix it, but got a new error.

I added brackets [] to the start and end of the file like this:

[
  {
    "commandMode": "COMMAND_CUSTOM",
    "customCommand": {
      ...
    }
  }
]

This brought a new error:

Failed to load file at "/home/ubuntu/Minecraft_Server/./config/commandaliases/spawn.json" throws com.fasterxml.jackson.databind.exc.MismatchedInputException: Cannot deserialize value of type `me.flashyreese.mods.commandaliases.command.CommandAlias` from Array value (token `JsonToken.START_ARRAY`)
 at [Source: (File); line: 1, column: 1]
[12:37:22 INFO]: 
commandaliases
└── spawn.json - Failed to load

I'd assume this is because brackets [] are not the right solution, but I figured I would mention that I tried anyway.

ryleu commented 1 year ago

wait how did you fix this?