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.

Sequelize : Warning: a promise was created in a handler but was not returned from it

See original GitHub issue

(This issue tracker is only for bug reports or feature requests, if this is neither, please choose appropriate channel from http://bluebirdjs.com/docs/support.html)

Please answer the questions the best you can:

  1. What version of bluebird is the issue happening on? 3.5.1

  2. What platform and version? (For example Node.js 0.12 or Google Chrome 32) Node.js 9.8.0

  3. Did this issue happen with earlier version of bluebird? 3.5.0: yes

(Write description of your issue here, stack traces from errors and code that reproduces the issue are helpful)

I am either deleting or saving model instances through sequelize, eg

User.destroy({ where: { id: id } })
.then(() => {})

var user = new User({...})
user.save()
.then(() => {})

and everytime I get the warning. I’ve tried adding return null in the then clause but that does absolutely nothing.

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:7 (1 by maintainers)

github_iconTop GitHub Comments

1reaction
georgecrawfordcommented, May 23, 2018

@opichon I’m seeing a similar problem (with Sequelize v3.30.4 - we’re not currently in a position to upgrade). Did you raise a ticket with them, or find a fix for the Bluebird warning?

0reactions
petkaantonovcommented, May 25, 2019

Do you have the code from:

/Users/olivier/projects/kinkao/api/auth/auth.js:19:16

And

/Users/olivier/projects/kk/api/auth/oauth.js:34:21

?

Look at those lines in those files

Read more comments on GitHub >

github_iconTop Results From Across the Web

Getting: "Warning: a promise was created in a handler but was ...
Issue Description I have a nodejs server as a REST API with various routes and i am using sequelize to access and manage...
Read more >
a promise was created in a handler but was not returned from it
If I run a simple Promise or any other Sequelize call (find, update, create) without the transaction it does not show this warning....
Read more >
Why do I not get the warning "a promise was created in a ...
I observed some cases where I'm getting following warning: Warning: a promise was created in a handler but was not returned from it....
Read more >
Warning: A Promise Was Created In A Handler At But Was Not ...
Warning: a promise was created in a handler but was not returned from it This usually means that you simply forgot a return...
Read more >
a promise was created in a handler at but was not returned ...
Coding example for the question Warning: a promise was created in a handler at but was not returned from it [bluebird]-node.js.
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