desktop icon indicating copy to clipboard operation
desktop copied to clipboard

OAS 3.0 parse issues

Open imhogan opened this issue 6 years ago • 3 comments
trafficstars

Hi, I have an OAS 3.0 YAML file which does not import correctly, however if I use http://convertjson.com/yaml-to-json.htm to convert to JSON, then the file loads okay in stoplight.io. The file is attached.

QrveyWithQuestionsV3.2.oas3.txt Hopefully this may be a quick fix. Blessings, Ian Hogan.

imhogan avatar Mar 23 '19 01:03 imhogan

Hi Ian,

I ran this file into our tool and a few others and generally am getting the following errors. Looks like your file may be invalid.

Structural error at components.schemas.AddressQuestion should have required property '$ref' missingProperty: $ref Jump to line 184 Structural error at components.schemas.AddressQuestion should match exactly one schema in oneOf Jump to line 184 Structural error at components.schemas.AddressQuestion.allOf.1 should have required property '$ref' missingProperty: $ref Jump to line 187 Structural error at components.schemas.AddressQuestion.allOf.1 should match exactly one schema in oneOf Jump to line 187 Structural error at components.schemas.AddressQuestion.allOf.1.properties.answers should have required property '$ref' missingProperty: $ref Jump to line 196 Structural error at components.schemas.AddressQuestion.allOf.1.properties.answers should match exactly one schema in oneOf Jump to line 196 Structural error at components.schemas.AddressQuestion.allOf.1.properties.answers.items should NOT have additional properties additionalProperty: schema Jump to line 198 Structural error at components.schemas.AddressQuestion.allOf.1.properties.answers.items should have required property '$ref' missingProperty: $ref Jump to line 198 Structural error at components.schemas.AddressQuestion.allOf.1.properties.answers.items should match exactly one schema in oneOf Jump to line 198

Thanks Brian

brianmrock avatar Mar 25 '19 18:03 brianmrock

Take a look at those errors, and let me know if you have any additional questions.

brianmrock avatar Mar 25 '19 18:03 brianmrock

Hi Brian,  thanks for that. As I mentioned though, if I used the online YAML to JSON converter the resultant JSON does load okay. If I get a chance in the next couple of days I will try converting the JSON back to YAML and compare that with the original YAML.

Blessings,Ian Hogan.Mobile: +61 (0) 417 013553Ian MacDonald Hogan IT Services

On Tuesday, 26 March 2019, 4:52:12 am AEST, Brian Rock <[email protected]> wrote:  

Take a look at those errors, and let me know if you have any additional questions.

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or mute the thread.

imhogan avatar Mar 27 '19 07:03 imhogan