Skip to content

Conversation

Copy link
Contributor

Copilot AI commented Dec 18, 2025

Description

When users run aspire deploy without deployment resources configured, the command reports success despite doing nothing. This leaves users uncertain whether deployment succeeded or configuration is missing.

Changes

Added CheckForEmptyMetaStep to DistributedApplicationPipeline.ExecuteAsync:

  • Detects when targeted meta-steps (deploy, publish, build, push) have no child steps beyond prerequisites
  • Logs warning with actionable guidance when empty meta-step is invoked
  • Only checks when specific step is targeted via --step flag

Warning output:

No steps were found to execute for the 'deploy' operation. This usually means no resources or environments are configured for this operation. Please ensure your application has the necessary configuration to support this step.

Example scenario triggering warning:

# AppHost with no deployment resources configured
aspire deploy
# Now warns: "No steps were found to execute for the 'deploy' operation..."

Testing

  • 4 new tests covering empty/non-empty meta-steps and full pipeline execution
  • All 67 pipeline tests pass

Checklist

  • Is this feature complete?
    • Yes. Ready to ship.
    • No. Follow-up changes expected.
  • Are you including unit tests for the changes and scenario tests if relevant?
    • Yes
    • No
  • Did you add public API?
    • Yes
    • No
  • Does the change make any security assumptions or guarantees?
    • Yes
    • No
  • Does the change require an update in our Aspire docs?
    • Yes
    • No
Original prompt

This section details on the original issue you should resolve

<issue_title>aspire deploy doesn't report failure when nothing was deployed</issue_title>
<issue_description>### Is there an existing issue for this?

  • I have searched the existing issues

Describe the bug

I tried to run the aspire deploy command with the expectation that it would tell me what's missing for my app to be deployed, instead it reported success.

Nothing was deployed.

> aspire deploy
12:52:11 (pipeline execution) → Starting pipeline execution...
12:52:11 (deploy) → Starting deploy...
12:52:11 (deploy) ✓ deploy completed successfully
12:52:11 (pipeline execution) ✓ Completed successfully
------------------------------------------------------------
✓ 2/2 steps succeeded • Total time: 0.0s

Steps Summary:
   0.0 s  ✓ pipeline execution
   0.0 s  ✓ deploy

✓ PIPELINE SUCCEEDED

Expected Behavior

An error or a warning that cloud resources are missing

Steps To Reproduce

No response

Exceptions (if any)

No response

.NET Version info

.NET SDK:
 Version:           10.0.100
 Commit:            b0f34d51fc
 Workload version:  10.0.100-manifests.5fb86115
 MSBuild version:   18.0.2+b0f34d51f

Runtime Environment:
 OS Name:     Windows
 OS Version:  10.0.27928
 OS Platform: Windows
 RID:         win-arm64
 Base Path:   C:\Program Files\dotnet\sdk\10.0.100\

.NET workloads installed:
 [maui-windows]
   Installation Source: VS 17.14.36717.8
   Manifest Version:    10.0.0/10.0.100
   Manifest Path:       C:\Program Files\dotnet\sdk-manifests\10.0.100\microsoft.net.sdk.maui\10.0.0\WorkloadManifest.json
   Install Type:              Msi

 [maccatalyst]
   Installation Source: VS 17.14.36717.8
   Manifest Version:    26.1.10494/10.0.100
   Manifest Path:       C:\Program Files\dotnet\sdk-manifests\10.0.100\microsoft.net.sdk.maccatalyst\26.1.10494\WorkloadManifest.json
   Install Type:              Msi

 [ios]
   Installation Source: VS 17.14.36717.8
   Manifest Version:    26.1.10494/10.0.100
   Manifest Path:       C:\Program Files\dotnet\sdk-manifests\10.0.100\microsoft.net.sdk.ios\26.1.10494\WorkloadManifest.json
   Install Type:              Msi

 [android]
   Installation Source: VS 17.14.36717.8
   Manifest Version:    36.1.2/10.0.100
   Manifest Path:       C:\Program Files\dotnet\sdk-manifests\10.0.100\microsoft.net.sdk.android\36.1.2\WorkloadManifest.json
   Install Type:              Msi

Configured to use workload sets when installing new manifests.
No workload sets are installed. Run "dotnet workload restore" to install a workload set.

Host:
  Version:      10.0.0
  Architecture: arm64
  Commit:       b0f34d51fc

.NET SDKs installed:
  9.0.308 [C:\Program Files\dotnet\sdk]
  10.0.100 [C:\Program Files\dotnet\sdk]

.NET runtimes installed:
  Microsoft.AspNetCore.App 8.0.22 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.App]
  Microsoft.AspNetCore.App 9.0.11 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.App]
  Microsoft.AspNetCore.App 10.0.0 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.App]
  Microsoft.NETCore.App 8.0.21 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
  Microsoft.NETCore.App 8.0.22 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
  Microsoft.NETCore.App 9.0.11 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
  Microsoft.NETCore.App 10.0.0 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
  Microsoft.WindowsDesktop.App 8.0.21 [C:\Program Files\dotnet\shared\Microsoft.WindowsDesktop.App]
  Microsoft.WindowsDesktop.App 8.0.22 [C:\Program Files\dotnet\shared\Microsoft.WindowsDesktop.App]
  Microsoft.WindowsDesktop.App 9.0.11 [C:\Program Files\dotnet\shared\Microsoft.WindowsDesktop.App]
  Microsoft.WindowsDesktop.App 10.0.0 [C:\Program Files\dotnet\shared\Microsoft.WindowsDesktop.App]

Other architectures found:
  x64   [C:\Program Files\dotnet\x64]
    registered at [HKLM\SOFTWARE\dotnet\Setup\InstalledVersions\x64\InstallLocation]
  x86   [C:\Program Files (x86)\dotnet]
    registered at [HKLM\SOFTWARE\dotnet\Setup\InstalledVersions\x86\InstallLocation]

Environment variables:
  Not set

global.json file:
  Not found

Learn more:
  https://aka.ms/dotnet/info

Download .NET:
  https://aka.ms/dotnet/download

Anything else?

No response</issue_description>

<agent_instructions>Add logic to the distributed application pipeline that will check to see if any child steps will run as part of the meta-steps that are registered in the pipeline. If no child steps will run, then emit a log message indicating that no steps have been found. Do this only when the step that was invoked is empty.</agent_instructions>

Comments on the Issue (you are @copilot in this section)

@captainsafia @tonybaloney Thanks for reporting this issue!

We had a failure mode that would tell you what you needed to do (add a compute environment to your AppHost) but we lost this ability as par...


✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.

Copilot AI changed the title [WIP] Fix aspire deploy not reporting failure for missing resources Warn when pipeline meta-steps execute with no child steps Dec 18, 2025
Copilot AI requested a review from captainsafia December 18, 2025 22:29
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.

aspire deploy doesn't report failure when nothing was deployed

2 participants