question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

[LiveLogger] Garbled output in cmd.exe

See original GitHub issue

Issue Description

LiveLogger does not work in cmd.exe.

Steps to Reproduce

dotnet build /ll in cmd.exe.

Expected Behavior

Either LiveLogger errors out or MSBuild falls back to regular console logging.

Actual Behavior

My first attempt to use LiveLogger resulted in this:

image

Analysis

If this console is not fancy-capable then the logger should not be allowed to run. Note that you still get this kind of console when running the VS Developer prompt as administrator so this would be a blocker for enabling LL by default.

Versions & Configurations

No response

Issue Analytics

  • State:closed
  • Created 7 months ago
  • Comments:5 (4 by maintainers)

github_iconTop GitHub Comments

1reaction
rainersigwaldcommented, Feb 16, 2023

I would have expected the livelogger to not be enabled in this case

https://github.com/dotnet/msbuild/blob/dfd8f413a80cd0865f968b2c0ad9b09c0df8c430/src/MSBuild/XMake.cs#L3436-L3455

So that’s likely the first thing to chase.

0reactions
baronfelcommented, Feb 16, 2023

Oh, that makes sense too 👍 I did a check real quick and verified that cmd inside Windows Terminal does render correctly (which I hoped since Windows Terminal was doing the rendering portion).

Read more comments on GitHub >

github_iconTop Results From Across the Web

MSBuild TerminalLogger keeps users informed about their ...
The LiveLogger is an exciting new feature that MSBuild team has planned for .NET 8. ... [LiveLogger] Garbled output in cmd.exe #8455
Read more >
Jumbled output in CMD.EXE with a manually allocated ...
I have a Windows GUI application that manually opens a console. Calling AllocConsole and redirecting stdin , stdout , and stderr all work ......
Read more >
How to logs result to file AND display when using W10 ...
Its possible to first write it to the textfile and then displaying it by using the following command: dir > a.txt | type...
Read more >
What is the problem with the output of plink?
The output sent by the server will be written straight to your command prompt window, which will most likely not interpret terminal control ......
Read more >
Notepad.exe shows incorrect characters in file created by ...
Running command line tools and redirecting the output to a file on a non-English system may produce unreadable characters when the file is...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found