Skip to content

ReferencePolicy.Spec.From.Namespace is Optional #962

@robscott

Description

@robscott

What happened:
ReferencePolicy.Spec.From.Namespace is Optional.

What you expected to happen:
It should be required.

Anything else we need to know?:
It looks like the accidental inclusion of omitempty on that field resulted in an optional field. Thanks to @howardjohn for catching this.

I'm not actually sure what the appropriate mitigation is here. Our current versioning guidelines do not allow us to tighten validation. To me this seems to very clearly be a bug, and making this field required could be considered a bug fix, but I think that would also break API conversion. We could consider a new v1alpha2 release just to fix this, but that would also require an update to our versioning guidelines. If we want to fix this, we should probably do it before we hit beta. Alternatively, we could leave this indefinitely and update documentation to state that the lack of a namespace is invalid.

Metadata

Metadata

Assignees

No one assigned

    Labels

    kind/bugCategorizes issue or PR as related to a bug.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions