vision-camera-code-scanner icon indicating copy to clipboard operation
vision-camera-code-scanner copied to clipboard

CocoaPods could not find compatible versions for pod "GTMSessionFetcher/Core"

Open Texicitys opened this issue 2 years ago • 9 comments

Hello

After yarn add vision-camera-code-scanner I have this bug when I want to pod install

[!] CocoaPods could not find compatible versions for pod "GTMSessionFetcher/Core":
  In snapshot (Podfile.lock):
    GTMSessionFetcher/Core (< 3.0, = 2.3.0, >= 1.1, >= 1.5)

  In Podfile:
    RNGoogleSignin (from `../node_modules/@react-native-google-signin/google-signin`) was resolved to 9.0.2, which depends on
      GoogleSignIn (~> 6.2) was resolved to 6.2.4, which depends on
        GTMAppAuth (~> 1.3) was resolved to 1.3.1, which depends on
          GTMSessionFetcher/Core (< 3.0, >= 1.5)

    RNGoogleSignin (from `../node_modules/@react-native-google-signin/google-signin`) was resolved to 9.0.2, which depends on
      GoogleSignIn (~> 6.2) was resolved to 6.2.4, which depends on
        GTMSessionFetcher/Core (< 3.0, >= 1.1)

    vision-camera-code-scanner (from `../node_modules/vision-camera-code-scanner`) was resolved to 0.2.0, which depends on
      GoogleMLKit/BarcodeScanning was resolved to 0.60.0, which depends on
        GoogleMLKit/MLKitCore (= 0.60.0) was resolved to 0.60.0, which depends on
          MLKitCommon (~> 0.60.0) was resolved to 0.60.0, which depends on
            GTMSessionFetcher/Core (~> 1.1)


You have either:
 * out-of-date source repos which you can update with `pod repo update` or with `pod install --repo-update`.
 * changed the constraints of dependency `GTMSessionFetcher/Core` inside your development pod `vision-camera-code-scanner`.
   You should run `pod update GTMSessionFetcher/Core` to apply changes you've made.

Here is my package.json :

  "dependencies": {
    "@invertase/react-native-apple-authentication": "^2.2.2",
    "@react-native-async-storage/async-storage": "^1.17.11",
    "@react-native-google-signin/google-signin": "^9.0.2",
    "@react-navigation/bottom-tabs": "^6.5.2",
    "@react-navigation/native": "^6.1.0",
    "@react-navigation/stack": "^6.3.10",
    "axios": "^1.2.1",
    "i18next": "^22.1.5",
    "native-base": "^3.4.25",
    "react": "18.1.0",
    "react-hook-form": "^7.41.2",
    "react-i18next": "^12.1.1",
    "react-native": "0.70.6",
    "react-native-device-info": "^10.3.0",
    "react-native-fbsdk-next": "^11.1.0",
    "react-native-gesture-handler": "^2.8.0",
    "react-native-get-random-values": "^1.8.0",
    "react-native-localize": "^2.2.4",
    "react-native-reanimated": "^2.13.0",
    "react-native-rename": "^3.1.0",
    "react-native-safe-area-context": "^4.4.1",
    "react-native-screens": "^3.18.2",
    "react-native-svg": "12.1.1",
    "react-native-vector-icons": "^9.2.0",
    "react-native-vision-camera": "^2.15.2",
    "react-native-webview": "^11.26.0",
    "vision-camera-code-scanner": "^0.2.0"
  },
  "devDependencies": {
    "@babel/core": "^7.12.9",
    "@babel/runtime": "^7.12.5",
    "@react-native-community/eslint-config": "^2.0.0",
    "babel-jest": "^26.6.3",
    "eslint": "^7.32.0",
    "jest": "^26.6.3",
    "metro-react-native-babel-preset": "0.72.3",
    "react-test-renderer": "18.1.0"
  },
  "jest": {
    "preset": "react-native"
  }

Thanks for your help.

Texicitys avatar Dec 30 '22 21:12 Texicitys

I tried to fork your repository and to add s.dependency "GoogleMLKit/BarcodeScanning", "3.2.0" in vision-camera-code-scanner.podspec but the end dependencies still needs GTMSessionFetcher/Core (~> 1.1).

