joltup / rn-fetch-blob

A project committed to making file access and data transfer easier, efficient for React Native developers.
MIT License
2.8k stars 770 forks source link

method '-RNFBContainsString' in category from "..." conflicts with same method from another category when archiving on IOS/xcode #803

Open matt-dalton opened 1 year ago

matt-dalton commented 1 year ago

Describe the bug I am trying to archive my project using fastlane (gym) on circleCI. I'm getting the following error:

⚠️  ld: method '-RNFBContainsString:' in category from /Users/distiller/Library/Developer/Xcode/DerivedData/myapp-afcitdfwjbmwxbbbhpiatfbfkjkg/Build/Intermediates.noindex/ArchiveIntermediates/myapp/BuildProductsPath/Staging-iphoneos/rn-fetch-blob/librn-fetch-blob.a(RNFetchBlobReqBuilder.o) conflicts with same method from another category
⚠️  ld: method '-RNFBContainsString:' in category from /Users/distiller/Library/Developer/Xcode/DerivedData/myapp-afcitdfwjbmwxbbbhpiatfbfkjkg/Build/Intermediates.noindex/ArchiveIntermediates/myapp/BuildProductsPath/Staging-iphoneos/rn-fetch-blob/librn-fetch-blob.a(RNFetchBlobRequest.o) conflicts with same method from another category
...
Running script 'Bundle React Native code and images'
▸ Generating 'myapp.app.dSYM'
** ARCHIVE FAILED **

The following build commands failed:
    PhaseScriptExecution Bundle\ React\ Native\ code\ and\ images /Users/distiller/Library/Developer/Xcode/DerivedData/myapp-afcitdfwjbmwxbbbhpiatfbfkjkg/Build/Intermediates.noindex/ArchiveIntermediates/myapp/IntermediateBuildFilesPath/myapp.build/Staging-iphoneos/myapp.build/Script-00DD1BFF1BD5951E006B06BC.sh (in target 'myapp' from project 'myapp')
(1 failure)
[14:26:45]: Exit status: 65

Building locally is fine. I've tried Xcode cleans, plus my pods are re-installing fresh each time.

If it helps, the fastlane gym/build config I'm using is

    xcversion(version: "13.4.1")
    cocoapods(
      clean_install: true,
      podfile: "./ios/Podfile"
    )

    gymOptions = ({
      silent: true,
      clean: true,
      configuration: ENV['BUILD_CONFIGURATION'],
      export_team_id: ENV['IOS_TEAM_ID'],
      export_options: {
        signingStyle: "manual",
        provisioningProfiles: { 
          ENV['IOS_APP_ID'] => ENV[profile_env_name],
          ENV['PUSH_INTERCEPTOR_BUNDLE_ID'] => ENV[push_interceptor_profile_env_name],
          ENV['WIDGETS_BUNDLE_ID'] => ENV[widgets_profile_env_name],
        }
      }
    }).merge(
      File.directory?("../#{xcworkspace}") ?
        {workspace: xcworkspace} :
        {project: xcodeproj}
    )
    gym(gymOptions)

The versions I'm using are:

Any ideas on things I can try? From reading around on similar issues this looks like something the library author usually needs to fix, but it seems odd no one else has experienced this (I can't see any other similar issues)

matt-dalton commented 1 year ago

Ah I see this was mentioned here

Is it possible to add a patch for version 12 here? We don't want to be using a beta release (13) in prod.