Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unable to launch OrleansVoting sample #141

Open
yoDon opened this issue Mar 3, 2024 · 1 comment
Open

Unable to launch OrleansVoting sample #141

yoDon opened this issue Mar 3, 2024 · 1 comment

Comments

@yoDon
Copy link

yoDon commented Mar 3, 2024

I'm hitting errors while trying to run the OrleansVoting sample. I've listed what I think are appropriate suggestions to fix the first 5 doc issues I hit (the last is still a blocker for me), but before submitting a PR I wanted to check whether whoever owns the doc structure would rather tackle them across all docs themselves rather than having me PR this one piecemeal (which I'm happy to do).

For context, I'm running on an m3 Mac so Visual Studio is not available.

Issue A: The OrleansVoting readme has two different CLI instructions.

One line says At the command line, type dotnet run the other says dotnet run --project OrleansVoting.AppHost.

I couldn't get either to work (see Issue B)

Issue B: It's unclear where to cd to run the CLI commands

The directions say to run from the folder that holds the sample code. It's not clear if that means the OrleansVoting folder (that's the sample I care about), the samples folder (that's where the samples are) or the root of the repo (since its a sample repo).

3 folders x 2 CLI commands is six options, all of which result in error messages.

Suggestion: The Readme should tell the reader to cd samples/OrleansVoting and dotnet run --project OrleansVoting.AppHost to avoid confusion.

Issue C: Obfuscating error messages

Running the correct command in the correct directory results in what looks like a redundant/duplicate error message.

/usr/local/share/dotnet/sdk/8.0.201/Sdks/Microsoft.NET.Sdk/targets/Microsoft.NET.Sdk.ImportWorkloads.targets(38,5): error NETSDK1147: To build this project, the following workloads must be installed: aspire [/Users/don/Websites/202403a/aspire-samples/samples/OrleansVoting/OrleansVoting.AppHost/OrleansVoting.AppHost.csproj]
/usr/local/share/dotnet/sdk/8.0.201/Sdks/Microsoft.NET.Sdk/targets/Microsoft.NET.Sdk.ImportWorkloads.targets(38,5): error NETSDK1147: To install these workloads, run the following command: dotnet workload restore [/Users/don/Websites/202403a/aspire-samples/samples/OrleansVoting/OrleansVoting.AppHost/OrleansVoting.AppHost.csproj]

The build failed. Fix the build errors and run again.

That block contains two error messages. Both are error NETSDK1147. Both reference the same file, line, and character. Each starts with the same ~50 characters, and each ends with the same ~50 characters. In the console the line breaks make it tricky to compare the entries. It took me quite a while to spot that the second error message had an instruction in it to dotnet workload restore.

Suggestion: The Readme should tell the reader to dotnet workload restore to avoid hitting these error messages.

Suggestion: The platform should do a better job of reporting aspire error NETSDK1147.

Issue D: "Docker is unhealthy" error message

Following the above suggestions, and continuing to try to run the sample, I get:

Docker was found but appears to be unhealthy. Exit code for 'docker ps --latest --quiet' was 1.

Suggestion: Improve this error message to suggest launching Docker Desktop.

Issue E: Unable to get this project to build using the most current 2023.3 Rider IDE build.

Even when the project builds and runs under the CLI, I'm getting Error MSB3971 : The reference assemblies for ".NETFramework,Version=v8.0" were not found. You might be using an older .NET SDK to target .NET 5.0 or higher. Update Visual Studio and/or your .NET SDK.

Issue F: (BLOCKING ISSUE) What do I do once Aspire is running?

Suggestion: The Readme should explain to CLI users how to get to the app in the browser, including whether there is one page or multiple pages to open (I've not yet been able to figure this part out on my own).

Should I submit a PR?

If my suggestions are correct, I'm happy to submit a PR for the OrleansVoting sample, but as I mentioned it feels like this might be a sufficiently consisted issue across the repo that if there's someone focusing on the sample framework they might prefer to handle the issues consistently across all the samples themselves rather than having me tackle this one on its own.

I'll mention @ReubenBond here, in case this is helpful.

@DamianEdwards
Copy link
Member

@ReubenBond

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

No branches or pull requests

2 participants