ARCore in nanopb Dependency Conflict with Firebase & Flutter
Hi all, we've built our AR module that relies on ARCore. We're also using the Firebase Flutter packages and just tried to update them to the latest version.
The error we got is the following (when using Cocapods to build the dependency graph for iOS):
[!] CocoaPods could not find compatible versions for pod "nanopb": In Podfile: ar_flutter_plugin (from .symlinks/plugins/ar_flutter_plugin/ios`) was resolved to 0.6.2, which depends on
ARCore/CloudAnchors (~> 1.45.0) was resolved to 1.45.0, which depends on
nanopb (< 2.30911.0, >= 2.30908.0)
firebase_messaging (from `.symlinks/plugins/firebase_messaging/ios`) was resolved to 15.1.0, which depends on
Firebase/Messaging (= 11.0.0) was resolved to 11.0.0, which depends on
FirebaseMessaging (~> 11.0.0) was resolved to 11.0.0, which depends on
nanopb (~> 3.30910.0)`
I understand that nanopb has breaking changes but when do you plan to launch support for the latest version? Otherwise I assume it's a big problem for Flutter users, potentially iOS too?
I have the same issue any solution for this?
Have you solution for this?
I rolled back all the upgrades for now and downgraded the firebase packages. Anything sort of Google supporting the new nanopb library would be a risky patch.
Hi everyone!
I have temporarily created a fork of ARCore called ARCoreNanoPbUpdated 1.46.0.1 to address the issue while we await an official update from Google for the ARCore package.
To integrate this fix, simply replace the following line in your Podspec:
s.dependency 'ARCore/CloudAnchors', '~> 1.46.0'
with :
s.dependency 'ARCoreNanoPbUpdated/CloudAnchors', '~> 1.46.0.2'
I hope this helps!
Hey @hlefe, thanks a lot for the fix!
However, when I try to install 'ARCoreNanoPbUpdated/Geospatial', I cannot import ARCore anymore.
Do you happen to know how to resolve it?
Could you try replacing import ARCore with import ARCoreBase and let me know if it works?
(Still installing 'ARCoreNanoPbUpdated/Geospatial', '~> 1.46.0.2' )
Thanks @hlefe but I couldn't make it work. Would you be able to share the podspec file you used to create the cocoapods library? I wasn't able to find one myself. thanks!
I just added it : https://github.com/hlefe/ARCoreNanoPbUpdated/blob/main/ARCoreNanoPbUpdated.podspec