Aspire upgrade impossible

I've been developing using Aspire since the end of 2023 - I stuck with 8.0.0-preview.3.24105.21.

If I upgrade to  8.0.0-preview.4.24156.9, I get the following error:

Application orchestrator dependency check had an unexpected error System.InvalidOperationException: Command /usr/local/share/dotnet/packs/Aspire.Hosting.Orchestration.osx-arm64/8.0.0-preview.3.24105.21/tools/dcp info returned non-zero exit code 1
  at Aspire.Hosting.Dcp.DcpDependencyCheck.EnsureDcpDependenciesAsync(CancellationToken cancellationToken) in /_/src/Aspire.Hosting/Dcp/DcpDependencyCheck.cs:line 67.
 

If I upgrade to anything else (starting at 8.0.0-preview.5.24201.12):

4>Sdk.targets(38,5): Warning ASPIRE002 : MarketData.AppHost is an Aspire AppHost project but necessary dependencies aren't present. Are you missing an Aspire.Hosting PackageReference?

< tons of errors> 


"obj/Debug/net8.0/.NETCoreApp,Version=v8.0.AssemblyAttributes.cs" obj/Debug/net8.0/MarketData.AppHost.AssemblyInfo.cs /warnaserror+:NU1605,SYSLIB0011
4>Program.cs(7,37): Error CS0246 : The type or namespace name 'Projects' could not be found (are you missing a using directive or an assembly reference?)
4>Program.cs(8,41): Error CS0246 : The type or namespace name 'Projects' could not be found (are you missing a using directive or an assembly reference?)
4>Program.cs(9,38): Error CS0246 : The type or namespace name 'Projects' could not be found (are you missing a using directive or an assembly reference?)
4>Program.cs(11,20): Error CS0246 : The type or namespace name 'Projects' could not be found (are you missing a using directive or an assembly reference?)
4>Program.cs(17,20): Error CS0246 : The type or namespace name 'Projects' could not be found (are you missing a using directive or an assembly reference?)

If I try to move to 9 (9.0.0-preview.1.24113.3):

4>Program.cs(1,7): Error CS0246 : The type or namespace name 'Aspire' could not be found (are you missing a using directive or an assembly reference?)
4>Project.AppHost.GlobalUsings.g.cs(2,22): Error CS0400 : The type or namespace name 'Aspire' could not be found in the global namespace (are you missing an assembly reference?)
4>Project.AppHost.GlobalUsings.g.cs(3,22): Error CS0400 : The type or namespace name 'Aspire' could not be found in the global namespace (are you missing an assembly reference?)
4>Project_market.ProjectMetadata.g.cs(4,42): Error CS0400 : The type or namespace name 'Aspire' could not be found in the global namespace (are you missing an assembly reference?)
4>Project_ApiService.ProjectMetadata.g.cs(4,46): Error CS0400 : The type or namespace name 'Aspire' could not be found in the global namespace (are you missing an assembly reference?)
4>Project_Content.ProjectMetadata.g.cs(4,43): Error CS0400 : The type or namespace name 'Aspire' could not be found in the global namespace (are you missing an assembly reference?)
4>Project_studio.ProjectMetadata.g.cs(4,42): Error CS0400 : The type or namespace name 'Aspire' could not be found in the global namespace (are you missing an assembly reference?)
4>Project_UserService.ProjectMetadata.g.cs(4,47): Error CS0400 : The type or namespace name 'Aspire' could not be found in the global namespace (are you missing an assembly reference?)

0
3 comments

Hello,

Thank you for contacting Rider support.

Would you mind sharing additional information as described below?

  • Don't you encounter the same issues in Visual Studio?
  • Do you have .Net Aspire plugin installed in Rider?
  • A screencast that demonstrates the way you reproduce the issue having a working project;
  • It would be helpful if you could share a repro solution with us too, so that we can reproduce the issue and troubleshoot it.
  • Output of the `dotnet --info` command invoked from the terminal.
  • You can upload files to the Upload service and let me know upload ID.

Have a nice day!

0

Following up on this (again), I've created an empty aspire project in the latest version of Rider (2024.2) - the original project comes up with:

     <PackageReference Include="Aspire.Hosting" Version="8.0.0-preview.3.24105.21" />

If I upgrade with Nuget:

     <PackageReference Include="Aspire.Hosting" Version="8.1.0" />

The only code in the application is (as I am trying to go line by line)

using Aspire.Hosting;

var builder = DistributedApplication.CreateBuilder(args);

builder.Build().Run();

Then I get the following runtime error:

