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

Make it possible to install VS Code web-extensions #22320

Open
azatsarynnyy opened this issue Jun 23, 2023 · 7 comments · May be fixed by che-incubator/che-code#248
Open

Make it possible to install VS Code web-extensions #22320

azatsarynnyy opened this issue Jun 23, 2023 · 7 comments · May be fixed by che-incubator/che-code#248
Labels
area/editor/vscode Issues related to the Code OSS editor of Che kind/task Internal things, technical debt, and to-do tasks to be performed. severity/P1 Has a major impact to usage or development of the system.

Comments

@azatsarynnyy
Copy link
Member

azatsarynnyy commented Jun 23, 2023

Is your task related to a problem? Please describe

When the user tries to install a web-extension, e.g. vscodevim.Vim, the installation fails with:
image
From the logs:
[error] Error: No extension gallery service configured.

When the user clicks the Try Downloading Manually... button, Che-Code downloads the vsix file, and then the user is able to install the extension with the help of the Install from VSIX... command.

A web-extension that is running in a browser extension host (instead of a remote extension host) should be installed without any errors.

Describe the solution you'd like

Most likely, the problem is that in Che-Code there's no extensionsGallery.resourceUrlTemplate specified in the product.json file. It looks mandatory for installing the web-extensions.
We need to check that.

Describe alternatives you've considered

No response

Additional context

No response

@azatsarynnyy azatsarynnyy added kind/task Internal things, technical debt, and to-do tasks to be performed. severity/P1 Has a major impact to usage or development of the system. area/editor/vscode Issues related to the Code OSS editor of Che labels Jun 23, 2023
@azatsarynnyy
Copy link
Member Author

this quick patch should fix the problem che-incubator/che-code#248
but need to test more thoroughly + adapt to a custom OpenVSX

@azatsarynnyy
Copy link
Member Author

My quick patch to set the resourceUrlTemplate fixes the [error] Error: No extension gallery service configured.
But the requested URL is incorrect.

2023-06-28 17:34:45.715 [info] Installing extension: vscodevim.vim
2023-06-28 17:34:46.130 [info] Request to 'https://che-dogfooding.apps.che-dev.x6e0.p1.openshiftapps.com/oss-dev/web-extension-resource/open-vsx.org/vscode/unpkg/vscodevim/vim/1.25.2/extension' failed with status code 404
2023-06-28 17:34:46.130 [warning] Error while fetching extension resources list Not Found

Needs more investigation.

@che-bot
Copy link
Contributor

che-bot commented Dec 25, 2023

Issues go stale after 180 days of inactivity. lifecycle/stale issues rot after an additional 7 days of inactivity and eventually close.

Mark the issue as fresh with /remove-lifecycle stale in a new comment.

If this issue is safe to close now please do so.

Moderators: Add lifecycle/frozen label to avoid stale mode.

@che-bot che-bot added the lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. label Dec 25, 2023
@che-bot che-bot closed this as completed Jan 1, 2024
@github-project-automation github-project-automation bot moved this from 📋 Backlog (not in current Sprint) to ✅ Done in Eclipse Che Team B Backlog Jan 1, 2024
@azatsarynnyy azatsarynnyy reopened this Jan 3, 2024
@azatsarynnyy
Copy link
Member Author

/remove-lifecycle stale

@che-bot che-bot removed the lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. label Jan 3, 2024
@RomanNikitenko RomanNikitenko moved this to 📋 Backlog (not in current Sprint) in Eclipse Che Team B Backlog Jan 10, 2024
@azatsarynnyy
Copy link
Member Author

One more example of the extension reporting the same error
https://marketplace.visualstudio.com/items?itemName=k--kato.intellij-idea-keybindings

@azatsarynnyy
Copy link
Member Author

I found out how to install such kinds of web (UI) extensions like https://open-vsx.org/extension/vscodevim/vim or https://open-vsx.org/extension/k--kato/intellij-idea-keybindings

There's a Remote: Extension Kind setting in Che-Code.
image

It allows to override where an extension should be run.

Adding the following section to the settings.json file

"remote.extensionKind": {
        "k--kato.intellij-idea-keybindings": [
            "workspace"
        ],
        "vscodevim.vim": [
            "workspace"
        ]
    }

allowed me to install both mentioned extensions.

@AObuchow
Copy link

@azatsarynnyy that's amazing, I'm glad to hear there's finally a workaround for this 😁

It's a shame that you have to manually specify which web-extensions you want to allow to be installed locally -- would be nice if there was a way for us to force all web-extensions to be installed in the workspace with a setting the in remote settings.json.

Still, a workaround is a huge improvement here :D

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/editor/vscode Issues related to the Code OSS editor of Che kind/task Internal things, technical debt, and to-do tasks to be performed. severity/P1 Has a major impact to usage or development of the system.
Projects
Status: 📋 Backlog (not in current Sprint)
Development

Successfully merging a pull request may close this issue.

3 participants