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

There is no document for breakpointinput:vs.editor.ICodeEditor%3A1 #7671

Open
akosyakov opened this issue Apr 27, 2020 · 10 comments
Open

There is no document for breakpointinput:vs.editor.ICodeEditor%3A1 #7671

akosyakov opened this issue Apr 27, 2020 · 10 comments
Labels
bug bugs found in the application help wanted issues meant to be picked up, require help 🤔 needs more info issues that require more info from the author vscode issues related to VSCode compatibility

Comments

@akosyakov
Copy link
Member

It seems we provide documents for inline editors like breakpoint expressions editor to the plugin host process. Not sure we should do it.

Error: There is no document for breakpointinput:vs.editor.ICodeEditor%3A1
    at CodeLensAdapter.provideCodeLenses (/theia/node_modules/@theia/plugin-ext/lib/plugin/languages/lens.js:70)
    at /theia/node_modules/@theia/plugin-ext/lib/plugin/languages.js:372
    at LanguagesExtImpl.<anonymous> (/theia/node_modules/@theia/plugin-ext/lib/plugin/languages.js:153)
    at step (/theia/node_modules/@theia/plugin-ext/lib/plugin/languages.js:47)
    at Object.next (/theia/node_modules/@theia/plugin-ext/lib/plugin/languages.js:28)
    at /theia/node_modules/@theia/plugin-ext/lib/plugin/languages.js:22
    at new Promise (<anonymous>)
    at __awaiter (/theia/node_modules/@theia/plugin-ext/lib/plugin/languages.js:18)
    at LanguagesExtImpl.withAdapter (/theia/node_modules/@theia/plugin-ext/lib/plugin/languages.js:145)
    at LanguagesExtImpl.$provideCodeLenses (/theia/node_modules/@theia/plugin-ext/lib/plugin/languages.js:372)
    at editor.main.js:30
@akosyakov akosyakov added bug bugs found in the application vscode issues related to VSCode compatibility 🤔 needs more info issues that require more info from the author help wanted issues meant to be picked up, require help labels Apr 27, 2020
@jili544
Copy link

jili544 commented Mar 23, 2021

hello I also encountered the same problem, how can I solve it?

@vince-fugnitto
Copy link
Member

hello I also encountered the same problem, how can I solve it?

@jili544 thank you for the response, do you mind providing details on how you reproduced the issue (steps)?

@tsmaeder
Copy link
Contributor

To reproduce, open any file (for example, a package.json) while the debug view is open.

@colin-grant-work
Copy link
Contributor

colin-grant-work commented Jun 25, 2021

To reproduce, open any file (for example, a package.json) while the debug view is open.

Or even when the debug view isn't open. I seem to get it opening any source code file at all. Closing the debug view entirely doesn't stop the error. I hadn't seen this previously, but in the last 3-4 weeks (at least), it's been pretty constant.

@FinnChen
Copy link
Contributor

FinnChen commented Jun 1, 2022

To reproduce this problem, follow the steps below.
step 1: install the GitLens VS Code extension
step 2: open any file

Error: There is no document for breakpointinput:vs.editor.ICodeEditor%3A26
    at LinkProviderAdapter.provideLinks (:3000/Users/finn/CloudIDE/theia/packages/plugin-ext/lib/plugin/languages/link-provider.js:31:35)
    at :3000/Users/finn/CloudIDE/theia/packages/plugin-ext/lib/plugin/languages.js:281:97
    at LanguagesExtImpl.withAdapter (:3000/Users/finn/CloudIDE/theia/packages/plugin-ext/lib/plugin/languages.js:112:20)
    at LanguagesExtImpl.$provideDocumentLinks (:3000/Users/finn/CloudIDE/theia/packages/plugin-ext/lib/plugin/languages.js:281:21)
    at RPCProtocolImpl.doInvokeHandler (:3000/Users/finn/CloudIDE/theia/packages/plugin-ext/lib/common/rpc-protocol.js:232:23)
    at RPCProtocolImpl.invokeHandler (:3000/Users/finn/CloudIDE/theia/packages/plugin-ext/lib/common/rpc-protocol.js:217:41)
    at RPCProtocolImpl.receiveRequest (:3000/Users/finn/CloudIDE/theia/packages/plugin-ext/lib/common/rpc-protocol.js:181:33)
    at RPCProtocolImpl.receiveOneMessage (:3000/Users/finn/CloudIDE/theia/packages/plugin-ext/lib/common/rpc-protocol.js:145:26)
    at :3000/Users/finn/CloudIDE/theia/packages/plugin-ext/lib/common/rpc-protocol.js:69:48
    at :3000/Users/finn/CloudIDE/theia/packages/core/lib/common/event.js:103:69
    at errors.ts:26:12

