From a0ead49b04816127ce42478a88b9ed94d6511b9c Mon Sep 17 00:00:00 2001 From: Stefan Verhoeven Date: Tue, 3 Nov 2026 08:44:41 +0100 Subject: [PATCH 1/4] Use strings for non-finite numbers Refs #57 --- openapi.yaml | 18 ++++++++++++++---- 1 file changed, 14 insertions(+), 4 deletions(-) diff --git a/openapi.yaml b/openapi.yaml index 7ffa01a..97b5d28 100644 --- a/openapi.yaml +++ b/openapi.yaml @@ -1105,6 +1105,16 @@ paths: - Unstructured components: schemas: + IEEENumber: + nullable: true + oneOf: + - type: number + - type: string + description: Non-finite IEEE 754 floating-point values. + enum: + - 'NaN' + - 'Infinity' + - '-Infinity' GetVarLocationResponseLocation: type: object properties: @@ -1187,12 +1197,12 @@ components: GetValueAtIndicesResponse: type: array items: - type: number + $ref: '#/components/schemas/IEEENumber' minItems: 1 GetValueResponse: type: array items: - type: number + $ref: '#/components/schemas/IEEENumber' minItems: 1 GetVarGridResponse: type: integer @@ -1258,7 +1268,7 @@ components: values: type: array items: - type: number + $ref: '#/components/schemas/IEEENumber' minItems: 1 required: - indices @@ -1267,7 +1277,7 @@ components: SetValueRequest: type: array items: - type: number + $ref: '#/components/schemas/IEEENumber' minItems: 1 Grid: type: integer From 56e7202bc60efde77da0bb3e92db256c1de9376b Mon Sep 17 00:00:00 2001 From: Stefan Verhoeven Date: Tue, 3 Nov 2026 10:13:47 +0100 Subject: [PATCH 2/4] Make linter happy --- openapi.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/openapi.yaml b/openapi.yaml index 97b5d28..244bede 100644 --- a/openapi.yaml +++ b/openapi.yaml @@ -1106,9 +1106,9 @@ paths: components: schemas: IEEENumber: - nullable: true oneOf: - type: number + nullable: true - type: string description: Non-finite IEEE 754 floating-point values. enum: From 70c2b762dccad4db65003823baa7b462e893f8e5 Mon Sep 17 00:00:00 2001 From: sverhoeven Date: Thu, 5 Nov 2026 15:01:42 +0100 Subject: [PATCH 3/4] Make Doubles return IEEEDouble type + drop nullable from IEEENumber + Add IEEEDoubleNoNaN for update_until and time functions Also move example value to IEEE* types as using $ref will ignore other props. --- openapi.yaml | 34 +++++++++++++++++++++++++--------- 1 file changed, 25 insertions(+), 9 deletions(-) diff --git a/openapi.yaml b/openapi.yaml index 244bede..a480fd3 100644 --- a/openapi.yaml +++ b/openapi.yaml @@ -1106,15 +1106,36 @@ paths: components: schemas: IEEENumber: + example: 1.0 oneOf: - type: number - nullable: true - type: string description: Non-finite IEEE 754 floating-point values. enum: - 'NaN' - 'Infinity' - '-Infinity' + IEEEDouble: + example: 1.0 + oneOf: + - type: number + format: double + - type: string + description: Non-finite IEEE 754 double precision floating-point values. + enum: + - 'NaN' + - 'Infinity' + - '-Infinity' + IEEEDoubleNoNaN: + example: 1.0 + oneOf: + - type: number + format: double + - type: string + description: Non-finite IEEE 754 double precision floating-point values, excluding NaN. + enum: + - 'Infinity' + - '-Infinity' GetVarLocationResponseLocation: type: object properties: @@ -1152,8 +1173,7 @@ components: Doubles: type: array items: - type: number - format: double + $ref: '#/components/schemas/IEEEDouble' minItems: 1 GetGridRankResponse: type: integer @@ -1178,13 +1198,9 @@ components: - type additionalProperties: false GetTimeResponse: - type: number - format: double - example: 0.0 + $ref: '#/components/schemas/IEEEDoubleNoNaN' GetTimeStepResponse: - type: number - format: double - example: 1.0 + $ref: '#/components/schemas/IEEEDoubleNoNaN' GetTimeUnitsResponse: type: object properties: From abf5be4abd114e5d9c13530f5d62fa56410c1221 Mon Sep 17 00:00:00 2001 From: Stefan Verhoeven Date: Mon, 9 Nov 2026 09:18:21 +0100 Subject: [PATCH 4/4] Make yamllint happy --- openapi.yaml | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/openapi.yaml b/openapi.yaml index a480fd3..a2b8f6a 100644 --- a/openapi.yaml +++ b/openapi.yaml @@ -1121,7 +1121,8 @@ components: - type: number format: double - type: string - description: Non-finite IEEE 754 double precision floating-point values. + description: Non-finite IEEE 754 double precision + floating-point values. enum: - 'NaN' - 'Infinity' @@ -1132,7 +1133,8 @@ components: - type: number format: double - type: string - description: Non-finite IEEE 754 double precision floating-point values, excluding NaN. + description: Non-finite IEEE 754 double precision + floating-point values, excluding NaN. enum: - 'Infinity' - '-Infinity'