Skip to content

flagsmith init obscure error against older Flagsmith versions #76

Description

@khvn26

Currently, running flagsmith init against an old server results in an obscure error:

➜  dev flagsmith init --api-url <some-url>
Error: <some-url>/.well-known/oauth-authorization-server returned 404 Not Found — is this a Flagsmith API URL?

We should add a server /version check to flagsmith init. If it's less than v2.255.0, friendly nudge the user towards a Master API Key.

The nudge must name the host-scoped variable for the instance, e.g. FLAGSMITH_API_KEY_flagsmith_example_com — anyone hitting this is by definition self-hosted, and the unscoped FLAGSMITH_API_KEY is ignored anywhere but api.flagsmith.com. See #77.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions