Unable to compile an "installed build" of the editor, random syntax errors, also happens when packaging on non-installed

Hi,

I’m trying to compile an installed build of Unreal 4.27 and I’m having an issue where there will be random syntax errors in automation scripts when I try

Full log:
errorslog.txt (100.8 KB)

Please advise on how to fix this, as I can’t seem to figure out how to.
Some have advised replacing CMake binaries, though this has not fixed it.

This also happens when packaging a game with a non-installed build