No apparent way to config/debug ionide on vscode with nixos at WSL
Describe the bug**
I am using nixos under WSL, so I use vscode with the nix plugin and I create an environment with sharp, omnisharp, dotnet-sdk 3 and 5 and everything appears to work on the command line, however, ionide never seems to get started as it doesn't show, how should I debug it?
Steps to reproduce
- Create a new SAFE template on a nixos wsl instance and open it on windows vscode
- Add the file shell.nix and initialize the environment
- dotnet restore
- Open any F# file, it only has syntax highlighting but no suggerences or documentations
- Execute the vscode command
F#: Get ionide logs. Error pops up
The output from ionide logs is:
Command 'F#: Get Ionide logs' resulted in an error (command 'fsharp.diagnostics.getIonideLogs' not found)
The shell.nix file contents are:
{ nixpkgs ? import <nixpkgs> { } }:
let
pkgs = [
nixpkgs.nodejs
nixpkgs.yarn
nixpkgs.stack
nixpkgs.git
nixpkgs.dotnet-sdk_3
nixpkgs.dotnet-sdk_5
nixpkgs.fsharp
nixpkgs.omnisharp-roslyn
];
in
nixpkgs.stdenv.mkDerivation {
name = "SAFE";
buildInputs = pkgs;
}
Expected behavior
Ionide working as good as nodejs and other tooling does or to see a helpful message about what ionide binary has been called, and what was the return code came or any other helpful information.
Machine info
- Windows 10
- .NET SDK version: 3.1
- Ionide version: 5.3.2
Additional context
If I could somehow see the actual logs and know whether ionide tries to begin, and where is the exact configuration I may correct the path to make it point to the correct binaries at nix os.
Any help is welcome
Hey @vrescobar :wave:,
Thank you for opening an issue. We will get back to you as soon as we can. Also, check out our OpenCollective and consider backing us.
https://opencollective.com/ionide
PS.: We offer
backersupport for all backers. Don't forget to addbackerlabel when you start backing us :smile:
I'm running into the same issue on WSL2 Debian / Windows 10 with the .NET SDK 5.0.200.
Up to version 5.2.0 - Ionide loads (but project cracking fails due to #1509)
Version 5.3.2 and version 5.4.0 - Ionide doesn't load at all, the F# symbol is missing from the Activity Bar, F# isn't available in the Output drop-down menu. Trying to open the logs behaves the same as for @vrescobar.
"F#: Clear Project Cache" also gives the same kind of error:
Command 'F#: Clear Project Cache' resulted in an error (command 'fsharp.clearCache' not found)
More stuff that didn't work:
- Uninstalling the extension
- Deleting the /bin and /obj folder
- Deleting the .ionide folder
- Settings
fsharp.workspacePathto./myproject.sln - Switching to a basic project folder (
dotnet new console -lang f#) - Uninstalling all SDKs and runtimes other than the latest stable (5.0.200 / 5.0.3)
- Adding a
global.jsonfor the 5.0.200 SDK
EDIT: Tried using Ionide on Windows 10 directly (not in WSL2) and the same behaviour appears on a fresh new project. Something might be wonky with my VSCode setup as a whole...
Update: Completely uninstalled VSCode and all extensions, settings, etc., then reinstalled from scratch. Now Ionide 5.4.0 works. Will update this comment if I find any new extension/setting that replicates the issue.
I am having this exact same issue as @piaste on windows.
.NET SDK (reflecting any global.json):
Version: 6.0.201
Commit: ef40e6aa06
Runtime Environment:
OS Name: Windows
OS Version: 10.0.19043
OS Platform: Windows
RID: win10-x64
Base Path: C:\Program Files\dotnet\sdk\6.0.201\
Host (useful for support): Version: 6.0.3 Commit: c24d9a9c91
Update: Completely uninstalled VSCode and all extensions, settings, etc., then reinstalled from scratch. Now Ionide 5.4.0 works. Will update this comment if I find any new extension/setting that replicates the issue.
I did this and still am not getting it to load. The new "Runtime Status" tab on the extension says it's never even activated.
