Remix.run Logo
squirrellous 5 days ago

IME console-based debuggers work great for single-threaded code without a lot of console output. They don't work that well otherwise. GUI-based debuggers can probably fix both of those issues. I just haven't really tried them as much.

pdb is great for python, though.

MrDarcy 5 days ago | parent [-]

I frequently use the go debugger to debug concurrent go routines. I haven’t found it any different than single threaded debugging.

I simply use conditional break points to break when whatever go routine happens to be working on the struct I care about.

Is there more to the issue?

squirrellous 5 days ago | parent [-]

Thinking back, the issue I had with multi-threaded code was two-fold:

- Things like "continue", "step" are no longer a faithful reproduction of what the program does in real time, so it's more difficult to understand the program's behavior. Some timing-related bugs simplify disappear under a debugger.

- There's usually some background thread that's logging things to console, which reduces to problem 2 in my comment.

I haven't used Go that much. I imagine since goroutines are such a cornerstone of the language, the go debugger must have some nifty features to support multi-(green)-threaded debugging?