Unreal 5.5 Unreal Game Sync (UGS) Perforce: sync p4 client -o [CLIENT] failed!

I’m not sure if you managed to fix the issue, but in my case, the issue seemed to be that the P4PASSWD environment variable was not being set by TeamCity, so the P4Connection could not authenticate. I manually added it as a build parameter and it fixed it. I’m sure there’s a better way to do it, but for now at least it works.