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

always print auth messages in TL, regardless of verbosity #11551

Open
wants to merge 6 commits into
base: main
Choose a base branch
from

Conversation

baronfel
Copy link
Member

@baronfel baronfel commented Mar 8, 2025

Part of dotnet/sdk#47602

Context

With NuGetInteractive=true being passed in more scenarios as of dotnet/sdk#47226, the default verbosity for dotnet run is now minimal for user-present scenarios - that's gross.

Changes Made

Broadly what I'm trying to do here is not require passing -v m to loggers to get the authentication-related messages. Right now dotnet run does this and it's quite noisy compared to previous behavior. This changed because recently I made the SDK start passing --interactive when the user is at the keyboard (similar logic to Terminal Logger's own enablement), and dotnet run has logic to force verbosity to minimal when that happens so that the auth messages print where a user can see them.

I kind of think of auth messages as messages that we should write regardless of verbosity (like errors are), so this is a step down that path for TL.

This change ensures that auth messages are always written in the TL experience, as immediate messages.

If this is accepted, then the SDK could remove the special case it currently has.

Testing

Updated snapshot baselines, manual testing.

Notes

@baronfel baronfel force-pushed the special-auth-messages branch from 7c7d9d8 to 26a168c Compare March 20, 2025 01:54
@baronfel baronfel marked this pull request as ready for review March 20, 2025 19:31
RenderImmediateMessage(message);
return;
}

if (Verbosity > LoggerVerbosity.Quiet)
{
// Show immediate messages to the user.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
// Show immediate messages to the user.

Comment on lines -2 to -6
directory/file(1,2,3,4): warning AA0000:
A
Multi
Line
Warning!
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What happened to these warnings?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants