I try to build Flutter iOS app and my workflow is as follows:
Flutter release build with --no-codesign option
Fastlane step:
register_devices
fastlane match for ad-hoc
build_app ā
appcenter_upload
Fastlaneās build_app fails with following error even though match step indicates that all provisioning profiles are installed.
fastlane match finishes with success:
[21:21:31]: All required keys, certificates and provisioning profiles are installed
build_app executes and breaks with error:
[21:21:45]: āø Code Signing Error: There are no accounts registered with Xcode. Add your developer account to Xcode
[21:21:45]: āø Code Signing Error: No profiles for āpl.app.app.testā were found: Xcode couldnāt find any iOS App Development provisioning profiles matching āpl.app.app.testā.
[21:21:45]: āø Code Signing Error: Code signing is required for product type āApplicationā in SDK āiOS 12.2ā
Also, when building locally with exactly the same commands on my machine (i.e. flutter build and fastlane copied from Bitrise log) everything works fine.
Iāve already connected my Apple Developer account to the Bitrise account but it didnāt help.
I tried to run Certificate and profile installer but with no success.
I also tried to archive the iOS app with Xcode Archive & Export for iOS step (xcode-archive@2.5.0), but it also fails with the error:
Code Signing Error: Code signing is required for product type āApplicationā in SDK āiOS 12.2ā
I tried a lot of things and frankly I donāt know what else I can try. Maybe different Apple Developer account? I can provide any further details if url to build is not sufficient.
Sorry to hear about the issue! Have you tried including a development type profile as well? You seem to be missing that in this build and that could likely cause this error
Ok, I exported my p12 file (according to this guide) and mobile provisioning files from Apple developer portal, and then imported them into Bitrise workflow.
One of the errors is as follows, but I connected my Apple account with Bitrise:
Ensure cookies for Apple Developer Portal
Failed to activate the Bitrise Apple Developer Portal connection: %!s(MISSING)
Read more: https://devcenter.bitrise.io/getting-started/signing-up/connecting-apple-dev-account/
errors
Falied to fetch portal data from Bitrise, error: Response status: 404 - Body: {āerror_msgā:āNo Apple developer account found for this build.ā}
I donāt understand why fastlane match is able to download and install all the required profiles, but later when archiving with Xcode it doesnāt work. Maybe multiple schemes defined in my Xcode project are problematic?
Iāll try to switch to manual provisioning in Xcode and push changes to repository.
Oh I see, this message about your Developer Portal was printed out by the fastlane step as a bug, sorry about that!
But otherwise your fastlane match command seemed to have failed, also if Iām correct uploading your p12 on Bitrise wouldnāt have an effect on this build since youāre still using the match to import them from another repo