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

Implement CustomExecution extension API #9189

Merged

Conversation

shyshywhy
Copy link
Contributor

@shyshywhy shyshywhy commented Mar 12, 2021

Fixes: #7185
Fixes: #8767

What it does

Implement CustomExecution extension API, and fixed issue: #7185, #8767

How to test

Use Gradle Tasks extension to test.

Review checklist

Reminder for reviewers

@shyshywhy
Copy link
Contributor Author

image

@azatsarynnyy
Copy link
Member

Hello @shyshywhy,
thank you for your contribution to Theia project!

eclipsefdn/eca status check isn't passed which means you have to sign an Eclipse Contributor Agreement before contributing the code.
By the following link https://wiki.eclipse.org/Development_Resources/Contributing_via_Git#Eclipse_Contributor_Agreement
you can find all the required information on how to sign an ECA.

@shyshywhy shyshywhy force-pushed the ft/support_custom_execution branch 4 times, most recently from bd7555f to 3fe0ad7 Compare March 14, 2021 03:38
@shyshywhy
Copy link
Contributor Author

@azatsarynnyy Ok, I fixed it.

@vince-fugnitto vince-fugnitto added the vscode issues related to VSCode compatibility label Mar 15, 2021
@kittaakos
Copy link
Contributor

I will have time for a full-blown review and verification tomorrow. Please bear with me. Thanks!

@kittaakos
Copy link
Contributor

I am verifying the PR with the task-provider-sample from here.

Steps:

  • Run Task...
  • custombuildscript: 32.
  • Continue without scanning the task output.
  • Task terminates, see the Terminal will be reused by task, press Enter.
logger-protocol.ts:112 root ERROR The ws channel does not exist 23
log @ logger-protocol.ts:111
(anonymous) @ logger-frontend-module.ts:40
(anonymous) @ logger.ts:311
(anonymous) @ logger.ts:303
Promise.then (async)
../../packages/core/lib/common/logger.js.Logger.log @ logger.ts:298
log @ logger.ts:44
../../packages/core/lib/common/messaging/abstract-connection-provider.js.AbstractConnectionProvider.handleIncomingRawMessage @ abstract-connection-provider.ts:112
WebSocketConnectionProvider.socket.onmessage @ ws-connection-provider.ts:63
ReconnectingWebSocket._handleMessage @ reconnecting-websocket-mjs.js:172
main.js:904 Uncaught (in promise) Error: Connection got disposed.
    at Object.dispose (main.js:904)
    at Object.disposable.dispose (disposable.ts:96)
    at DisposableCollection.../../packages/core/lib/common/disposable.js.DisposableCollection.dispose (disposable.ts:74)
    at DisposableCollection.disposable.dispose (disposable.ts:96)
    at DisposableCollection.disposable.dispose (disposable.ts:96)
    at DisposableCollection.../../packages/core/lib/common/disposable.js.DisposableCollection.dispose (disposable.ts:74)
    at TerminalWidgetImpl.../../packages/core/lib/browser/widgets/widget.js.BaseWidget.dispose (widget.ts:68)
    at TerminalWidgetImpl.push.../../packages/terminal/lib/browser/terminal-widget-impl.js.TerminalWidgetImpl.dispose (terminal-widget-impl.ts:603)
    at terminal-widget-impl.ts:695
    at HTMLTextAreaElement.<anonymous> (widget.ts:226)

@shyshywhy
Copy link
Contributor Author

I am verifying the PR with the task-provider-sample from here.

Steps:

  • Run Task...
  • custombuildscript: 32.
  • Continue without scanning the task output.
  • Task terminates, see the Terminal will be reused by task, press Enter.
