Giter VIP home page Giter VIP logo

Comments (2)

benjamingr avatar benjamingr commented on June 2, 2024

Hello, I would like to use Bluebird instead of native Promises because native stack traces give me no clue where to look for errors that are happening

We fixed native stack traces in Node.js with async functions and native promises a while ago (circa 2018) - can you outline what doesn't work?


This seems to indicate that the native Promise doesn't get overwritten

I can't extract the tar.gz file here (on mobile) can you upload a gist or a gh repo?

from bluebird.

hbielenia avatar hbielenia commented on June 2, 2024

We fixed native stack traces in Node.js with async functions and native promises a while ago (circa 2018) - can you outline what doesn't work?

I added Promises around Node's http callback-based utility functions and I'm getting an error like this one:

node:events:491
      throw er; // Unhandled 'error' event
      ^

Error: connect ECONNREFUSED ::1:80
    at TCPConnectWrap.afterConnect [as oncomplete] (node:net:1494:16)
Emitted 'error' event on ClientRequest instance at:
    at Socket.socketErrorListener (node:_http_client:502:9)
    at Socket.emit (node:events:513:28)
    at emitErrorNT (node:internal/streams/destroy:151:8)
    at emitErrorCloseNT (node:internal/streams/destroy:116:3)
    at process.processTicksAndRejections (node:internal/process/task_queues:82:21) {
  errno: -111,
  code: 'ECONNREFUSED',
  syscall: 'connect',
  address: '::1',
  port: 80
}

Node.js v18.14.0

The error itself is pretty straightforward, but stack trace doesn't show where in my code does this call originate. After Googling, I learned that Bluebird is supposedly capable of longer stack traces and I want to check if it would do the job here.

I can't extract the tar.gz file here (on mobile) can you upload a gist or a gh repo?

Sure thing: https://gist.github.com/hbielenia/6dc79ded33f461dcf971002cd077b554

from bluebird.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.