-
Notifications
You must be signed in to change notification settings - Fork 40
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Implementation of inferior PTY / IO needed #161
Comments
Hmm the MI should really not be on the same channel as the program output. |
I believe no one has implemented this functionality yet - probably because most of the usecases for the adapter so far are embedded. On Linux probably want to use There is already PTY support needed by the Patches welcome. |
Using DAP's runInTerminal this PR adds the ability to use that new terminal for the inferior's I/O. The basic idea of the inferior terminal on Linux is: - adapter requests client (aka vscode) to create a terminal (using runInTerminal) - in that terminal we run a small script that "returns" the tty name to the adapter (using an atomically created file with the output of tty command) - then the script waits until the adapter is complete by monitoring the PID of the adapter's node process The script run in the terminal won't auto-stop when running the adapter in server mode (typically should only be used for development of the adapter) Part of eclipse-cdt-cloud#161
Using DAP's runInTerminal this PR adds the ability to use that new terminal for the inferior's I/O. The basic idea of the inferior terminal on Linux is: - adapter requests client (aka vscode) to create a terminal (using runInTerminal) - in that terminal we run a small script that "returns" the tty name to the adapter (using an atomically created file with the output of tty command) - then the script waits until the adapter is complete by monitoring the PID of the adapter's node process The script run in the terminal won't auto-stop when running the adapter in server mode (typically should only be used for development of the adapter) Part of eclipse-cdt-cloud#161
I did a first pass of Linux support for this in #252. If anyone wants to review that to see what they think that would be much appreciated. |
Cannot distinguish program output from gdb mi output
cdt-gdb-adapter
would try to interpret every line as gdb mi output, which causes a problem because it cannot distinguish program output from that. For example:In the image above,
cdt-gdb-adapter
tried to parse the line that's started with=
or*
, and failed.Only parse the output after a line is finished
According to:
https://github.com/eclipse-cdt/cdt-gdb-adapter/blob/3b9442075d06759035dbae616dbbd9923b921bc6/src/MIParser.ts#L26
the MIParser only handle the output when a line is finished. In the case of program output, this can be really buggy.
The text was updated successfully, but these errors were encountered: