문제

I'm just starting to build a web app with web2py for the first time. It's great how well PyCharm integrates with web2py.

One thing I'd like to do, however, is avoid the web2py ticketing system and just allow exceptions to be caught in the normal way in PyCharm. Currently, any attempt to catch exceptions, even via an "All Exceptions" breakpoint, never results in anything getting caught by Pycharm.

Can someone tell me if this is possible, and if so, how to do it?

도움이 되었습니까?

해결책

I figured this out by looking through the web2py source code. Apparently, web2py is set up to do what I want to do for a particular debugger, seemingly called Wing Db. There's a constant env var ref in the code named WINGDB_ACTIVE that, if set, redirects exceptions to an external debugger.

All I had do to was define this env var, WINGDB_ACTIVE, as 1 in my PyCharm execution configuration, and voila, exceptions are now passed through to my debugger!

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top