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

Sending multiple codeLens requests from VSCode #3116

Closed
kenkangxgwe opened this issue Jan 10, 2020 · 6 comments
Closed

Sending multiple codeLens requests from VSCode #3116

kenkangxgwe opened this issue Jan 10, 2020 · 6 comments

Comments

@kenkangxgwe
Copy link

kenkangxgwe commented Jan 10, 2020

Issue Type: Bug

I am developing a language extension but it receives multiple (two or more) codeLens requests from VSCode whenever a file is opened or changed.

After I disabled Live Share extension the codeLens went back to normal. Once a time.
Actually, I just installed the Live Share extension, but did not even run any session with it. So I guess the Live Share somehow duplicates the request.

Here is the log that shows the editor sending 3 requests with the same textDocument URI simultaneously. The textDocument was not changed during this short time.

[Trace - 1:13:20 AM] Sending request 'textDocument/codeLens - (3)'.
Params: {
    "textDocument": {
        "uri": "file:///d%3A/Projects/lsp-wl/repo/src/WolframLanguageServer/Server.wl"
    }
}


[Trace - 1:13:20 AM] Sending request 'textDocument/codeLens - (4)'.
Params: {
    "textDocument": {
        "uri": "file:///d%3A/Projects/lsp-wl/repo/src/WolframLanguageServer/Server.wl"
    }
}


[Trace - 1:13:20 AM] Sending request 'textDocument/codeLens - (5)'.
Params: {
    "textDocument": {
        "uri": "file:///d%3A/Projects/lsp-wl/repo/src/WolframLanguageServer/Server.wl"
    }
}

microsoft/vscode#88353 (comment)

Extension version: 1.0.1456
VS Code version: Code 1.41.1 (26076a4de974ead31f97692a0d32f90d735645c0, 2019-12-18T14:58:56.166Z)
OS version: Windows_NT x64 10.0.18363

System Info
Item Value
CPUs Intel(R) Core(TM) i7-7700HQ CPU @ 2.80GHz (8 x 2808)
GPU Status 2d_canvas: enabled
flash_3d: enabled
flash_stage3d: enabled
flash_stage3d_baseline: enabled
gpu_compositing: enabled
metal: disabled_off
multiple_raster_threads: enabled_on
oop_rasterization: disabled_off
protected_video_decode: enabled
rasterization: enabled
skia_renderer: disabled_off
surface_control: disabled_off
surface_synchronization: enabled_on
video_decode: enabled
viz_display_compositor: enabled_on
viz_hit_test_surface_layer: disabled_off
webgl: enabled
webgl2: enabled
Load (avg) undefined
Memory (System) 15.89GB (6.64GB free)
Process Argv
Screen Reader no
VM 0%
@IlyaBiryukov
Copy link
Collaborator

@daytonellwanger Is this by design?
CC @fubaduba

@daytonellwanger
Copy link
Collaborator

This is not by design, and quite unexpected to be happening outside of a Live Share session. Outside of a Live Share session, Live Share shouldn't be modifying the behavior of the IDE in any way.

@kenkangxgwe could you provide a minimal extension that repros the problem?

kenkangxgwe added a commit to kenkangxgwe/vscode-extension-samples that referenced this issue Jan 11, 2020
@kenkangxgwe
Copy link
Author

Sure, just use the above commit kenkangxgwe/vscode-extension-samples@097b16b, modified from official samples.
In debug window, change the message level to verbose and open a plaintext file you will see two codeLens requests at the same time.

@kenkangxgwe
Copy link
Author

Any updates?

@jmbockhorst
Copy link

I am running into this too. Getting multiple codelens requests for one document change even when there is no live share session going. Disabling live share fixes the problem.

@derekbekoe
Copy link
Collaborator

I'm going to close this as #4470 will address the issue of Live Share activating when not in use.

@derekbekoe derekbekoe closed this as not planned Won't fix, can't repro, duplicate, stale Nov 12, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

8 participants