WorryFree Computers   »   [go: up one dir, main page]

Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error satisfying GoogleUtilities/MethodSwizzler dependency. #1845

Closed
zgosalvez opened this issue Sep 19, 2018 · 35 comments
Closed

Error satisfying GoogleUtilities/MethodSwizzler dependency. #1845

zgosalvez opened this issue Sep 19, 2018 · 35 comments
Assignees
Milestone

Comments

@zgosalvez
Copy link
  • Xcode version: 10.0 (10A255)
  • Firebase SDK version: 5.8.0
  • Firebase Component: Auth, Core, Database, Functions, Messaging, Performance, Storage
  • Component version: 5.8.0

Steps to reproduce:

  1. Create a new Xcode project
  2. pod init
  3. Add the following lines in the Podfile
pod 'Firebase'
pod 'Firebase/Auth'
pod 'Firebase/Core'
pod 'Firebase/Database'
pod 'Firebase/Functions'
pod 'Firebase/Messaging'
pod 'Firebase/Performance'
pod 'Firebase/Storage'

Note: Changing the platform to platform :ios, '12.0' causes the same issue.

  1. pod install
Analyzing dependencies
[!] CocoaPods could not find compatible versions for pod "Firebase/Performance":
  In Podfile:
    Firebase/Performance

Specs satisfying the `Firebase/Performance` dependency were found, but they required a higher minimum deployment target.
CocoaPods could not find compatible versions for pod "GoogleUtilities/MethodSwizzler":
  In Podfile:
    Firebase/Performance was resolved to 5.8.0, which depends on
      FirebasePerformance (= 2.1.1) was resolved to 2.1.1, which depends on
        GoogleUtilities/MethodSwizzler (~> 5.2.0)

Specs satisfying the `GoogleUtilities/MethodSwizzler (~> 5.2.0)` dependency were found, but they required a higher minimum deployment target.
@paulb777 paulb777 self-assigned this Sep 19, 2018
@jayahariv
Copy link

Analyzing dependencies
[!] CocoaPods could not find compatible versions for pod "Firebase/Core":
In Podfile:
Firebase/Core

Specs satisfying the Firebase/Core dependency were found, but they required a higher minimum deployment target.
CocoaPods could not find compatible versions for pod "GoogleUtilities/AppDelegateSwizzler":
In Podfile:
Firebase/Core was resolved to 5.8.0, which depends on
FirebaseAnalytics (= 5.1.2) was resolved to 5.1.2, which depends on
GoogleUtilities/AppDelegateSwizzler (~> 5.2.0)

Specs satisfying the GoogleUtilities/AppDelegateSwizzler (~> 5.2.0) dependency were found, but they required a higher minimum deployment target.

@paulb777
Copy link
Member
paulb777 commented Sep 19, 2018

This looks like a CocoaPods bug with version resolution.

A workaround is adding pod 'GoogleUtilities', '5.2.3' to the Podfile.

We'll continue to investigate. Thanks for the detailed report @zgosalvez

@zgosalvez
Copy link
Author

@paulb777, I can confirm that the workaround works. Thanks.

No problem; It's the least I could do. Please keep us posted.

@paulb777
Copy link
Member

@jayahariv Thanks for the update. I'll delete your comments here to keep this thread focused on original topic.

@firebase firebase deleted a comment from jayahariv Sep 19, 2018
@firebase firebase deleted a comment from jayahariv Sep 19, 2018
jakubgs added a commit to status-im/status-mobile that referenced this issue Sep 19, 2018
pedropombeiro pushed a commit to status-im/status-mobile that referenced this issue Sep 19, 2018
jakubgs added a commit to status-im/status-mobile that referenced this issue Sep 19, 2018
jakubgs added a commit to status-im/status-mobile that referenced this issue Sep 19, 2018
@paulb777
Copy link
Member

A better workaround is pod 'GoogleUtilities', '5.2.3' to get some build time fixes. I'll also edit above.

Meanwhile, we're working on doing a Firebase 5.8.1 patch to eliminate the need for the workaround.

