Skip to content
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

Debuggee output breaks adapter with "internalConsole" #1659

Closed
int19h opened this issue Aug 6, 2019 · 0 comments

Comments

@int19h
Copy link
Contributor

commented Aug 6, 2019

Debug adapter allows the child process to read from stdin and write to stdout. When communicating with the IDE over stdio, this interferes with DAP messages.

The adapter should block stdin for the debuggee entirely in that mode, and capture stdout/err into "output" DAP messages. Since the debug server will also generate "output" events, those would have to be suppressed in that mode to avoid duplicates.

@int19h int19h added the Bug label Aug 6, 2019

@int19h int19h self-assigned this Aug 6, 2019

@karthiknadig karthiknadig added this to the Aug 2019.1 milestone Aug 7, 2019

int19h added a commit to int19h/ptvsd that referenced this issue Aug 17, 2019

Fix microsoft#1697: Adapter doesn't handle "env" properly in "interna…
…lConsole" mode on Python 2.7

Encode environment variables on Python 2.

Fix microsoft#1659: Debuggee output breaks adapter with "internalConsole"

Use os.devnull for debuggee stdin, and redirect debuggee stdout to stderr.

Capture output for debuggee stdout and stderr, generate DAP "output" events from it, and suppress the same coming from the debug server.

int19h added a commit to int19h/ptvsd that referenced this issue Aug 17, 2019

Fix microsoft#1697: Adapter doesn't handle "env" properly in "interna…
…lConsole" mode on Python 2.7

Encode environment variables on Python 2.

Fix microsoft#1659: Debuggee output breaks adapter with "internalConsole"

Use os.devnull for debuggee stdin, and redirect debuggee stdout to stderr.

Capture output for debuggee stdout and stderr, generate DAP "output" events from it, and suppress the same coming from the debug server.

int19h added a commit that referenced this issue Aug 17, 2019

Fix #1697: Adapter doesn't handle "env" properly in "internalConsole"…
… mode on Python 2.7

Encode environment variables on Python 2.

Fix #1659: Debuggee output breaks adapter with "internalConsole"

Use os.devnull for debuggee stdin, and redirect debuggee stdout to stderr.

Capture output for debuggee stdout and stderr, generate DAP "output" events from it, and suppress the same coming from the debug server.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
2 participants
You can’t perform that action at this time.