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

Warning: a promise was created in a handler at lib/pool.js:248:14 but was not returned from it. #285

Open
meenie opened this issue Sep 12, 2016 · 6 comments · May be fixed by #346
Open

Comments

@meenie
Copy link

meenie commented Sep 12, 2016

I'm using thinky#2.3.6 and that pulled down rethinkdbdash#2.3.21. I only ran into this when I started to use the pingInterval option.

Here's the full error:

(node:46024) Warning: a promise was created in a handler at `node_modules/rethinkdbdash/lib/pool.js:248:14` but was not returned from it, see http://goo.gl/rRqMUw
      at new Promise (`./node_modules/rethinkdbdash/node_modules/bluebird/js/release/promise.js:77:14`)

To fix it, I put in return statements at the line specified above, and also on line: 321. Not sure that is the correct fix though, so I haven't created a PR.

@neumino
Copy link
Owner

neumino commented Sep 14, 2016

Fixed in 2.3.22

nopnop added a commit to nopnop/rethinkdbdash that referenced this issue Sep 14, 2016
Bluebird default behavior is to warn on un-returned promise. This PR
fix many of those in cursor.js
@nopnop
Copy link

nopnop commented Sep 14, 2016

Hi @neumino,

There is still some un-returned promise (such as here) - Which throw many warning when toStream is used.

@meenie
Copy link
Author

meenie commented Sep 14, 2016

@neumino Your fix didn't fix it fully. Pool.prototype._expandBuffer() needs to return something as well. The PR I had open did actually fix it.

@meenie
Copy link
Author

meenie commented Sep 19, 2016

@neumino Just bumping this up again. Need to re-open this issue.

@neumino neumino reopened this Sep 20, 2016
@neumino
Copy link
Owner

neumino commented Sep 20, 2016

Can you send a PR?

@meenie
Copy link
Author

meenie commented Sep 20, 2016

@neumino This is the PR I originally had: #286

thejsj added a commit to thejsj/rethinkdbdash that referenced this issue Dec 17, 2016
* 'master' of github.com:neumino/rethinkdbdash: (304 commits)
  Fix leaked variable from test
  Bump to 2.3.27
  Fix neumino#313
  Bump to 2.3.26
  fix: return null where new Promises are created but not returned
  Fix leak in tests
  Fix leak in tests
  Bump to 2.3.25
  Make identification errors operational such that they can be properly caught - Fix neumino#295
  Bump to 2.3.24
  Close the stream if an error is emitted since we can't recover frm it
  Remove the use of Buffer with new for node 7 - Fix neumino#304
  Wrap sending the proof in a try/catch in case the connection is closed - Fix neumino#296
  Bump to 2.3.23
  Prevent bluebird warning - Fix neumino#287
  Bump to 2.3.22
  Prevent bluebird warning - Fix neumino#285
  function r: remove unused parameter `options`
  readme: minor typo fix
  Bump to 2.3.21
  ...
meenie pushed a commit to meenie/rethinkdbdash that referenced this issue Aug 9, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants