Skip to content

Instantly share code, notes, and snippets.

@alco
Created February 5, 2018 21:54
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save alco/183714a0e37fa3041d05ef67ec7f2ca0 to your computer and use it in GitHub Desktop.
Save alco/183714a0e37fa3041d05ef67ec7f2ca0 to your computer and use it in GitHub Desktop.
$ apib2swagger -i my_api.apib --yaml -o my_api.yaml
TypeError: Cannot read property 'length' of undefined
at jsonSchemaFromMSON (/usr/local/lib/node_modules/apib2swagger/index.js:266:38)
at /usr/local/lib/node_modules/apib2swagger/index.js:39:67
at Array.forEach (<anonymous>)
at /usr/local/lib/node_modules/apib2swagger/index.js:32:26
at Array.forEach (<anonymous>)
at module.exports.convertParsed (/usr/local/lib/node_modules/apib2swagger/index.js:29:8)
at Object.exports.convert (/usr/local/lib/node_modules/apib2swagger/index.js:402:23)
at processBlueprint (/usr/local/lib/node_modules/apib2swagger/bin/apib2swagger.js:87:18)
at ReadStream.__dirname.on.on (/usr/local/lib/node_modules/apib2swagger/bin/apib2swagger.js:67:5)
at ReadStream.emit (events.js:165:20)
$ api-spec-converter --from api_blueprint --to openapi_3 my_api.apib >my_api.yaml
Fatal TypeError: Cannot read property 'length' of undefined
at jsonSchemaFromMSON (/usr/local/lib/node_modules/api-spec-converter/node_modules/apib2swagger/index.js:266:38)
at /usr/local/lib/node_modules/api-spec-converter/node_modules/apib2swagger/index.js:39:67
at Array.forEach (<anonymous>)
at /usr/local/lib/node_modules/api-spec-converter/node_modules/apib2swagger/index.js:32:26
at Array.forEach (<anonymous>)
at Object.module.exports.convertParsed (/usr/local/lib/node_modules/api-spec-converter/node_modules/apib2swagger/index.js:29:8)
at converters.swagger_2.Promise.method.apibp (/usr/local/lib/node_modules/api-spec-converter/lib/formats/api_blueprint.js:16:24)
at tryCatcher (/usr/local/lib/node_modules/api-spec-converter/node_modules/bluebird/js/release/util.js:16:23)
at /usr/local/lib/node_modules/api-spec-converter/node_modules/bluebird/js/release/method.js:15:34
at Promise.try (/usr/local/lib/node_modules/api-spec-converter/lib/base_format.js:162:12)
at tryCatcher (/usr/local/lib/node_modules/api-spec-converter/node_modules/bluebird/js/release/util.js:16:23)
at Function.Promise.attempt.Promise.try (/usr/local/lib/node_modules/api-spec-converter/node_modules/bluebird/js/release/method.js:39:29)
at module.exports.BaseFormat.convertTo (/usr/local/lib/node_modules/api-spec-converter/lib/base_format.js:154:21)
at prom.then.spec (/usr/local/lib/node_modules/api-spec-converter/lib/base_format.js:178:19)
at tryCatcher (/usr/local/lib/node_modules/api-spec-converter/node_modules/bluebird/js/release/util.js:16:23)
at Promise._settlePromiseFromHandler (/usr/local/lib/node_modules/api-spec-converter/node_modules/bluebird/js/release/promise.js:512:31)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment