Ah Haskell!
I've used ghc and ghci in the terminal plenty of times since I first started learning Haskell. Not that I got very far with that! Ha ha!
But I've never used VSCode before, so I'm not sure what to suggest there. I tend to use tmux and vim in the terminal for all of my programming activities.
But I'd guess it probably has something to do with the environment variables that are set in the terminal used in VSCode.
The environment may be slightly different to that in bash in your distros default terminal, perhaps?!
Try running the following command in the terminal in VSCode AND in your main terminal and note the differences:
I'd bet that the $PATH in VSCode is different to the one in your usual terminal!
Re: fixing the problem, I'd imagine there's probably a setting in VSCode somewhere for customising the terminal environment.
But again - I don't use VSCode - so I'll leave that to you to explore.
It might also be worth checking that VSCode's integrated terminal actually IS running bash and not Powershell. I believe Powershell is also available on Linux now... Wouldn't surprise me if they've set that as the default terminal, ha ha! Sounds like something Microsuck would do.
And if that's the case, then changing VSCode's default terminal to bash should fix the problem. Assuming that they let you select which terminal to use!