You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I was trying to generate a csharp client library for Partner Center OpenApi v3 using typespec for the first time. I hit an error trying to translate the OpenApi spec to typespec.
Seems like it might be related to the fact that the OpenApi spec doesn't define operationIds. Took me a while to figure this out as the error isn't very clear what's going on. If it is the case, might want to add some better error handling to call out that as a requirement.
Reproduction
tsp-openapi3 .\swagger.json --output-dir ./tsp-output
TypeError: Cannot read properties of undefined (reading 'split')
at getScopeAndName (file:///C:/Users/adstep/AppData/Roaming/npm/node_modules/@typespec/openapi3/dist/src/cli/actions/convert/utils/get-scope-and-name.js:3:31)
at transformPaths (file:///C:/Users/adstep/AppData/Roaming/npm/node_modules/@typespec/openapi3/dist/src/cli/actions/convert/transforms/transform-paths.js:32:20)
at transform (file:///C:/Users/adstep/AppData/Roaming/npm/node_modules/@typespec/openapi3/dist/src/cli/actions/convert/transforms/transforms.js:9:24)
at convertAction (file:///C:/Users/adstep/AppData/Roaming/npm/node_modules/@typespec/openapi3/dist/src/cli/actions/convert/convert-file.js:13:21)
Describe the bug
I was trying to generate a csharp client library for Partner Center OpenApi v3 using typespec for the first time. I hit an error trying to translate the OpenApi spec to typespec.
Seems like it might be related to the fact that the OpenApi spec doesn't define operationIds. Took me a while to figure this out as the error isn't very clear what's going on. If it is the case, might want to add some better error handling to call out that as a requirement.
Reproduction
Checklist
The text was updated successfully, but these errors were encountered: