microsoft / vscode

Visual Studio Code
https://code.visualstudio.com
MIT License
160.53k stars 28.11k forks source link

Typing `c#` triggers variable suggestions in chat #216757

Open mjbvz opened 2 weeks ago

mjbvz commented 2 weeks ago

Type: Bug

  1. Open chat input
  2. Type c#

bug Completions show up

VS Code version: Code - Insiders 1.91.0-insider (Universal) (6afc1c279374106ca4c60382c0d92ed661f4c7e4, 2024-06-20T05:50:16.512Z) OS version: Darwin arm64 23.5.0 Modes:

System Info |Item|Value| |---|---| |CPUs|Apple M2 Max (12 x 2400)| |GPU Status|2d_canvas: unavailable_software
canvas_oop_rasterization: disabled_off
direct_rendering_display_compositor: disabled_off_ok
gpu_compositing: disabled_software
multiple_raster_threads: enabled_on
opengl: disabled_off
rasterization: disabled_software
raw_draw: disabled_off_ok
skia_graphite: disabled_off
video_decode: disabled_software
video_encode: disabled_software
webgl: unavailable_software
webgl2: unavailable_software
webgpu: unavailable_software| |Load (avg)|4, 5, 5| |Memory (System)|64.00GB (0.53GB free)| |Process Argv|--crash-reporter-id 0fffb5da-9cd7-46fd-9e7f-a1564e8c5fda| |Screen Reader|no| |VM|0%|
bsShoham commented 4 days ago

This looks interesting, I'm thinking of trying to have a go at this issue, may I, and is it available?

I believe this could be solved in a generic way by adding to the CompletionItemProvider interface a function that accept the context (the text model, position, perhaps some other stuff) and returns whether or not suggestion should be shown, allowing each completion provider to add it's own logic