[!] CocoaPods could not find compatible versions for pod "GTMSessionFetcher/Core":
  In snapshot (Podfile.lock):
    GTMSessionFetcher/Core (< 3.0, = 2.3.0, >= 1.1, >= 1.5)

  In Podfile:
    RNGoogleSignin (from `../node_modules/@react-native-google-signin/google-signin`) was resolved to 9.0.2, which depends on
      GoogleSignIn (~> 6.2) was resolved to 6.2.4, which depends on
        GTMAppAuth (~> 1.3) was resolved to 1.3.1, which depends on
          GTMSessionFetcher/Core (< 3.0, >= 1.5)

    RNGoogleSignin (from `../node_modules/@react-native-google-signin/google-signin`) was resolved to 9.0.2, which depends on
      GoogleSignIn (~> 6.2) was resolved to 6.2.4, which depends on
        GTMSessionFetcher/Core (< 3.0, >= 1.1)

    vision-camera-code-scanner (from `../node_modules/vision-camera-code-scanner`) was resolved to 0.2.0, which depends on
      GoogleMLKit/BarcodeScanning (= 3.2.0) was resolved to 3.2.0, which depends on
        MLKitBarcodeScanning (~> 2.2.0) was resolved to 2.2.0, which depends on
          MLKitVision (~> 4.2) was resolved to 4.2.0, which depends on
            GTMSessionFetcher/Core (~> 1.1)


You have either:
 * out-of-date source repos which you can update with `pod repo update` or with `pod install --repo-update`.
 * changed the constraints of dependency `GTMSessionFetcher/Core` inside your development pod `vision-camera-code-scanner`.
   You should run `pod update GTMSessionFetcher/Core` to apply changes you've made.

Do you think there is a solution ?

Texicitys avatar Dec 31 '22 10:12 Texicitys

This compatibily problem seams to be shared here : [ML Kit] Cocoapods dependency conflicts between MLKit and Firebase 10

Texicitys avatar Dec 31 '22 11:12 Texicitys

any update on this ? cause it's only happening when i use this plugin

Bamorem avatar Jan 09 '23 13:01 Bamorem

any update on this issue? i face the same problem. need help.

harisnaufal avatar Jan 10 '23 09:01 harisnaufal

also getting same issue. any updates .??

eramudeep avatar Jan 30 '23 11:01 eramudeep

As mentionned here you can do the following:

1- Create MLKitVision.podspec.json in ios folder taking content from this file here

2- Create MLKitCommon.podspec.json in ios folder taking content from this file here

3- Modify in both files the GTMSessionFetcher/Core definition from 1.1 to version 2.1.

4- Inside your Podfile for the target 'project-name' you have to add at the end the following lines:

pod 'MLKitVision', :podspec => 'MLKitVision.podspec.json'
pod 'MLKitCommon', :podspec => 'MLKitCommon.podspec.json'

5- Run pod install

6- build the app

riamon-v avatar Jan 30 '23 14:01 riamon-v

As mentionned here you can do the following:

1- Create MLKitVision.podspec.json in ios folder taking content from this file here

2- Create MLKitCommon.podspec.json in ios folder taking content from this file here

3- Modify in both files the GTMSessionFetcher/Core definition from 1.1 to version 2.1.

4- Inside your Podfile for the target 'project-name' you have to add at the end the following lines:

pod 'MLKitVision', :podspec => 'MLKitVision.podspec.json'
pod 'MLKitCommon', :podspec => 'MLKitCommon.podspec.json'

5- Run pod install

6- build the app

I have issue SwiftEmitModule normal x86_64 Emitting\ module\ for\ vision_camera_code_scanner (in target 'vision-camera-code-scanner' from project 'Pods')

vinpro24 avatar Mar 23 '23 07:03 vinpro24

+1

SwiftEmitModule normal x86_64 Emitting\ module\ for\ vision_camera_code_scanner (in target 'vision-camera-code-scanner' from project 'Pods')

IlanAMG avatar Apr 24 '23 21:04 IlanAMG