logger-protocol.ts:112 root ERROR The ws channel does not exist 23
log @ logger-protocol.ts:111
(anonymous) @ logger-frontend-module.ts:40
(anonymous) @ logger.ts:311
(anonymous) @ logger.ts:303
Promise.then (async)
../../packages/core/lib/common/logger.js.Logger.log @ logger.ts:298
log @ logger.ts:44
../../packages/core/lib/common/messaging/abstract-connection-provider.js.AbstractConnectionProvider.handleIncomingRawMessage @ abstract-connection-provider.ts:112
WebSocketConnectionProvider.socket.onmessage @ ws-connection-provider.ts:63
ReconnectingWebSocket._handleMessage @ reconnecting-websocket-mjs.js:172
main.js:904 Uncaught (in promise) Error: Connection got disposed.
    at Object.dispose (main.js:904)
    at Object.disposable.dispose (disposable.ts:96)
    at DisposableCollection.../../packages/core/lib/common/disposable.js.DisposableCollection.dispose (disposable.ts:74)
    at DisposableCollection.disposable.dispose (disposable.ts:96)
    at DisposableCollection.disposable.dispose (disposable.ts:96)
    at DisposableCollection.../../packages/core/lib/common/disposable.js.DisposableCollection.dispose (disposable.ts:74)
    at TerminalWidgetImpl.../../packages/core/lib/browser/widgets/widget.js.BaseWidget.dispose (widget.ts:68)
    at TerminalWidgetImpl.push.../../packages/terminal/lib/browser/terminal-widget-impl.js.TerminalWidgetImpl.dispose (terminal-widget-impl.ts:603)
    at terminal-widget-impl.ts:695
    at HTMLTextAreaElement.<anonymous> (widget.ts:226)

I fixed it, and fixed some problems found by my own test.

@kittaakos
Copy link
Contributor

I fixed it, and fixed some problems found by my own test.

Thank you so much, you work blazing fast. I cannot catch up with your pace... I added a few comments here and there, none of them are crucial. Can you please look into them?

I am going to fetch your changes and keep on with the verification. I noticed an issue with the missing exitCode and signal. Maybe you have already fixed them.

packages/plugin-ext/src/plugin/types-impl.ts Show resolved Hide resolved
packages/task/src/node/custom/custom-task.ts Show resolved Hide resolved
packages/task/src/node/task-server.ts Outdated Show resolved Hide resolved
packages/terminal/src/browser/terminal-widget-impl.ts Outdated Show resolved Hide resolved
packages/task/src/node/custom/custom-task-runner.ts Outdated Show resolved Hide resolved
packages/plugin-ext/src/plugin/tasks/tasks.ts Outdated Show resolved Hide resolved
packages/plugin-ext/src/main/browser/tasks-main.ts Outdated Show resolved Hide resolved
packages/plugin-ext/src/plugin/tasks/tasks.ts Outdated Show resolved Hide resolved
packages/plugin-ext/src/plugin/terminal-ext.ts Outdated Show resolved Hide resolved
@shyshywhy
Copy link
Contributor Author

@kittaakos I fixed the above problem and merged it into the previous commit

@kittaakos
Copy link
Contributor

Fixes: #8767

It does not really fix this issue. Although vscode.CustomExecution works, the Gradle task view is not populated in Theia. It works in VS Code. I found these errors when testing the vscode.CustomExecution with the Gradle Tasks extension:

plugin-contribution-handler.ts:382 Uncaught (in promise) Error: command 'gradle.refresh' not found
    at PluginContributionHandler.<anonymous> (plugin-contribution-handler.ts:382)
    at step (plugin-contribution-handler.ts:15)
    at Object.next (plugin-contribution-handler.ts:15)
    at plugin-contribution-handler.ts:15
    at new Promise (<anonymous>)
    at push.../../packages/plugin-ext/lib/main/browser/plugin-contribution-handler.js.__awaiter (plugin-contribution-handler.ts:15)
    at Object.execute (plugin-contribution-handler.ts:379)
    at CommandRegistry.<anonymous> (command.ts:294)
    at step (command.ts:15)
    at Object.next (command.ts:15)
plugin-contribution-handler.ts:382 Uncaught (in promise) Error: command 'gradle.runBuild' not found
    at PluginContributionHandler.<anonymous> (plugin-contribution-handler.ts:382)
    at step (plugin-contribution-handler.ts:15)
    at Object.next (plugin-contribution-handler.ts:15)
    at plugin-contribution-handler.ts:15
    at new Promise (<anonymous>)
    at push.../../packages/plugin-ext/lib/main/browser/plugin-contribution-handler.js.__awaiter (plugin-contribution-handler.ts:15)
    at Object.execute (plugin-contribution-handler.ts:379)
    at CommandRegistry.<anonymous> (command.ts:294)
    at step (command.ts:15)
    at Object.next (command.ts:15)
plugin-contribution-handler.ts:382 Uncaught (in promise) Error: command 'gradle.explorerFlat' not found
    at PluginContributionHandler.<anonymous> (plugin-contribution-handler.ts:382)
    at step (plugin-contribution-handler.ts:15)
    at Object.next (plugin-contribution-handler.ts:15)
    at plugin-contribution-handler.ts:15
    at new Promise (<anonymous>)
    at push.../../packages/plugin-ext/lib/main/browser/plugin-contribution-handler.js.__awaiter (plugin-contribution-handler.ts:15)
    at Object.execute (plugin-contribution-handler.ts:379)
    at CommandRegistry.<anonymous> (command.ts:294)
    at step (command.ts:15)
    at Object.next (command.ts:15)
