We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
oav generate-examples
byte
Discovered in this typespec generated PR
User entered oav generate-examples ./generated.json using the generated.json spec present in above PR.
oav generate-examples ./generated.json
generated.json
Here is an example of the specific place in the generated example that was problematic.
Prior to user manually correcting with "<your image bytes>" these were generated with values that failed validation. Specifically:
"<your image bytes>"
{ message: [ { code: 'INVALID_TYPE', message: 'Expected type string but found type object', schemaUrl: '.\\ImageAnalysis.json', exampleUrl: 'examples\\SegmentFromStream_MaximumSet_Gen.json', schemaPosition: { line: 139, column: 23 } , schemaJsonPath: '#/properties/body/type', examplePosition: { line: 7, column: 21 } , exampleJsonPath: '$parameters.imageContent', severity: 0, source: 'request', operationId: 'SegmentFromStream', [Symbol(level)]: 'error', [Symbol(message)]: '{"code":"INVALID_TYPE","exampleJsonPath":"$parameters.imageContent","examplePosition":{"column":21,"line":7},"exampleUrl":"examples\\\\SegmentFromStream_MaximumSet_Gen.json","level":"error","message":"Expected type string but found type object","operationId":"SegmentFromStream","schemaJsonPath":"#/properties/body/type","schemaPosition":{"column":23,"line":139},"schemaUrl":".\\\\ImageAnalysis.json","severity":0,"source":"request"}' } level: '\x1B[31merror\x1B[39m' }
This is because the imageContent was generating with erroneous value {}. User correct {} to "<your bytes here>" and example passed validation.
imageContent
{}
"<your bytes here>"
The text was updated successfully, but these errors were encountered:
No branches or pull requests
Discovered in this typespec generated PR
User entered
oav generate-examples ./generated.json
using thegenerated.json
spec present in above PR.Here is an example of the specific place in the generated example that was problematic.
Prior to user manually correcting with
"<your image bytes>"
these were generated with values that failed validation. Specifically:This is because the
imageContent
was generating with erroneous value{}
. User correct{}
to"<your bytes here>"
and example passed validation.The text was updated successfully, but these errors were encountered: