VS Code "Terminal : Clear" command not working as desired

I'm not even sure if you need the answer anymore but... while I couldn't find a VS CODE behavior that can do what you want (I also tried looking for it). What you can do is add these two lines at the very beginning of your code:

import os
os.system('cls')

It will clear all the terminal garbage before each execution.