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

Emit NETSDK1057 at most once in -tl #9610

Merged

Conversation

rainersigwald
Copy link
Member

Fixes #9602 by emitting NETSDK1057 as an immediate message at most once in the TerminalLogger.

dotnet build
MSBuild version 17.10.0-dev-24055-01+3500455af for .NET
Restore complete (1.1s)
You are using a preview version of .NET. See: https://aka.ms/dotnet-support-policy
  Lib1 succeeded (3.1s) → Lib1\bin\Debug\net9.0\Lib1.dll
  Lib2 succeeded (3.1s) → Lib2\bin\Debug\net9.0\Lib2.dll
  App succeeded (3.2s) → App\bin\Debug\net9.0\App.dll

Build succeeded in 4.5s

It is slightly ugly to do this deduplication at the logger level, but it cleans up a customer annoyance so I think it's worth it.

Fixes dotnet#9602 by emitting NETSDK1057 as an immediate message at most once
in the TerminalLogger.

```sh-session
❯ dotnet build
MSBuild version 17.10.0-dev-24055-01+3500455af for .NET
Restore complete (1.1s)
You are using a preview version of .NET. See: https://aka.ms/dotnet-support-policy
  Lib1 succeeded (3.1s) → Lib1\bin\Debug\net9.0\Lib1.dll
  Lib2 succeeded (3.1s) → Lib2\bin\Debug\net9.0\Lib2.dll
  App succeeded (3.2s) → App\bin\Debug\net9.0\App.dll

Build succeeded in 4.5s
```
@rainersigwald rainersigwald added the Area: Terminal Logger Problems with the livelogger/fancylogger/terminallogger -tl functionality. label Jan 5, 2024
src/MSBuild/TerminalLogger/TerminalLogger.cs Outdated Show resolved Hide resolved
Co-authored-by: Ladi Prosek <ladi.prosek@gmail.com>
@rainersigwald rainersigwald enabled auto-merge (squash) January 8, 2024 19:00
@rainersigwald rainersigwald merged commit 8215fb1 into dotnet:main Jan 8, 2024
8 checks passed
@rainersigwald rainersigwald deleted the 9602-tl-show-sdk-preview-message branch January 8, 2024 19:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Area: Terminal Logger Problems with the livelogger/fancylogger/terminallogger -tl functionality.
Projects
None yet
3 participants