Alex Rivera | Logout

gevent monkey-patching and breakpoints

Asked 2012-07-15T20:27:49.130
21

I have been playing with Gevent, and I like it a lot. However I have run into a problem. Breakpoint are not being hit, and debugging doesn't work (using both Visual Studio Python Tools and Eclipse PyDev). This happens after monkey.patch_all() is called.

This is a big problem for me, and unfortunately this is a blocker for the use of gevent. I have found a few threads that seem to indicate that gevent breaks debugging, but I would imagine there is a solution for that.

Does anyone know how to make debugging and breakpoints work with gevent and monkey patching?

Edit
Report

1 Answer

9

PyCharm IDE solves the problem. It supports gevent code debugging after you set a configuration flag: http://blog.jetbrains.com/pycharm/2012/08/gevent-debug-support/.

Unfortunately, at the moment I don't know a free tool capable of debugging gevent.

UPD: THERE IS! Now there is a community version of PyCharm.

answered 2012-12-26T10:12:26.910

Your Answer