8 implementations of DisplayError
aspire (2)
Interaction\ConsoleInteractionService.cs (1)
495
public void
DisplayError
(string errorMessage, bool allowMarkup = false)
Interaction\ExtensionInteractionService.cs (1)
388
public void
DisplayError
(string errorMessage, bool allowMarkup = false)
Aspire.Cli.Tests (6)
Commands\PublishCommandPromptingIntegrationTests.cs (1)
1241
public void
DisplayError
(string errorMessage, bool allowMarkup = false) => DisplayedErrors.Add(errorMessage);
Commands\UpdateCommandTests.cs (1)
3532
public void
DisplayError
(string errorMessage, bool allowMarkup = false) => _innerService.DisplayError(errorMessage, allowMarkup);
Projects\ExtensionGuestLauncherTests.cs (1)
172
public void
DisplayError
(string errorMessage, bool allowMarkup = false) => throw new NotImplementedException();
Templating\DotNetTemplateFactoryTests.cs (1)
404
public void
DisplayError
(string message, bool allowMarkup = false) { }
TestServices\TestExtensionInteractionService.cs (1)
112
public void
DisplayError
(string errorMessage, bool allowMarkup = false)
TestServices\TestInteractionService.cs (1)
243
public void
DisplayError
(string errorMessage, bool allowMarkup = false)
150 references to DisplayError
aspire (149)
Commands\AgentInitCommand.cs (6)
232
InteractionService.
DisplayError
(ex.Message);
315
InteractionService.
DisplayError
(bundleInstallFailureMessage);
420
InteractionService.
DisplayError
(message!);
433
InteractionService.
DisplayError
(ex.Message);
451
InteractionService.
DisplayError
(ex.Message);
748
InteractionService.
DisplayError
(
Commands\ApiListCommand.cs (1)
61
InteractionService.
DisplayError
(string.Format(CultureInfo.CurrentCulture, ApiCommandStrings.NoApiEntriesFound, scope));
Commands\ApiSearchCommand.cs (1)
75
InteractionService.
DisplayError
(string.Format(CultureInfo.CurrentCulture, ApiCommandStrings.NoResultsFound, query));
Commands\AppHostConnectionResultHandler.cs (2)
15
interactionService.
DisplayError
(errorMessage);
28
interactionService.
DisplayError
(errorMessage);
Commands\AppHostLauncher.cs (3)
830
interactionService.
DisplayError
(RunCommandStrings.FailedToStartAppHost);
849
interactionService.
DisplayError
(RunCommandStrings.FailedToStartAppHost);
853
interactionService.
DisplayError
(failureMessage);
Commands\AppHostStartupTimeout.cs (1)
31
interactionService.
DisplayError
(string.Format(
Commands\BaseCommand.cs (2)
124
InteractionService.
DisplayError
(miscasedOptionError);
202
InteractionService.
DisplayError
(result.ErrorMessage);
Commands\CacheCommand.cs (1)
69
InteractionService.
DisplayError
(errorMessage);
Commands\CertificatesCleanCommand.cs (2)
44
InteractionService.
DisplayError
(details);
45
InteractionService.
DisplayError
(CertificatesCommandStrings.CleanFailure);
Commands\ConfigCommand.cs (7)
103
InteractionService.
DisplayError
(string.Format(CultureInfo.CurrentCulture, ErrorStrings.ConfigurationKeyNotFound, key));
168
InteractionService.
DisplayError
(ErrorStrings.LegacyAppHostPathCannotBeSetWithConfigCommand);
174
InteractionService.
DisplayError
(ErrorStrings.GlobalAppHostPathCannotBeSetWithConfigCommand);
193
InteractionService.
DisplayError
(errorMessage);
389
InteractionService.
DisplayError
(string.Format(CultureInfo.CurrentCulture, ErrorStrings.ConfigurationKeyNotFound, key));
423
InteractionService.
DisplayError
(string.Format(CultureInfo.CurrentCulture, ErrorStrings.ConfigurationKeyNotFound, key));
431
InteractionService.
DisplayError
(errorMessage);
Commands\DashboardRunCommand.cs (3)
427
InteractionService.
DisplayError
(string.Format(CultureInfo.CurrentCulture, DashboardCommandStrings.DashboardFailedToStart, ex.Message));
487
InteractionService.
DisplayError
(exitMessage);
517
InteractionService.
DisplayError
(GetExitCodeMessage(process.ExitCode));
Commands\DescribeCommand.cs (1)
203
InteractionService.
DisplayError
(string.Format(CultureInfo.CurrentCulture, DescribeCommandStrings.ResourceNotFound, resourceName));
Commands\DocsSearchCommand.cs (1)
70
InteractionService.
DisplayError
(string.Format(CultureInfo.CurrentCulture, DocsCommandStrings.NoResultsFound, query));
Commands\ExportCommand.cs (1)
169
InteractionService.
DisplayError
(string.Format(CultureInfo.CurrentCulture, ExportCommandStrings.ResourceNotFound, resourceName));
Commands\InitCommand.cs (6)
412
InteractionService.
DisplayError
(ex.Message);
417
InteractionService.
DisplayError
(ex.Message);
426
InteractionService.
DisplayError
(ex.Message);
444
InteractionService.
DisplayError
(string.Format(CultureInfo.CurrentCulture, TemplatingStrings.TemplateInstallationFailed, installOutcome.ExitCode));
465
InteractionService.
DisplayError
(string.Format(CultureInfo.CurrentCulture, InitCommandStrings.FailedToCreateAppHostFromTemplate, result));
547
InteractionService.
DisplayError
(string.Format(CultureInfo.CurrentCulture, InitCommandStrings.FailedToParseExistingConfig, AspireConfigFile.FileName, configPath, ex.Message));
Commands\IntegrationPackageSearchService.cs (1)
166
interactionService.
DisplayError
(ex.Message);
Commands\IntegrationSearchCommand.cs (3)
184
InteractionService.
DisplayError
(AddCommandStrings.NoPolyglotCompatibleIntegrationsFound);
188
InteractionService.
DisplayError
(string.Format(CultureInfo.CurrentCulture, AddCommandStrings.NoIntegrationPackagesMatchedSearchTerm, searchTerm));
192
InteractionService.
DisplayError
(AddCommandStrings.NoPackagesFound);
Commands\NewCommand.cs (8)
232
InteractionService.
DisplayError
($"Template '{template.Name}' does not support language '{explicitLanguageId}'.");
244
InteractionService.
DisplayError
($"Template '{template.Name}' does not support language '{explicitLanguageId}'.");
309
InteractionService.
DisplayError
($"Template '{parseResult.CommandResult.Command.Name}' is not available. Ensure the required runtime is installed.");
316
InteractionService.
DisplayError
("No templates are available for the current environment.");
322
InteractionService.
DisplayError
(NewCommandStrings.NonInteractiveTemplateRequired);
331
InteractionService.
DisplayError
("No templates are available for the current environment.");
500
InteractionService.
DisplayError
(NewCommandStrings.SourceWithCredentialsCannotBePersisted);
508
InteractionService.
DisplayError
(string.Format(
Commands\PipelineCommandBase.cs (4)
454
InteractionService.
DisplayError
(errorMessage);
467
InteractionService.
DisplayError
(errorMessage);
480
InteractionService.
DisplayError
(errorMessage);
1136
InteractionService.
DisplayError
(error);
Commands\RenderCommand.cs (5)
203
InteractionService.
DisplayError
($"Unknown render scenario '{choice}'.");
239
InteractionService.
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.");
246
InteractionService.
DisplayError
("This is an error message.");
252
InteractionService.
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.");
386
InteractionService.
DisplayError
("Cancelled.");
Commands\ResourceCommandHelper.cs (4)
103
interactionService.
DisplayError
($"Failed to validate command arguments for command '{commandName}' on resource '{resourceName}':{Environment.NewLine}{errorMessage}");
108
interactionService.
DisplayError
($"Failed to execute command '{commandName}' on resource '{resourceName}': {errorMessage}");
146
interactionService.
DisplayError
($"Failed to validate command arguments for command '{commandName}' on resource '{resourceName}':{Environment.NewLine}{errorMessage}");
151
interactionService.
DisplayError
($"Failed to {baseVerb} resource '{resourceName}': {errorMessage}");
Commands\Sdk\SdkDumpCommand.cs (3)
185
InteractionService.
DisplayError
("Failed to build capability scanner.");
284
InteractionService.
DisplayError
("Failed to build capability scanner.");
312
InteractionService.
DisplayError
("Failed to dump capabilities for one or more integrations.");
Commands\Sdk\SdkExportCommand.cs (4)
198
InteractionService.
DisplayError
("Failed to build the API export scanner.");
233
InteractionService.
DisplayError
(ex.Message);
238
InteractionService.
DisplayError
(ex.Message);
243
InteractionService.
DisplayError
(ex.Message);
Commands\Sdk\SdkGenerateCommand.cs (1)
146
InteractionService.
DisplayError
("Failed to build SDK generation server.");
Commands\StopCommand.cs (7)
142
InteractionService.
DisplayError
(StopCommandStrings.CouldNotDetermineAppHostPath);
174
InteractionService.
DisplayError
(errorMessage);
216
InteractionService.
DisplayError
(SharedCommandStrings.AppHostNotRunning);
245
InteractionService.
DisplayError
(string.Format(CultureInfo.InvariantCulture, StopCommandStrings.MultipleAppHostsNonInteractive, s_appHostOption.Name, s_allOption.Name));
360
InteractionService.
DisplayError
(StopCommandStrings.DcpCleanupUnavailable);
367
InteractionService.
DisplayError
(string.Format(CultureInfo.CurrentCulture, StopCommandStrings.DcpCleanupFailed, appHostDisplayPath, details));
522
InteractionService.
DisplayError
(string.Format(CultureInfo.CurrentCulture, StopCommandStrings.FailedToStopAppHost, appHostIdentifier));
Commands\TelemetryCommandHelpers.cs (2)
204
interactionService.
DisplayError
(TelemetryCommandStrings.DashboardUrlAndAppHostExclusive);
329
interactionService.
DisplayError
(errorInfo.Error);
Commands\TelemetryLogsCommand.cs (1)
139
_interactionService.
DisplayError
($"Resource '{resource}' not found.");
Commands\TelemetrySpansCommand.cs (1)
129
InteractionService.
DisplayError
($"Resource '{resource}' not found.");
Commands\TelemetryTracesCommand.cs (2)
141
InteractionService.
DisplayError
(string.Format(CultureInfo.CurrentCulture, TelemetryCommandStrings.TraceNotFound, traceId));
193
InteractionService.
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)
697
InteractionService.
DisplayError
(
Commands\WaitCommand.cs (3)
123
InteractionService.
DisplayError
(string.Format(CultureInfo.CurrentCulture, WaitCommandStrings.ResourceNotFound, resourceName));
129
InteractionService.
DisplayError
(string.Format(CultureInfo.CurrentCulture, WaitCommandStrings.WaitTimedOut, resourceName, statusLabel, timeoutSeconds));
134
InteractionService.
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)
825
interactionService.
DisplayError
(message);
838
interactionService.
DisplayError
(message);
850
interactionService.
DisplayError
(message);
870
interactionService.
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)
487
interactionService.
DisplayError
(string.Format(CultureInfo.CurrentCulture, TemplatingStrings.TemplateInstallationFailed, installOutcome.ExitCode));
521
interactionService.
DisplayError
(TemplatingStrings.ProjectAlreadyExists);
526
interactionService.
DisplayError
(string.Format(CultureInfo.CurrentCulture, TemplatingStrings.ProjectCreationFailed, newProjectExitCode));
573
interactionService.
DisplayError
(ex.Message);
578
interactionService.
DisplayError
(ex.Message);
587
interactionService.
DisplayError
(ex.Message);
Templating\OutputPathHelper.cs (1)
32
interactionService.
DisplayError
(earlyError);
Utils\AppHostHelper.cs (4)
46
interactionService.
DisplayError
(string.Format(CultureInfo.CurrentCulture, ErrorStrings.ProjectCouldNotBeAnalyzed, logFilePath));
52
interactionService.
DisplayError
(ErrorStrings.ProjectIsNotAppHost);
58
interactionService.
DisplayError
(ErrorStrings.CouldNotParseAspireSDKVersion);
65
interactionService.
DisplayError
(string.Format(CultureInfo.CurrentCulture, ErrorStrings.AspireSDKVersionNotSupported, aspireHostingVersion));
Utils\SdkInstallHelper.cs (1)
55
interactionService.
DisplayError
(sdkErrorMessage);
Aspire.Cli.Tests (1)
Commands\UpdateCommandTests.cs (1)
3532
public void DisplayError(string errorMessage, bool allowMarkup = false) => _innerService.
DisplayError
(errorMessage, allowMarkup);