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

Uncaught error event crashes process #12

Open
olalonde opened this issue Jul 21, 2016 · 0 comments
Open

Uncaught error event crashes process #12

olalonde opened this issue Jul 21, 2016 · 0 comments

Comments

@olalonde
Copy link

I was running my server locally and my laptop accidentally connected to one of those wifis which redirects all your http(s) requests. This resulted in this error:

error:  Error: self signed certificate
    at Strategy.OAuthStrategy._createOAuthError (/Users/olalonde/code/myapp/myapp-api/node_modules/passport-oauth1/lib/strategy.js:396:17)
    at /Users/olalonde/code/myapp/myapp-api/node_modules/passport-oauth1/lib/strategy.js:244:41
    at /Users/olalonde/code/myapp/myapp-api/node_modules/oauth/lib/oauth.js:543:17
    at ClientRequest.<anonymous> (/Users/olalonde/code/myapp/myapp-api/node_modules/oauth/lib/oauth.js:421:9)
    at emitOne (events.js:96:13)
    at ClientRequest.emit (events.js:188:7)
    at TLSSocket.socketErrorListener (_http_client.js:306:9)
    at emitOne (events.js:96:13)
    at TLSSocket.emit (events.js:188:7)
    at emitErrorNT (net.js:1265:8)
    at _combinedTickCallback (internal/process/next_tick.js:74:11)
    at process._tickDomainCallback (internal/process/next_tick.js:122:9)
GET /v1/auth/connect/twitter 500 75.890 ms - 39
events.js:160
      throw er; // Unhandled 'error' event
      ^

Error: self signed certificate
    at Error (native)
    at TLSSocket.<anonymous> (_tls_wrap.js:1055:38)
    at emitNone (events.js:86:13)
    at TLSSocket.emit (events.js:185:7)
    at TLSSocket._finishInit (_tls_wrap.js:580:8)
    at TLSWrap.ssl.onhandshakedone (_tls_wrap.js:412:38)
[nodemon] app crashed - waiting for file changes before starting...

I was wondering if there would be any way to catch this error so that it doesn't crash the whole process next time.

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

No branches or pull requests

1 participant