-
Notifications
You must be signed in to change notification settings - Fork 28.8k
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
selectionRangeProvider on inner array always returns outer array #91852
Comments
(Experimental duplicate detection) |
Expand to selection works, I know. It must do something different. Yes, the position in the document was wrong. Maybe I changed it by accident before pushing. Anyway, I fixed the position. If you pull again, you will see the correct position. I think those issues you are referring to are linter issues? If so, they don't matter, but I fixed them anyway. Here is a screenshot of an active debug session: And here is the value of
|
It seems that the positions don't make it back to the JSON language server: I add the following to the beginning of the test:
When the test is run, the following is printed: |
I just tried it with 1.44-insider and my tests work again. Thanks! |
Issue Type: Bug
Steps to Reproduce:
Execute
selectionRangeProvider
in an JSON array that is enclosed in another array. It will return the outer array. This behavior changed from 1.41.0 to 1.42.0. In 1.41.0 the inner array was returned.If the selectionrange provider is executed at the current position, it will return the top array (first and last line). In previous version, it returned the array from line 4-7.
I have created a repository with a single that demonstrates this behavior:
https://github.com/fvclaus/vscode-selectionrangeprovider/blob/master/src/test/suite/searchEnclosingArray.test.ts
npm run test
will execute the test. The vscode version can be changed insrc/test/runTests.ts
VS Code version: Code 1.42.1 (c47d83b, 2020-02-11T14:50:36.977Z)
OS version: Linux x64 4.15.0-74-generic snap
Does this issue occur when all extensions are disabled?: Yes
System Info
flash_3d: disabled_software
flash_stage3d: disabled_software
flash_stage3d_baseline: disabled_software
gpu_compositing: disabled_software
metal: disabled_off
multiple_raster_threads: enabled_on
oop_rasterization: disabled_off
protected_video_decode: disabled_off
rasterization: disabled_software
skia_renderer: disabled_off
surface_control: disabled_off
surface_synchronization: enabled_on
video_decode: disabled_software
viz_display_compositor: enabled_on
viz_hit_test_surface_layer: disabled_off
webgl: unavailable_software
webgl2: unavailable_software
Extensions (2)
The text was updated successfully, but these errors were encountered: