Dynamsoft / capture-vision-react-native-samples

Dynamsoft Capture Vision React-Native SDK Samples
https://www.dynamsoft.com/capture-vision/docs/introduction/
Other
15 stars 7 forks source link

CocoaPods could not find compatible versions for pod "DynamsoftBarcodeReader" #28

Closed oktalk closed 2 months ago

oktalk commented 1 year ago

I'm trying to add this barcode scanner to an existing React Native project. After running yarn && npx pod-install ios here is the error I get:

[!] CocoaPods could not find compatible versions for pod "DynamsoftBarcodeReader":
  In Podfile:
    dynamsoft-capture-vision-react-native (from `../node_modules/dynamsoft-capture-vision-react-native`) was resolved to 1.1.7, which depends on
      DynamsoftBarcodeReader (= 9.2.13)

    vision-camera-dynamsoft-barcode-reader (from `../node_modules/vision-camera-dynamsoft-barcode-reader`) was resolved to 0.6.0, which depends on
      DynamsoftBarcodeReader (= 9.4.0)

Packages

"react-native": "0.67.1", "dynamsoft-capture-vision-react-native": "^1.1.7",

Any ideas on how to handle this?

alexboutros commented 1 year ago

Try uninstalling vision-camera-dynamsoft-barcode-reader and then running a pod install. They both have DynamsoftBarcodeReader as dependencies, but at different versions.

Sir-kof commented 1 year ago

Just go into the archive "node_modules/dynamsoft-capture-vision-react-native/dynamsoft-capture-vision-react-native.podspec" and update DynamsoftBarcodeReader version to 9.4.0 and run pod install again.