6

I have an app made in Flutter and since the latest version of Xcode absolutely nothing works as before. I have been struggling with this problem for nearly a week now and the errors vary depending on the hour.

The main problem is that when distributing the application to Apple for review, they reject it with the following message:


2.1 Performance: App Completeness Guideline

2.1 - Performance - App Completeness

We discovered one or more bugs in your app when reviewed on iPad running iOS 14.0 on Wi-Fi.

Specifically, we were still unable to login through Sign in with Apple


I find this strange as all my previous uploads got verified without any problems. So to rectify this issue I'm trying to run the app through the simulator as I don't own an iPad. And here is where the problems start.

Side note: Running on a physical iPhone works without problems and I'm opening the project runner.xcworkspace, not the runner.xccodeproj.

The main problem is that Xcode won't find any libraries, starting with the first one:

GeneratedPluginRegistrant.m:10:9: Module 'apple_sign_in' not found

I have tried every solution related to this issue but to no avail.

Flutter doctor and pod-file below:

[✓] Flutter (Channel stable, 1.20.4, on Mac OS X 10.15.6 19G2021, locale en-ES) • Flutter version 1.20.4 at /Users/peter/flutter • Framework revision fba99f6cf9 (11 days ago), 2020-09-14 15:32:52 -0700 • Engine revision d1bc06f032 • Dart version 2.9.2

[✓] Android toolchain - develop for Android devices (Android SDK version 30.0.1) • Android SDK at /Users/peter/Library/Android/sdk • Platform android-30, build-tools 30.0.1 • Java binary at: /Library/Java/JavaVirtualMachines/jdk1.8.0_51.jdk/Contents/Home/bin/java • Java version Java(TM) SE Runtime Environment (build 1.8.0_51-b16) • All Android licenses accepted.

[✓] Xcode - develop for iOS and macOS (Xcode 12.0) • Xcode at /Applications/Xcode.app/Contents/Developer • Xcode 12.0, Build version 12A7209 • CocoaPods version 1.9.3

[!] Android Studio (not installed) • Android Studio not found; download from https://developer.android.com/studio/index.html (or visit https://flutter.dev/docs/get-started/install/macos#android-setup for detailed instructions).

[!] IntelliJ IDEA Community Edition (version 2017.2.5) • IntelliJ at /Applications/IntelliJ IDEA CE.app ✗ Flutter plugin not installed; this adds Flutter specific functionality. ✗ Dart plugin not installed; this adds Dart specific functionality. • For information about installing plugins, see https://flutter.dev/intellij-setup/#installing-the-plugins

[✓] Connected device (1 available) • iPhone 11 (mobile) • F1B8AE15-9028-4E0D-BD9D-2F2C7CC93ECE • ios • com.apple.CoreSimulator.SimRuntime.iOS-14-0 (simulator)

! Doctor found issues in 2 categories.

podfile:

# Uncomment this line to define a global platform for your project
platform :ios, '9.0'

# CocoaPods analytics sends network stats synchronously affecting flutter build latency.
ENV['COCOAPODS_DISABLE_STATS'] = 'true'

project 'Runner', {
  'Debug' => :debug,
  'Profile' => :release,
  'Release' => :release,
}

def flutter_root
  generated_xcode_build_settings_path = File.expand_path(File.join('..', 'Flutter', 'Generated.xcconfig'), __FILE__)
  unless File.exist?(generated_xcode_build_settings_path)
    raise "#{generated_xcode_build_settings_path} must exist. If you're running pod install manually, make sure flutter pub get is executed first"
  end

  File.foreach(generated_xcode_build_settings_path) do |line|
    matches = line.match(/FLUTTER_ROOT\=(.*)/)
    return matches[1].strip if matches
  end
  raise "FLUTTER_ROOT not found in #{generated_xcode_build_settings_path}. Try deleting Generated.xcconfig, then run flutter pub get"
end

require File.expand_path(File.join('packages', 'flutter_tools', 'bin', 'podhelper'), flutter_root)

flutter_ios_podfile_setup

target 'Runner' do
  use_frameworks!
  use_modular_headers!

  flutter_install_all_ios_pods File.dirname(File.realpath(__FILE__))
end

post_install do |installer|
  installer.pods_project.targets.each do |target|
    target.build_configurations.each do |config|
      config.build_settings['ENABLE_BITCODE'] = 'YES'
      config.build_settings['IPHONEOS_DEPLOYMENT_TARGET'] = '9.0'
    end
  end
end
enkara
  • 6,189
  • 6
  • 34
  • 52
  • It is very strange that you are able to execute a Xcode build if it warn you about a missing module. How you implemented Apple SignIn? With a package? – E.Benedos Sep 25 '20 at 12:20
  • @E.Benedos I can run the code on a physical device but not on a simulator, thats when the import error occurs. Apple sign in is with a package that i have used for a few months now. Im using this: https://pub.dev/packages/apple_sign_in – enkara Sep 25 '20 at 12:39
  • Have you also tried to open an issue on the dedicated repo? It seems a package problem and not a flutter one. – E.Benedos Sep 25 '20 at 12:42
  • @E.Benedos. if i remove that package, it will give me the same error for the next package in line. If I can complie and run on a physical device, there shouldn't be any reason not to be able to do the same on a simulator. – enkara Sep 25 '20 at 12:45
  • package wise issues may result if you are using a non-stable flutter release. You would return to the stable channel, then (you can google for this). But the error I received in this situation was different to yours. However, based on the Apple statements I understand you are lacking the Apple ID login possibility. So from there, I would investigate towards your problem (implemented, package running with flutter release, working package feature...) – w461 Sep 30 '20 at 09:17
  • @w461It all worked before iOS14 and the last xcode update – enkara Oct 06 '20 at 07:41
  • https://stackoverflow.com/a/75901008/14167970 This will work 100%, look into this solution. https://stackoverflow.com/questions/75894992/missing-file-libarclite-iphoneos-a-in-xcode-14-3-after-update-flutter-and-xcod/75901008#75901008 – Tushar Patel Mar 31 '23 at 18:03

3 Answers3

1

There are problems with Flutter 1.20.4 and XCode12/iOS14.
You need to update Flutter to the current beta (1.22.0-12.3.pre) which contains a lot of fixes for the new iOS/XCode versions.

See https://flutter.dev/docs/development/ios-14

Edit 10/01/2020: Flutter 1.22.0 has been released to stable and should work with XCode 12 and iOS 14 out of the box.

kuhnroyal
  • 7,188
  • 1
  • 34
  • 47
1

It might be a problem with the iOS Simulator.

Check out this forum.

You might want to reply to them pointing out this issue from the forum, seems to have worked for others.

Hemant Menon
  • 180
  • 6
0

Try to allow the module in xcode to see if it finds apple_sign_in

Open Xcode select Runner > Signing % Capabilities > +Capabilities > Select Apple_Sign_In

Xcode screenshot

kuhnroyal
  • 7,188
  • 1
  • 34
  • 47
  • Yep, that's all there. I haven't touched any of these settings since the last working and accepted version of my app. – enkara Oct 06 '20 at 07:44