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

[dotnet, golang] Connot access to extension SDK despite it being installed and FLATPAK_ENABLE_SDK_EXT being used #434

Open
Dremor opened this issue Sep 16, 2023 · 7 comments

Comments

@Dremor
Copy link

Dremor commented Sep 16, 2023

I installed VSCode through Flatpak, and followed the instruction in the first run text file, but VSCode as well as VScode-OSS both do not detect the Flatpak sdk extension.

I tried both FLATPAK_ENABLE_SDK_EXT=dotnet and FLATPAK_ENABLE_SDK_EXT=dotnet7 before flatpak run com.visualstudio.code, both returned Requested SDK extension "dotnet" is not installed

Installed SDKs:

$ flatpak list | grep -i sdk
Freedesktop SDK	org.freedesktop.Sdk	22.08.15	22.08	flathub	system
.NET Core SDK extension	org.freedesktop.Sdk.Extension.dotnet7	7.0.401	23.08	flathub	system
Go programming language Sdk extension	org.freedesktop.Sdk.Extension.golang	1.21.0	23.08	flathub	system

Same problem with the golang extenssion and FLATPAK_ENABLE_SDK_EXT=golang

In all cases /usr/lib/sdk/ is empty.

Edit: the command $ find / -iname dotnet returns no result when executed inside the container.

Edit2: Something noteworthy I ended up finding is that the dotnet6 sdk do work as intended, but both dotnet5, dotnet7 and golang don't.

@chanster
Copy link

chanster commented Sep 20, 2023

Try downgrading to the 22.08 branch for each Sdk Extension

flatpak install org.freedesktop.Sdk.Extension.dotnet7 org.freedesktop.Sdk.Extension.golang org.freedesktop.Sdk.Extension.rust-stable
Looking for matches…
Similar refs found for ‘org.freedesktop.Sdk.Extension.dotnet7’ in remote ‘flathub’ (user):

   1) runtime/org.freedesktop.Sdk.Extension.dotnet7/x86_64/22.08
   2) runtime/org.freedesktop.Sdk.Extension.dotnet7/x86_64/23.08

Which do you want to use (0 to abort)? [0-2]: 1
Similar refs found for ‘org.freedesktop.Sdk.Extension.golang’ in remote ‘flathub’ (user):

   1) runtime/org.freedesktop.Sdk.Extension.golang/x86_64/19.08
   2) runtime/org.freedesktop.Sdk.Extension.golang/x86_64/20.08
   3) runtime/org.freedesktop.Sdk.Extension.golang/x86_64/21.08
   4) runtime/org.freedesktop.Sdk.Extension.golang/x86_64/1.6
   5) runtime/org.freedesktop.Sdk.Extension.golang/x86_64/22.08
   6) runtime/org.freedesktop.Sdk.Extension.golang/x86_64/23.08
   7) runtime/org.freedesktop.Sdk.Extension.golang/x86_64/18.08

Which do you want to use (0 to abort)? [0-7]: 5

Then when running vscode, you may see the extensions load successfully

flatpak run com.visualstudio.code
flatpak-vscode: Enabling SDK extension "golang"
flatpak-vscode: Enabling SDK extension "dotnet7"

I have overrides set to I do not need to pass in the env.

flatpak --user override --show com.visualstudio.code
[Environment]
FLATPAK_ENABLE_SDK_EXT=golang,dotnet7

@Dremor
Copy link
Author

Dremor commented Sep 24, 2023

Both works with the 22.08 branch. Is it normal or is there a need for a fix ?

@chanster
Copy link

chanster commented Sep 25, 2023

It's because this flatpak is built upon the 22.08 of org.freedesktop.Sdk, so we want to install the SDK extensions that are also built upon the same version.

See the source for com.visualstudio.code.yaml showing the org.freedesktop.Sdk runtime.

@omergoktas
Copy link

Would have been great if you have also updated the README.md

@chanster
Copy link

chanster commented Jan 5, 2024

Looks like #473 this merge resolves this issue.

@Dremor
Copy link
Author

Dremor commented Jan 5, 2024

Looks like #473 this merge resolves this issue.

Until the next runtime major update. It is kinda the problem with Flatpak extension. Is it doesn't know for which app we are installing the extension, it just instal the latest one.

Would have been great if you have also updated the README.md

Maybe we should create our own extension that just pulls the correct extension, for the correct runtime. If we update this in the documentation, we'll have to continue doing it every times we update the runtime.

@ricvelozo
Copy link

I tried to use the PHP 8.2 SDK extension (22.08 branch) and had the same problem.

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

4 participants