Skip to content

[release/13.4] Add embedded Aspire skills fallback#17548

Merged
davidfowl merged 3 commits into
release/13.4from
dapine/manual-backport-17537
May 27, 2026
Merged

[release/13.4] Add embedded Aspire skills fallback#17548
davidfowl merged 3 commits into
release/13.4from
dapine/manual-backport-17537

Conversation

@IEvangelist
Copy link
Copy Markdown
Member

@IEvangelist IEvangelist commented May 27, 2026

Backport of #17537 to release/13.4

Customer Impact

Customers running Aspire CLI agent initialization can be blocked when the Aspire skills bundle cannot be acquired from an existing cache or GitHub release assets. This backport adds an embedded, validated skills bundle fallback so the CLI can continue installing Aspire agent skills when online acquisition is unavailable.

Testing

Source PR validation covered restore, bundle update/verify scripts, GitHub attestation verification, UpdateXlf, targeted Aspire.Cli tests, Aspire.Cli build, and diff check. Manual release/13.4 backport validation covered restore, UpdateXlf, and targeted Aspire.Cli tests for AgentInitCommandTests and AspireSkillsInstallerTests.

Risk

Low. The change is scoped to Aspire CLI skills bundle acquisition, embedded fallback metadata, and refresh automation; existing attestation/hash validation and safe archive extraction paths remain in use.

Regression?

Unknown - the source PR did not link an issue or identify an explicit regression.

IEvangelist and others added 2 commits May 27, 2026 10:51
Embed a checked-in Aspire skills bundle snapshot for CLI fallback, make agent init warn instead of fail when bundle acquisition is unavailable, and add automation to refresh the snapshot via a draft PR.

Co-authored-by: IEvangelist <7679720+IEvangelist@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copilot AI review requested due to automatic review settings May 27, 2026 15:58
@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented May 27, 2026

🚀 Dogfood this PR with:

⚠️ WARNING: Do not do this without first carefully reviewing the code of this PR to satisfy yourself it is safe.

curl -fsSL https://raw.githubusercontent.com/microsoft/aspire/main/eng/scripts/get-aspire-cli-pr.sh | bash -s -- 17548

Or

  • Run remotely in PowerShell:
iex "& { $(irm https://raw.githubusercontent.com/microsoft/aspire/main/eng/scripts/get-aspire-cli-pr.ps1) } 17548"

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Backports the embedded Aspire skills bundle fallback to release/13.4 so aspire agent init can proceed when neither a validated cache nor the microsoft/aspire-skills GitHub release asset is available, while keeping hash/attestation validation and safe extraction.

Changes:

  • Add an embedded (assembly resource) Aspire skills bundle + metadata and wire it into AspireSkillsInstaller as a third acquisition source.
  • Change aspire agent init output to emit a single “installed skills” summary instead of per-skill messages.
  • Add automation (scripts + workflows) to verify and refresh the embedded bundle, including draft PR support in the shared create-pull-request action.

Reviewed changes

Copilot reviewed 29 out of 31 changed files in this pull request and generated no comments.

