vscode-pawn icon indicating copy to clipboard operation
vscode-pawn copied to clipboard

Add a "debug" mode with help of sampctl and/or crashdetect to listen for run time errors and/or server crashes

Open AGraber opened this issue 5 years ago • 1 comments

I don't know if the vscode API would allow for this (since debugs should have full support for breaking) but it would be cool to have some kind of debug mode when running the package in normal mode or running tests.

This debug mode would be listening the output for runtime errors that crashdetect would output, maybe with the help of sampctl if needed. In the occurrence of a server crash or a run time error, vscode would probably trigger some "fake" break (or something similar or cleaner, I don't know about what the vscode API allows) to directly pinpoint the affected file and line if available, in a similar to how exceptions are pinpointed when debugging C++ in vscode. Obviously, since there's (unfortunately) no plugin/tool to stop and actually debug that yet, there would be no stop at all.

It would be very useful specially when running tests.

AGraber avatar Sep 08 '18 22:09 AGraber

Yes I believe the vscode API would allow that - debug mode doesn't need to provide the full stop/step functionality, it can be reversed so the application being debugged is actually driving control of the vscode interface to help with debugging.

I'll look into this when I get time.

Southclaws avatar Sep 10 '18 08:09 Southclaws