Reputation: 61
I'm currently trying to implement the RevenueCat SDK with Ionic React (Capacitor) and whilst building the app using Ionic Appflow I get the following error
[18:38:13]: ▸ [error] Error running update: Analyzing dependencies
[18:38:13]: ▸ Fetching podspec for `Capacitor` from `../../node_modules/@capacitor/ios`
[18:38:13]: ▸ Fetching podspec for `CapacitorCommunityHttp` from `../../node_modules/@capacitor-community/http`
[18:38:13]: ▸ Fetching podspec for `CapacitorCordova` from `../../node_modules/@capacitor/ios`
[18:38:13]: ▸ Fetching podspec for `CordovaPlugins` from `../capacitor-cordova-ios-plugins`
[18:38:13]: ▸ Fetching podspec for `CordovaPluginsStatic` from `../capacitor-cordova-ios-plugins`
[18:38:13]: ▸ [!] CocoaPods could not find compatible versions for pod "PurchasesHybridCommon":
[18:38:13]: ▸ In Podfile:
[18:38:13]: ▸ CordovaPluginsStatic (from `../capacitor-cordova-ios-plugins`) was resolved to 2.4.0, which depends on
[18:38:13]: ▸ PurchasesHybridCommon (= 1.2.0)
[18:38:13]: ▸ None of your spec sources contain a spec satisfying the dependency: `PurchasesHybridCommon (= 1.2.0)`.
[18:38:13]: ▸ You have either:
[18:38:13]: ▸ * out-of-date source repos which you can update with `pod repo update` or with `pod install --repo-update`.
[18:38:13]: ▸ * mistyped the name or version.
[18:38:13]: ▸ * not added the source repo that hosts the Podspec to your Podfile.
[18:38:13]: ▸ Note: as of CocoaPods 1.0, `pod repo update` does not happen on `pod install` by default.
[18:38:13]: ▸ Sync finished in 3.219s
Upvotes: 5
Views: 3428
Reputation: 66
For those of you that find this article, since this issue still happens, here is what I did to fix the issue. First, this did not work:
pod install --repo-update
It just kept generating the error:
CocoaPods could not find compatible versions for pod "PurchaseHybridCommon"
I reinstalled CocoaPods, updated the dependencies, and still no luck. This simple fix worked. Reinstall RevenueCat plugin. It will install the correct version of the PurchaseHybridCommon pod:
npm uninstall @revenuecat/purchases-capacitor
npx cap sync
npm install @revenuecat/purchases-capacitor@latest
npx cap sync
Upvotes: 0
Reputation: 1
try to clean your podfile and reinstall; move to ios/App folder:
pod cache clean --all
rm -rf Podfile.lock
pod install
Upvotes: 0
Reputation: 18738
The comment from @enc_life worked for me (on a Flutter app, not React, but I guess the iOS part works the same either way):
pod install --repo-update
After that everything worked like a charm.
The error message I had was
[!] CocoaPods could not find compatible versions for pod "PurchasesHybridCommon":
In Podfile:
purchases_flutter (from `.symlinks/plugins/purchases_flutter/ios`) was
resolved to 1.4.3, which depends on PurchasesHybridCommon (= 1.4.5)
None of your spec sources contain a spec satisfying the dependency:
`PurchasesHybridCommon (= 1.4.5)`.
Upvotes: 14