In my case, I was copying the .exe to another directory and running it there. The Could not resolve CoreCLR path error was resolved by also copying MyProject.runtimeconfig.json to the target directory.
Could not resolve CoreCLR path
MyProject.runtimeconfig.json