Skip to content

v4 JSON schema requires non-empty string arrays #316

Closed
@StephenCleary

Description

@StephenCleary

The current spec allows empty required and empty arrays in dependencies.

However, the stringArray type defined in the Draft 04 schema does not:

"stringArray": {
    "type": "array",
    "items": { "type": "string" },
    "minItems": 1,
    "uniqueItems": true
}

Since these two places are the only locations in the schema that use stringArray, this can be fixed by removing the minItems requirement:

"stringArray": {
    "type": "array",
    "items": { "type": "string" },
    "uniqueItems": true
}

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