root ERROR [hosted-plugin: 20438] Promise rejection not handled in one second: Error: argument does not match one of these constraints: arg instanceof constraint, arg.constructor === constraint, nor constraint(arg) === true , reason: Error: argument does not match one of these constraints: arg instanceof constraint, arg.constructor === constraint, nor constraint(arg) === true
root ERROR [hosted-plugin: 20438] With stack trace: Error: argument does not match one of these constraints: arg instanceof constraint, arg.constructor === constraint, nor constraint(arg) === true
    at validateConstraint (file:///Users/akos.kitta/git/theia/examples/electron/lib/vs/editor/editor.main.js:16287:19)
    at Object.validateConstraints (file:///Users/akos.kitta/git/theia/examples/electron/lib/vs/editor/editor.main.js:16262:13)
    at idOrCommand.handler (file:///Users/akos.kitta/git/theia/examples/electron/lib/vs/editor/editor.main.js:82213:29)
    at InstantiationService.invokeFunction (file:///Users/akos.kitta/git/theia/examples/electron/lib/vs/editor/editor.main.js:84046:27)
    at Object.execute (file:///Users/akos.kitta/git/theia/examples/electron/lib/68.bundle.js:601:64)
    at CommandRegistry.<anonymous> (file:///Users/akos.kitta/git/theia/examples/electron/lib/bundle.js:133591:62)
    at step (file:///Users/akos.kitta/git/theia/examples/electron/lib/bundle.js:133368:23)
    at Object.next (file:///Users/akos.kitta/git/theia/examples/electron/lib/bundle.js:133349:53)
    at fulfilled (file:///Users/akos.kitta/git/theia/examples/electron/lib/bundle.js:133340:58)
Uncaught Error: Language client is not ready yet

Error: Language client is not ready yet
    at T.sendRequest (/Users/akos.kitta/.theia/extensions/redhat.java-0.76.0/extension/dist/extension.js:1)
    at o (/Users/akos.kitta/.theia/extensions/redhat.java-0.76.0/extension/dist/extension.js:9)
    at Object.provideFoldingRanges (/Users/akos.kitta/.theia/extensions/redhat.java-0.76.0/extension/dist/extension.js:9)
    at FoldingProviderAdapter.provideFoldingRanges (/Users/akos.kitta/git/theia/packages/plugin-ext/lib/plugin/languages/folding.js:31)
    at /Users/akos.kitta/git/theia/packages/plugin-ext/lib/plugin/languages.js:427
    at LanguagesExtImpl.<anonymous> (/Users/akos.kitta/git/theia/packages/plugin-ext/lib/plugin/languages.js:156)
    at step (/Users/akos.kitta/git/theia/packages/plugin-ext/lib/plugin/languages.js:48)
    at Object.next (/Users/akos.kitta/git/theia/packages/plugin-ext/lib/plugin/languages.js:29)
    at /Users/akos.kitta/git/theia/packages/plugin-ext/lib/plugin/languages.js:23
    at new Promise (<anonymous>)
    at /Users/akos.kitta/git/theia/examples/electron/lib/vs/editor/editor.main.js:1607
bundle.js:133596 Uncaught (in promise) Error: The command '__plugin.view.title.action.gradle.explorerFlat' cannot be executed. There are no active handlers available for the command.
    at CommandRegistry.<anonymous> (bundle.js:133596)
    at step (bundle.js:133368)
    at Object.next (bundle.js:133349)
    at bundle.js:133343
    at new Promise (<anonymous>)
    at ../../packages/core/lib/common/command.js.__awaiter (bundle.js:133339)
    at CommandRegistry.../../packages/core/lib/common/command.js.CommandRegistry.executeCommand (bundle.js:133581)
    at TabBarToolbar._this.executeCommand (bundle.js:121921)
    at HTMLUnknownElement.callCallback (bundle.js:51456)
    at Object.invokeGuardedCallbackDev (bundle.js:51505)

@kittaakos
Copy link
Contributor

I found an error when playing with the Gradle Tasks extension:

  • Clone https://github.com/jitpack/gradle-simple,
  • Open in a Theia workspace,
  • Build starts, Gradle config starts 👍,
  • See the thumbs-up in the status bar, click on it,
  • Nothing happens, see the error in the log.
Uncaught (in promise) Error: Run task config does not return after being started
    at TasksExtImpl.<anonymous> (/Users/akos.kitta/gi…/tasks/tasks.js:254)
    at step (/Users/akos.kitta/gi…n/tasks/tasks.js:48)
    at Object.next (/Users/akos.kitta/gi…n/tasks/tasks.js:29)
    at fulfilled (/Users/akos.kitta/gi…n/tasks/tasks.js:20)
    at processTicksAndRejections (/Users/akos.kitta/gi…s/task_queues.js:94)

@kittaakos
Copy link
Contributor

Unfortunately, there is another issue. When I install the Language Support for Java(TM) by Red Hat VSX, I can check the build status task with the following command:

Screen Shot 2021-03-23 at 13 23 03

In VS Code, it shows the terminal that runs the task:
Screen Shot 2021-03-23 at 13 24 48

In Theia, I always see this:
Screen Shot 2021-03-23 at 13 25 09

But the task is not active anymore.

@kittaakos
Copy link
Contributor

The PR looks very promising, @shyshywhy. If you need assistance with the bug-fixes, let me know, and I try to chime in into the development. Thank you so much for your help so far 🙏

@shyshywhy
Copy link
Contributor Author

Fixes: #8767

It does not really fix this issue. Although vscode.CustomExecution works, the Gradle task view is not populated in Theia. It works in VS Code. I found these errors when testing the vscode.CustomExecution with the Gradle Tasks extension:

plugin-contribution-handler.ts:382 Uncaught (in promise) Error: command 'gradle.refresh' not found
    at PluginContributionHandler.<anonymous> (plugin-contribution-handler.ts:382)
    at step (plugin-contribution-handler.ts:15)
    at Object.next (plugin-contribution-handler.ts:15)
    at plugin-contribution-handler.ts:15
    at new Promise (<anonymous>)
    at push.../../packages/plugin-ext/lib/main/browser/plugin-contribution-handler.js.__awaiter (plugin-contribution-handler.ts:15)
    at Object.execute (plugin-contribution-handler.ts:379)
    at CommandRegistry.<anonymous> (command.ts:294)
    at step (command.ts:15)
    at Object.next (command.ts:15)
plugin-contribution-handler.ts:382 Uncaught (in promise) Error: command 'gradle.runBuild' not found
    at PluginContributionHandler.<anonymous> (plugin-contribution-handler.ts:382)
    at step (plugin-contribution-handler.ts:15)
    at Object.next (plugin-contribution-handler.ts:15)
    at plugin-contribution-handler.ts:15
    at new Promise (<anonymous>)
    at push.../../packages/plugin-ext/lib/main/browser/plugin-contribution-handler.js.__awaiter (plugin-contribution-handler.ts:15)
    at Object.execute (plugin-contribution-handler.ts:379)
    at CommandRegistry.<anonymous> (command.ts:294)
    at step (command.ts:15)
    at Object.next (command.ts:15)
plugin-contribution-handler.ts:382 Uncaught (in promise) Error: command 'gradle.explorerFlat' not found
    at PluginContributionHandler.<anonymous> (plugin-contribution-handler.ts:382)
    at step (plugin-contribution-handler.ts:15)
    at Object.next (plugin-contribution-handler.ts:15)
    at plugin-contribution-handler.ts:15
    at new Promise (<anonymous>)
    at push.../../packages/plugin-ext/lib/main/browser/plugin-contribution-handler.js.__awaiter (plugin-contribution-handler.ts:15)
    at Object.execute (plugin-contribution-handler.ts:379)
    at CommandRegistry.<anonymous> (command.ts:294)
    at step (command.ts:15)
    at Object.next (command.ts:15)
root ERROR [hosted-plugin: 20438] Promise rejection not handled in one second: Error: argument does not match one of these constraints: arg instanceof constraint, arg.constructor === constraint, nor constraint(arg) === true , reason: Error: argument does not match one of these constraints: arg instanceof constraint, arg.constructor === constraint, nor constraint(arg) === true
root ERROR [hosted-plugin: 20438] With stack trace: Error: argument does not match one of these constraints: arg instanceof constraint, arg.constructor === constraint, nor constraint(arg) === true
    at validateConstraint (file:///Users/akos.kitta/git/theia/examples/electron/lib/vs/editor/editor.main.js:16287:19)
    at Object.validateConstraints (file:///Users/akos.kitta/git/theia/examples/electron/lib/vs/editor/editor.main.js:16262:13)
    at idOrCommand.handler (file:///Users/akos.kitta/git/theia/examples/electron/lib/vs/editor/editor.main.js:82213:29)
    at InstantiationService.invokeFunction (file:///Users/akos.kitta/git/theia/examples/electron/lib/vs/editor/editor.main.js:84046:27)
    at Object.execute (file:///Users/akos.kitta/git/theia/examples/electron/lib/68.bundle.js:601:64)
    at CommandRegistry.<anonymous> (file:///Users/akos.kitta/git/theia/examples/electron/lib/bundle.js:133591:62)
    at step (file:///Users/akos.kitta/git/theia/examples/electron/lib/bundle.js:133368:23)
    at Object.next (file:///Users/akos.kitta/git/theia/examples/electron/lib/bundle.js:133349:53)
    at fulfilled (file:///Users/akos.kitta/git/theia/examples/electron/lib/bundle.js:133340:58)
Uncaught Error: Language client is not ready yet

Error: Language client is not ready yet
    at T.sendRequest (/Users/akos.kitta/.theia/extensions/redhat.java-0.76.0/extension/dist/extension.js:1)
    at o (/Users/akos.kitta/.theia/extensions/redhat.java-0.76.0/extension/dist/extension.js:9)
    at Object.provideFoldingRanges (/Users/akos.kitta/.theia/extensions/redhat.java-0.76.0/extension/dist/extension.js:9)
    at FoldingProviderAdapter.provideFoldingRanges (/Users/akos.kitta/git/theia/packages/plugin-ext/lib/plugin/languages/folding.js:31)
    at /Users/akos.kitta/git/theia/packages/plugin-ext/lib/plugin/languages.js:427
    at LanguagesExtImpl.<anonymous> (/Users/akos.kitta/git/theia/packages/plugin-ext/lib/plugin/languages.js:156)
    at step (/Users/akos.kitta/git/theia/packages/plugin-ext/lib/plugin/languages.js:48)
    at Object.next (/Users/akos.kitta/git/theia/packages/plugin-ext/lib/plugin/languages.js:29)
    at /Users/akos.kitta/git/theia/packages/plugin-ext/lib/plugin/languages.js:23
    at new Promise (<anonymous>)
    at /Users/akos.kitta/git/theia/examples/electron/lib/vs/editor/editor.main.js:1607
bundle.js:133596 Uncaught (in promise) Error: The command '__plugin.view.title.action.gradle.explorerFlat' cannot be executed. There are no active handlers available for the command.
    at CommandRegistry.<anonymous> (bundle.js:133596)
    at step (bundle.js:133368)
    at Object.next (bundle.js:133349)
    at bundle.js:133343
    at new Promise (<anonymous>)
    at ../../packages/core/lib/common/command.js.__awaiter (bundle.js:133339)
    at CommandRegistry.../../packages/core/lib/common/command.js.CommandRegistry.executeCommand (bundle.js:133581)
    at TabBarToolbar._this.executeCommand (bundle.js:121921)
    at HTMLUnknownElement.callCallback (bundle.js:51456)
    at Object.invokeGuardedCallbackDev (bundle.js:51505)

For this issue, i have fixed, but not sure if the repair is appropriate.

In the Task, updateDefinitionBasedOnExecution will modify the type of TaskDefinition, resulting in plugin judgment errors.

private updateDefinitionBasedOnExecution(): void {
        if (this.taskExecution instanceof ProcessExecution) {
            Object.assign(this.taskDefinition, {
                type: 'process',
                id: this.taskExecution.computeId(),
                taskType: this.taskDefinition!.type
            });
        } else if (this.taskExecution instanceof ShellExecution) {
            Object.assign(this.taskDefinition, {
                type: 'shell',
                id: this.taskExecution.computeId(),
                taskType: this.taskDefinition!.type
            });
        } else if (this.taskExecution instanceof CustomExecution) {
            Object.assign(this.taskDefinition, {
                type: 'customExecution',
                id: this.taskExecution.computeId(),
                taskType: this.taskDefinition!.type
            });
        } else {
            Object.assign(this.taskDefinition, {
                type: '$empty',
                id: UUID.uuid4(),
                taskType: this.taskDefinition!.type
            });
        }
    }

so, i change it, but it’s not clear if it conflicts with theia design

@shyshywhy
Copy link
Contributor Author

Unfortunately, there is another issue. When I install the Language Support for Java(TM) by Red Hat VSX, I can check the build status task with the following command:

Screen Shot 2021-03-23 at 13 23 03

In VS Code, it shows the terminal that runs the task:
Screen Shot 2021-03-23 at 13 24 48

In Theia, I always see this:
Screen Shot 2021-03-23 at 13 25 09

But the task is not active anymore.

I think can open another issue to track this issue.

The reason for this problem is that the repeated judgment of the task does not distinguish the client, and there is no recovery mechanism after the terminal is closed.

@kittaakos
Copy link
Contributor

Although vscode.CustomExecution works, the Gradle task view is not populated in Theia.

👍 This works now:

screencast 2021-03-30 10-04-12

@kittaakos
Copy link
Contributor

Thank you for the update, @shyshywhy. I will approve your changes and leave the PR open for a few more days if someone else wants to chime in and try it in action. I have not used the vscode.CustomExecution before, but I have tried the followings with your changeset:

Overall, it's a great improvement. Thank you so much for your help 👍


There are a few issues I have noticed. We can fix them later:

  1. Somehow, I managed to get an error when opening the terminal for a task. I am not sure how to reproduce it:
command.ts:15 Uncaught (in promise) Error: Run task config does not return after being started
    at TasksExtImpl.<anonymous> (/Users/akos.kitta/git/theia/packages/plugin-ext/lib/plugin/tasks/tasks.js:254)
    at step (/Users/akos.kitta/git/theia/packages/plugin-ext/lib/plugin/tasks/tasks.js:48)
    at Object.next (/Users/akos.kitta/git/theia/packages/plugin-ext/lib/plugin/tasks/tasks.js:29)
    at fulfilled (/Users/akos.kitta/git/theia/packages/plugin-ext/lib/plugin/tasks/tasks.js:20)
    at processTicksAndRejections (internal/process/task_queues.js:94)
  1. When a task is finished, I can see the 👍 (thumbs-up icon) in the status bar, when I click on it, I see the notification with the action, but I cannot reopen the terminal for the task. (See here.)
    Screen Shot 2021-03-30 at 13 08 10

  2. If I am not mistaken, Theia does create an identifier for a task. VS Code has a KeyedTaskIdentifier that can be used if two tasks are the "same". VS Code can report that a "same" task is already running, or here is the result of that task.

  3. When trying the Gradle Tasks VS Code extension, I got this: (unrelated to this PR)

Error: Language client is not ready yet
    at T.sendRequest (/Users/akos.kitta/.t…dist/extension.js:1)
    at o (/Users/akos.kitta/.t…dist/extension.js:9)
    at Object.provideFoldingRanges (/Users/akos.kitta/.t…dist/extension.js:9)
    at FoldingProviderAdapter.provideFoldingRanges (/Users/akos.kitta/gi…uages/folding.js:31)
    at /Users/akos.kitta/gi…in/languages.js:427
    at LanguagesExtImpl.<anonymous> (/Users/akos.kitta/gi…in/languages.js:156)
    at step (/Users/akos.kitta/gi…gin/languages.js:48)
    at Object.next (/Users/akos.kitta/gi…gin/languages.js:29)
    at /Users/akos.kitta/gi…gin/languages.js:23
    at new Promise (<anonymous>)
    at errors.ts:26
  1. I got this once when I reloaded the browser example: (I assume this is unrelated to vscode.CustomExecution)
root ERROR Could not transfer 'README.md' file from 'redhat_java' Error: Request aborted
    at onaborted (/Users/akos.kitta/git/theia/node_modules/express/lib/response.js:1025:15)
    at Immediate.<anonymous> (/Users/akos.kitta/git/theia/node_modules/express/lib/response.js:1067:9)
    at processImmediate (internal/timers.js:439:21)
root ERROR Could not transfer 'README.md' file from 'richardwillis_vscode_gradle' Error: Request aborted
    at onaborted (/Users/akos.kitta/git/theia/node_modules/express/lib/response.js:1025:15)
    at Immediate.<anonymous> (/Users/akos.kitta/git/theia/node_modules/express/lib/response.js:1067:9)
    at processImmediate (internal/timers.js:439:21)
  1. There was some issue with OVSX when I started the app: (Seems to be unrelated to this PR)
root ERROR [foo-bar.task-provider-samples]: failed to refresh, reason: Error: Extension with id foo-bar.task-provider-samples not found at https://open-vsx.org/api
    at VSXRegistryAPI.<anonymous> (http://localhost:3000/71.bundle.js:3165:31)
    at step (http://localhost:3000/71.bundle.js:3020:23)
    at Object.next (http://localhost:3000/71.bundle.js:3001:53)
    at fulfilled (http://localhost:3000/71.bundle.js:2992:58)

Signed-off-by: Lewin Tan <e_tanhaiyang@163.com>
Signed-off-by: Lewin Tan <e_tanhaiyang@163.com>
@shyshywhy shyshywhy force-pushed the ft/support_custom_execution branch from 80725c2 to 0d03021 Compare April 2, 2021 10:29
@shyshywhy
Copy link
Contributor Author

@shyshywhy do you mind rebasing the pull-request against the latest master? There are some changes which will be required due to the re-export pull-request: #9124.

ok,its done.

@kittaakos kittaakos merged commit fd91f21 into eclipse-theia:master Apr 6, 2021
@vince-fugnitto vince-fugnitto added this to the 1.13.0 milestone Apr 6, 2021
@shyshywhy shyshywhy deleted the ft/support_custom_execution branch April 7, 2021 02:17
@@ -89,7 +90,7 @@ export class TaskServerImpl implements TaskServer, Disposable {
}

async run(taskConfiguration: TaskConfiguration, ctx?: string, option?: RunTaskOption): Promise<TaskInfo> {
const runner = this.runnerRegistry.getRunner(taskConfiguration.type);
const runner = this.runnerRegistry.getRunner(taskConfiguration.taskType);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@shyshywhy
could you share the reason why type was replaced by taskType?

@vince-fugnitto
Copy link
Member

The commit seems to have broken a lot of functionality from tasks, should we revert for the time being?

If a PR causes regressions after landing then an author and maintainers have 2 days to resolve them after that a PR has to be reverted.

If the issues are not resolved before the release I think we should revert as to not release a broken task system.

@tsmaeder
Copy link
Contributor

@vince-fugnitto So what breakage is left?

@vince-fugnitto
Copy link
Member

@RomanNikitenko
Copy link
Contributor

#9341

@azatsarynnyy
Copy link
Member

I fully agree with Vincent. It should be reverted according to our PR policy. As the PR originator hasn't responded for a week.

@RomanNikitenko
Copy link
Contributor

RomanNikitenko commented Apr 16, 2021

I'm not able to take in progress any issue from the list above soon, so I'm +1 for reverting...

@azatsarynnyy
Copy link
Member

I fully agree with Vincent. It should be reverted according to our PR policy. As the PR originator hasn't responded for a week.

unless someone else is going to fix all the breakages before the release

@azatsarynnyy
Copy link
Member

On the other hand, we have almost two weeks before the release date...
So, I see two choices here:

  • revert the PR
  • or get the concrete assignees for all the issues found, who could help to fix all of them

@tsmaeder
Copy link
Contributor

I think we all agree this PR should not have been merged. The question now is what the way forward should be. Personally, I think we (probably me, since I already have a head start) should fix the issues, The PR was not huge and I think we could fix the issues in question within maybe 2 days. At least invest a couple of hours to see what the problem is before throwing out the feature.

@vince-fugnitto
Copy link
Member

I think we all agree this PR should not have been merged. The question now is what the way forward should be. Personally, I think we (probably me, since I already have a head start) should fix the issues, The PR was not huge and I think we could fix the issues in question within maybe 2 days. At least invest a couple of hours to see what the problem is before throwing out the feature.

@tsmaeder since we have time before the release I think we can spend time to fix the regressions, and if ever we see that we run out of time, or there are too many regressions for the framework to be released we can think of reverting.

@tsmaeder
Copy link
Contributor

Sounds like a plan!

@RomanNikitenko
Copy link
Contributor

Great!
I can help with testing :-)

@alvsan09 alvsan09 mentioned this pull request Apr 19, 2021
1 task
@alvsan09
Copy link
Contributor

The PR #9189 merged 5 commits to support the Tasks customExecution API,
one of the commits ("Fixed task type is modified") is the one that has caused cascading issues related to task type,
The PR #9373, removes only that particular problematic commit and two other trying to work around the main issue.

The good part is that removing that particular commit does not remove the support for customExecution,
the impacted scenario is #8767 where gradle tasks are not visible.

if we consider PR #9373 as a good base, we can then concentrate on fixing #8767.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
vscode issues related to VSCode compatibility
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Gradle Tasks extension does not work in Theia support vscode.CustomExecution api
7 participants