Show a summary per file
File Description
tests/Aspire.Cli.Tests/Commands/AgentInitCommandTests.cs Updates/extends tests to validate the new “installed skills summary” output.
tests/Aspire.Cli.Tests/Agents/AspireSkillsInstallerTests.cs Adds tests covering embedded-bundle fallback behaviors and SHA-256 validation.
src/Aspire.Cli/Resources/xlf/AgentCommandStrings.zh-Hant.xlf Updates localized resources for new summary strings and embedded-fallback messaging.
src/Aspire.Cli/Resources/xlf/AgentCommandStrings.zh-Hans.xlf Updates localized resources for new summary strings and embedded-fallback messaging.
src/Aspire.Cli/Resources/xlf/AgentCommandStrings.tr.xlf Updates localized resources for new summary strings and embedded-fallback messaging.
src/Aspire.Cli/Resources/xlf/AgentCommandStrings.ru.xlf Updates localized resources for new summary strings and embedded-fallback messaging.
src/Aspire.Cli/Resources/xlf/AgentCommandStrings.pt-BR.xlf Updates localized resources for new summary strings and embedded-fallback messaging.
src/Aspire.Cli/Resources/xlf/AgentCommandStrings.pl.xlf Updates localized resources for new summary strings and embedded-fallback messaging.
src/Aspire.Cli/Resources/xlf/AgentCommandStrings.ko.xlf Updates localized resources for new summary strings and embedded-fallback messaging.
src/Aspire.Cli/Resources/xlf/AgentCommandStrings.ja.xlf Updates localized resources for new summary strings and embedded-fallback messaging.
src/Aspire.Cli/Resources/xlf/AgentCommandStrings.it.xlf Updates localized resources for new summary strings and embedded-fallback messaging.
src/Aspire.Cli/Resources/xlf/AgentCommandStrings.fr.xlf Updates localized resources for new summary strings and embedded-fallback messaging.
src/Aspire.Cli/Resources/xlf/AgentCommandStrings.es.xlf Updates localized resources for new summary strings and embedded-fallback messaging.
src/Aspire.Cli/Resources/xlf/AgentCommandStrings.de.xlf Updates localized resources for new summary strings and embedded-fallback messaging.
src/Aspire.Cli/Resources/xlf/AgentCommandStrings.cs.xlf Updates localized resources for new summary strings and embedded-fallback messaging.
src/Aspire.Cli/Resources/AgentCommandStrings.resx Adds new summary string resources and updates GitHub-unavailable messaging to include embedded fallback.
src/Aspire.Cli/Resources/AgentCommandStrings.Designer.cs Regenerates strongly-typed accessors for the updated resources.
src/Aspire.Cli/Program.cs Registers the embedded bundle provider in DI.
src/Aspire.Cli/Commands/AgentInitCommand.cs Aggregates per-skill installs into a single summary message and refactors install result reporting.
src/Aspire.Cli/Aspire.Cli.csproj Embeds the snapshot archive + metadata as assembly resources.
src/Aspire.Cli/Agents/AspireSkills/SkillBundleManifest.cs Adds JSON model + source-gen context entry for embedded bundle metadata.
src/Aspire.Cli/Agents/AspireSkills/EmbeddedAspireSkillsBundleProvider.cs Implements reading embedded snapshot + metadata from assembly resources.
src/Aspire.Cli/Agents/AspireSkills/Embedded/aspire-skills.metadata.json Adds pinned embedded snapshot metadata (version/repo/tag/asset/SHA-256).
src/Aspire.Cli/Agents/AspireSkills/AspireSkillsInstaller.cs Adds embedded acquisition path with SHA-256 verification and fallback logic.
src/Aspire.Cli/Agents/AspireSkills/AspireSkillsBundle.cs Exposes SHA-256 normalization helper for installer reuse.
eng/scripts/verify-aspire-skills-bundle.ps1 Adds script to validate embedded bundle SHA-256 and GitHub attestation.
eng/scripts/update-aspire-skills-bundle.ps1 Adds script to download/attestation-verify a release asset and refresh embedded snapshot + pinned version.
.github/workflows/verify-aspire-skills-bundle.yml Adds CI workflow to verify the embedded snapshot via the verification script.
.github/workflows/update-aspire-skills-bundle.yml Adds scheduled/manual workflow to refresh the embedded snapshot and open a draft PR.
.github/actions/create-pull-request/action.yml Adds a draft input and passes --draft to gh pr create when requested.
Files not reviewed (1)
  • src/Aspire.Cli/Resources/AgentCommandStrings.Designer.cs: Language not supported

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
@github-actions
Copy link
Copy Markdown
Contributor

CLI E2E Tests failed — 106 passed, 1 failed, 2 unknown (commit ad335b8)

Failed Tests