@paulb777 paulb777 added this to the 5.8.1 milestone Sep 19, 2018
jakubgs added a commit to status-im/status-mobile that referenced this issue Sep 19, 2018
@paulb777
Copy link
Member

Fixed in Firebase 5.8.1

@ghost
Copy link
ghost commented Sep 26, 2018

@paulb777 do you know if this issue is also presented in the Unity SDK and if it is, has it been fixed?

@ozbra
Copy link
ozbra commented Sep 27, 2018

@paulb777 do you know if this issue is also presented in the Unity SDK and if it is, has it been fixed?

I am having the same issue. Even empty project just with Firebase Auth and database plugin-ins added to project doesn't get a proper build. Spend almost a day to figure it out which also support cloud build but I am empty handed :/

@ghost
Copy link
ghost commented Sep 27, 2018

I tried to build the Firebase dynamic_links sample app in Unity using Firebase 5.3 SDK and got this error:

pod install output:

Analyzing dependencies
[!] Unable to satisfy the following requirements:

  • GoogleUtilities/MethodSwizzler (~> 5.2.0) required by FirebaseAnalytics (5.1.1)

Specs satisfying the GoogleUtilities/MethodSwizzler (~> 5.2.0) dependency were found, but they required a higher minimum deployment target.

@ozbra
Copy link
ozbra commented Sep 27, 2018

I tried to build the Firebase dynamic_links sample app in Unity using Firebase 5.3 SDK and got this error:

pod install output:

Analyzing dependencies
[!] Unable to satisfy the following requirements:

  • GoogleUtilities/MethodSwizzler (~> 5.2.0) required by FirebaseAnalytics (5.1.1)

Specs satisfying the GoogleUtilities/MethodSwizzler (~> 5.2.0) dependency were found, but they required a higher minimum deployment target.

It seems where every Firebase needs Core, this error is throwing. The sad part is I was able to get a working build without any problem 5 days ago but now I can't.

@OguzhanKuloglu
Copy link

@paulb777 do you know if this issue is also presented in the Unity SDK and if it is, has it been fixed?

@paulb777 Do you have any idea about that?Because I have same problem in unity?

@paulb777
Copy link
Member

I'll follow up with the Unity SDK team today on updating to at least the iOS Firebase SDK 5.8.1.

@ghost
Copy link
ghost commented Sep 27, 2018

I'll follow up with the Unity SDK team today on updating to at least the iOS Firebase SDK 5.8.1.

@paulb777 do you know of any workaround for this issue?

@hex
Copy link
hex commented Sep 27, 2018

@phuong-unity @ozbra I solved it by adding <iosPod name="GoogleUtilities/MethodSwizzler" version="5.2.0"> inside Firebase/Editor/AppDependencies.xml next to the Firebase/Core entry.

@mthormann-dhi
Copy link
mthormann-dhi commented Sep 27, 2018

Another workaround that seems to work is supporting iOS 11.0 and higher in your project and in the podfile. Obviously not possible from many apps but if you're updating anyways to support 11.0+, you can get by.

@stewartmiles
Copy link
Contributor
stewartmiles commented Sep 27, 2018

Hi everyone,

We're working on patching the Firebase C++ and Unity releases to migrate them to the 5.9.0 iOS SDK. In the meantime, under Assets/Firebase/Editor/ there are a set of files matching *Dependencies.xml files (e.g AnalyticsDependencies.xml) that reference the iOS SDK version. You'll need to modify the <iosPods> section of each file to reference iOS SDK 5.9.0 rather than 5.6.0. For example, in AnalyticsDependencies.xml change...

<iosPods>
    <iosPod name="Firebase/Analytics" version="5.6.0" minTargetSdk="8.0">
    </iosPod>
  </iosPods>

to...

<iosPods>
    <iosPod name="Firebase/Analytics" version="5.9.0" minTargetSdk="8.0">
    </iosPod>
  </iosPods>

@ozbra
Copy link
ozbra commented Sep 27, 2018

Hi everyone,

We're working on patching the Firebase C++ and Unity releases to migrate them to the 5.9.0 iOS SDK. In the meantime, under Assets/Firebase/Editor/ there are a set of files matching *Dependencies.xml files (e.g AnalyticsDependencies.xml) that reference the iOS SDK version. You'll need to modify the <iosPods> section of each file to reference iOS SDK 5.9.0 rather than 5.6.0. For example, in AnalyticsDependencies.xml change...

