Get stderr or last few lines of extension-owned Terminal in API when it crashes? #91016
Labels
*duplicate
Issue identified as a duplicate of another issue(s)
terminal
General terminal issues that don't fall under another label
under-discussion
Issue is under discussion for relevance, priority, approach
Milestone
I've read through #78574 and #62103, but please feel free to let me know if this is a duplicate or unfeasible.
Every so often we get an issue opened on the PowerShell extension like this one where the subprocess we start as a terminal crashes before we can log anything.
In those cases, it's currently quite hard to work out why the terminal crashed. We either need the user to run the invocation we pass to VSCode to start the terminal, or get them to record a GIF of the crash when they reproduce it to capture the brief moment the error message is displayed in the terminal before it's cleaned up.
If it were possible for us to get the stderr or the most recent output of the terminal in some way, we'd be able to log the error and probably have a significantly improved rate of error fixing and user satisfaction. I understand that ask is vague and there are performance implications with reading everything as it comes through and so on, but just want to express the general desire to see more than the exit code when a terminal process crashes. And query whether that's:
The text was updated successfully, but these errors were encountered: