【发布时间】:2020-04-09 06:50:04
【问题描述】:
我正在尝试在 ios 模拟器(ios 13)上构建我的应用程序,但构建失败并给出 pod 文件错误:Podfile is out of date
这是错误。
Launching lib/main.dart on iPhone 11 Pro Max in debug mode...
Warning: Podfile is out of date
This can cause a mismatched version of Flutter to be embedded in your app, which may result in App Store submission rejection or crashes.
If you have local Podfile edits you would like to keep, see https://github.com/flutter/flutter/issues/24641 for instructions.
To regenerate the Podfile, run:
rm ios/Podfile
Warning: Podfile is out of date
This can cause issues if your application depends on plugins that do not support iOS.
See https://flutter.dev/docs/development/packages-and-plugins/developing-packages#plugin-platforms for details.
If you have local Podfile edits you would like to keep, see https://github.com/flutter/flutter/issues/45197 for instructions.
To regenerate the Podfile, run:
rm ios/Podfile
Running Xcode build...
Xcode build done. 7,8s
Failed to build iOS app
Error output from Xcode build:
↳
** BUILD FAILED **
Xcode's output:
↳
/Users/kareldebedts/developer/flutter/.pub-cache/hosted/pub.dartlang.org/cloud_firestore-0.12.11/ios/Classes/CloudFirestorePlugin.m:155:24: error: no visible @interface for 'FIRQuery' declares the selector 'queryWhereField:arrayContainsAny:'
query = [query queryWhereField:fieldName arrayContainsAny:value];
~~~~~ ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/Users/kareldebedts/developer/flutter/.pub-cache/hosted/pub.dartlang.org/cloud_firestore-0.12.11/ios/Classes/CloudFirestorePlugin.m:157:24: error: no visible @interface for 'FIRQuery' declares the selector 'queryWhereFieldPath:arrayContainsAny:'
query = [query queryWhereFieldPath:fieldPath arrayContainsAny:value];
~~~~~ ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/Users/kareldebedts/developer/flutter/.pub-cache/hosted/pub.dartlang.org/cloud_firestore-0.12.11/ios/Classes/CloudFirestorePlugin.m:163:24: error: no visible @interface for 'FIRQuery' declares the selector 'queryWhereField:in:'
query = [query queryWhereField:fieldName in:value];
~~~~~ ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
/Users/kareldebedts/developer/flutter/.pub-cache/hosted/pub.dartlang.org/cloud_firestore-0.12.11/ios/Classes/CloudFirestorePlugin.m:165:24: error: no visible @interface for 'FIRQuery' declares the selector 'queryWhereFieldPath:in:'
query = [query queryWhereFieldPath:fieldPath in:value];
~~~~~ ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/Users/kareldebedts/developer/flutter/.pub-cache/hosted/pub.dartlang.org/cloud_firestore-0.12.11/ios/Classes/CloudFirestorePlugin.m:764:16: warning: 'timestampsInSnapshotsEnabled' is deprecated [-Wdeprecated-declarations]
settings.timestampsInSnapshotsEnabled = (bool)call.arguments[@"timestampsInSnapshotsEnabled"];
^
In module 'FirebaseFirestore' imported from /Users/kareldebedts/DRINKM8/drinkm8_git/ios/Pods/Headers/Public/Firebase/Firebase.h:31:
/Users/kareldebedts/DRINKM8/drinkm8_git/ios/Pods/FirebaseFirestore/Firestore/Source/Public/FIRFirestoreSettings.h:69:20: note: 'timestampsInSnapshotsEnabled' has been explicitly marked deprecated here
__attribute__((deprecated));
^
1 warning and 4 errors generated.
Could not build the application for the simulator.
Error launching application on iPhone 11 Pro Max.
我试过 rm ios/Podfile ,但终端说该命令不存在...
这是我的 pubspec yaml。
dependencies:
flutter:
sdk: flutter
cupertino_icons: ^0.1.2
firebase_core: ^0.4.0
firebase_auth: ^0.11.1+12
flutter_facebook_login: ^2.0.1
cloud_firestore: ^0.12.7+1
shared_preferences: ^0.5.3+4
geolocator: ^5.1.1+1
url_launcher: ^5.1.2
rflutter_alert: ^1.0.3
font_awesome_flutter: ^8.5.0
flutter_picker: ^1.0.13
uuid: 2.0.1
image_picker: ^0.6.1
path_provider: ^1.2.0
image: ^2.1.4
firebase_storage: ^3.0.4
flutter_datetime_picker: ^1.2.5
intl: ^0.15.8
native_contact_picker: ^0.0.6
flutter_spinkit: ^4.0.0
transparent_image: ^1.0.0
connectivity: ^0.4.3+7
flare_splash_screen: ^2.1.3
algolia: ^0.1.6+1
http: ^0.12.0+2
cloud_functions: ^0.4.1+6
firebase_messaging: ^5.0.2
avatar_glow: ^1.0.0
google_maps_flutter: ^0.5.21+8
geoflutterfire: ^2.0.2
rxdart: ^0.22.2
auto_size_text: ^2.1.0
camera: ^0.5.4+1
video_player: ^0.10.2+1
story_view: ^0.11.0
thumbnails: ^1.0.1
image_crop: ^0.3.1
file_picker: ^1.4.2
pdf_viewer_plugin: ^1.0.0+2
flutter_background_geolocation: ^1.3.2
location_permissions: ^2.0.3
image_downloader: ^0.19.1
permission_handler: ^3.3.0
firebase_database: ^3.1.0
有人知道导致问题的原因吗? 可能是因为我把模拟器升级到了IOS 13...
提前致谢!
【问题讨论】:
标签: ios iphone xcode flutter podfile