Skip to content

CLI rejects operator-exported spam filter YAML with prefixed apiVersion #169

Description

@mmanciop

When a user exports a spam filter CRD that was created by the Dash0 Kubernetes operator and feeds it back into the CLI via spam-filters create -f, spam-filters update -f, or apply -f, the CLI rejects the document:

unsupported spam filter apiVersion "operator.dash0.com/v1alpha1" (supported: "v1alpha1", "v1alpha2")

The operator stamps apiVersion: operator.dash0.com/v1alpha1 on its CRD resources (standard Kubernetes TypeMeta behavior). The CLI's DetectSpamFilterAPIVersion compares the raw string against bare enum values (v1alpha1, v1alpha2) and fails on the group-prefixed form.

The same issue applies to the canonical dash0.com/v1alpha1 prefix that the server will emit once apiVersion canonicalization ships.

Affected commands:

  • dash0 spam-filters create -f <file>
  • dash0 spam-filters update -f <file>
  • dash0 apply -f <file> (when the file contains a spam filter document)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions