microsoft / microsoft/vscode-cpptools

First character is skipped on logging message

Open
#954 5 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

bug debugger
Dominant language
TypeScript
Stars
6.2k
Forks
1.7k
Avg merge
14h 46m
Merged PRs (30d)
61

Description

Hi,
I'm using the debugger in remote. It worked quite well, except for one thing: the first character is skipped for each logged message, this is the script I'm using to debug a remote program on CentOs:

    {
      "name": "C++ remote launch (ssh)",
      "type": "cppdbg",
      "request": "launch",
      "program": "/home/renaud/workspace/LGDN_001_DEMONSTRATOR/testApplications/lgdn_001_demonstrator/Lgdn001Demonstrator", // Executable on the remote machine
      "args": ["-v2", "-j5", "-t3", "13"],
      "stopAtEntry": false,
      "cwd": "/home/renaud/workspace/LGDN_001_DEMONSTRATOR/testApplications/lgdn_001_demonstrator", // Directory on remote machine
      "environment": [],
      "externalConsole": true,
      "sourceFileMap": {
        "/home/renaud/workspace/LGDN_001_DEMONSTRATOR/testApplications/lgdn_001_demonstrator/src": "${workspaceRoot}/software/src" // "Compile time source location": "local source location"
      },
      "pipeTransport": {
        "pipeCwd": "/usr/bin", // Local directory of pipe program
        "pipeProgram": "ssh", // Pipe program
        "pipeArgs": ["renaud@10.1.38.10"],
        "debuggerPath": "/usr/bin/gdb" // Debugger location on the remote machine
      },
      "logging": {
        "engineLogging": true
      }
    }

An example of message expected:

0min 1sec: [3;34mDEBUG: Lockable: Unlock the instance of the program

But I'm getting that:

min 1sec: [3;34mDEBUG: Lockable: Unlock the instance of the program

With the engine logging enabled, I get that information (hope it can help):

1: (5826) ->0min 1sec: [3;34mDEBUG: Lockable: Unlock the instance of the program

Also everything is logged in the debug console, and not on an external terminal (as requested in the script), but that's not problem for me.

If you want more details, just ask.

Contributor guide

Open the contributing guide

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

Reproduce the issue using the reported cppdbg launch configuration, especially pipeTransport with ssh and remote gdb on CentOS, with engineLogging enabled. Compare the raw logged message with the displayed message; done means the first character is retained in each logging message.

Written by the indexing model from the issue text.

Assessment

Tech stack
cpp, vscode
Domain
devtools
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
38/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.