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

Have extensionKind: "ui" only run in the ui #85036

Closed
alexdima opened this issue Nov 18, 2019 · 5 comments
Closed

Have extensionKind: "ui" only run in the ui #85036

alexdima opened this issue Nov 18, 2019 · 5 comments
Assignees
Labels
extensions Issues concerning extensions feature-request Request for new features or functionality on-testplan
Milestone

Comments

@alexdima
Copy link
Member

  • In September, we made "extensionKind":"ui" run on the workspace extension host if the extension is only installed there.
  • In October, we have added support for "extensionKind": ["ui","workspace"] to express that an extension can run on either side, but prefers the ui side.
  • In October, we have left "extensionKind":"ui" to be able to execute on the workspace side.

We should clean this up and enforce that "extensionKind":"ui" only allows an extension to run on the ui.

@alexdima alexdima added this to the November 2019 milestone Nov 18, 2019
@alexdima alexdima added feature-request Request for new features or functionality extensions Issues concerning extensions labels Nov 21, 2019
@alexdima
Copy link
Member Author

fyi @sandy081 @egamma - I have removed that ui extensions are allowed to execute on the remote side.

Still left to do:

  1. extensions actions in the viewlet need to also enforce this everywhere and we need to bring back the tests that we removed in September (go back to the August state) @sandy081 .
  2. do a pass over extensions in the marketplace or in our product.json which use "extensionKind":"ui" and check, very likely they might need to adopt "extensionKind": ["ui","workspace"] in their package.json or we should do it for them if we run out of time in our product.json.

@sandy081 @egamma LMK if you need any help with point 2, otherwise I consider this done from my side.

@alexdima alexdima removed their assignment Nov 21, 2019
devrsi0n pushed a commit to devrsi0n/vscode that referenced this issue Nov 27, 2019
@sandy081
Copy link
Member

Added code to disable UI extension on Web. Also disallowed installing them.

@sandy081
Copy link
Member

sandy081 commented Nov 29, 2019

Here is the report after analysing extensions in Marketplace

  • 148 - Total extensions in market place that define extensionKind
  • 88 - UI extensions out of which 21 are in top 200.
  • 55 - Workspace extensions out of which 6 are in top 200.
  • 4 - UI, Workspace extensions
  • 1 - Workspace, UI extensions

Impact Analysis

Treating "extensionKind": "ui" as strict UI extensions has following impact:

88 extensions (21 in top 200)

  • will no longer run in dev container
  • will no longer run in VSO and user cannot install them in VSO

Impact on VSO is pretty bad.

Mitigation Steps

After discussions @egamma and me came up with following

  • Treat "extensionKind": "ui" as "extensionKind": ["ui", "workspace"]. This will allow above 88 extensions to work in VSO
  • Those extensions which are tagged "extensionKind": "ui" and cannot run in workspace/remote/VSO eg: Settings Sync -> update the product.json by adding them to strict ui list. eg: "Shan.code-settings-sync": ["ui"].
  • Deprecate / Remove string value type for extensionKind from the schema so that we will encourage authors to use the array rather than string type as it has mixed behaviour.
  • Also add checks in vsce and block/warn publishing if extensionKind has string value

@egamma @alexandrudima FYI

@alexdima
Copy link
Member Author

@sandy081 treating "extensionKind": "ui" as "extensionKind": ["ui, workspace"] can be done in a single place, so we wouldn't need to adopt anything, except perhaps tests...

// check the manifest itself
result = manifest.extensionKind;
if (typeof result !== 'undefined') {
return toArray(result);
}

sandy081 added a commit that referenced this issue Nov 29, 2019
change extension kind ui to be ui + workspace
deprecate string value for extension kind
@sandy081
Copy link
Member

sandy081 commented Nov 29, 2019

@sandy081 sandy081 closed this as completed Dec 4, 2019
@vscodebot vscodebot bot locked and limited conversation to collaborators Jan 18, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
extensions Issues concerning extensions feature-request Request for new features or functionality on-testplan
Projects
None yet
Development

No branches or pull requests

2 participants