@FinnChen
Copy link
Contributor

FinnChen commented Jun 1, 2022

I don't know if I found the root cause.

Probably when create the DebugBreakpointWidget input editor, we should emit a event to notify the EditorAndDocumentStateComputer a MonacoEditorModel was added.

 async createInline(uri: URI, node: HTMLElement, options?: MonacoEditor.IOptions): Promise<MonacoEditor> {
        return this.doCreateEditor(uri, async (override, toDispose) => {
            const overrides = override ? Array.from(override) : [];
            overrides.push([IContextMenuService, { showContextMenu: () => {/** no op! */ } }]);
            const document = new MonacoEditorModel({
                uri,
                readContents: async () => '',
                dispose: () => { }
            }, this.m2p, this.p2m);
            toDispose.push(document);
            // =======================================================
            // probably we should emit a event to notify a model added
            // =======================================================
            const model = (await document.load()).textEditorModel;
            return new MonacoEditor(
                uri,
                document,
                node,
                this.services,
                Object.assign({
                    model,
                    isSimpleWidget: true,
                    autoSizing: false,
                    minHeight: 1,
                    maxHeight: 1
                }, MonacoEditorProvider.inlineOptions, options),
                overrides
            );
        });
    }

@safisa
Copy link
Contributor

safisa commented Jun 30, 2022

Hi,
I am now facing the same error in the console log, when using the vscode.git and vscode.git-ui extensions/plugins.
When opening any text file I am seeing the error:

errors.ts:26 Uncaught Error: There is no document for breakpointinput:vs.editor.ICodeEditor%3A4

Error: There is no document for breakpointinput:vs.editor.ICodeEditor%3A4
    at LinkProviderAdapter.provideLinks (c:\proj\node_modules\@theia\plugin-ext\lib\plugin\languages\link-provider.js:31:35)
    at c:\proj\node_modules\@theia\plugin-ext\lib\plugin\languages.js:287:97
    at LanguagesExtImpl.withAdapter (c:\proj\node_modules\@theia\plugin-ext\lib\plugin\languages.js:118:20)
    at LanguagesExtImpl.$provideDocumentLinks (c:\proj\node_modules\@theia\plugin-ext\lib\plugin\languages.js:287:21)
    at RPCProtocolImpl.doInvokeHandler (c:\proj\node_modules\@theia\plugin-ext\lib\common\rpc-protocol.js:232:23)
    at RPCProtocolImpl.invokeHandler (c:\proj\node_modules\@theia\plugin-ext\lib\common\rpc-protocol.js:217:41)
    at RPCProtocolImpl.receiveRequest (c:\proj\node_modules\@theia\plugin-ext\lib\common\rpc-protocol.js:181:33)
    at RPCProtocolImpl.receiveOneMessage (c:\proj\node_modules\@theia\plugin-ext\lib\common\rpc-protocol.js:145:26)
    at c:\proj\node_modules\@theia\plugin-ext\lib\common\rpc-protocol.js:69:48
    at c:\proj\node_modules\@theia\core\lib\common\event.js:103:69
    at http://<MY_URL>/vendors-node_modules_theia_markers_lib_browser_index_js-node_modules_theia_monaco_lib_browser-34ab92.js:29647:27

Any updates on this issue?

@colin-grant-work
Copy link
Contributor

I believe I now understand the source of the issue. As part of the lifecycle of various widgets, we create Monaco editors for specific purposes (breakpoint log entry input and output), but we either don't register those with the document store available to extensions or their URI's get mangled and aren't accessible under the stringified name used by plugins. As a consequence, when the editor makes requests (for code lenses, for example) that would normally be served by plugins, the plugins find that they can't service the request, and errors are logged. I will do some further investigation and then work to ensure that editors that should not make these requests don't make them.

@danepowell
Copy link
Contributor

danepowell commented Aug 16, 2023

@colin-grant-work did you ever make progress on this?

Does anyone know of a workaround?

I also started to see this error after switching from @theia/git to vscode git in #10786

I just noticed that open-vsx.org is down, I wonder if that could be related.

@vince-fugnitto
Copy link
Member

Does anyone know of a workaround?

@danepowell the error itself should be pretty harmless and there is no workaround at the moment for it. You could investigate if you'd like to find a solution, the latest was to determine which editors might be making these requests when they shouldn't (ex: debug console) (#7671 (comment)).

I just noticed that open-vsx.org is down, I wonder if that could be related.

The error is unrelated to the status of open-vsx.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug bugs found in the application help wanted issues meant to be picked up, require help 🤔 needs more info issues that require more info from the author vscode issues related to VSCode compatibility
Projects
None yet
Development

No branches or pull requests

8 participants