FSX / momoko

Wraps (asynchronous) Psycopg2 for Tornado.
http://momoko.61924.nl/
Other
363 stars 73 forks source link

Replace IOLoop.update_handler with remove_handler and add_handler #38

Closed boringcrypto closed 11 years ago

boringcrypto commented 11 years ago

Using IOLoop.update_handler was causing issues with Exception handling in tornado.gen in the host application to the extend that the errors were returned on the wrong RequestHandler. Even other code errors. I assume it has something to do with the StackContext. add_handler creates a new StackContext, but update_handler doesn't.

FSX commented 11 years ago

Thanks! :)

FSX commented 11 years ago

Hey, I made a few changes your pull request after I looked at the code more carefully. Here's the commit, everything is explained in the commit message: FSX/Momoko@92940db0a0f6d780724f42d3d66f1b75a78430ff. It's in the develop branch for now.