Nils Reichardt
Nils Reichardt

Reputation: 3579

Codemagic: Error when building for iOS "No profiles for 'com.example.example' were found: Xcode could't find any iOS App Development

I try to build for iOS my app with Codemagic. I followed the steps for signing iOS apps in the Codemagic docs.

No profiles for 'com.example.example' were found: Xcode couldn't find any iOS App Development provisioning profiles matching 'com.example.example'. Automatic signing is disabled and unable to generate a profile. To enable automatic signing, pass -allowProvisioningUpdates to xcodebuild.

Full error message:


Archiving fun.gatch.chat.example...
Automatically signing iOS for device deployment using specified development team in Xcode project: JB7VLPB7F6
Running pod install...                                             85.5s
Running Xcode build...                                          
Xcode archive done.                                          9.5s
Failed to build iOS app
Error output from Xcode build:
↳
    ** ARCHIVE FAILED **


Xcode's output:
↳
    Writing result bundle at path:
        /var/folders/m7/h1mg7c7x40ddjz6mxjxm3htr0000gn/T/flutter_tools.TDA8uV/flutter_ios_build_temp_dirVLpaDD/temporary_xcresult_bundle

    note: Using new build system
    note: Planning
    note: Build preparation complete
    note: Building targets in dependency order
    error: No profiles for 'fun.gatch.chat.example' were found: Xcode couldn't find any iOS App Development provisioning profiles matching 'fun.gatch.chat.example'. Automatic signing is disabled and unable to generate a profile. To enable automatic signing, pass -allowProvisioningUpdates to xcodebuild. (in target 'Runner' from project 'Runner')

    Result bundle written to path:
        /var/folders/m7/h1mg7c7x40ddjz6mxjxm3htr0000gn/T/flutter_tools.TDA8uV/flutter_ios_build_temp_dirVLpaDD/temporary_xcresult_bundle


Error (Xcode): No profiles for 'fun.gatch.chat.example' were found: Xcode couldn't find any iOS App Development provisioning profiles matching 'fun.gatch.chat.example'. Automatic signing is disabled and unable to generate a profile. To enable automatic signing, pass -allowProvisioningUpdates to xcodebuild.


It appears that there was a problem signing your application prior to installation on the device.

Verify that the Bundle Identifier in your project is your signing id in Xcode
  open ios/Runner.xcworkspace

Also try selecting 'Product > Build' to fix the problem:
Encountered error while archiving for device.

Upvotes: 1

Views: 3694

Answers (1)

Nils Reichardt
Nils Reichardt

Reputation: 3579

My problem was that the values for APP_STORE_CONNECT_KEY_IDENTIFIER, CERTIFICATE_PRIVATE_KEY were wrong.

This was a little tricky, because the message for this printed out in the step where I set up the keychain. The error messages give you a concrete reasoning why the signing is failing, like:

  • GET https://api.appstoreconnect.apple.com/v1/bundleIds?limit=100&sort=name&filter%5Bidentifier%5D=bundle.id&filter%5Bplatform%5D=IOS returned 401: Authentication credentials are missing or invalid. - Provide a properly configured and signed bearer token, and make sure that it has not expired. Learn more about Generating Tokens for API Requests https://developer.apple.com/go/?id=api-generating-tokens
  • app-store-connect: error: argument --certificate-key: Provided value
  • app-store-connect: error: argument --private-key: Provided value is not a valid PEM encoded private key

Upvotes: 1

Related Questions