I have a react-native application which iam using to build the ios .ipa. Iam using fastlane to build it. When iam building it with "match(type: 'appstore', readonly: true)" The following lanes from my fastfile show the lane "build" which works well and the lane "buildbis" which launches the error.

desc 'Build the iOS application.'
lane :build do #|options|
  match(type: 'appstore', readonly: true)
build_ios_app(
    workspace: ENV['IOS_WORKSPACE'],
    scheme: ENV['IOS_SCHEME'],
    configuration: ENV['IOS_CONFIGURATION'],
    include_bitcode: false,
    skip_profile_detection: true,
    export_method: 'app-store',
    export_options: {
        provisioningProfiles: {}
    },
    xcargs: "-UseModernBuildSystem=NO"  # Equivalent to set xcode workspace build to legacy
  )
end

desc 'AD-HOC : Build the iOS application.'
lane :buildbis do
  match(type: "adhoc", force_for_new_devices: true)
  build_ios_app(
    workspace: ENV['IOS_WORKSPACE'],
    scheme: ENV['IOS_SCHEME'],
    configuration: 'AdHoc',
    skip_profile_detection: true,
    #export_method: 'ad-hoc',
    clean: true,
    export_options: {
        method: "ad-hoc",
        provisioningProfiles: {}
    },
    xcargs: "-UseModernBuildSystem=NO"  # Equivalent to set xcode workspace build to legacy
  )
end

When building with mode "appstore" no problem, the build finishes well. But not when i put the mode "ad-hoc". I can't see where the problem is. in jenkins here is the message:

❌  error: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.

** ARCHIVE FAILED **
The following build commands failed:
PhaseScriptExecution [CP]\ Check\ Pods\ Manifest.lock /Users/****/Library/Developer/Xcode/DerivedData/**** ......

but as soon as i put back the build lane which contains "appstore" everything goes well again.

What could the reason(s) ?

0 Answers