I work with VS code for Nim, but how I (and I'm guessing a lot of Nim users work) usually compile and execute the apps in a separate command-line (ie, what editor or IDE you're using doesn't affect your dev and testing).
Just a total random thumbsuck, but it may be some interaction with "nimsuggest" that can cause this problem? Try disabling the Nim-specific addons in VS Code (or just disabling nimsuggest) and see if that makes a difference?
