113 references to ErrorStrings
aspire (81)
Backchannel\AppHostCliBackchannel.cs (3)
313
throw new InvalidOperationException(
ErrorStrings
.AlreadyConnectedToBackchannel);
358
string.Format(CultureInfo.CurrentCulture,
ErrorStrings
.AppHostIncompatibleWithCli, BaselineCapability),
386
string.Format(CultureInfo.CurrentCulture,
ErrorStrings
.AppHostIncompatibleWithCli, BaselineCapability),
Backchannel\ExtensionBackchannel.cs (9)
83
?? throw new InvalidOperationException(
ErrorStrings
.ExtensionTokenMustBeSet);
253
throw new ArgumentException(string.Format(CultureInfo.CurrentCulture,
ErrorStrings
.InvalidSocketPath, endpoint));
305
string.Format(CultureInfo.CurrentCulture,
ErrorStrings
.ExtensionIncompatibleWithCli,
321
string.Format(CultureInfo.CurrentCulture,
ErrorStrings
.ExtensionIncompatibleWithCli,
525
throw new ExtensionOperationCanceledException(string.Format(CultureInfo.CurrentCulture,
ErrorStrings
.NoSelectionMade, promptText));
555
throw new ExtensionOperationCanceledException(string.Format(CultureInfo.CurrentCulture,
ErrorStrings
.NoSelectionMade, promptText));
579
throw new ExtensionOperationCanceledException(string.Format(CultureInfo.CurrentCulture,
ErrorStrings
.NoSelectionMade, promptText));
605
throw new ExtensionOperationCanceledException(string.Format(CultureInfo.CurrentCulture,
ErrorStrings
.NoSelectionMade, promptText));
631
throw new ExtensionOperationCanceledException(string.Format(CultureInfo.CurrentCulture,
ErrorStrings
.NoSelectionMade, promptText));
Certificates\CertificateService.cs (4)
104
interactionService.DisplayMessage(KnownEmojis.Warning, string.Format(CultureInfo.CurrentCulture,
ErrorStrings
.CertificateGenerationFailed, generateResult));
110
interactionService.DisplayMessage(KnownEmojis.Warning,
ErrorStrings
.CertificatesPartiallyTrustedNonInteractive);
114
interactionService.DisplayMessage(KnownEmojis.Warning,
ErrorStrings
.CertificatesNotTrustedNonInteractive);
143
interactionService.DisplayMessage(KnownEmojis.Warning, string.Format(CultureInfo.CurrentCulture,
ErrorStrings
.CertificatesMayNotBeFullyTrusted, trustResultCode));
CliExecutionContext.cs (1)
63
?? throw new InvalidOperationException(
ErrorStrings
.UnableToRetrieveAssemblyVersion);
Commands\ConfigCommand.cs (11)
80
return CommandResult.Failure(CliExitCodes.InvalidCommand,
ErrorStrings
.ConfigurationKeyRequired);
103
InteractionService.DisplayError(string.Format(CultureInfo.CurrentCulture,
ErrorStrings
.ConfigurationKeyNotFound, key));
140
return CommandResult.Failure(CliExitCodes.InvalidCommand,
ErrorStrings
.ConfigurationKeyRequired);
145
return CommandResult.Failure(CliExitCodes.InvalidCommand,
ErrorStrings
.ConfigurationValueRequired);
168
InteractionService.DisplayError(
ErrorStrings
.LegacyAppHostPathCannotBeSetWithConfigCommand);
174
InteractionService.DisplayError(
ErrorStrings
.GlobalAppHostPathCannotBeSetWithConfigCommand);
191
var errorMessage = string.Format(CultureInfo.CurrentCulture,
ErrorStrings
.ErrorSettingConfiguration, ex.Message);
376
return CommandResult.Failure(CliExitCodes.InvalidCommand,
ErrorStrings
.ConfigurationKeyRequired);
389
InteractionService.DisplayError(string.Format(CultureInfo.CurrentCulture,
ErrorStrings
.ConfigurationKeyNotFound, key));
423
InteractionService.DisplayError(string.Format(CultureInfo.CurrentCulture,
ErrorStrings
.ConfigurationKeyNotFound, key));
429
var errorMessage = string.Format(CultureInfo.CurrentCulture,
ErrorStrings
.ErrorDeletingConfiguration, ex.Message);
Commands\Sdk\SdkExportCommand.cs (2)
117
ErrorStrings
.SdkExportLanguageDoesNotSupportCodeGeneration,
137
ErrorStrings
.SdkExportGeneratorPackageNotExportable,
Commands\UpdateCommand.cs (1)
425
if (string.Equals(ex.Message,
ErrorStrings
.NoProjectFileFound, StringComparisons.CliInputOrOutput))
Configuration\AspireConfigFile.cs (1)
147
string.Format(CultureInfo.CurrentCulture,
ErrorStrings
.InvalidJsonInConfigFile, filePath, ex.Message),
Configuration\ConfigurationService.cs (1)
479
string.Format(CultureInfo.CurrentCulture,
ErrorStrings
.InvalidJsonInConfigFile, filePath, ex.Message),
DotNet\DotNetCliRunner.cs (2)
903
var ex = new InvalidOperationException(
ErrorStrings
.CantUseBothWatchAndNoBuild);
1134
throw new InvalidOperationException(
ErrorStrings
.FailedToParseTemplateVersionFromStdout);
NuGet\BundleNuGetPackageCache.cs (2)
215
throw new NuGetPackageCacheException(string.Format(CultureInfo.CurrentCulture,
ErrorStrings
.FailedToSearchForPackages, exitCode));
267
throw new NuGetPackageCacheException(
ErrorStrings
.FailedToParsePackageSearchResults);
NuGet\NuGetPackageCache.cs (3)
84
}) ?? throw new NuGetPackageCacheException(
ErrorStrings
.FailedToRetrieveCachedTemplatePackages);
144
throw new NuGetPackageCacheException(string.Format(CultureInfo.CurrentCulture,
ErrorStrings
.FailedToSearchForPackages, result.ExitCode));
210
throw new NuGetPackageCacheException(string.Format(CultureInfo.CurrentCulture,
ErrorStrings
.FailedToSearchForPackages, result.ExitCode));
Program.cs (3)
206
ErrorStrings
.GlobalAppHostPathIgnored,
787
errorMessage = string.Format(CultureInfo.CurrentCulture,
ErrorStrings
.UnsupportedLocaleProvided, localeOverride, string.Join(", ", LocaleHelpers.SupportedLocales));
790
errorMessage = string.Format(CultureInfo.CurrentCulture,
ErrorStrings
.InvalidLocaleProvided, localeOverride);
Projects\GuestAppHostProject.cs (5)
1661
$"[yellow]{Markup.Escape(
ErrorStrings
.LegacyTypeScriptAppHostWarning)}[/]",
1793
ErrorStrings
.CodegenVersionSkewWarning,
1849
ErrorStrings
.CodegenIncompatibleSdkSummary,
1874
_interactionService.DisplayMessage(KnownEmojis.Information, $"[grey]{Markup.Escape(
ErrorStrings
.CodegenDebugHint)}[/]", allowMarkup: true);
1878
_interactionService.DisplayMessage(KnownEmojis.Microscope, $"[grey]{Markup.Escape(
ErrorStrings
.CodegenDebugHeader)}[/]", allowMarkup: true);
Projects\PrebuiltAppHostServer.cs (2)
704
ErrorStrings
.IntegrationBuildPackageDowngradeFailed,
706
:
ErrorStrings
.IntegrationBuildFailed;
Projects\ProjectLocator.cs (22)
371
interactionService.DisplayRawText(
ErrorStrings
.DotNetSdkUnavailableAppHostDiscoveryWarning, ConsoleOutput.Error);
414
interactionService.DisplayMessage(KnownEmojis.Warning, string.Format(CultureInfo.CurrentCulture,
ErrorStrings
.ProjectFileUnsupportedInCurrentEnvironment, relativePath));
428
interactionService.DisplayMessage(KnownEmojis.Warning, string.Format(CultureInfo.CurrentCulture,
ErrorStrings
.ProjectFileMayBeUnbuildableAppHost, relativePath));
513
interactionService.DisplayMessage(KnownEmojis.Warning, string.Format(CultureInfo.CurrentCulture,
ErrorStrings
.ProjectFileUnsupportedInCurrentEnvironment, relativePath));
538
interactionService.DisplayMessage(KnownEmojis.Warning, string.Format(CultureInfo.CurrentCulture,
ErrorStrings
.ProjectFileMayBeUnbuildableAppHost, settingsAppHostRelativePath));
549
interactionService.DisplayMessage(KnownEmojis.Warning, string.Format(CultureInfo.CurrentCulture,
ErrorStrings
.ProjectFileUnsupportedInCurrentEnvironment, settingsAppHostRelativePath));
734
interactionService.DisplayMessage(KnownEmojis.Warning, string.Format(CultureInfo.CurrentCulture,
ErrorStrings
.AppHostWasSpecifiedButDoesntExist, configFilePath, qualifiedPath));
794
interactionService.DisplayMessage(KnownEmojis.Warning, string.Format(CultureInfo.CurrentCulture,
ErrorStrings
.AppHostWasSpecifiedButDoesntExist, settingsFile.FullName, qualifiedAppHostPath));
803
var message = string.Format(CultureInfo.CurrentCulture,
ErrorStrings
.InvalidJsonInConfigFile, settingsFile.FullName, ex.Message);
822
var message = string.Format(CultureInfo.CurrentCulture,
ErrorStrings
.ConfigurationFileMustBeJsonObject, configFilePath);
835
var message = string.Format(CultureInfo.CurrentCulture,
ErrorStrings
.ConfiguredAppHostPathMustBeString, configFilePath, fieldName);
870
interactionService.DisplayError(string.Format(CultureInfo.CurrentCulture,
ErrorStrings
.ConfiguredAppHostPathHasInvalidCharacters, configFilePath, fieldName));
951
throw new ProjectLocatorException(
ErrorStrings
.AppHostsMayNotBeBuildable, ProjectLocatorFailureReason.AppHostsMayNotBeBuildable);
956
throw new ProjectLocatorException(
ErrorStrings
.NoProjectFileFound, ProjectLocatorFailureReason.UnsupportedProjects);
960
throw new ProjectLocatorException(
ErrorStrings
.ProjectFileDoesntExist, ProjectLocatorFailureReason.ProjectFileDoesntExist);
988
throw new ProjectLocatorException(
ErrorStrings
.MultipleProjectFilesFound, ProjectLocatorFailureReason.MultipleProjectFilesFound);
1017
throw new ProjectLocatorException(
ErrorStrings
.ProjectFileDoesntExist, ProjectLocatorFailureReason.ProjectFileDoesntExist);
1067
throw new ProjectLocatorException(
ErrorStrings
.ProjectFileDoesntExist, ProjectLocatorFailureReason.ProjectFileDoesntExist);
1111
throw new ProjectLocatorException(
ErrorStrings
.NoProjectFileFound, ProjectLocatorFailureReason.UnsupportedProjects);
1115
throw new ProjectLocatorException(
ErrorStrings
.NoProjectFileFound, ProjectLocatorFailureReason.NoProjectFileFound);
1126
throw new ProjectLocatorException(
ErrorStrings
.AppHostsMayNotBeBuildable, ProjectLocatorFailureReason.AppHostsMayNotBeBuildable);
1159
MultipleAppHostProjectsFoundBehavior.Throw => throw new ProjectLocatorException(
ErrorStrings
.MultipleProjectFilesFound, ProjectLocatorFailureReason.MultipleProjectFilesFound),
Resources\ErrorStrings.Designer.cs (1)
36
System.Resources.ResourceManager temp = new System.Resources.ResourceManager("Aspire.Cli.Resources.ErrorStrings", typeof(
ErrorStrings
).Assembly);
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\ConfigurationHelper.cs (1)
278
string.Format(CultureInfo.CurrentCulture,
ErrorStrings
.InvalidJsonInConfigFile, filePath, ex.Message),
Utils\MissingJavaScriptToolWarning.cs (1)
37
return string.Format(CultureInfo.CurrentCulture,
ErrorStrings
.ProjectFilesCreatedButNodeToolsNotFound, installCommand, installDisplayName);
Utils\SdkInstallHelper.cs (1)
52
ErrorStrings
.MinimumSdkVersionNotMet,
Utils\VersionHelper.cs (1)
73
return PackageUpdateHelpers.GetCurrentAssemblyVersion() ?? throw new InvalidOperationException(
ErrorStrings
.UnableToRetrieveAssemblyVersion);
Aspire.Cli.Tests (32)
Backchannel\AppHostConnectionResolverTests.cs (1)
154
throw new ProjectLocatorException(
ErrorStrings
.AppHostsMayNotBeBuildable, ProjectLocatorFailureReason.AppHostsMayNotBeBuildable)
Certificates\CertificateServiceTests.cs (1)
618
var expectedMessage = string.Format(System.Globalization.CultureInfo.CurrentCulture,
ErrorStrings
.CertificateGenerationFailed, EnsureCertificateResult.ErrorCreatingTheCertificate);
Commands\ConfigCommandTests.cs (7)
915
[InlineData("appHost.path", nameof(
ErrorStrings
.GlobalAppHostPathCannotBeSetWithConfigCommand))]
916
[InlineData("appHost:path", nameof(
ErrorStrings
.GlobalAppHostPathCannotBeSetWithConfigCommand))]
917
[InlineData("appHostPath", nameof(
ErrorStrings
.LegacyAppHostPathCannotBeSetWithConfigCommand))]
980
nameof(
ErrorStrings
.GlobalAppHostPathCannotBeSetWithConfigCommand) =>
ErrorStrings
.GlobalAppHostPathCannotBeSetWithConfigCommand,
981
nameof(
ErrorStrings
.LegacyAppHostPathCannotBeSetWithConfigCommand) =>
ErrorStrings
.LegacyAppHostPathCannotBeSetWithConfigCommand,
Commands\RunCommandTests.cs (1)
1057
Assert.Contains(
ErrorStrings
.ProjectIsNotAppHost, interactionService.DisplayedErrors);
Commands\UpdateCommandTests.cs (3)
262
throw new ProjectLocatorException(
ErrorStrings
.NoProjectFileFound, ProjectLocatorFailureReason.NoProjectFileFound);
1327
throw new ProjectLocatorException(
ErrorStrings
.NoProjectFileFound, ProjectLocatorFailureReason.NoProjectFileFound);
1417
throw new ProjectLocatorException(
ErrorStrings
.NoProjectFileFound, ProjectLocatorFailureReason.NoProjectFileFound);
DotNetSdkInstallerTests.cs (1)
226
ErrorStrings
.ResourceManager.GetString("MinimumSdkVersionNotMet", CultureInfo.GetCultureInfo("en-US"))!,
Projects\GuestAppHostProjectTests.cs (4)
1328
Assert.Equal(
ErrorStrings
.LegacyTypeScriptAppHostWarning, Markup.Remove(m.Message));
1339
/// <see cref="
ErrorStrings
.CodegenVersionSkewWarning"/> when the on-disk SDK version
1402
ErrorStrings
.CodegenVersionSkewWarning,
1426
Assert.Equal(
ErrorStrings
.LegacyTypeScriptAppHostWarning, Markup.Remove(m.Message));
Projects\PrebuiltAppHostServerTests.cs (1)
347
Assert.Equal(
ErrorStrings
.IntegrationBuildFailed, PrebuiltAppHostServer.GetIntegrationBuildFailureMessage(output));
Projects\ProjectLocatorTests.cs (13)
496
Assert.Equal(
ErrorStrings
.ProjectFileDoesntExist, ex.Message);
647
Assert.Equal(
ErrorStrings
.AppHostsMayNotBeBuildable, ex.Message);
678
Assert.Equal(
ErrorStrings
.ProjectFileDoesntExist, ex.Message);
710
Assert.Equal(
ErrorStrings
.ProjectFileDoesntExist, ex.Message);
949
var exception = new ProjectLocatorException(
ErrorStrings
.NoProjectFileFound, ProjectLocatorFailureReason.NoProjectFileFound);
1375
Assert.Equal(
ErrorStrings
.NoProjectFileFound, ex.Message);
1984
Assert.Equal(
ErrorStrings
.ProjectFileDoesntExist, ex.Message);
2055
Assert.Equal(
ErrorStrings
.ProjectFileDoesntExist, ex.Message);
2300
Assert.Equal(
ErrorStrings
.ProjectFileDoesntExist, ex.Message);
2364
Assert.Equal(
ErrorStrings
.AppHostsMayNotBeBuildable, ex.Message);
2411
Assert.Equal(
ErrorStrings
.ProjectFileDoesntExist, ex.Message);
2539
Assert.Equal(
ErrorStrings
.ProjectFileDoesntExist, ex.Message);
2885
Assert.Equal(
ErrorStrings
.DotNetSdkUnavailableAppHostDiscoveryWarning, warning.Text);