У меня есть приложение, созданное по флаттеру, и я хотел бы добавить firebase_auth и cloud_firestore. Раньше работал гладко. Затем я добавил следующие две строки в pubspe c .yaml:
firebase_auth: ^0.15.4
cloud_firestore: ^0.13.0+1
и запустил пакеты get. Ничего не делая, если я запускаю свой проект, он выдает следующую ошибку:
Launching lib/main.dart on iPhone 11 Pro Max in debug mode...
Running pod install...
Running Xcode build...
Xcode build done. 132.2s
Failed to build iOS app
Error output from Xcode build:
↳
2020-01-31 14:17:56.015 xcodebuild[41367:4940394] DTDeviceKit: deviceType from 00008006-0007354C3EFA002E was NULL
2020-01-31 14:17:57.763 xcodebuild[41367:4940338] [MT] iPhoneConnect: ?<DVTiOSDevice (0x7fbdeb156390), Baseduo, iPhone, 13.3.1 (17D5050a), 4be1310269eaf14dd153c6def229bddceaeebbe6> == Underlying device preparation errors ==
2020-01-31 14:17:57.763 xcodebuild[41367:4940338] [MT] iPhoneConnect: ?<DVTiOSDevice (0x7fbdeb156390), Baseduo, iPhone, 13.3.1 (17D5050a), 4be1310269eaf14dd153c6def229bddceaeebbe6> -- Failed _shouldMakeReadyForDevelopment check even though device is not locked by passcode.
Domain: com.apple.platform.iphoneos
Code: 5
Failure Reason: allowsSecureServices: 1. isConnected: 0. Platform: <DVTPlatform:0x7fbde662bd20:'com.apple.platform.iphoneos':<DVTFilePath:0x7fbde662bca0:'/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform'>>. DTDKDeviceIdentifierIsIDID: 0
--
2020-01-31 14:17:57.763 xcodebuild[41367:4940338] [MT] iPhoneConnect: ?<DVTiOSDevice (0x7fbdeb156390), Baseduo, iPhone, 13.3.1 (17D5050a), 4be1310269eaf14dd153c6def229bddceaeebbe6> == END: Underlying device preparation errors ==
** BUILD FAILED **
Xcode's output:
↳
/Users/Baseduo/Developer/flutter/.pub-cache/hosted/pub.dartlang.org/firebase_auth-0.15.4/ios/Classes/FLTFirebaseAuthPlugin.m:505:38: error: no known class method for selector 'credentialWithProviderID:IDToken:rawNonce:accessToken:'
credential = [FIROAuthProvider credentialWithProviderID:provider
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/Users/Baseduo/Developer/flutter/.pub-cache/hosted/pub.dartlang.org/firebase_auth-0.15.4/ios/Classes/FLTFirebaseAuthPlugin.m:514:38: error: no known class method for selector 'credentialWithProviderID:IDToken:rawNonce:'
credential = [FIROAuthProvider credentialWithProviderID:provider
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
2 errors generated.
Command CompileSwift failed with a nonzero exit code
Command CompileSwift failed with a nonzero exit code
Command CompileSwift failed with a nonzero exit code
Command CompileSwift failed with a nonzero exit code
Command CompileSwift failed with a nonzero exit code
note: Using new build system
note: Planning build
note: Constructing build description
Could not build the application for the simulator.
Error launching application on iPhone 11 Pro Max.
Нет ответа от Flutter Doctor:
/Users/Baseduo/Developer/flutter/bin/flutter doctor --verbose
[✓] Flutter (Channel stable, v1.12.13+hotfix.7, on Mac OS X 10.15.2 19C57, locale en-TR)
• Flutter version 1.12.13+hotfix.7 at /Users/Baseduo/Developer/flutter
• Framework revision 9f5ff2306b (4 days ago), 2020-01-26 22:38:26 -0800
• Engine revision a67792536c
• Dart version 2.7.0
[!] Android toolchain - develop for Android devices (Android SDK version 29.0.0)
• Android SDK at /Users/Baseduo/Library/Android/sdk
• Android NDK location not configured (optional; useful for native profiling support)
• Platform android-29, build-tools 29.0.0
• Java binary at: /Applications/Android Studio.app/Contents/jre/jdk/Contents/Home/bin/java
• Java version OpenJDK Runtime Environment (build 1.8.0_202-release-1483-b49-5587405)
! Some Android licenses not accepted. To resolve this, run: flutter doctor --android-licenses
[✓] Xcode - develop for iOS and macOS (Xcode 11.3.1)
• Xcode at /Applications/Xcode.app/Contents/Developer
• Xcode 11.3.1, Build version 11C504
• CocoaPods version 1.9.0.beta.2
[✓] Android Studio (version 3.5)
• Android Studio at /Applications/Android Studio.app/Contents
• Flutter plugin version 42.1.1
• Dart plugin version 191.8593
• Java version OpenJDK Runtime Environment (build 1.8.0_202-release-1483-b49-5587405)
[✓] Connected device (2 available)
• Baseduo • 4be1310269eaf14dd153c6def229bddceaeebbe6 • ios • iOS 13.3.1
• iPhone 11 Pro Max • 954398E8-1CB7-4189-B2E6-84E9F87BB94A • ios • com.apple.CoreSimulator.SimRuntime.iOS-13-3 (simulator)
! Doctor found issues in 1 category.
Process finished with exit code 0
Я не смог найти никаких действий для Решите это и оцените ваш ответ.
Спасибо,
ps: я использовал то же действие в других своих приложениях, и никаких проблем не существует.
ps2: Это работает для Android эмулятора.