Xcode 11, Command CodeSign failed with a nonzero exit code

Ever since updating (against my will) to Xcode 11, I'm getting this error when I try to build my project:

"Command CodeSign failed with a nonzero exit code"

I've tried cleaning my project, resetting my login keychain, and restarting my computer, but I still get this error... what to do?


I solved it by deleting the wrong image file in the 'SceneKitAssetCatalog.scnassets' folder.

I had 2 "Apple Worldwide Developer Relations Certification Authority" certificates. After deleting the older (expired) one in Keychain Access, the error went away in Xcode 13.1.

Same problem. I used to love apple, now I'm moving to other languages away from swift and cocoa. It seems they own me with all this stuff, code signing, tons of manuals, technology updates every five minutes.

Now I can not run my own code, cannot update my app.

Dawn.

what worked for me was to reinstall the profile... then Xcode updated the list of profiles properly. go figure...

Check the Certificate which named Apple Root Certificate Authority, make sure you select the option Use System Defaults under the Trust menu.

Worked for me too. Thanks a lot!

In case someone is still running into this, after hours of attempts this is what finally worked for me: Open Terminal, navigate to project folder and run "xattr -cr ."

Then in Xcode clean project (Shift + Command + K) and rebuild. Good luck!

Has anyone solved the CodeSign proglem. I tried every "solution" presented in this forum, but since then, IOS 17 just came out, so I'm updating now, I'll try again, but if anyone has anything I should know, please reply here.

John

One thing I'm curious about, I'm updating my iPhone iOS now, but it's 16.7.2, But when I went to XCode, its trying to install 17.0.x on my iPhone. Is this because y iPhone no longer supports 17.0.x? It's an iPhone 13, it was release a little more then a year ago, does this mean it's already obsolete.

John

Now I get completely different error message: No such module 'ExpoModulesCore' I'm going to have to try and re-build the expo part and try it again.

This was completely different then the code signing parf.

Just from updating XCode and my IOS.

John

Xcode 11, Command CodeSign failed with a nonzero exit code
 
 
Q