Can't generate project files (or even open project)

In my case it was a file in Intermediate\Source. In there was a Target.cs file that was conflicting with the one in the C++ Source directory, It must be what is used for Blueprint-only. Deleting that got it all working again.