samridhgupta
samridhgupta

Reputation: 1745

GoogleUtilities/AppDelegateSwizzler/Private/GULApplication.h' file > not found

After Migrating react-native-firebase to @react-native-firebase

Error coming up

/Users/samridhgupta/Work/Development/TCD/classroom-door-react-native/ios/Pods/Headers/Private/GoogleUtilities/GULAppDelegateSwizzler.h:19:9: 'GoogleUtilities/AppDelegateSwizzler/Private/GULApplication.h' file not found

on file

Pods > GoogleUtilities > AppDelegateSwizzler

#import "GoogleUtilities/AppDelegateSwizzler/Private/GULApplication.h"

PodLock File have these packages (GoogleUtilities/AppDelegateSwizzler)

Tried resetting the Pod by removing the Podlock file and then running Pod install. Plus also tried removing the DerivedData still the issue remains Gist from padlock file

     - Firebase/Core (6.27.1):
    - Firebase/CoreOnly
    - FirebaseAnalytics (= 6.6.2)
  - Firebase/CoreOnly (6.27.1):
    - FirebaseCore (= 6.8.1)
  - Firebase/Database (6.27.1):
    - Firebase/CoreOnly
    - FirebaseDatabase (~> 6.3.0)
  - Firebase/Firestore (6.27.1):
    - Firebase/CoreOnly
    - FirebaseFirestore (~> 1.16.0)
  - Firebase/Functions (6.27.1):
    - Firebase/CoreOnly
    - FirebaseFunctions (~> 2.6.0)
  - Firebase/Messaging (6.27.1):
    - Firebase/CoreOnly
    - FirebaseMessaging (~> 4.5.0)
  - Firebase/Storage (6.27.1):
    - Firebase/CoreOnly
    - FirebaseStorage (~> 3.7.0)
  - FirebaseAnalytics (6.6.2):
    - FirebaseCore (~> 6.8)
    - FirebaseInstallations (~> 1.4)
    - GoogleAppMeasurement (= 6.6.2)
    - GoogleUtilities/AppDelegateSwizzler (~> 6.0)
    - GoogleUtilities/MethodSwizzler (~> 6.0)
    - GoogleUtilities/Network (~> 6.0)
    - "GoogleUtilities/NSData+zlib (~> 6.0)"
    - nanopb (~> 1.30905.0)
  - FirebaseAuth (6.6.0):
    - FirebaseCore (~> 6.8)
    - GoogleUtilities/AppDelegateSwizzler (~> 6.5)
    - GoogleUtilities/Environment (~> 6.5)
    - GTMSessionFetcher/Core (~> 1.1)
  - FirebaseCore (6.8.1):
    - FirebaseCoreDiagnostics (~> 1.3)
    - GoogleUtilities/Environment (~> 6.5)
    - GoogleUtilities/Logger (~> 6.5)
  - FirebaseCoreDiagnostics (1.5.0):
    - GoogleDataTransport (~> 7.0)
    - GoogleUtilities/Environment (~> 6.7)
    - GoogleUtilities/Logger (~> 6.7)
    - nanopb (~> 1.30905.0)
  - FirebaseDatabase (6.3.0):
    - FirebaseCore (~> 6.8)
    - leveldb-library (~> 1.22)
  - FirebaseFirestore (1.16.1):
    - abseil/algorithm (= 0.20200225.0)
    - abseil/base (= 0.20200225.0)
    - abseil/memory (= 0.20200225.0)
    - abseil/meta (= 0.20200225.0)
    - abseil/strings/strings (= 0.20200225.0)
    - abseil/time (= 0.20200225.0)
    - abseil/types (= 0.20200225.0)
    - FirebaseCore (~> 6.8)
    - "gRPC-C++ (~> 1.28.0)"
    - leveldb-library (~> 1.22)
    - nanopb (~> 1.30905.0)
  - FirebaseFunctions (2.6.0):
    - FirebaseCore (~> 6.8)
    - GTMSessionFetcher/Core (~> 1.1)
  - FirebaseInstallations (1.5.0):
    - FirebaseCore (~> 6.8)
    - GoogleUtilities/Environment (~> 6.7)
    - GoogleUtilities/UserDefaults (~> 6.7)
    - PromisesObjC (~> 1.2)
  - FirebaseInstanceID (4.5.0):
    - FirebaseCore (~> 6.8)
    - FirebaseInstallations (~> 1.0)
    - GoogleUtilities/Environment (~> 6.7)
    - GoogleUtilities/UserDefaults (~> 6.7)
  - FirebaseMessaging (4.5.0):
    - FirebaseCore (~> 6.8)
    - FirebaseInstanceID (~> 4.3)
    - GoogleUtilities/AppDelegateSwizzler (~> 6.5)
    - GoogleUtilities/Environment (~> 6.5)
    - GoogleUtilities/Reachability (~> 6.5)
    - GoogleUtilities/UserDefaults (~> 6.5)
    - Protobuf (>= 3.9.2, ~> 3.9)
  - FirebaseStorage (3.7.0):
    - FirebaseCore (~> 6.8)
    - GTMSessionFetcher/Core (~> 1.1)

Comment if you need any other details which can help me resolving this issue

Upvotes: 13

Views: 4796

Answers (6)

TechnoTim
TechnoTim

Reputation: 3205

Looks like this may have just been fixed. There was a bug upstream and they have fixed it.

https://github.com/firebase/firebase-ios-sdk/pull/6051

You should be able to run this to get the fixed version.

pod update

Upvotes: 0

probablykabari
probablykabari

Reputation: 1389

It seems like the path to AppDelegateSwizzler changed here https://github.com/firebase/firebase-ios-sdk/commit/3f556ddb9e4a79ed282e674b483ea99c7ae1f8c8#diff-8a5c430b661a4b0572837ada64f3cc95

Upgrading to FirebaseAuth 6.7 (from 6.6) resolved this for me.

Upvotes: 0

Rick Love
Rick Love

Reputation: 12790

This is a script that will make the updates (suggested by https://stackoverflow.com/a/62906019/567524) automatically and will exist under source control:

In your podfile, add this to the post_install:

  post_install do |installer|
    ...

    # Workarounds
    puts 'FIX Version Incompatibility with Firebase and GoogleUtilities (6.7.0)'
    system("sed -i '' s=GoogleUtilities/AppDelegateSwizzler/Private/GULApplication.h=GoogleUtilities/GULApplication.h=g ./Pods/GoogleUtilities/GoogleUtilities/AppDelegateSwizzler/Private/GULAppDelegateSwizzler.h")
  end

Upvotes: 5

Jakub Pogorzelski
Jakub Pogorzelski

Reputation: 72

In case someone encounter this in Cordova project with Firebase plugin, you need to downgrade Firebase/Core pod to version 6.0.0, i.e. replace:

<pod name="Firebase/Core" version="~> 6.0.0" />

with

<pod name="Firebase/Core" version="6.0.0" />

in the config.xml file.

Upvotes: 0

why001
why001

Reputation: 41

Try 6.6.0, it works for me

pod 'GoogleUtilities', '6.6.0'

Upvotes: 4

ChauGiang
ChauGiang

Reputation: 123

For now, you can work around by change code at file GULAppDelegateSwizzler.h

#import "GoogleUtilities/AppDelegateSwizzler/Private/GULApplication.h"
->
#import "GoogleUtilities/GULApplication.h"

Upvotes: 10

Related Questions