Skip to content

clarify default behavior of parameterConsistency or require parameter #928

@benbellick

Description

@benbellick

Problem

The JSON schema defines these parameters but doesn't mark them as required:

variadicBehavior:
type: object
additionalProperties: false
properties:
min:
type: number
max:
type: number
parameterConsistency:
type: string
enum: [CONSISTENT, INCONSISTENT]

The docs define the meaning of the parameters when set, but doesn't specify the behavior when the consistency parameter isn't set.

Fixes

One fix is to just require the parameter. Requiring the parameter could in theory break backwards compatibility. However, the breaking of backwards-compat is a minor issue because implementers will just throw an error at YAML-load time. This approach has the benefit of being explicit

The other option is to just define CONSISTENT as the default behavior when nothing is set.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions