Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    text
    copied!<p><strong>Quick and dirty solution for development</strong>:</p> <p>Use <a href="https://github.com/mattinsler/longjohn" rel="nofollow noreferrer">longjohn</a>, you get long stack traces that will contain the async operations.</p> <p><strong>Clean and correct solution</strong>: Technically, in node, whenever <a href="http://nodejs.org/api/all.html#all_class_events_eventemitter" rel="nofollow noreferrer">you emit an <code>'error'</code> event and no one listens to it, it will throw</a>. To make it not throw, put a listener on it and handle it yourself. That way you can log the error with more information.</p> <p><strike>To have one listener for a group of calls you can use <a href="http://nodejs.org/api/all.html#all_domain" rel="nofollow noreferrer">domains</a> and also catch other errors on runtime. Make sure each async operation related to http(Server/Client) is in different <a href="http://nodejs.org/api/all.html#all_domain" rel="nofollow noreferrer">domain</a> context comparing to the other parts of the code, the domain will automatically listen to the <code>error</code> events and will propagate it to it's own handler. So you only listen to that handler and get the error data. <a href="http://nodejs.org/api/all.html#all_additions_to_error_objects" rel="nofollow noreferrer">You also get more information for free.</a></strike>(Domains are depreceated). </p> <p>As <code>Mike</code> suggested you can also set <code>NODE_DEBUG=net</code> or use <a href="https://stackoverflow.com/q/174942/774086">strace</a>. They both provide you what is node doing internally. </p>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload