question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

serverless-offline raises warning due to callback usage

See original GitHub issue

Describe the bug This bug is originally raised by @Strernd on gitter. When Laconia is used together with serverless-offline, it is raising a warning.

To Reproduce Use Laconia with serverless-offline

Expected behavior A clear and concise description of what you expected to happen.

Actual behavior A warning message generated by serverless-offline:

Serverless: Warning: handler 'laconia-handler' returned a promise and also uses a callback! | This is problematic and might cause issues in your lambda.

Additional context The callback is originally retained even though we support node 8 because of a problem in AWS Lambda. Seems like this problem is now fixed, see: https://stackoverflow.com/a/51988695/2464295

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Reactions:1
  • Comments:10 (10 by maintainers)

github_iconTop GitHub Comments

1reaction
ceilforscommented, Nov 27, 2019

@hugosenari Good point. Another option is, we could introduce a configuration that we eventually deprecate i.e. LACONIA_NO_CALLBACK = true.

0reactions
hugosenaricommented, Feb 10, 2020

Fixed by #511 (v1.9.0) Now we can add LACONIA_NO_CALLBACK=‘true’ to env or omitting callback parameter.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Serverless-offline throws "Configuration error" or "Cannot read ...
So in the root of the project, I installed serverless-offline: npm install serverless-offline. It threw several warnings during installation ...
Read more >
Serverless Offline - Serverless Framework: Plugins
This Serverless plugin emulates AWS λ and API Gateway on your local machine to speed up your development cycles. To do so, it...
Read more >
Serverless - FAQ | NestJS - A progressive Node.js framework
When an app is not in use, there are no computing resources allocated to the app. Pricing is based on the actual amount...
Read more >
Wait using callbacks | Workflows - Google Cloud
Using a custom retry predicate, the workflow logs a warning when a timeout occurs and then retries the wait on the callback endpoint,...
Read more >
AWS Step Functions - AWS Documentation
AWS SDK and Optimized integrations Standard and Express workflowsUse casesService ... AWS Step Functions is a serverless orchestration service that lets you ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found