Unable to generate IPA. unable to build and sign IPA

I’m trying to build iOS version for App Store but I keep having this error from builder

Unable to generate IPA.
unable to build and sign IPA

There are similar issues and the solution has been updating exp cli but I’m using the latest 49.0.3

Build is 078d5e5c-6f56-4647-802e-dd0ab6b9240e

Hi @ttl, I’m sorry you had this issue.

We have introduced some new behavior with the builders, where if your task takes longer than an hour, we automatically clear it. This should allow you to try again since you posted this 6 hours ago.

I also looked into the table of build jobs manually and I could not find your current build, so I think you should try again and let us know if you have any more problems :slight_smile:

Thanks for using Expo!

The issue persists.

Latest build I’ve tried is 074812d7-1551-487a-a4d6-2995b2e6c520.

I’ve tried to build using existing Apple certificates as our team already has the maximum of 3 distribution ones.

Here’s the full log

creating keychain
Executing command: security create-keychain -p ee8b81c0-080b-11e8-b5e3-0050568e0259 /tmp/turtle-agent/ee8b81b1-080b-11e8-b5e3-0050568e0259.keychain
Executing command: security default-keychain -s /tmp/turtle-agent/ee8b81b1-080b-11e8-b5e3-0050568e0259.keychain
Executing command: security set-keychain-settings -t 360000s /tmp/turtle-agent/ee8b81b1-080b-11e8-b5e3-0050568e0259.keychain
Executing command: security list-keychains -d user
Old Keychain list
New Keychain list
Executing command: security list-keychains -s /tmp/turtle-agent/ee8b81b1-080b-11e8-b5e3-0050568e0259.keychain
Unlocking keychain…
Executing command: security unlock-keychain -p ee8b81c0-080b-11e8-b5e3-0050568e0259 /tmp/turtle-agent/ee8b81b1-080b-11e8-b5e3-0050568e0259.keychain
Unlocked keychain
Executing command: security show-keychain-info /tmp/turtle-agent/ee8b81b1-080b-11e8-b5e3-0050568e0259.keychain
deferring keychain deletion
done creating keychain
getting credentials
Importing certificate into keychain…
Certificate has password.
Executing command: security import /tmp/turtle/823d0a42-0e2c-498a-b231-1697d2a94d40/cert-074812d7-1551-487a-a4d6-2995b2e6c520.p12 -A -k /tmp/turtle-agent/ee8b81b1-080b-11e8-b5e3-0050568e0259.keychain -f pkcs12 -P XXX
Imported certificate into keychain
done getting credentials
running shell app builder
extracting build configuration from app.json
[03:26:53] Using gulpfile /usr/local/turtle-agent/tools-public/gulpfile.js
[03:26:53] Starting ‘ios-shell-app’…
IosIcons: setting image functions to alternative sharp implementations
Using manifest: {“android”:{“package”:“xxx”},“androidStatusBar”:{“backgroundColor”:“#1BB7CB”},“icon”:“./src/assets/app-icon.png”,“iconUrl”:“https://d1wp6m56sqw74a.cloudfront.net/~assets/fb0f918418196e0a7b3c7fa166b66441",“ios”:{“bundleIdentifier”:“xxx”},“name”:“xxx”,“orientation”:“portrait”,“sdkVersion”:“23.0.0”,“slug”:“xxx”,“splash”:{“image”:“./src/assets/splashScreen2.png”,“imageUrl”:“https://d1wp6m56sqw74a.cloudfront.net/~assets/6be2f7f02cf2a4b897299adf5c1c6a7d”,“resizeMode”:“cover”},“version”:“0.1.0”,“id”:“@ttl/xxx”,“revisionId”:“0.1.0-r.NVwkjveLwJ”,“publishedTime”:“2018-02-02T11:30:52.109Z”,“bundleUrl”:“https://d1wp6m56sqw74a.cloudfront.net/%40ttl%2Fxxx%2F0.1.0%2F9d00d5b3b48065380ed04477e84923ea-23.0.0-ios.js”,“releaseChannel”:"default”}
Modifying NSBundle configuration at /tmp/turtle/823d0a42-0e2c-498a-b231-1697d2a94d40/archive/Release/ExpoKitApp.xcarchive/Products/Applications/ExpoKitApp.app…
Using shell config: { isShell: true,
manifestUrl: ‘https://exp.host:443/@ttl/xxx’,
releaseChannel: ‘default’ }
Configuring iOS Launch Screen…
2018-02-02 03:26:57.256 ibtoold[29584:222773] WARNING: Unhandled destination metrics: (null)
2018-02-02 03:26:57.271 ibtoold[29584:222773] WARNING: Unhandled destination metrics: (null)
2018-02-02 03:26:57.388 ibtoold[29584:222773] WARNING: Unhandled destination metrics: (null)
2018-02-02 03:26:57.389 ibtoold[29584:222773] WARNING: Unhandled destination metrics: (null)
2018-02-02 03:26:57.389 ibtoold[29584:222773] WARNING: Unhandled destination metrics: (null)
2018-02-02 03:26:57.389 ibtoold[29584:222773] WARNING: Unhandled destination metrics: (null)
2018-02-02 03:26:57.390 ibtoold[29584:222773] WARNING: Unhandled destination metrics: (null)
2018-02-02 03:26:57.391 ibtoold[29584:222773] WARNING: Unhandled destination metrics: (null)
2018-02-02 03:26:57.393 ibtoold[29584:222773] WARNING: Unhandled destination metrics: (null)
2018-02-02 03:26:57.394 ibtoold[29584:222773] WARNING: Unhandled destination metrics: (null)
2018-02-02 03:26:57.394 ibtoold[29584:222773] WARNING: Unhandled destination metrics: (null)
2018-02-02 03:26:57.394 ibtoold[29584:222773] WARNING: Unhandled destination metrics: (null)
2018-02-02 03:26:57.394 ibtoold[29584:222773] WARNING: Unhandled destination metrics: (null)
2018-02-02 03:26:57.395 ibtoold[29584:222773] WARNING: Unhandled destination metrics: (null)
Compiling resources…
Using manifest: {“android”:{“package”:“host.exp.exponent”,“publishBundlePath”:“…/android/app/src/main/assets/kernel.android.bundle”},“description”:“”,“extra”:{“amplitudeApiKey”:“081e5ec53f869b440b225d5e40ec73f9”},“icon”:“https://s3.amazonaws.com/exp-brand-assets/ExponentEmptyManifest_192.png",“iconUrl”:“https://s3.amazonaws.com/exp-brand-assets/ExponentEmptyManifest_192.png”,“ios”:{“bundleIdentifier”:“host.exp.exponent”,“publishBundlePath”:“../ios/Exponent/Supporting/kernel.ios.bundle”,“supportsTablet”:true},“isKernel”:true,“kernel”:{“androidManifestPath”:“../android/app/src/main/assets/kernel-manifest.json”,“iosManifestPath”:“../ios/Exponent/Supporting/kernel-manifest.json”},“loading”:{“hideExponentText”:false,“icon”:“https://s3.amazonaws.com/exp-brand-assets/ExponentEmptyManifest_192.png”,“iconUrl”:“https://s3.amazonaws.com/exp-brand-assets/ExponentEmptyManifest_192.png”},“name”:“exponent-home”,“notification”:{“color”:“#000000”,“icon”:“https://s3.amazonaws.com/exp-us-standard/placeholder-push-icon-blue-circle.png”,“iconUrl”:“https://s3.amazonaws.com/exp-us-standard/placeholder-push-icon-blue-circle.png”},“orientation”:“portrait”,“packagerOpts”:{“config”:“./_universe/rn-cli.config.js”},“primaryColor”:“#cccccc”,“privacy”:“unlisted”,“scheme”:“exp”,“sdkVersion”:“25.0.0”,“slug”:“home”,“version”:“25.0.0”,“id”:“@exponent/home”,“revisionId”:“25.0.0-r.3ygrzLgjpL”,“publishedTime”:“2018-01-16T23:47:17.627Z”,“bundleUrl”:“https://d1wp6m56sqw74a.cloudfront.net/%40exponent%2Fhome%2F25.0.0%2Fc1a154450d896116f345f81d67126ac8-25.0.0-ios.js”,“releaseChannel”:"default”}
Cleaning up iOS…
[03:27:01] Finished ‘ios-shell-app’ after 8.41 s
done running shell app builder
Assuming that client will run creating app on dev center ruby code
done creating app on dev center
building and signing IPA
Executing command: security cms -D -i /tmp/turtle/823d0a42-0e2c-498a-b231-1697d2a94d40/provisioning-823d0a42-0e2c-498a-b231-1697d2a94d40/823d0a42-0e2c-498a-b231-1697d2a94d40.mobileprovision
done retrieving provisioning profile
Checking if teamID is present in keychain and that certificate is valid…
decoding p12 certificate
verifying certificate is installed
Executing command: security find-identity -v -s (XXXXXXXXXX)
confirmed team ID is present in keychain
Chose export method: app-store
writing export-options.plist file…
building IPA
Executing command: fastlane gym -n 823d0a42-0e2c-498a-b231-1697d2a94d40-unsigned.ipa --workspace /usr/local/turtle-agent/shellAppWorkspaces/ios/default/ExpoKitApp.xcworkspace --scheme ExpoKitApp --archive_path /tmp/turtle/823d0a42-0e2c-498a-b231-1697d2a94d40/823d0a42-0e2c-498a-b231-1697d2a94d40.xcarchive --skip_build_archive true -i E296AC9601CA86749EBC2BA3915CDA126B8E5CEE --export_options /tmp/turtle/823d0a42-0e2c-498a-b231-1697d2a94d40/provisioning-823d0a42-0e2c-498a-b231-1697d2a94d40/export-options.plist --export_method app-store --export_xcargs OTHER_CODE_SIGN_FLAGS=“–keychain /tmp/turtle-agent/ee8b81b1-080b-11e8-b5e3-0050568e0259.keychain” -o /tmp/turtle/823d0a42-0e2c-498a-b231-1697d2a94d40/823d0a42-0e2c-498a-b231-1697d2a94d40-build --verbose
Unable to generate IPA.
unable to build and sign IPA
Executing command: security delete-keychain /tmp/turtle-agent/ee8b81b1-080b-11e8-b5e3-0050568e0259.keychain
Restoring keychain list…
Executing command: security list-keychains -s /private/tmp/turtle-agent/38fc509a-07a2-11e8-b5e3-0050568e0259.keychain
Restored keychain list.

I found this in the logs:

"Signing certificate is invalid....is not valid for code signing. It may have been revoked or expired., IDEProvisioningError_UserInfoKey_IDEProvisioningErrorPlatform=com.apple.platform.iphoneos, IDEProvisioningError_UserInfoKey_IDEProvisioningErrorAction=5, 

So you can you please carefully:

  1. Revoke the dist, push and provisioning profile associated with this app on your developer.apple.com account.
  2. run exp build:ios -c so that it clears out these files on our machines.

I think there is a mismatch of chosen provisioning profile and the cert also provided.

1 Like

The issue still persist. I deleted existing provisioning profile and app id and ran exp build:ios -c by overwriting dist cert with existing certificate. The provisioning profile the expo creates in the process has the correct certificate selected and everything seems to be fine in apple developer portal but still I ran into this error.

I’ll try revoking one of my certs and let expo handle the distribution cert as well.

Yup, works by letting Expo create new dist cert.

3 Likes

This topic was automatically closed 20 days after the last reply. New replies are no longer allowed.