Open dibarbet opened 5 months ago
to clarify, the issue happens with or without specifying DOTNET_ROOT it happens on multiple repos as well. Let me know what logs I can share to help figure this out, this is really impacting my productivity
This issue has been marked as stale after 14 days of inactivity. @[ @ @], could you please take a look?
@lifengl Can you check to see if we've fixed this issue (or if it still repros?
Same Issue. Activating the "Microsoft.VisualStudio.CpsProjectIconSourceService (0.1)" service failed. I have reinstalled the extensions but the issue is not resolved.
I am also having this issue now on a Unity project. Was fine yesterday.
If I uninstall the Unity extension, and then uninstall the c# dev kit extension, then reinstall them both and reload extensions everything works until the next time I close and re-open VSCode.
I am also having this issue now on a Unity project. Was fine yesterday.
If I uninstall the Unity extension, and then uninstall the c# dev kit extension, then reinstall them both and reload extensions everything works until the next time I close and re-open VSCode.
Installed v1.4.29 and everything worked fine!
Installed v1.4.29 and everything worked fine!
Thanks for the heads up. That seems to be working fine for me now.
I am also having this issue now on a Unity project. Was fine yesterday. If I uninstall the Unity extension, and then uninstall the c# dev kit extension, then reinstall them both and reload extensions everything works until the next time I close and re-open VSCode.
Installed v1.4.29 and everything worked fine!
Can confirm with my Unity project that using v1.5.20 of the C# Dev Kit extension no longer works, but manually downgrading v1.4.29 fixed things.
@lifengl or @jbevain - could we have broken something in project query?
FWIW downgrading C# Dev Kit to v1.4.29 fixed my similar issues. Using "straight" c#, no Unity or web or anything.
Based on the information posted earlier, it looks like the project system failed to load. Based on the timeline, it is about the time when the project system hosting process was updated to support Aspire projects, but there are also many other things happening about the same time. To understand what was going on, we need help if anyone running into this issue could send us some log files from the extension.
In the session when the extension failed, use vscode command "open extension logs folder", and browse into ms-dotnettools.csdevkit\ServiceHub sub-folder, the first interesting one is named like this:
-hubController--*-1.log
this file should capture some command line information to start the project system process.
The second one is named like -dotnet--*-1.log, which contains the initial logging of the project system hosting process.
The third one is named like -Microsoft.VisualStudio.ProjectSystem.CompositionService--*-1.log, including the project system initialization log.
If the system failed earlier, the later log files might be missing. Or, the earlier log might show things working, and a later failure point might be logged in a later log file.
if anyone can help to provide some content of those files, (or sometime, an exception with call stack in one of that would help us to narrow down what is going on.
also output of dotnet --info might help. Although the original issue was reported from a non-windows platform, the later screen-shot is clearly from a windows machine. The dotnet info command provide some version information of dotnet SDK installed on the machine, sometime, we may not aware of problems when the extension might be broken on a slightly older runtime...
Anyone can help for this situation ? i don't know how to downgrade and i cant see the the version of v1.4.29
@mertdorukkalkan Go to the "C# dev Kit" extension in VSCode. Next to the Uninstall button is a pulldown that will let you install a different version.
I change the "C# dev Kit" ver from v1.5.20->1.4.29 fixed it.
Maybe the extension requires ASP.NET Runtime
.
I have .NET SDK
installed when encountered this problem, and after installing ASP.NET Runtime
, everything works.
The naming convention is too difficult for me to understand.
@Doekin ,
that is what I thought. The difference between 1.5.20 and 1.4.29 is that the newer version requires ASP.NET runtime. Usually, APS.NET would be installed when .NET SDK is installed. Can you run dotnet --info, which may explain what has been installed on the machine?
hmm... I guess one possibility is that the machine has NET 8 Core runtime, but no ASP.NET runtime. Because ASP.NET runtime is installed with SDK, so maybe the machine running into this problem has newer runtime + older SDKs? I wonder maybe certain configuration confused the extension so it picks up a wrong runtime configuration.
On Arch, ASP.NET Runtime
is not installed with SDK. 😂
Running command pacman -S dotnet-sdk
will install the following paackages
we now have
To get ASP.NET Runtime
, we should run pacman -S aspnet-runtime
Same problem on Arch, fixed by installing pasman -S aspnet-runtime
The issue is resolved by installing the older version of C# Dev Kit. I have now installed v1.5.14 as shown in screenshot below and disabled auto update of extension in VS Code. To disable auto-update in Visual Studio Code (VS Code), you can follow these steps: Open Settings: Press Ctrl+, (Windows/Linux) or Cmd+, (Mac) to open the Settings tab. Alternatively, you can click on File > Preferences > Settings. Search for "update": In the search bar at the top of the Settings tab, type "update". This will filter the settings to show those related to updates. Disable Auto-Update: Look for the setting named "Update: Mode" or similar. Change the value to "none". This setting usually has options like "manual", "default", or "none". Setting it to "none" disables auto-update. Save Changes: Close the Settings tab, and VS Code will automatically save your changes. After following these steps, VS Code should no longer automatically update itself. You'll need to manually check for updates and install them if desired.
Anyone can help for this situation ? i don't know how to downgrade and i cant see the the version of v1.4.29
If you are still having issue. You can install v1.5.14. Look at my comment how to do it.
@lifengl I finally had a chance to gather logs as you suggested. Starting the 1.5.20 version I get:
Error : You must install or update .NET to run this application.
Error : The following frameworks were found:
6.0.22 at [/usr/local/share/dotnet/shared/Microsoft.AspNetCore.App]
7.0.11 at [/usr/local/share/dotnet/shared/Microsoft.AspNetCore.App]
After installing .NET SDK 8.0 everything works fine now.
thanks @Doekin and @ericpohl,
yeah, it is clear the assumption that the SDK carrying the ASP.Net runtime is incorrect. It is the story to use the Microsoft installation directly. We will find out a solution for this.
In the meaning time, installing ASP.NET runtime would be a straight workaround.
While the team is working on a fix, to work around this issue: 1, install .NET SDK 8.0 to the machine 2, if you are using Arch Linux, make sure install NET 8 Asp.Net runtime along with the NET 8 SDK to the machine.
I am also having this issue now on a Unity project. Was fine yesterday.
If I uninstall the Unity extension, and then uninstall the c# dev kit extension, then reinstall them both and reload extensions everything works until the next time I close and re-open VSCode.
Thank you! works fine with v1.4.29
Yes, everything worked for me after installation, too.NET SDK
While the team is working on a fix, to work around this issue: 1, install .NET SDK 8.0 to the machine 2, if you are using Arch Linux, make sure install NET 8 Asp.Net runtime along with the NET 8 SDK to the machine.
I was getting the "Microsoft.VisualStudio.CpsProjectIconSourceService (0.1)" service failed.
notification whilst trying to open Solution Explorer, and it seems to be solved after installing the aspnet-runtime package that was missing, I thought I only needed the dotnet runtime and SDK packages.
Thanks!
Note that the latest prerelease version (currently 1.7.4) has a fix such that the ASP.NET runtime will only be needed if you are launching/debugging Aspire app host projects. This bug will be closed when that fix makes it to a release version.
Describe the Issue
This is copied from a comment on https://github.com/dotnet/vscode-csharp/issues/6777#issuecomment-1879102010, originally posted by @dpoole73
I do see this error when opening code:
Activating the "Microsoft.VisualStudio.CpsProjectIconSourceService (0.1)" service failed.
I also see this in the C# Dev Kit - Test explorer log:
Likely because there is no solution shown in the solution explorer is why the Language server is not working?
Steps To Reproduce
No response
Expected Behavior
No response
Environment Information
i'm seeing very similar issues. I'm running on MacBook with apple silicon using the x64 version of dotnet and setting DOTNET_ROOT