Unhandled exception. System.AggregateException: One or more errors occurred. (Property CliPath: The path to the DCP executable used for Aspire orchestration is required.; Property DashboardPath: The path to the Aspire Dashboard binaries is missing.)
---> Microsoft.Extensions.Options.OptionsValidationException: Property CliPath: The path to the DCP executable used for Aspire orchestration is required.; Property DashboardPath: The path to the Aspire Dashboard binaries is missing.
  at Microsoft.Extensions.Options.OptionsFactory`1.Create(String name)
  at Microsoft.Extensions.Options.UnnamedOptionsManager`1.get_Value()
  at Aspire.Hosting.Dashboard.ConfigureDefaultDashboardOptions.Configure(DashboardOptions options) in /_/src/Aspire.Hosting/Dashboard/DashboardOptions.cs:line 25
  at Microsoft.Extensions.Options.OptionsFactory`1.Create(String name)
  at Microsoft.Extensions.Options.UnnamedOptionsManager`1.get_Value()
  at Aspire.Hosting.Dashboard.DashboardLifecycleHook.AddDashboardResource(DistributedApplicationModel model) in /_/src/Aspire.Hosting/Dashboard/DashboardLifecycleHook.cs:line 77
  at Aspire.Hosting.Dashboard.DashboardLifecycleHook.BeforeStartAsync(DistributedApplicationModel model, CancellationToken cancellationToken) in /_/src/Aspire.Hosting/Dashboard/DashboardLifecycleHook.cs:line 46
  at Aspire.Hosting.DistributedApplication.ExecuteBeforeStartHooksAsync(CancellationToken cancellationToken) in /_/src/Aspire.Hosting/DistributedApplication.cs:line 353
  at Aspire.Hosting.DistributedApplication.RunAsync(CancellationToken cancellationToken) in /_/src/Aspire.Hosting/DistributedApplication.cs:line 309
  --- End of inner exception stack trace ---
  at System.Threading.Tasks.Task.ThrowIfExceptional(Boolean includeTaskCanceledExceptions)
  at System.Threading.Tasks.Task.Wait(Int32 millisecondsTimeout, CancellationToken cancellationToken)
  at System.Threading.Tasks.Task.Wait()
  at Aspire.Hosting.DistributedApplication.Run() in /_/src/Aspire.Hosting/DistributedApplication.cs:line 338
  at Program.<Main>$(String[] args) in /Users/joshuacornejo/Desktop/Projects/aspire/MarketData/AspireControlCentre/Program.cs:line 6
