greim / hoxy

Web-hacking proxy API for node
http://greim.github.io/hoxy/
MIT License
599 stars 97 forks source link

Error reporting for missing mime type #12

Open digitalrinaldo opened 13 years ago

digitalrinaldo commented 13 years ago

In many cases the stack trace for an exception is clear. It would be nice to have a gernal error module where exceptions can be trapped and reported as errors in the log. I would like to work on this.

uncaught exception: Cannot call method 'indexOf' of undefined TypeError: Cannot call method 'indexOf' of undefined at isText (/Users/rinaldo/Documents/workspace/Maxwell/DirectPrint/src/main/proxy/hoxy/plugins/ghost-server.js:141:15) at getContentType (/Users/rinaldo/Documents/workspace/Maxwell/DirectPrint/src/main/proxy/hoxy/plugins/ghost-server.js:149:5) at /Users/rinaldo/Documents/workspace/Maxwell/DirectPrint/src/main/proxy/hoxy/plugins/ghost-server.js:106:28 at [object Object]. (fs.js:107:5) at [object Object].emit (events.js:61:17) at afterRead (fs.js:878:12) at wrapper (fs.js:245:17)

Rinaldo

greim commented 10 years ago

I've been crazy busy the last 2.x years, and have neglected this poor project. I'll note here that v1.x has a hopefully more flexible logging mechanism, and a hoxy.forever() method to handle uncaught exceptions.