View all recordings
Status Test Recording
AddPackageInteractiveWhileAppHostRunningDetached ▶️ View recording
AddPackageWhileAppHostRunningDetached ▶️ View recording
AgentCommands_AllHelpOutputs_AreCorrect ▶️ View recording
AgentInitCommand_DefaultSelection_InstallsDefaultSkills ▶️ View recording
AgentInitCommand_MigratesDeprecatedConfig ▶️ View recording
AgentMcpListStructuredLogsReturnsLogsFromStarterApp ▶️ View recording
AgentMcpListStructuredLogsReturnsLogsFromStarterApp_DevLocalhost ▶️ View recording
AgentMcpListStructuredLogsReturnsLogsFromStarterApp_Isolated ▶️ View recording
AllPublishMethodsBuildDockerImages ▶️ View recording
AspireAddAndStartWorkAgainstLegacyAppHostTs ▶️ View recording
AspireAddPackageVersionToDirectoryPackagesProps ▶️ View recording
AspireInitSingleFileAppHostRunsViaDotnetRunAppHost ▶️ View recording
AspireInitWithExistingAppHostDirRecreatesMissingNuGetConfigAndPreservesFiles ▶️ View recording
AspireInitWithSolutionFileGeneratesAppHostThatBuildsAgainstChannelHive ▶️ View recording
AspireStartUpdatesStaleTypeScriptAppHostPath ▶️ View recording
AspireUpdateRemovesAppHostPackageVersionFromDirectoryPackagesProps ▶️ View recording
AspireUpdateRemovesOrphanAppHostPackageVersionWhenSdkAlreadyCurrent ▶️ View recording
Banner_DisplayedOnFirstRun ▶️ View recording
Banner_DisplayedWithExplicitFlag ▶️ View recording
Banner_NotDisplayedWithNoLogoFlag ▶️ View recording
CertificatesClean_RemovesCertificates ▶️ View recording
CertificatesTrust_WithNoCert_CreatesAndTrustsCertificate ▶️ View recording
CertificatesTrust_WithUntrustedCert_TrustsCertificate ▶️ View recording
ConfigSetGet_CreatesNestedJsonFormat ▶️ View recording
CreateAndRunAspireStarterProject ▶️ View recording
CreateAndRunAspireStarterProjectWithBundle ▶️ View recording
CreateAndRunEmptyAppHostProject ▶️ View recording
CreateAndRunJavaEmptyAppHostProject ▶️ View recording
CreateAndRunJsReactProject ▶️ View recording
CreateAndRunPythonReactProject ▶️ View recording
CreateAndRunTypeScriptEmptyAppHostProject ▶️ View recording
CreateAndRunTypeScriptStarterProject ▶️ View recording
CreateJavaAppHostWithViteApp ▶️ View recording
CreateTypeScriptAppHostWithViteApp_AllowsGuestAppPackageManagerToDiffer ▶️ View recording
CreateTypeScriptAppHostWithViteApp_UsesConfiguredToolchain ▶️ View recording
DashboardRunWithAgentMcpListTracesReturnsNoTraces ▶️ View recording
DashboardRunWithAgentMcpListTracesReturnsNoTraces_DevLocalhost ▶️ View recording
DashboardRunWithOtelTracesReturnsNoTraces ▶️ View recording
DashboardRunWithOtelTracesReturnsNoTraces_DevLocalhost ▶️ View recording
DeployK8sBasicApiService ▶️ View recording
DeployK8sWithExternalHelmChart ▶️ View recording
DeployK8sWithGarnet ▶️ View recording
DeployK8sWithMongoDB ▶️ View recording
DeployK8sWithMySql ▶️ View recording
DeployK8sWithPostgres ▶️ View recording
DeployK8sWithRabbitMQ ▶️ View recording
DeployK8sWithRedis ▶️ View recording
DeployK8sWithSqlServer ▶️ View recording
DeployK8sWithValkey ▶️ View recording
DeployTypeScriptAppToKubernetes ▶️ View recording
DescribeCommandResolvesReplicaNames ▶️ View recording
DescribeCommandShowsRunningResources ▶️ View recording
DetachFormatJsonProducesValidJson ▶️ View recording
DetachFormatJsonProducesValidJsonWhenRestartingExistingInstance ▶️ View recording
DoPublishAndDeployListStepsWork ▶️ View recording
DocsCommand_RendersInteractiveMarkdownFromLocalSource ▶️ View recording
DoctorCommand_DetectsDeprecatedAgentConfig ▶️ View recording
DoctorCommand_TypeScriptAppHostReportsMissingConfiguredToolchain ▶️ View recording
DoctorCommand_WithSslCertDir_ShowsTrusted ▶️ View recording
DoctorCommand_WithoutSslCertDir_ShowsPartiallyTrusted ▶️ View recording
GatewayWithoutExternalEndpoint_FailsPublishWithGuidance ▶️ View recording
GeneratedAspireDevScript_StartsWatchMode_WithConfiguredToolchain ▶️ View recording
GlobalMigration_HandlesCommentsAndTrailingCommas ▶️ View recording
GlobalMigration_HandlesMalformedLegacyJson ▶️ View recording
GlobalMigration_PreservesAllValueTypes ▶️ View recording
GlobalMigration_SkipsWhenNewConfigExists ▶️ View recording
GlobalSettings_MigratedFromLegacyFormat ▶️ View recording
IngressWithoutExternalEndpoint_FailsPublishWithGuidance ▶️ View recording
InitTypeScriptAppHost_AugmentsExistingViteRepoInWorkspaceSubdirectory ▶️ View recording
InteractiveCSharpInitCreatesExpectedFiles ▶️ View recording
InvalidAppHostPathWithComments_IsHealedOnRun ▶️ View recording
JavaScriptHostingApisRunFromTypeScriptAppHost ▶️ View recording
LatestCliCanStartStableChannelAppHost ▶️ View failure recording
LatestCliCanStartStableChannelTypeScriptAppHost ▶️ View recording
LegacySettingsMigration_AdjustsRelativeAppHostPath ▶️ View recording
LogsCommandShowsResourceLogs ▶️ View recording
OtelLogsReturnsStructuredLogsFromStarterApp ▶️ View recording
OtelLogsReturnsStructuredLogsFromStarterAppIsolated ▶️ View recording
PsCommandListsRunningAppHost ▶️ View recording
PsFormatJsonOutputsOnlyJsonToStdout ▶️ View recording
PublishJavaScriptPatternsGeneratesExpectedDockerComposeArtifacts ▶️ View recording
PublishWithConfigureEnvFileUpdatesEnvOutput ▶️ View recording
PublishWithDockerComposeServiceCallbackSucceeds ▶️ View recording
PublishWithoutOutputPathUsesAppHostDirectoryDefault ▶️ View recording
ResourceCommand_FailedExecution_DisplaysAppHostLogPathAndLogContainsEntries ▶️ View recording
ResourceCommand_SetAndDeleteParameterUpdatesDescribeOutput ▶️ View recording
RestoreGeneratesSdkFiles ▶️ View recording
RestoreGeneratesSdkFiles_WithConfiguredToolchain ▶️ View recording
RestoreRefreshesGeneratedSdkAfterAddingIntegration ▶️ View recording
RestoreSupportsConfigOnlyHelperPackageAndCrossPackageTypes ▶️ View recording
RunFromParentDirectory_UsesExistingConfigNearAppHost ▶️ View recording
RunReportsSyntaxErrorsForDotNetAppHost ▶️ View recording
RunReportsSyntaxErrorsForTypeScriptAppHost ▶️ View recording
SecretCrudOnDotNetAppHost ▶️ View recording
SecretCrudOnTypeScriptAppHost ▶️ View recording
StagingChannel_ConfigureAndVerifySettings_ThenSwitchChannels ▶️ View recording
StartAndWaitForTypeScriptSqlServerAppHostWithNativeAssets ▶️ View recording
StartReportsSyntaxErrorsForDotNetAppHost ▶️ View recording
StartReportsSyntaxErrorsForTypeScriptAppHost ▶️ View recording
StopAllAppHostsFromAppHostDirectory ▶️ View recording
StopJavaPolyglotAppHostUsingApphostDirectory ▶️ View recording
StopNonInteractiveSingleAppHost ▶️ View recording
StopTypeScriptPolyglotAppHostUsingApphostDirectory ▶️ View recording
StopWithNoRunningAppHostExitsSuccessfully ▶️ View recording
UnAwaitedChainsCompileWithAutoResolvePromises ▶️ View recording
UpdateProjectChannelToStable_CSharpEmptyAppHost_PreservesAspireConfigChannel ▶️ View recording
UpdateProjectChannelToStable_CSharpSingleFileInit_PreservesAspireConfigChannel ▶️ View recording
UpdateProjectChannelToStable_TypeScriptSingleFileInit_PreservesAspireConfigChannel ▶️ View recording
UpdateProjectChannelToStable_TypeScript_PreviewsStablePackagesAndPreservesChannel ▶️ View recording

