Skip to content
New issue

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

lb export-api-def throws loopbackApplication.get is not a function #4331

Closed
garrettg123 opened this issue Jul 14, 2020 · 2 comments
Closed

Comments

@garrettg123
Copy link

garrettg123 commented Jul 14, 2020

Steps to reproduce

lb export-api-def

Current Behavior

TypeError: loopbackApplication.get is not a function
    at createSwaggerObject (/Users/gsquare567/.config/yarn/global/node_modules/loopback-api-definition/node_modules/loopback-swagger/lib/specgen/swagger-spec-generator.js:31:35)
    at Object.getApiDef (/Users/gsquare567/.config/yarn/global/node_modules/loopback-api-definition/lib/get-api-def.js:23:23)
    at constructor.generate (/Users/gsquare567/.config/yarn/global/node_modules/generator-loopback/export-api-def/index.js:39:31)
    at Object.<anonymous> (/Users/gsquare567/.config/yarn/global/node_modules/generator-loopback/node_modules/yeoman-generator/lib/base.js:431:23)
    at /Users/gsquare567/.config/yarn/global/node_modules/run-async/index.js:25:25
    at new Promise (<anonymous>)
    at /Users/gsquare567/.config/yarn/global/node_modules/run-async/index.js:24:19
    at /Users/gsquare567/.config/yarn/global/node_modules/generator-loopback/node_modules/yeoman-generator/lib/base.js:432:9
    at processImmediate (internal/timers.js:456:21)
    at process.topLevelDomainCallback (domain.js:137:15)

Expected Behavior

Output the API def

Link to reproduction sandbox

Additional information

NOTE: I had to use yarn list --prod --depth 0 | grep loopback because I'm using yarn workspace

Related Issues

See Reporting Issues for more tips on writing good issues

@bajtos
Copy link
Member

bajtos commented Sep 11, 2020

Thank you for reporting the issue. I don't see any obvious cause of the problem. Can you please create a small app we can use to reproduce it?

See https://loopback.io/doc/en/contrib/Reporting-issues.html#loopback-3x-bugs

Note: Failure to provide a sandbox application for reproduction purposes will result in the issue being closed.

@stale
Copy link

stale bot commented Dec 25, 2020

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@stale stale bot added the stale label Dec 25, 2020
@bajtos bajtos closed this as completed Jan 5, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants