ionide / ionide-vscode-fsharp

VS Code plugin for F# development
http://ionide.io
MIT License
859 stars 278 forks source link

Double space needed to "refresh" Ionide type checker #1622

Open isaacabraham opened 2 years ago

isaacabraham commented 2 years ago

Describe the bug

Sometimes Ionide doesn't "refresh" itself when there are changes to the code e.g. intellisense or coloration isn't refreshed. I've seen that sometimes hitting two spaces (honestly!) will refresh the typechecker. Nothing else does it short of a reset, but for some reason two spaces does the trick.

Expected behaviour

The type checker should never get out of sync, but if it does, it's unclear why double-space refreshes it.

Machine info

open-collective-bot[bot] commented 2 years ago

Hey @isaacabraham :wave:,

Thanks for backing our project. If possible, We will handle your issue with priority support. To make sure we don't forget how special you are, we added a backer label to your issue.

Thanks again for backing us :tada:!

witoldsz commented 2 years ago

I have same issue all the time. If I change something in one file and it affects the other, I have to edit anything in that other file, like hitting a space and backspace and then all the checking and what-else kicks in.

mrboring commented 2 years ago

I have the same issue. Need to press space then delete the space to get syntax highlighting to kick in.

UPDATE: I also get this issue when opening a folder in VSCODE. I tend to leave files open when I close VSCODE, and they are opened automatically next time I start it. The selected file does not have syntax highlighting, but other opens files do. Same solution works: space/delete space. Also, I often see errors (red squigglies) in Expecto test files. Again space/delete space solves this.

baronfel commented 2 years ago

my guess based on these reports is that:

a fix for this might be to force those endpoints to wait for fresh typechecking responses instead of trying to find recent ones