I have been trying to generate the archive for the last 2 days. I have created react native project. It's run successfully on the device. But when I am trying to generate the archive to upload on a test flight. It gives me errors.

My RN version is 0.64, Xcode 12.5.
Here is my pod file:
require_relative '../node_modules/react-native/scripts/react_native_pods'
require_relative '../node_modules/@react-native-community/cli-platform-ios/native_modules'
require_relative '../node_modules/react-native-unimodules/cocoapods.rb'
platform :ios, '11.0'
target 'XXXX' do
use_unimodules!
config = use_native_modules!
use_react_native!(
:path => config[:reactNativePath],
# to enable hermes on iOS, change `false` to `true` and then install pods
:hermes_enabled => false
)
target 'XXXXXTests' do
inherit! :complete
# Pods for testing
end
# Enables Flipper.
#
# Note that if you have use_frameworks! enabled, Flipper will not work and
# you should disable the next line.
use_flipper!({ 'Flipper-Folly' => '2.5.3', 'Flipper' => '0.87.0', 'Flipper-RSocket' => '1.3.1' })
post_install do |installer|
react_native_post_install(installer)
end
end
I have tried pod deintegrated and installed pod again many times. but it doesn't work
For me, it was a different app target version in Podfile(platform:ios, '11.0') and in the Xcode project file

It causing Archiving job to fail in the CI pipeline. Matching both values fixed an issue! Hope this helps anyone.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With