1

I am getting this error below on running "pod install" with the latest firebase_core sdk, on flutter for iOS. I cleared the Pod, symlinks folders and deleted the Podfile.lock file, and ran pod install, but the result is the same as below. What is the issue here?

Analyzing dependencies
cloud_firestore: Using Firebase SDK version '9.2.0' defined in 'firebase_core'
firebase_auth: Using Firebase SDK version '9.2.0' defined in 'firebase_core'
firebase_core: Using Firebase SDK version '9.2.0' defined in 'firebase_core'
Warning: firebase_app_id_file.json file does not exist. This may cause issues in upload-symbols. If this error is unexpected, try running flutterfire configure again.
firebase_crashlytics: Using Firebase SDK version '9.2.0' defined in 'firebase_core'
firebase_dynamic_links: Using Firebase SDK version '9.2.0' defined in 'firebase_core'
firebase_messaging: Using Firebase SDK version '9.2.0' defined in 'firebase_core'
firebase_storage: Using Firebase SDK version '9.2.0' defined in 'firebase_core'
**[!] CocoaPods could not find compatible versions for pod "FirebaseCore":
  In Podfile:
    firebase_core (from `.symlinks/plugins/firebase_core/ios`) was resolved to 1.19.2, which depends on
      Firebase/CoreOnly (= 9.2.0) was resolved to 9.2.0, which depends on
        FirebaseCore (= 9.2.0)

    firebase_storage (from `.symlinks/plugins/firebase_storage/ios`) was resolved to 10.3.2, which depends on
      Firebase/Storage (= 9.2.0) was resolved to 9.2.0, which depends on
        FirebaseStorage (~> 9.2.0) was resolved to 9.2.0, which depends on
          FirebaseCore (~> 9.0)

    google_ml_kit (from `.symlinks/plugins/google_ml_kit/ios`) was resolved to 0.6.0, which depends on
      GoogleMLKit/LinkFirebase (~> 2.2.0) was resolved to 2.2.0, which depends on
        MLKitLinkFirebase (~> 1.3.0) was resolved to 1.3.0, which depends on
          FirebaseCore (~> 8.0)

CocoaPods could not find compatible versions for pod "MLKitVision":
  In Podfile:
    google_ml_kit (from `.symlinks/plugins/google_ml_kit/ios`) was resolved to 0.6.0, which depends on
      GoogleMLKit/ImageLabeling (~> 2.2.0) was resolved to 2.2.0, which depends on
        MLKitImageLabeling (~> 1.3.0) was resolved to 1.3.0, which depends on
          MLKitVision (~> 1.3)

    google_ml_kit (from `.symlinks/plugins/google_ml_kit/ios`) was resolved to 0.6.0, which depends on
      GoogleMLKit/PoseDetection (~> 2.2.0) was resolved to 2.2.0, which depends on
        MLKitPoseDetection (~> 1.0.0-beta4) was resolved to 1.0.0-beta6, which depends on
          MLKitXenoCommon (= 1.0.0-beta6) was resolved to 1.0.0-beta6, which depends on
            MLKitVision (~> 2.0)**
Jai Thomso
  • 51
  • 1
  • 2

4 Answers4

2

Install clean:

sudo gem install cocoapods-clean

Run deintegrate in the folder of the project:

pod deintegrate

Modify your podfile (delete the lines with the pods you don't want to use anymore) and run:

pod install

pod update
1

Just do it:

pod repo update && pod install --repo-update
rochelryu
  • 21
  • 2
0

Delete Pods folder, .symlinks folder and Podfile.lock. Then run pod install and try again

Kaushik Chandru
  • 15,510
  • 2
  • 12
  • 30
  • As mentioned in the question, I did that and it is not working :( – Jai Thomso Jul 14 '22 at 06:48
  • 1
    I thibk some of your packages are not updated. Please take a backup and run `pod install --repo-update` but before this make sure all packages you use support flutter 3+ and your flutter sdk also is 3+ – Kaushik Chandru Jul 14 '22 at 07:12
  • @JaiThomso Could you share your Podfile so that we can reproduce this and further investigate it? Thanks! – Julie Zhou Jul 18 '22 at 16:13
0

Flutter mlkit plugin does not support Firebase version 10, therefor you need to downgrade.

Compatible dependencies:

google_mlkit_text_recognition: ^0.5.0
firebase_core: ^1.24.0
firebase_analytics: ^9.1.5
cloud_firestore: ^3.5.1
firebase_crashlytics: ^2.9.0
firebase_auth: ^3.11.2

dependency_overrides:
    firebase_core_platform_interface: 4.5.1

Add this in top of Podfile

$FirebaseSDKVersion = '9.6.0' 
Christer
  • 2,746
  • 3
  • 31
  • 50