8 implementations of DisplayError
aspire (2)
Interaction\ConsoleInteractionService.cs (1)
186public void DisplayError(string errorMessage)
Interaction\ExtensionInteractionService.cs (1)
229public void DisplayError(string errorMessage)
Aspire.Cli.Tests (6)
Commands\NewCommandTests.cs (1)
897public void DisplayError(string errorMessage) { }
Commands\PublishCommandPromptingIntegrationTests.cs (1)
982public void DisplayError(string errorMessage) => DisplayedErrors.Add(errorMessage);
Commands\UpdateCommandTests.cs (1)
962public void DisplayError(string errorMessage) => _innerService.DisplayError(errorMessage);
Templating\DotNetTemplateFactoryTests.cs (1)
430public void DisplayError(string message) { }
TestServices\TestConsoleInteractionService.cs (1)
77public void DisplayError(string errorMessage)
TestServices\TestExtensionInteractionService.cs (1)
65public void DisplayError(string errorMessage)
100 references to DisplayError
aspire (99)
Commands\AddCommand.cs (4)
163InteractionService.DisplayError(AddCommandStrings.NoPackagesFound); 222InteractionService.DisplayError(string.Format(CultureInfo.CurrentCulture, AddCommandStrings.PackageInstallationFailed, ExitCodeConstants.FailedToAddPackage)); 240InteractionService.DisplayError(ex.Message); 249InteractionService.DisplayError(string.Format(CultureInfo.CurrentCulture, AddCommandStrings.ErrorOccurredWhileAddingPackage, ex.Message));
Commands\BaseCommand.cs (6)
63interactionService.DisplayError(InteractionServiceStrings.SpecifiedProjectFileNotAppHostProject); 68interactionService.DisplayError(InteractionServiceStrings.ProjectOptionDoesntExist); 73interactionService.DisplayError(InteractionServiceStrings.ProjectOptionNotSpecifiedMultipleAppHostsFound); 78interactionService.DisplayError(InteractionServiceStrings.ProjectOptionNotSpecifiedNoCsprojFound); 83interactionService.DisplayError(InteractionServiceStrings.UnbuildableAppHostsDetected); 87interactionService.DisplayError(string.Format(CultureInfo.CurrentCulture, InteractionServiceStrings.UnexpectedErrorOccurred, ex.Message));
Commands\CacheCommand.cs (1)
125InteractionService.DisplayError(string.Format(CultureInfo.CurrentCulture, CacheCommandStrings.CacheClearFailed, ex.Message));
Commands\ConfigCommand.cs (9)
89InteractionService.DisplayError(ErrorStrings.ConfigurationKeyRequired); 113InteractionService.DisplayError(string.Format(CultureInfo.CurrentCulture, ErrorStrings.ConfigurationKeyNotFound, key)); 153InteractionService.DisplayError(ErrorStrings.ConfigurationKeyRequired); 159InteractionService.DisplayError(ErrorStrings.ConfigurationValueRequired); 194InteractionService.DisplayError(string.Format(CultureInfo.CurrentCulture, ErrorStrings.ErrorSettingConfiguration, ex.Message)); 311InteractionService.DisplayError(ErrorStrings.ConfigurationKeyRequired); 325InteractionService.DisplayError(string.Format(CultureInfo.CurrentCulture, ErrorStrings.ConfigurationKeyNotFound, key)); 359InteractionService.DisplayError(string.Format(CultureInfo.CurrentCulture, ErrorStrings.ConfigurationKeyNotFound, key)); 365InteractionService.DisplayError(string.Format(CultureInfo.CurrentCulture, ErrorStrings.ErrorDeletingConfiguration, ex.Message));
Commands\ExecCommand.cs (9)
106InteractionService.DisplayError(ExecCommandStrings.TargetResourceNotSpecified); 114InteractionService.DisplayError(ExecCommandStrings.NoCommandSpecified); 122InteractionService.DisplayError(ExecCommandStrings.FailedToParseCommand); 148InteractionService.DisplayError(ErrorStrings.CommandNotSupportedWithSingleFileAppHost); 261InteractionService.DisplayError(RunCommandStrings.ProjectCouldNotBeRun); 272InteractionService.DisplayError(RunCommandStrings.ProjectCouldNotBeRun); 294InteractionService.DisplayError(string.Format(CultureInfo.CurrentCulture, TemplatingStrings.CertificateTrustError, ex.Message)); 299InteractionService.DisplayError(string.Format(CultureInfo.CurrentCulture, InteractionServiceStrings.ErrorConnectingToAppHost, ex.Message)); 305InteractionService.DisplayError(string.Format(CultureInfo.CurrentCulture, InteractionServiceStrings.UnexpectedErrorOccurred, ex.Message));
Commands\InitCommand.cs (10)
154InteractionService.DisplayError($"Unknown language: {selectedProject.LanguageId}"); 215InteractionService.DisplayError("Failed to get projects from solution."); 362InteractionService.DisplayError("Failed to install Aspire templates."); 389InteractionService.DisplayError($"Failed to create Aspire projects. Exit code: {createResult}"); 400InteractionService.DisplayError("Failed to find created AppHost or ServiceDefaults projects in template output."); 442InteractionService.DisplayError($"Failed to add AppHost project to solution. Exit code: {addAppHostResult}"); 468InteractionService.DisplayError($"Failed to add ServiceDefaults project to solution. Exit code: {addServiceDefaultsResult}"); 500InteractionService.DisplayError($"Failed to add reference to {Path.GetFileNameWithoutExtension(project.ProjectFile.Name)}."); 534InteractionService.DisplayError($"Failed to add ServiceDefaults reference to {Path.GetFileNameWithoutExtension(project.ProjectFile.Name)}."); 587InteractionService.DisplayError("Single-file AppHost template not found.");
Commands\NewCommand.cs (1)
172InteractionService.DisplayError($"Unknown language: '{explicitLanguage}'");
Commands\PipelineCommandBase.cs (6)
248InteractionService.DisplayError(GetCanceledMessage()); 263InteractionService.DisplayError(ex.Message); 271InteractionService.DisplayError(string.Format(CultureInfo.CurrentCulture, InteractionServiceStrings.ErrorConnectingToAppHost, ex.Message)); 283InteractionService.DisplayError(string.Format(CultureInfo.CurrentCulture, InteractionServiceStrings.AppHostConnectionLost, ex.Message)); 295InteractionService.DisplayError(string.Format(CultureInfo.CurrentCulture, InteractionServiceStrings.UnexpectedErrorOccurred, ex.Message)); 749InteractionService.DisplayError(error);
Commands\RunCommand.cs (9)
159InteractionService.DisplayError("Unrecognized app host type."); 203InteractionService.DisplayError(InteractionServiceStrings.ProjectCouldNotBeBuilt); 226InteractionService.DisplayError(RunCommandStrings.DashboardFailedToStart); 314InteractionService.DisplayError(string.Format(CultureInfo.CurrentCulture, TemplatingStrings.CertificateTrustError, ex.Message.EscapeMarkup())); 319InteractionService.DisplayError(string.Format(CultureInfo.CurrentCulture, InteractionServiceStrings.ErrorConnectingToAppHost, ex.Message.EscapeMarkup())); 328InteractionService.DisplayError(string.Format(CultureInfo.CurrentCulture, InteractionServiceStrings.UnexpectedErrorOccurred, ex.Message.EscapeMarkup())); 758_interactionService.DisplayError(RunCommandStrings.FailedToStartAppHost); 770_interactionService.DisplayError(string.Format( 777_interactionService.DisplayError(RunCommandStrings.TimeoutWaitingForAppHost);
Commands\Sdk\SdkDumpCommand.cs (4)
83InteractionService.DisplayError($"Integration project not found: {integrationProject.FullName}"); 89InteractionService.DisplayError($"Expected a .csproj file, got: {integrationProject.Extension}"); 96InteractionService.DisplayError("Cannot specify both --json and --ci. Choose one format."); 148InteractionService.DisplayError("Failed to build capability scanner.");
Commands\Sdk\SdkGenerateCommand.cs (4)
72InteractionService.DisplayError($"Integration project not found: {integrationProject.FullName}"); 78InteractionService.DisplayError($"Expected a .csproj file, got: {integrationProject.Extension}"); 86InteractionService.DisplayError($"Unsupported language: {language}"); 149InteractionService.DisplayError("Failed to build SDK generation server.");
Commands\StopCommand.cs (7)
81_interactionService.DisplayError(StopCommandStrings.NoRunningAppHostsFound); 100_interactionService.DisplayError(StopCommandStrings.NoRunningAppHostsFound); 167_interactionService.DisplayError(StopCommandStrings.NoRunningAppHostsFound); 199_interactionService.DisplayError(StopCommandStrings.FailedToStopAppHost); 228_interactionService.DisplayError(StopCommandStrings.FailedToStopAppHost); 234_interactionService.DisplayError(StopCommandStrings.FailedToStopAppHost); 272_interactionService.DisplayError(StopCommandStrings.FailedToStopAppHost);
Commands\UpdateCommand.cs (5)
127InteractionService.DisplayError("CLI self-update is not available in this environment."); 217InteractionService.DisplayError(message); 223InteractionService.DisplayError(message); 280InteractionService.DisplayError("Unable to determine the current executable path."); 317InteractionService.DisplayError($"Failed to update CLI: {ex.Message}");
Projects\GuestAppHostProject.cs (9)
188_interactionService.DisplayError("Failed to build AppHost server."); 360_interactionService.DisplayError("App host exited unexpectedly."); 472_interactionService.DisplayError($"Failed to run {DisplayName} AppHost: {ex.Message}"); 620_interactionService.DisplayError("App host exited unexpectedly."); 725_interactionService.DisplayError($"Failed to publish {DisplayName} AppHost: {ex.Message}"); 1126_interactionService.DisplayError("GuestRuntime not initialized. This is a bug."); 1133_interactionService.DisplayError($"Failed to install {_resolvedLanguage?.DisplayName ?? "guest"} dependencies."); 1154_interactionService.DisplayError("GuestRuntime not initialized. This is a bug."); 1176_interactionService.DisplayError("GuestRuntime not initialized. This is a bug.");
Projects\LanguageService.cs (1)
114_interactionService.DisplayError($"Unknown language: '{explicitLanguageId}'");
Scaffolding\ScaffoldingService.cs (2)
82_interactionService.DisplayError("Failed to build AppHost server."); 189_interactionService.DisplayError($"Failed to install {language.DisplayName} dependencies.");
Templating\DotNetTemplateFactory.cs (6)
434interactionService.DisplayError(string.Format(CultureInfo.CurrentCulture, TemplatingStrings.TemplateInstallationFailed, templateInstallResult.ExitCode)); 468interactionService.DisplayError(TemplatingStrings.ProjectAlreadyExists); 473interactionService.DisplayError(string.Format(CultureInfo.CurrentCulture, TemplatingStrings.ProjectCreationFailed, newProjectExitCode)); 495interactionService.DisplayError(string.Format(CultureInfo.CurrentCulture, TemplatingStrings.CertificateTrustError, ex.Message)); 500interactionService.DisplayError(ex.Message); 505interactionService.DisplayError(ex.Message);
Utils\AppHostHelper.cs (4)
23interactionService.DisplayError(ErrorStrings.ProjectCouldNotBeAnalyzed); 29interactionService.DisplayError(ErrorStrings.ProjectIsNotAppHost); 35interactionService.DisplayError(ErrorStrings.CouldNotParseAspireSDKVersion); 42interactionService.DisplayError(string.Format(CultureInfo.CurrentCulture, ErrorStrings.AspireSDKVersionNotSupported, appHostInformation.AspireHostingVersion));
Utils\SdkInstallHelper.cs (2)
51interactionService.DisplayError(sdkErrorMessage); 103interactionService.DisplayError(
Aspire.Cli.Tests (1)
Commands\UpdateCommandTests.cs (1)
962public void DisplayError(string errorMessage) => _innerService.DisplayError(errorMessage);