<iosPods>
    <iosPod name="Firebase/Analytics" version="5.6.0" minTargetSdk="8.0">
    </iosPod>
  </iosPods>

to...

<iosPods>
    <iosPod name="Firebase/Analytics" version="5.9.0" minTargetSdk="8.0">
    </iosPod>
  </iosPods>

Thank for information, although I still get an error. This time it is different. It seems FirebaseAuth gives an error.

Analyzing dependencies
[!] FirebaseAuth requires CocoaPods version >= 1.4.0, which is not satisified by your current version, 1.1.1.

@ghost
Copy link
ghost commented Sep 27, 2018

Analyzing dependencies
[!] FirebaseAuth requires CocoaPods version >= 1.4.0, which is not satisified by your current version, 1.1.1.

@ozbra you just need to update your CocoaPods version. in terminal enter this command: gem install cocoapods

@ozbra
Copy link
ozbra commented Sep 27, 2018

Analyzing dependencies
[!] FirebaseAuth requires CocoaPods version >= 1.4.0, which is not satisified by your current version, 1.1.1.

@ozbra you just need to update your CocoaPods version. in terminal enter this command: gem install cocoapods

Thank you. That worked.

@ghost
Copy link
ghost commented Sep 27, 2018

@stewartmiles @paulb777 - thanks for the update. Looking forward to the fix in the new version.

@hex thanks for the workaround!

@pablorengo
Copy link

Hi! I have the same issue

Specs satisfying the GoogleUtilities/AppDelegateSwizzler (~> 5.2.0) dependency were found, but they required a higher minimum deployment target.

But it started failing today in one CI machine, the others still install the dependencies fine. I'm using the Unity Plugin 5.2.1.

I'll add the AppDelegateSwizzler 5.2.3 in the xxDependencies.xml to make this work, but would love to know why this started failing from one day to another.

@paulb777
Copy link
Member

A recent pod repo update or regeneration of the Podfile.lock file will expose the bug.

@RobertBateman
Copy link
RobertBateman commented Oct 2, 2018

Hi guys, I've had the same issue here.

Using Unity 2018.1.0f2, Firebase Dynamic Links v5.3.0 and the Unity Cloud Build service.

Initially I got this message:
Specs satisfying the GoogleUtilities/AppDelegateSwizzler (~> 5.2.0) dependency were found, but they required a higher minimum deployment target.

I added this to the AppDependancies.xml:
<iosPod name="GoogleUtilities/MethodSwizzler" version="5.2.0">
</iosPod>

And updated this line in AppDependancies.xml and DynamicLinksDependances.xml:
<iosPod name="Firebase/Analytics" version="5.9.0" minTargetSdk="8.0">

...based on the advice listed above, which has now removed that error message.

However I am now getting a different error in the Unity Cloud Build:
21365: ▸ ❌; /BUILD_PATH/xxx.xxx.xxx/temp.XXXXXX20181001-2937-155m1yy/Pods/FirebaseDynamicLinks/Firebase/DynamicLinks/FDLURLComponents/FDLURLComponents.m:19:9: 'DynamicLinks/FDLURLComponents/FDLURLComponents+Private.h' file not found

I can't find anything useful by googling and I can't figure out what's missing. Do you think this error is related? There isn't much to configure in Unity and I've checked there are no missing files by re-downloading Firebase v5.3.0 so I'm not sure what to try next. Any suggestions are welcome.

@MiketoString
Copy link

Hi @RobertBateman, I had this exact issue yesterday.

The fix for me was to add the iosPod GoogleUtilities/MethodSwizzler xml line to AppDependancies.xml (per @hex's suggestion) but do NOT change the version number(s) in *Dependancies.xml from 5.6.0 to 5.9.0 -- just leave them as-is or you'll get the FDLURLComponents file not found error, not sure what fix is for that.

@RobertBateman
Copy link

Hi @MiketoString ,

yeah that fixed it.

Thank you kindly :)

