-
Notifications
You must be signed in to change notification settings - Fork 418
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
Improve writing dashboard startup config failure messages #3243
Conversation
@mitchdenny What does the host do on configuration or startup failure? We should think about consistency. |
Can you do it in both places? |
This is the way we do it in the AppHost: aspire/src/Aspire.Hosting/DistributedApplicationBuilder.cs Lines 98 to 99 in 9c4533e
|
I want to register a type. I don't want to use a callback. |
Review please 🙏 |
case FrontendAuthMode.OpenIdConnect: | ||
break; | ||
case null: | ||
errorMessages.Add($"Frontend endpoint authentication is not configured. Either specify {DashboardConfigNames.DashboardUnsecuredAllowAnonymousName.ConfigKey}=true, or specify {DashboardConfigNames.DashboardFrontendAuthModeName.ConfigKey}. Possible values: {string.Join(", ", typeof(FrontendAuthMode).GetEnumNames())}"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Error messages should be localised.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If we want to do that then create a new issue. It's beyond the scope of this PR.
f6a99ad
to
b926934
Compare
b926934
to
0469c0d
Compare
/backport to release/8.0 |
Started backporting to release/8.0: https://github.com/dotnet/aspire/actions/runs/8535836985 |
@JamesNK backporting to release/8.0 failed, the patch most likely resulted in conflicts: $ git am --3way --ignore-whitespace --keep-non-patch changes.patch
Applying: Improve writing dashboard startup config failure messages
Using index info to reconstruct a base tree...
M src/Aspire.Dashboard/DashboardWebApplication.cs
M tests/Aspire.Dashboard.Tests/Integration/StartupTests.cs
Falling back to patching base and 3-way merge...
Auto-merging tests/Aspire.Dashboard.Tests/Integration/StartupTests.cs
Auto-merging src/Aspire.Dashboard/DashboardWebApplication.cs
CONFLICT (content): Merge conflict in src/Aspire.Dashboard/DashboardWebApplication.cs
error: Failed to merge in the changes.
hint: Use 'git am --show-current-patch=diff' to see the failed patch
Patch failed at 0001 Improve writing dashboard startup config failure messages
When you have resolved this problem, run "git am --continue".
If you prefer to skip this patch, run "git am --skip" instead.
To restore the original branch and stop patching, run "git am --abort".
Error: The process '/usr/bin/git' failed with exit code 128 Please backport manually! |
@JamesNK an error occurred while backporting to release/8.0, please check the run log for details! Error: git am failed, most likely due to a merge conflict. |
Fixes #3168
Before:
After:
Microsoft Reviewers: Open in CodeFlow