darwin-morocho / flutter-facebook-auth

A flutter plugin to add login with facebook in your flutter app
193 stars 127 forks source link

Swift Compiler Error (Xcode): No such module 'FBSDKCoreKit' #254

Closed DevarshRanpara closed 1 year ago

DevarshRanpara commented 1 year ago

What version are you using?

4.3.4

What OS and version are you using to local deploy your application?

Intel Mac Pro

What platforms are you seeing the problem on?

iOS

Describe the Bug

I am getting error that Swift Compiler is not able to find FBSDKCoreKit in flutter_facebook_auth package when I try to create an archive.

Swift Compiler Error (Xcode): No such module 'FBSDKCoreKit'
/Users/builder/programs/flutter/.pub-cache/hosted/pub.dartlang.org/flutter_facebook_auth-4.3.4/ios/Classes/FacebookAuth.swift:8:7

Expected Behavior

It should compile and build archive!

To Reproduce

Make iOS archive with your plugin.

flutter doctor -v

[✓] Flutter (Channel stable, 2.10.4, on macOS 11.6.5 20G527 darwin-x64, locale en-IN)
    • Flutter version 2.10.4 at /Users/devarsh.ranpara/fvm/versions/2.10.4
    • Upstream repository https://github.com/flutter/flutter.git
    • Framework revision c860cba910 (2 months ago), 2022-03-25 00:23:12 -0500
    • Engine revision 57d3bac3dd
    • Dart version 2.16.2
    • DevTools version 2.9.2

[✓] Android toolchain - develop for Android devices (Android SDK version 31.0.0)
    • Android SDK at /Users/devarsh.ranpara/Library/Android/sdk
    • Platform android-31, build-tools 31.0.0
    • Java binary at: /Applications/Android Studio.app/Contents/jre/Contents/Home/bin/java
    • Java version OpenJDK Runtime Environment (build 11.0.11+0-b60-7590822)
    • All Android licenses accepted.

[✓] Xcode - develop for iOS and macOS (Xcode 13.0)
    • Xcode at /Applications/Xcode.app/Contents/Developer
    • CocoaPods version 1.11.2

[✓] Chrome - develop for the web
    • Chrome at /Applications/Google Chrome.app/Contents/MacOS/Google Chrome

[✓] Android Studio (version 2021.1)
    • Android Studio at /Applications/Android Studio.app/Contents
    • Flutter plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/9212-flutter
    • Dart plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/6351-dart
    • Java version OpenJDK Runtime Environment (build 11.0.11+0-b60-7590822)

[✓] VS Code (version 1.67.2)
    • VS Code at /Applications/Visual Studio Code.app/Contents
    • Flutter extension version 3.42.0

[✓] Connected device (4 available)
    • sdk gphone x86 (mobile) • emulator-5554             • android-x86    • Android 11 (API 30) (emulator)
    • SF-MOB-022 (mobile)     • ######### • ios            • iOS 15.3.1 19D52
    • macOS (desktop)         • macos                     • darwin-x64     • macOS 11.6.5 20G527 darwin-x64
    • Chrome (web)            • chrome                    • web-javascript • Google Chrome 102.0.5005.61

[✓] HTTP Host Availability
    • All required HTTP hosts are available

• No issues found!

This issue is already reported in https://github.com/darwin-morocho/flutter-facebook-auth/issues/251 But solution is not described there!

Screenshot of issue.

image image

DevarshRanpara commented 1 year ago

@darwin-morocho Can you please look into this in priority?

darwin-morocho commented 1 year ago

@darwin-morocho Can you please look into this in priority?

@DevarshRanpara try with 4.3.4+1

Before archive have you selected any ios device? also make sure that in your podfile and your deployment target has the same version. next you should run

flutter clean
flutter pub get
cd ios && pod install
flutter build ios

and try the archive again

DevarshRanpara commented 1 year ago

Thanks @darwin-morocho Looking into this.

DevarshRanpara commented 1 year ago

@darwin-morocho Now I am getting this error. image

gabrielbragaloft commented 1 year ago

just set the deployment target to 12.0

DevarshRanpara commented 1 year ago

@gabrielbragaloft , @darwin-morocho Tried everything, still facing same issue!

darwin-morocho commented 1 year ago

@DevarshRanpara that ia so weird because FBSDKCoreKit was removed on 4.3.4+2 it seems a cache problem. try to remove flutter_facebook_auth from your pubspec.yaml and run pod install next add flutter_facebook_auth again and run pod install . If the previous solution not works The last posible solution could be add the dependency FBSDKCoreKit manually in your Podfile

DevarshRanpara commented 1 year ago

@darwin-morocho Now it's different issue. It isn't able to find FBSDKLoginKit now. I am trying this in my CI/CD and I am not using any old catches for any builds.

Screenshot 2022-06-10 at 5 27 12 PM

darwin-morocho commented 1 year ago

@darwin-morocho Now it's different issue. It isn't able to find FBSDKLoginKit now. I am trying this in my CI/CD and I am not using any old catches for any builds.

Screenshot 2022-06-10 at 5 27 12 PM

Have you tried this locally in xcode?

DevarshRanpara commented 1 year ago

No, Trying in my local machine.

darwin-morocho commented 1 year ago

No, Trying in my local machine.

Let me know if in xcode you have the same error

DevarshRanpara commented 1 year ago

I am able to build archive in XCode but not in comand line! Can you help me in this case ?

Screenshot 2022-06-14 at 5 25 42 PM

darwin-morocho commented 1 year ago

I am able to build archive in XCode but not in comand line! Can you help me in this case ?

Screenshot 2022-06-14 at 5 25 42 PM

Hi in this case I think is not a bug of this plugin so I cannot help you.

DevarshRanpara commented 1 year ago

Okay thank you for your help.