Oh, I didn't know there are VSCode plug-ins for Lilypond.
Which one are you using?
Which one are you using?
https://github.com/lhl2617/VSLilyPond
Its a bit old, but works very well. I contributed a few fixes years ago to make the midi more reliable, depending on the type of keyboard you have