@stewartmiles
Copy link
Contributor

For the various Unity SDK users on this thread, we just released the 5.3.1 SDK with the fix for this issue.
https://firebase.google.com/support/release-notes/unity

@MiketoString
Copy link
MiketoString commented Oct 3, 2018

hi @stewartmiles, after importing v5.3.1 of the Unity SDK, I am now seeing the following build error on iOS:

285: ▸ Compiling FIRErrors.m
286: ❌;  /BUILD_PATH/unity/temp.XXXXXX20181003-3096-1bbqo71/Pods/FirebaseDynamicLinks/Firebase/DynamicLinks/FDLURLComponents/FDLURLComponents.m:19:9: 'DynamicLinks/FDLURLComponents/FDLURLComponents+Private.h' file not found

@forgedk
Copy link
forgedk commented Oct 3, 2018

screen shot 2018-10-03 at 4 45 25 pm

Hi @stewartmiles, I built a clean version from the 5.3.1 version and there is a compilation problem in Xcode. There is no much information about the error, just that code.

@huhund
Copy link
huhund commented Oct 7, 2018

I can't find the 5.3.1 version. The 5.3.0 still have this issue.

@paulb777
Copy link
Member
paulb777 commented Oct 7, 2018

@eladleb
Copy link
eladleb commented Oct 8, 2018

Hi @paulb777 and @stewartmiles I've just downloaded 5.3.1 from the secret link and now I'm getting the same error...

/FirebaseDynamicLinks/Firebase/DynamicLinks/FDLURLComponents/FDLURLComponents.m:19:9: 'DynamicLinks/FDLURLComponents/FDLURLComponents+Private.h' file not found

Update: Looks like this happens in Unity Cloud Build, but works fine locally on the machine.

In the cloud build log I see a lot of new "skipping" messages including:
24291: [Unity] Skipping adding source file Headers/Private/FirebaseDynamicLinks/FDLURLComponents+Private.h to Xcode project due to it is not part of the pod project

This didn't happen in previous (successful) builds with firebase 5.2.0.

@ozbra
Copy link
ozbra commented Oct 19, 2018

I am sorry to revive this post again but starting from today build errors started to occur.

I am having @forgedk error. If you solve this, can you guide me?

Here is my problem. I was using Firebase SDK 5.3.0 with manual modification which showing here and it was working until 2 days ago. Which is where I got a working build. Today, when I tried to get build I am getting this error.
ekran resmi 2018-10-19 17 06 35

I have upgraded Firebase SDK to 5.3.1 and tried also but the result is the same. I even went further and created an empty project just with Firebase Auth and Database sdk included version of 5.3.1 and it gave the same problem. Is there a way around? Why this happens?

What I am using are
Xcode version: 10
Firebase SDK version: 5.3.1
Firebase Component: Auth and Database
Unity: 2017.4.1f1
Gem version: 1.5.3

@paulb777
Copy link
Member

@ozbra You can see more about the link failure on the Xcode Report Navigator pane.

Also please do any follow up on one of the Firebase Unity support channels. See #1906.

@ozbra
Copy link
ozbra commented Oct 19, 2018

@ozbra You can see more about the link failure on the Xcode Report Navigator pane.

Also please do any follow up on one of the Firebase Unity support channels. See #1906.

Thank you for all those answers and guidance.

Thank you for redirection but the problem is Unity Firebase Unity support channels are not responding to anything. Similar question asked like 15 days but not a single proper answer yet. That is why I wanted to post here.

@Renanse
Copy link
Renanse commented Feb 21, 2019

In the cloud build log I see a lot of new "skipping" messages including:
24291: [Unity] Skipping adding source file Headers/Private/FirebaseDynamicLinks/FDLURLComponents+Private.h to Xcode project due to it is not part of the pod project

This didn't happen in previous (successful) builds with firebase 5.2.0.

Seeing this same issue on Unity Cloud Build building for iOS. I was on 5.4.4 and upgraded just now to 5.5.0 and have the issue in both versions. Has anyone solved this on UCB?

@firebase firebase locked and limited conversation to collaborators Oct 27, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests