Better HN
topnewbestaskshowjobs
Log inSign up

vlflnd

6 karma · joined Feb 18, 2016 (10y ago) · 2 submissions

Submissions

comment 10y ago · link · parent

Unfortunately there is no good way to capture the state of the client. For example in JavaScript there is no access to local variables of a function.

comment 10y ago · link · parent

The Python Cloud Debugger works with the standard (unmodified) CPython 2.7.x. Breakpoints are implemented by rewriting Python bytecode at runtime. The debugger inserts a method call at the breakpoint location in a code object. This method tells the debugger that the code reached a particular point. Generator functions are particularly tricky because they need to maintain correct offsets at "yield" points.

This source file implements all of it: https://github.com/GoogleCloudPlatform/cloud-debug-python/bl...