Theia: Error: Unknown decoration type key from text-editor-main.js.TextEditorMain.setDecorationsFast

Created on 1 Mar 2019  路  10Comments  路  Source: eclipse-theia/theia

Reproducible with https://marketplace.visualstudio.com/items?itemName=ms-vscode.Go
And https://github.com/demo-apps/go-gin-app repo

root ERROR [hosted-plugin: 21527] { Error: Unknown decoration type key: TextEditorDecorationType8
    at MonacoEditorService.CodeEditorServiceImpl.resolveDecorationOptions (https://3000-d776232d-4e50-43fd-b267-1d7ef7c1bf5d.ws-eu0.gitpod.io/vs/editor/editor.main.js:85341:23)
    at StandaloneEditor.CodeEditorWidget._resolveDecorationOptions (https://3000-d776232d-4e50-43fd-b267-1d7ef7c1bf5d.ws-eu0.gitpod.io/vs/editor/editor.main.js:92924:44)
    at StandaloneEditor.CodeEditorWidget.setDecorationsFast (https://3000-d776232d-4e50-43fd-b267-1d7ef7c1bf5d.ws-eu0.gitpod.io/vs/editor/editor.main.js:92563:78)
    at TextEditorMain.push.../../packages/plugin-ext/lib/main/browser/text-editor-main.js.TextEditorMain.setDecorationsFast (https://3000-d776232d-4e50-43fd-b267-1d7ef7c1bf5d.ws-eu0.gitpod.io/59.bundle.js:12083:34)
    at TextEditorsMainImpl.push.../../packages/plugin-ext/lib/main/browser/text-editors-main.js.TextEditorsMainImpl.$trySetDecorationsFast (https://3000-d776232d-4e50-43fd-b267-1d7ef7c1bf5d.ws-eu0.gitpod.io/59.bundle.js:12539:48)
    at RPCProtocolImpl.push.../../packages/plugin-ext/lib/api/rpc-protocol.js.RPCProtocolImpl.doInvokeHandler (https://3000-d776232d-4e50-43fd-b267-1d7ef7c1bf5d.ws-eu0.gitpod.io/59.bundle.js:833:23)
    at RPCProtocolImpl.push.../../packages/plugin-ext/lib/api/rpc-protocol.js.RPCProtocolImpl.invokeHandler (https://3000-d776232d-4e50-43fd-b267-1d7ef7c1bf5d.ws-eu0.gitpod.io/59.bundle.js:818:41)
    at RPCProtocolImpl.push.../../packages/plugin-ext/lib/api/rpc-protocol.js.RPCProtocolImpl.receiveRequest (https://3000-d776232d-4e50-43fd-b267-1d7ef7c1bf5d.ws-eu0.gitpod.io/59.bundle.js:782:45)
    at RPCProtocolImpl.push.../../packages/plugin-ext/lib/api/rpc-protocol.js.RPCProtocolImpl.receiveOneMessage (https://3000-d776232d-4e50-43fd-b267-1d7ef7c1bf5d.ws-eu0.gitpod.io/59.bundle.js:768:22)
    at https://3000-d776232d-4e50-43fd-b267-1d7ef7c1bf5d.ws-eu0.gitpod.io/59.bundle.js:711:89
  name: 'Error',
  message: 'Unknown decoration type key: TextEditorDecorationType8' }
bug plug-in system vscode

All 10 comments

@lmcbout I believe it's the same errors you noticed when testing the go vscode extension?

I'm testing go extension :) Do you have an issue already? Is it a dup?

I'm testing go extension :) Do you have an issue already? Is it a dup?

No no :) I know @lmcbout was trying the go extension to see how well it worked.
It'd be nice to know your findings as well while you test.

@tolusha you don't have these errors ?

I didn't have any errors.
I've just put GO extension [1] in the plugins folder and checked.

[1] https://marketplace.visualstudio.com/items?itemName=ms-vscode.Go

Hi,
I tried to install the same vscode go extension. It seems to work. However, there is no textmate. To add the coloring, I created a local copy for

  • GoContribution: in packages/textmate-grammars/src
  • go.tmLanguage.json: in packages/textmate-grammars/data // Copied it from vscode
    -textmate-grammars-frontend-module.ts : add handling for the GoContribution
    then I reloaded the application and I have the textmate available for the "*.go" file.
    I tried the Go:run.. and the debug. Both seems to work well, i was able to add break point in the file as well.
    My changes might not be necessary when Theia supports all vs-code API (Issue #4446 and issue #4448)

I tried to install the same vscode go extension. It seems to work. However, there is no textmate. To add the coloring...

From the go extension documentation there is not mention of providing the textmate-grammar (coloring) so I don't believe the extension attempts to provide it. In addition, I can see coloring in vscode for go files without the extension even installed.

I've installed built-in go extension to enable coloring, you can get it from https://github.com/theia-ide/vscode-builtin-extensions We can move textmate grammars from Theia go extension to textmate-grammars extension as well. Please file an issue and PRs are welcomed as usual.

FYI about grammar, (and the move from theia go extension to textmate-grammars)I it was part of https://github.com/theia-ide/theia/pull/4070
but due to being blocked by https://dev.eclipse.org/ipzilla/show_bug.cgi?id=18775 it was being opt-out of the PR
it is postponed until CQ is accepted

I can reproduce it with https://marketplace.visualstudio.com/items?itemName=hoovercj.vscode-power-mode wanted to have some fun :)

Was this page helpful?
0 / 5 - 0 ratings