tractr / directus-sync

A CLI tool for synchronizing the schema and configuration of Directus across various environments.
GNU General Public License v3.0
209 stars 8 forks source link

Better error message for missing extension #83

Closed jofmi closed 1 day ago

jofmi commented 2 months ago

Is your feature request related to a problem? Please describe. If I try to push a schema to a directus instance without the sync extension, I get the following error:

    errors: [
      {
        "message": "Invalid payload. Collections can't start with \"directus_\".",
        "extensions": {
          "code": "INVALID_PAYLOAD",
          "reason": "Collections can't start with \"directus_\""
        }
      }
    ]
    response: {}

Describe the solution you'd like It would be great if the npx script could detect that the extension is not installed and mention this in the error message.

EdouardDem commented 2 months ago

@jofmi You should get a message about missing extension when on pull command. I will also add this message on the push and diff commands.

jofmi commented 2 months ago

I can confirm that with "diff" I also get a correct error!

EdouardDem commented 1 day ago

@jofmi This has been solved : https://github.com/tractr/directus-sync/releases/tag/directus-sync%403.1.2