8 implementations of DisplayError
aspire (2)
Interaction\ConsoleInteractionService.cs (1)
495public void DisplayError(string errorMessage, bool allowMarkup = false)
Interaction\ExtensionInteractionService.cs (1)
388public void DisplayError(string errorMessage, bool allowMarkup = false)
Aspire.Cli.Tests (6)
Commands\PublishCommandPromptingIntegrationTests.cs (1)
1241public void DisplayError(string errorMessage, bool allowMarkup = false) => DisplayedErrors.Add(errorMessage);
Commands\UpdateCommandTests.cs (1)
3532public void DisplayError(string errorMessage, bool allowMarkup = false) => _innerService.DisplayError(errorMessage, allowMarkup);
Projects\ExtensionGuestLauncherTests.cs (1)
172public void DisplayError(string errorMessage, bool allowMarkup = false) => throw new NotImplementedException();
Templating\DotNetTemplateFactoryTests.cs (1)
404public void DisplayError(string message, bool allowMarkup = false) { }
TestServices\TestExtensionInteractionService.cs (1)
112public void DisplayError(string errorMessage, bool allowMarkup = false)
TestServices\TestInteractionService.cs (1)
243public void DisplayError(string errorMessage, bool allowMarkup = false)
150 references to DisplayError
aspire (149)
Commands\AgentInitCommand.cs (6)
232InteractionService.DisplayError(ex.Message); 315InteractionService.DisplayError(bundleInstallFailureMessage); 420InteractionService.DisplayError(message!); 433InteractionService.DisplayError(ex.Message); 451InteractionService.DisplayError(ex.Message); 748InteractionService.DisplayError(
Commands\ApiListCommand.cs (1)
61InteractionService.DisplayError(string.Format(CultureInfo.CurrentCulture, ApiCommandStrings.NoApiEntriesFound, scope));
Commands\ApiSearchCommand.cs (1)
75InteractionService.DisplayError(string.Format(CultureInfo.CurrentCulture, ApiCommandStrings.NoResultsFound, query));
Commands\AppHostConnectionResultHandler.cs (2)
15interactionService.DisplayError(errorMessage); 28interactionService.DisplayError(errorMessage);
Commands\AppHostLauncher.cs (3)
830interactionService.DisplayError(RunCommandStrings.FailedToStartAppHost); 849interactionService.DisplayError(RunCommandStrings.FailedToStartAppHost); 853interactionService.DisplayError(failureMessage);
Commands\AppHostStartupTimeout.cs (1)
31interactionService.DisplayError(string.Format(
Commands\BaseCommand.cs (2)
124InteractionService.DisplayError(miscasedOptionError); 202InteractionService.DisplayError(result.ErrorMessage);
Commands\CacheCommand.cs (1)
69InteractionService.DisplayError(errorMessage);
Commands\CertificatesCleanCommand.cs (2)
44InteractionService.DisplayError(details); 45InteractionService.DisplayError(CertificatesCommandStrings.CleanFailure);
Commands\ConfigCommand.cs (7)
103InteractionService.DisplayError(string.Format(CultureInfo.CurrentCulture, ErrorStrings.ConfigurationKeyNotFound, key)); 168InteractionService.DisplayError(ErrorStrings.LegacyAppHostPathCannotBeSetWithConfigCommand); 174InteractionService.DisplayError(ErrorStrings.GlobalAppHostPathCannotBeSetWithConfigCommand); 193InteractionService.DisplayError(errorMessage); 389InteractionService.DisplayError(string.Format(CultureInfo.CurrentCulture, ErrorStrings.ConfigurationKeyNotFound, key)); 423InteractionService.DisplayError(string.Format(CultureInfo.CurrentCulture, ErrorStrings.ConfigurationKeyNotFound, key)); 431InteractionService.DisplayError(errorMessage);
Commands\DashboardRunCommand.cs (3)
427InteractionService.DisplayError(string.Format(CultureInfo.CurrentCulture, DashboardCommandStrings.DashboardFailedToStart, ex.Message)); 487InteractionService.DisplayError(exitMessage); 517InteractionService.DisplayError(GetExitCodeMessage(process.ExitCode));
Commands\DescribeCommand.cs (1)
203InteractionService.DisplayError(string.Format(CultureInfo.CurrentCulture, DescribeCommandStrings.ResourceNotFound, resourceName));
Commands\DocsSearchCommand.cs (1)
70InteractionService.DisplayError(string.Format(CultureInfo.CurrentCulture, DocsCommandStrings.NoResultsFound, query));
Commands\ExportCommand.cs (1)
169InteractionService.DisplayError(string.Format(CultureInfo.CurrentCulture, ExportCommandStrings.ResourceNotFound, resourceName));
Commands\InitCommand.cs (6)
412InteractionService.DisplayError(ex.Message); 417InteractionService.DisplayError(ex.Message); 426InteractionService.DisplayError(ex.Message); 444InteractionService.DisplayError(string.Format(CultureInfo.CurrentCulture, TemplatingStrings.TemplateInstallationFailed, installOutcome.ExitCode)); 465InteractionService.DisplayError(string.Format(CultureInfo.CurrentCulture, InitCommandStrings.FailedToCreateAppHostFromTemplate, result)); 547InteractionService.DisplayError(string.Format(CultureInfo.CurrentCulture, InitCommandStrings.FailedToParseExistingConfig, AspireConfigFile.FileName, configPath, ex.Message));
Commands\IntegrationPackageSearchService.cs (1)
166interactionService.DisplayError(ex.Message);
Commands\IntegrationSearchCommand.cs (3)
184InteractionService.DisplayError(AddCommandStrings.NoPolyglotCompatibleIntegrationsFound); 188InteractionService.DisplayError(string.Format(CultureInfo.CurrentCulture, AddCommandStrings.NoIntegrationPackagesMatchedSearchTerm, searchTerm)); 192InteractionService.DisplayError(AddCommandStrings.NoPackagesFound);
Commands\NewCommand.cs (8)
232InteractionService.DisplayError($"Template '{template.Name}' does not support language '{explicitLanguageId}'."); 244InteractionService.DisplayError($"Template '{template.Name}' does not support language '{explicitLanguageId}'."); 309InteractionService.DisplayError($"Template '{parseResult.CommandResult.Command.Name}' is not available. Ensure the required runtime is installed."); 316InteractionService.DisplayError("No templates are available for the current environment."); 322InteractionService.DisplayError(NewCommandStrings.NonInteractiveTemplateRequired); 331InteractionService.DisplayError("No templates are available for the current environment."); 500InteractionService.DisplayError(NewCommandStrings.SourceWithCredentialsCannotBePersisted); 508InteractionService.DisplayError(string.Format(
Commands\PipelineCommandBase.cs (4)
454InteractionService.DisplayError(errorMessage); 467InteractionService.DisplayError(errorMessage); 480InteractionService.DisplayError(errorMessage); 1136InteractionService.DisplayError(error);
Commands\RenderCommand.cs (5)
203InteractionService.DisplayError($"Unknown render scenario '{choice}'."); 239InteractionService.DisplayError("Something went terribly wrong while attempting to connect to the remote application host. The connection timed out after 30 seconds. Please verify that the host is running and that the network configuration allows traffic on the specified port."); 246InteractionService.DisplayError("This is an error message."); 252InteractionService.DisplayError("Failed to resolve package 'Aspire.Hosting.Azure.CosmosDB' version 9.2.0. The package source 'https://api.nuget.org/v3/index.json' returned a 503 Service Unavailable response. Please check your network connection and try again, or configure an alternative package source in your NuGet.config file."); 386InteractionService.DisplayError("Cancelled.");
Commands\ResourceCommandHelper.cs (4)
103interactionService.DisplayError($"Failed to validate command arguments for command '{commandName}' on resource '{resourceName}':{Environment.NewLine}{errorMessage}"); 108interactionService.DisplayError($"Failed to execute command '{commandName}' on resource '{resourceName}': {errorMessage}"); 146interactionService.DisplayError($"Failed to validate command arguments for command '{commandName}' on resource '{resourceName}':{Environment.NewLine}{errorMessage}"); 151interactionService.DisplayError($"Failed to {baseVerb} resource '{resourceName}': {errorMessage}");
Commands\Sdk\SdkDumpCommand.cs (3)
185InteractionService.DisplayError("Failed to build capability scanner."); 284InteractionService.DisplayError("Failed to build capability scanner."); 312InteractionService.DisplayError("Failed to dump capabilities for one or more integrations.");
Commands\Sdk\SdkExportCommand.cs (4)
198InteractionService.DisplayError("Failed to build the API export scanner."); 233InteractionService.DisplayError(ex.Message); 238InteractionService.DisplayError(ex.Message); 243InteractionService.DisplayError(ex.Message);
Commands\Sdk\SdkGenerateCommand.cs (1)
146InteractionService.DisplayError("Failed to build SDK generation server.");
Commands\StopCommand.cs (7)
142InteractionService.DisplayError(StopCommandStrings.CouldNotDetermineAppHostPath); 174InteractionService.DisplayError(errorMessage); 216InteractionService.DisplayError(SharedCommandStrings.AppHostNotRunning); 245InteractionService.DisplayError(string.Format(CultureInfo.InvariantCulture, StopCommandStrings.MultipleAppHostsNonInteractive, s_appHostOption.Name, s_allOption.Name)); 360InteractionService.DisplayError(StopCommandStrings.DcpCleanupUnavailable); 367InteractionService.DisplayError(string.Format(CultureInfo.CurrentCulture, StopCommandStrings.DcpCleanupFailed, appHostDisplayPath, details)); 522InteractionService.DisplayError(string.Format(CultureInfo.CurrentCulture, StopCommandStrings.FailedToStopAppHost, appHostIdentifier));
Commands\TelemetryCommandHelpers.cs (2)
204interactionService.DisplayError(TelemetryCommandStrings.DashboardUrlAndAppHostExclusive); 329interactionService.DisplayError(errorInfo.Error);
Commands\TelemetryLogsCommand.cs (1)
139_interactionService.DisplayError($"Resource '{resource}' not found.");
Commands\TelemetrySpansCommand.cs (1)
129InteractionService.DisplayError($"Resource '{resource}' not found.");
Commands\TelemetryTracesCommand.cs (2)
141InteractionService.DisplayError(string.Format(CultureInfo.CurrentCulture, TelemetryCommandStrings.TraceNotFound, traceId)); 193InteractionService.DisplayError($"Resource '{resource}' not found.");
Commands\TerminalAttachCommand.cs (7)
86_interactionService.DisplayError("A resource name is required."); 106_interactionService.DisplayError( 118_interactionService.DisplayError(string.Format(CultureInfo.CurrentCulture, 136_interactionService.DisplayError(string.Format(CultureInfo.CurrentCulture, 194_interactionService.DisplayError(string.Format(CultureInfo.CurrentCulture, 221_interactionService.DisplayError(string.Format(CultureInfo.CurrentCulture, 238_interactionService.DisplayError(string.Format(CultureInfo.CurrentCulture,
Commands\TerminalPsCommand.cs (1)
118_interactionService.DisplayError(
Commands\UpdateCommand.cs (1)
697InteractionService.DisplayError(
Commands\WaitCommand.cs (3)
123InteractionService.DisplayError(string.Format(CultureInfo.CurrentCulture, WaitCommandStrings.ResourceNotFound, resourceName)); 129InteractionService.DisplayError(string.Format(CultureInfo.CurrentCulture, WaitCommandStrings.WaitTimedOut, resourceName, statusLabel, timeoutSeconds)); 134InteractionService.DisplayError(string.Format(CultureInfo.CurrentCulture, WaitCommandStrings.ResourceEnteredFailedState, resourceName, response.State ?? response.ErrorMessage));
Projects\GuestAppHostProject.cs (12)
315_interactionService.DisplayError("Failed to prepare AppHost server."); 533_interactionService.DisplayError("App host exited unexpectedly."); 624_interactionService.DisplayError("GuestRuntime not initialized."); 780_interactionService.DisplayError($"Failed to run {DisplayName} AppHost: {ex.Message}"); 1147_interactionService.DisplayError("App host exited unexpectedly."); 1252_interactionService.DisplayError($"Failed to publish {DisplayName} AppHost: {ex.Message}"); 1851_interactionService.DisplayError(summary); 2089_interactionService.DisplayError("GuestRuntime not initialized. This is a bug."); 2103_interactionService.DisplayError($"Failed to initialize {_resolvedLanguage?.DisplayName ?? "guest"} environment."); 2124_interactionService.DisplayError($"Failed to install {_resolvedLanguage?.DisplayName ?? "guest"} dependencies."); 2156_interactionService.DisplayError("GuestRuntime not initialized. This is a bug."); 2180_interactionService.DisplayError("GuestRuntime not initialized. This is a bug.");
Projects\LanguageService.cs (1)
128_interactionService.DisplayError($"Unknown language: '{explicitLanguageId}'");
Projects\ProjectLocator.cs (4)
825interactionService.DisplayError(message); 838interactionService.DisplayError(message); 850interactionService.DisplayError(message); 870interactionService.DisplayError(string.Format(CultureInfo.CurrentCulture, ErrorStrings.ConfiguredAppHostPathHasInvalidCharacters, configFilePath, fieldName));
Scaffolding\ScaffoldingService.cs (5)
148_interactionService.DisplayError("Failed to build AppHost server."); 176_interactionService.DisplayError(TemplatingStrings.ProjectAlreadyExists); 306_interactionService.DisplayError($"Failed to parse root package.json: {ex.Message}"); 441_interactionService.DisplayError($"Failed to initialize {language.DisplayName} environment."); 469_interactionService.DisplayError($"Failed to install {language.DisplayName} dependencies.");
Templating\CliTemplateFactory.EmptyTemplate.cs (3)
19_interactionService.DisplayError("Language selection is required."); 26_interactionService.DisplayError($"Unknown language: '{languageId}'"); 121_interactionService.DisplayError($"Failed to create project files: {ex.Message}");
Templating\CliTemplateFactory.GoStarterTemplate.cs (4)
25_interactionService.DisplayError("Unable to determine Aspire version for the Go starter template."); 80_interactionService.DisplayError("Automatic 'aspire restore' is unavailable for the new Go starter project because no Go AppHost SDK generator was found."); 88_interactionService.DisplayError("Automatic 'aspire restore' failed for the new Go starter project. Run 'aspire restore' in the project directory for more details."); 103_interactionService.DisplayError($"Failed to create project files: {ex.Message}");
Templating\CliTemplateFactory.JavaStarterTemplate.cs (4)
25_interactionService.DisplayError("Unable to determine Aspire version for the Java starter template."); 80_interactionService.DisplayError("Automatic 'aspire restore' is unavailable for the new Java starter project because no Java AppHost SDK generator was found."); 88_interactionService.DisplayError("Automatic 'aspire restore' failed for the new Java starter project. Run 'aspire restore' in the project directory for more details."); 103_interactionService.DisplayError($"Failed to create project files: {ex.Message}");
Templating\CliTemplateFactory.PythonStarterTemplate.cs (4)
26_interactionService.DisplayError("Unable to determine Aspire version for the Python starter template."); 94_interactionService.DisplayError("Automatic 'aspire restore' is unavailable for the new Python starter project because no TypeScript AppHost SDK generator was found."); 102_interactionService.DisplayError("Automatic 'aspire restore' failed for the new Python starter project. Run 'aspire restore' in the project directory for more details."); 117_interactionService.DisplayError($"Failed to create project files: {ex.Message}");
Templating\CliTemplateFactory.TypeScriptStarterTemplate.cs (4)
26_interactionService.DisplayError("Unable to determine Aspire version for the TypeScript starter template."); 78_interactionService.DisplayError("Automatic 'aspire restore' is unavailable for the new TypeScript starter project because no TypeScript AppHost SDK generator was found."); 86_interactionService.DisplayError("Automatic 'aspire restore' failed for the new TypeScript starter project. Run 'aspire restore' in the project directory for more details."); 101_interactionService.DisplayError($"Failed to create project files: {ex.Message}");
Templating\DotNetTemplateFactory.cs (6)
487interactionService.DisplayError(string.Format(CultureInfo.CurrentCulture, TemplatingStrings.TemplateInstallationFailed, installOutcome.ExitCode)); 521interactionService.DisplayError(TemplatingStrings.ProjectAlreadyExists); 526interactionService.DisplayError(string.Format(CultureInfo.CurrentCulture, TemplatingStrings.ProjectCreationFailed, newProjectExitCode)); 573interactionService.DisplayError(ex.Message); 578interactionService.DisplayError(ex.Message); 587interactionService.DisplayError(ex.Message);
Templating\OutputPathHelper.cs (1)
32interactionService.DisplayError(earlyError);
Utils\AppHostHelper.cs (4)
46interactionService.DisplayError(string.Format(CultureInfo.CurrentCulture, ErrorStrings.ProjectCouldNotBeAnalyzed, logFilePath)); 52interactionService.DisplayError(ErrorStrings.ProjectIsNotAppHost); 58interactionService.DisplayError(ErrorStrings.CouldNotParseAspireSDKVersion); 65interactionService.DisplayError(string.Format(CultureInfo.CurrentCulture, ErrorStrings.AspireSDKVersionNotSupported, aspireHostingVersion));
Utils\SdkInstallHelper.cs (1)
55interactionService.DisplayError(sdkErrorMessage);
Aspire.Cli.Tests (1)
Commands\UpdateCommandTests.cs (1)
3532public void DisplayError(string errorMessage, bool allowMarkup = false) => _innerService.DisplayError(errorMessage, allowMarkup);