📹 Recordings uploaded automatically from CI run #26523783214

@davidfowl davidfowl merged commit f18d66b into release/13.4 May 27, 2026
614 of 620 checks passed
@davidfowl davidfowl deleted the dapine/manual-backport-17537 branch May 27, 2026 17:48
@microsoft-github-policy-service microsoft-github-policy-service Bot added this to the 13.4 milestone May 27, 2026
aspire-repo-bot Bot added a commit to microsoft/aspire.dev that referenced this pull request May 27, 2026
Documents changes from microsoft/aspire#17548:
- aspire agent init now shows a consolidated installation summary instead
  of per-skill messages
- Added documentation for the three-tier skill bundle acquisition strategy
  (local cache → GitHub release asset → embedded fallback) so users know
  the command works in air-gapped/offline environments

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
@aspire-repo-bot
Copy link
Copy Markdown
Contributor

Pull request created: #1099

Generated by PR Documentation Check

@aspire-repo-bot
Copy link
Copy Markdown
Contributor

📝 Documentation has been drafted in microsoft/aspire.dev#1099 targeting release/13.4.

Updated src/frontend/src/content/docs/reference/cli/commands/aspire-agent-init.mdx to document two user-facing changes from the source PR:

  • Updated the "Apply selections" step to show the new consolidated installation summary output (Installed Aspire agent skills: / Skills: ... / Locations: ...) instead of per-skill messages.
  • Added a new "Skill bundle acquisition" subsection documenting the three-tier strategy (local cache → GitHub release asset → embedded fallback), so users in air-gapped/offline environments know aspire agent init can still complete successfully.

Note

This draft PR needs human review before merging.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants