Skip to content

max_edges declares a maximum of 0.0 but defaults to 50, so the OpenAPI document fails validation #409

Description

@gaurav

FilterKgraphTopNParameters.max_edges declares a maximum of 0.0 while defaulting to 50, so the published OpenAPI document fails validation against the OpenAPI 3.x schema:

50 is greater than the maximum of 0.0

Failed validating 'maximum' in schema:
    {'type': 'integer', 'maximum': 0.0, 'title': 'Max Edges', 'default': 50}

The schema as served:

"max_edges": {"type": "integer", "maximum": 0.0, "title": "Max Edges", "default": 50}

at #/components/schemas/FilterKgraphTopNParameters/properties/max_edges. A maximum of 0.0 on a positive edge count looks like a le=0 where ge=0 (or no bound at all) was meant — as written, every permitted value including the default is invalid.

Affected (checked 2026-08-31): every deployment I can reach, in both flavours.

Deployment Version
https://nodenorm.transltr.io/openapi.json 2.3.18
https://nodenorm.test.transltr.io/openapi.json 2.3.18
https://nodenormalization-sri.renci.org/openapi.json 2.4.1
https://nodenormalization-exp.apps.renci.org/openapi.json 2.5.1
https://nodenorm-es.test.transltr.io/webapp/openapi.json 1.0.0 (Elasticsearch)

To reproduce:

import requests
from openapi_spec_validator import validate
validate(requests.get("https://nodenorm.transltr.io/openapi.json").json())

Found by test_openapi_json in TranslatorSRI/babel-validation, which validates each target's published document.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions