microsoft / microsoft/MIEngine

Console interactions aren't handled when starting a process under the debugger

Open
#21 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

enhancement general-linux-support
Dominant language
C#
Stars
859
Forks
233
Avg merge
1d 6h
Merged PRs (30d)
3

Description

We don't have a story right now for how console input/output would work if we launched a process under the debugger.

This has two big problems:

  1. The program is going to get the input that we want to send to gdb
  2. There is no way for the user to send the input they would like to send to their program

Possible implementations that I can think of:

  1. Run the program under gdbserver so we can avoid the problem
  2. SSH into the box a second time to create a separate terminate, and redirect the output of the program using -inferior-tty-set.
    Ex:
    A. SSH in
    B. Run 'tty' to find out that device id.
    C. Run a program which isn't reading from stdin (ex: sleep)
    D. -inferior-tty-set /dev/pts/6
    E. -exec-run

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

The issue names no files, tests, or entry points. Start by tracing how MIEngine launches processes under gdb and how terminal input and output are currently routed; compare the proposed gdbserver and separate-terminal approaches. Done means a debugged program can receive its own input and expose its output without interfering with debugger commands.

Written by the indexing model from the issue text.

Assessment

Tech stack
csharp
Domain
devtools
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.