Process finished with exit code 134.

 

  • Don't you encounter the same issues in Visual Studio?
    • I use a Mac
  • Do you have .Net Aspire plugin installed in Rider?
    • Yes
  • A screencast that demonstrates the way you reproduce the issue having a working project;
    • uploading
  • It would be helpful if you could share a repro solution with us too, so that we can reproduce the issue and troubleshoot it.
    • Can't do that
  • Output of the `dotnet --info` command invoked from the terminal.
    • .NET SDK:
      Version:           8.0.304
      Commit:            352dc5a01f
      Workload version:  8.0.300-manifests.6b7f9d2a
      MSBuild version:   17.10.4+10fbfbf2e
    • Runtime Environment:
      OS Name:     Mac OS X
      OS Version:  15.1
      OS Platform: Darwin
      RID:         osx-arm64
      Base Path:   /usr/local/share/dotnet/sdk/8.0.304/
    • .NET workloads installed:
      There are no installed workloads to display.
    • Host:
       Version:      8.0.8
       Architecture: arm64
       Commit:       08338fcaa5
    • .NET SDKs installed:
       6.0.407 [/usr/local/share/dotnet/sdk]
       6.0.416 [/usr/local/share/dotnet/sdk]
       6.0.417 [/usr/local/share/dotnet/sdk]
       6.0.418 [/usr/local/share/dotnet/sdk]
       6.0.419 [/usr/local/share/dotnet/sdk]
       6.0.421 [/usr/local/share/dotnet/sdk]
       7.0.202 [/usr/local/share/dotnet/sdk]
       7.0.310 [/usr/local/share/dotnet/sdk]
       7.0.311 [/usr/local/share/dotnet/sdk]
       7.0.312 [/usr/local/share/dotnet/sdk]
       7.0.313 [/usr/local/share/dotnet/sdk]
       7.0.315 [/usr/local/share/dotnet/sdk]
       8.0.100 [/usr/local/share/dotnet/sdk]
       8.0.300 [/usr/local/share/dotnet/sdk]
       8.0.304 [/usr/local/share/dotnet/sdk]
    • .NET runtimes installed:
       Microsoft.AspNetCore.App 6.0.15 [/usr/local/share/dotnet/shared/Microsoft.AspNetCore.App]
       Microsoft.AspNetCore.App 6.0.24 [/usr/local/share/dotnet/shared/Microsoft.AspNetCore.App]
       Microsoft.AspNetCore.App 6.0.25 [/usr/local/share/dotnet/shared/Microsoft.AspNetCore.App]
       Microsoft.AspNetCore.App 6.0.26 [/usr/local/share/dotnet/shared/Microsoft.AspNetCore.App]
       Microsoft.AspNetCore.App 6.0.27 [/usr/local/share/dotnet/shared/Microsoft.AspNetCore.App]
       Microsoft.AspNetCore.App 6.0.29 [/usr/local/share/dotnet/shared/Microsoft.AspNetCore.App]
       Microsoft.AspNetCore.App 7.0.4 [/usr/local/share/dotnet/shared/Microsoft.AspNetCore.App]
       Microsoft.AspNetCore.App 7.0.13 [/usr/local/share/dotnet/shared/Microsoft.AspNetCore.App]
       Microsoft.AspNetCore.App 7.0.14 [/usr/local/share/dotnet/shared/Microsoft.AspNetCore.App]
       Microsoft.AspNetCore.App 7.0.15 [/usr/local/share/dotnet/shared/Microsoft.AspNetCore.App]
       Microsoft.AspNetCore.App 7.0.16 [/usr/local/share/dotnet/shared/Microsoft.AspNetCore.App]
       Microsoft.AspNetCore.App 7.0.18 [/usr/local/share/dotnet/shared/Microsoft.AspNetCore.App]
       Microsoft.AspNetCore.App 8.0.0 [/usr/local/share/dotnet/shared/Microsoft.AspNetCore.App]
       Microsoft.AspNetCore.App 8.0.5 [/usr/local/share/dotnet/shared/Microsoft.AspNetCore.App]
       Microsoft.AspNetCore.App 8.0.8 [/usr/local/share/dotnet/shared/Microsoft.AspNetCore.App]
       Microsoft.NETCore.App 6.0.15 [/usr/local/share/dotnet/shared/Microsoft.NETCore.App]
       Microsoft.NETCore.App 6.0.24 [/usr/local/share/dotnet/shared/Microsoft.NETCore.App]
       Microsoft.NETCore.App 6.0.25 [/usr/local/share/dotnet/shared/Microsoft.NETCore.App]
       Microsoft.NETCore.App 6.0.26 [/usr/local/share/dotnet/shared/Microsoft.NETCore.App]
       Microsoft.NETCore.App 6.0.27 [/usr/local/share/dotnet/shared/Microsoft.NETCore.App]
       Microsoft.NETCore.App 6.0.29 [/usr/local/share/dotnet/shared/Microsoft.NETCore.App]
       Microsoft.NETCore.App 7.0.4 [/usr/local/share/dotnet/shared/Microsoft.NETCore.App]
       Microsoft.NETCore.App 7.0.13 [/usr/local/share/dotnet/shared/Microsoft.NETCore.App]
       Microsoft.NETCore.App 7.0.14 [/usr/local/share/dotnet/shared/Microsoft.NETCore.App]
       Microsoft.NETCore.App 7.0.15 [/usr/local/share/dotnet/shared/Microsoft.NETCore.App]
       Microsoft.NETCore.App 7.0.16 [/usr/local/share/dotnet/shared/Microsoft.NETCore.App]
       Microsoft.NETCore.App 7.0.18 [/usr/local/share/dotnet/shared/Microsoft.NETCore.App]
       Microsoft.NETCore.App 8.0.0 [/usr/local/share/dotnet/shared/Microsoft.NETCore.App]
       Microsoft.NETCore.App 8.0.5 [/usr/local/share/dotnet/shared/Microsoft.NETCore.App]
       Microsoft.NETCore.App 8.0.8 [/usr/local/share/dotnet/shared/Microsoft.NETCore.App]
    • Other architectures found:
       None
    • Environment variables:
       Not set
    • global.json file:
       Not found
    • Learn more:
       https://aka.ms/dotnet/info
    • Download .NET:
       https://aka.ms/dotnet/download
  • You can upload files to the Upload service and let me know upload ID.
    • 2024_08_15_V8dHJ5Y4RZB26oA4tWyo6R
0

Hello,

Thank you for contacting Rider support.

Unfortunately, I can't reproduce the issue. It is weird, that the preview version is used by default.

I suggest trying the following option:

  • update workload: ‘dotnet workload update’ and create a new solution;
  • if that doesn't help, reinstall workload: ‘dotnet workload uninstall aspire’, ‘dotnet workload install aspire’;
  • try running from the terminal outside Rider: ‘cd {Solution}/{Project}’, ‘dotnet run’;

Please let me know the outcome.

Have a nice day!

0

Please sign in to leave a comment.