This error occurs when I try to build an iOS app with flutter: (flutter build ios command executed)
sunhui@sunhuideMacBook-Pro ios % flutter build ios
Changing current working directory to: /Users/sunhui/xcodeProjects/aiyunhua_ai_app
Building com.linshang.app for device (ios-release)...
Updating project for Xcode compatibility.
Upgrading project.pbxproj
Upgrading Runner.xcscheme
Automatically signing iOS for device deployment using specified development team in Xcode project: QW5598QK8Y
Running pod install... 1,638ms
CocoaPods' output:
↳
Preparing
Analyzing dependencies
Inspecting targets to integrate
Using `ARCHS` setting to build architectures of target `Pods-Runner`: (``)
Using `ARCHS` setting to build architectures of target `Pods-RunnerTests`: (``)
Fetching external sources
-> Fetching podspec for `Flutter` from `Flutter`
-> Fetching podspec for `aliyun_push` from `.symlinks/plugins/aliyun_push/ios`
-> Fetching podspec for `app_settings` from `.symlinks/plugins/app_settings/ios`
-> Fetching podspec for `flutter_baidu_mob_stat` from `.symlinks/plugins/flutter_baidu_mob_stat/ios`
-> Fetching podspec for `flutter_image_compress_common` from `.symlinks/plugins/flutter_image_compress_common/ios`
-> Fetching podspec for `flutter_local_notifications` from `.symlinks/plugins/flutter_local_notifications/ios`
-> Fetching podspec for `fluwx` from `.symlinks/plugins/fluwx/ios`
5.1.2
using sdk with pay
ignore_security:
app_id: universal_link:
-> Fetching podspec for `image_cropper` from `.symlinks/plugins/image_cropper/ios`
-> Fetching podspec for `image_editor_common` from `.symlinks/plugins/image_editor_common/ios`
-> Fetching podspec for `image_gallery_saver` from `.symlinks/plugins/image_gallery_saver/ios`
-> Fetching podspec for `image_picker_ios` from `.symlinks/plugins/image_picker_ios/ios`
-> Fetching podspec for `package_info_plus` from `.symlinks/plugins/package_info_plus/ios`
-> Fetching podspec for `path_provider_foundation` from `.symlinks/plugins/path_provider_foundation/darwin`
-> Fetching podspec for `permission_handler_apple` from `.symlinks/plugins/permission_handler_apple/ios`
-> Fetching podspec for `shared_preferences_foundation` from `.symlinks/plugins/shared_preferences_foundation/darwin`
-> Fetching podspec for `tobias` from `.symlinks/plugins/tobias/ios`
5.1.2
using sdk with normal
ignore_security:
universal_link:
-> Fetching podspec for `url_launcher_ios` from `.symlinks/plugins/url_launcher_ios/ios`
-> Fetching podspec for `video_player_avfoundation` from `.symlinks/plugins/video_player_avfoundation/darwin`
Resolving dependencies of `Podfile`
CDN: trunk Relative path: CocoaPods-version.yml exists! Returning local because checking is only performed in repo update
CDN: trunk Relative path: all_pods_versions_4_2_c.txt exists! Returning local because checking is only performed in repo update
CDN: trunk Relative path: Specs/4/2/c/FlutterMacOS/3.16.0/FlutterMacOS.podspec.json exists! Returning local because checking is only performed in repo
update
CDN: trunk Relative path: all_pods_versions_e_7_e.txt exists! Returning local because checking is only performed in repo update
[!] Unable to find a specification for `AlicloudPush` depended upon by `aliyun_push`
You have either:
* out-of-date source repos which you can update with `pod repo update` or with `pod install --repo-update`.
* mistyped the name or version.
* not added the source repo that hosts the Podspec to your Podfile.
/usr/local/lib/ruby/gems/3.3.0/gems/cocoapods-1.15.2/lib/cocoapods/resolver.rb:389:in `find_cached_set'
/usr/local/lib/ruby/gems/3.3.0/gems/cocoapods-1.15.2/lib/cocoapods/resolver.rb:360:in `specifications_for_dependency'
/usr/local/lib/ruby/gems/3.3.0/gems/cocoapods-1.15.2/lib/cocoapods/resolver.rb:165:in `search_for'
/usr/local/lib/ruby/gems/3.3.0/gems/cocoapods-1.15.2/lib/cocoapods/resolver.rb:274:in `block in sort_dependencies'
/usr/local/lib/ruby/gems/3.3.0/gems/cocoapods-1.15.2/lib/cocoapods/resolver.rb:267:in `each'
/usr/local/lib/ruby/gems/3.3.0/gems/cocoapods-1.15.2/lib/cocoapods/resolver.rb:267:in `sort_by'
/usr/local/lib/ruby/gems/3.3.0/gems/cocoapods-1.15.2/lib/cocoapods/resolver.rb:267:in `sort_by!'
/usr/local/lib/ruby/gems/3.3.0/gems/cocoapods-1.15.2/lib/cocoapods/resolver.rb:267:in `sort_dependencies'
/usr/local/Cellar/cocoapods/1.15.2/libexec/gems/molinillo-0.8.0/lib/molinillo/delegates/specification_provider.rb:60:in `block in sort_dependencies'
/usr/local/Cellar/cocoapods/1.15.2/libexec/gems/molinillo-0.8.0/lib/molinillo/delegates/specification_provider.rb:77:in
`with_no_such_dependency_error_handling'
/usr/local/Cellar/cocoapods/1.15.2/libexec/gems/molinillo-0.8.0/lib/molinillo/delegates/specification_provider.rb:59:in `sort_dependencies'
/usr/local/Cellar/cocoapods/1.15.2/libexec/gems/molinillo-0.8.0/lib/molinillo/resolution.rb:754:in `push_state_for_requirements'
/usr/local/Cellar/cocoapods/1.15.2/libexec/gems/molinillo-0.8.0/lib/molinillo/resolution.rb:744:in `require_nested_dependencies_for'
/usr/local/Cellar/cocoapods/1.15.2/libexec/gems/molinillo-0.8.0/lib/molinillo/resolution.rb:727:in `activate_new_spec'
/usr/local/Cellar/cocoapods/1.15.2/libexec/gems/molinillo-0.8.0/lib/molinillo/resolution.rb:684:in `attempt_to_activate'
/usr/local/Cellar/cocoapods/1.15.2/libexec/gems/molinillo-0.8.0/lib/molinillo/resolution.rb:254:in `process_topmost_state'
/usr/local/Cellar/cocoapods/1.15.2/libexec/gems/molinillo-0.8.0/lib/molinillo/resolution.rb:182:in `resolve'
/usr/local/Cellar/cocoapods/1.15.2/libexec/gems/molinillo-0.8.0/lib/molinillo/resolver.rb:43:in `resolve'
/usr/local/lib/ruby/gems/3.3.0/gems/cocoapods-1.15.2/lib/cocoapods/resolver.rb:94:in `resolve'
/usr/local/lib/ruby/gems/3.3.0/gems/cocoapods-1.15.2/lib/cocoapods/installer/analyzer.rb:1082:in `block in resolve_dependencies'
/usr/local/lib/ruby/gems/3.3.0/gems/cocoapods-1.15.2/lib/cocoapods/user_interface.rb:64:in `section'
/usr/local/lib/ruby/gems/3.3.0/gems/cocoapods-1.15.2/lib/cocoapods/installer/analyzer.rb:1080:in `resolve_dependencies'
/usr/local/lib/ruby/gems/3.3.0/gems/cocoapods-1.15.2/lib/cocoapods/installer/analyzer.rb:125:in `analyze'
/usr/local/lib/ruby/gems/3.3.0/gems/cocoapods-1.15.2/lib/cocoapods/installer.rb:422:in `analyze'
/usr/local/lib/ruby/gems/3.3.0/gems/cocoapods-1.15.2/lib/cocoapods/installer.rb:244:in `block in resolve_dependencies'
/usr/local/lib/ruby/gems/3.3.0/gems/cocoapods-1.15.2/lib/cocoapods/user_interface.rb:64:in `section'
/usr/local/lib/ruby/gems/3.3.0/gems/cocoapods-1.15.2/lib/cocoapods/installer.rb:243:in `resolve_dependencies'
/usr/local/lib/ruby/gems/3.3.0/gems/cocoapods-1.15.2/lib/cocoapods/installer.rb:162:in `install!'
/usr/local/lib/ruby/gems/3.3.0/gems/cocoapods-1.15.2/lib/cocoapods/command/install.rb:52:in `run'
/usr/local/Cellar/cocoapods/1.15.2/libexec/gems/claide-1.1.0/lib/claide/command.rb:334:in `run'
/usr/local/lib/ruby/gems/3.3.0/gems/cocoapods-1.15.2/lib/cocoapods/command.rb:52:in `run'
/usr/local/lib/ruby/gems/3.3.0/gems/cocoapods-1.15.2/bin/pod:55:in `<top (required)>'
/usr/local/Cellar/cocoapods/1.15.2/libexec/bin/pod:25:in `load'
/usr/local/Cellar/cocoapods/1.15.2/libexec/bin/pod:25:in `<main>'
Error output from CocoaPods:
↳
/usr/local/Cellar/ruby/3.3.4/lib/ruby/3.3.0/uri/rfc3986_parser.rb:81:in `rescue in split': bad URI(is not URI?): nil (URI::InvalidURIError)
from /usr/local/Cellar/ruby/3.3.4/lib/ruby/3.3.0/uri/rfc3986_parser.rb:78:in `split'
from /usr/local/Cellar/ruby/3.3.4/lib/ruby/3.3.0/uri/rfc3986_parser.rb:135:in `parse'
from /usr/local/Cellar/ruby/3.3.4/lib/ruby/3.3.0/uri/common.rb:185:in `parse'
from /Users/sunhui/.pub-cache/hosted/pub.dev/fluwx-4.5.5/ios/wechat_setup.rb:61:in `block in <main>'
from /Users/sunhui/.pub-cache/hosted/pub.dev/fluwx-4.5.5/ios/wechat_setup.rb:54:in `each'
from /Users/sunhui/.pub-cache/hosted/pub.dev/fluwx-4.5.5/ios/wechat_setup.rb:54:in `<main>'
/usr/local/Cellar/ruby/3.3.4/lib/ruby/3.3.0/uri/rfc3986_parser.rb:79:in `split': undefined method `to_str' for nil (NoMethodError)
uri = uri.to_str
^^^^^^^
from /usr/local/Cellar/ruby/3.3.4/lib/ruby/3.3.0/uri/rfc3986_parser.rb:135:in `parse'
from /usr/local/Cellar/ruby/3.3.4/lib/ruby/3.3.0/uri/common.rb:185:in `parse'
from /Users/sunhui/.pub-cache/hosted/pub.dev/fluwx-4.5.5/ios/wechat_setup.rb:61:in `block in <main>'
from /Users/sunhui/.pub-cache/hosted/pub.dev/fluwx-4.5.5/ios/wechat_setup.rb:54:in `each'
from /Users/sunhui/.pub-cache/hosted/pub.dev/fluwx-4.5.5/ios/wechat_setup.rb:54:in `<main>'
Must provide a project directory and project name.
Error: CocoaPods's specs repository is too out-of-date to satisfy dependencies.
To update the CocoaPods specs, run:
pod repo update
Error running pod install
I continue to execute the pod install –repo-update command, but I still get the following error:
sunhui@sunhuideMacBook-Pro ios % pod install --repo-update
Updating local specs repositories
Analyzing dependencies
5.1.2
using sdk with pay
ignore_security:
app_id: universal_link:
/usr/local/Cellar/ruby/3.3.4/lib/ruby/3.3.0/uri/rfc3986_parser.rb:81:in `rescue in split': bad URI(is not URI?): nil (URI::InvalidURIError)
from /usr/local/Cellar/ruby/3.3.4/lib/ruby/3.3.0/uri/rfc3986_parser.rb:78:in `split'
from /usr/local/Cellar/ruby/3.3.4/lib/ruby/3.3.0/uri/rfc3986_parser.rb:135:in `parse'
from /usr/local/Cellar/ruby/3.3.4/lib/ruby/3.3.0/uri/common.rb:185:in `parse'
from /Users/sunhui/.pub-cache/hosted/pub.dev/fluwx-4.5.5/ios/wechat_setup.rb:61:in `block in <main>'
from /Users/sunhui/.pub-cache/hosted/pub.dev/fluwx-4.5.5/ios/wechat_setup.rb:54:in `each'
from /Users/sunhui/.pub-cache/hosted/pub.dev/fluwx-4.5.5/ios/wechat_setup.rb:54:in `<main>'
/usr/local/Cellar/ruby/3.3.4/lib/ruby/3.3.0/uri/rfc3986_parser.rb:79:in `split': undefined method `to_str' for nil (NoMethodError)
uri = uri.to_str
^^^^^^^
from /usr/local/Cellar/ruby/3.3.4/lib/ruby/3.3.0/uri/rfc3986_parser.rb:135:in `parse'
from /usr/local/Cellar/ruby/3.3.4/lib/ruby/3.3.0/uri/common.rb:185:in `parse'
from /Users/sunhui/.pub-cache/hosted/pub.dev/fluwx-4.5.5/ios/wechat_setup.rb:61:in `block in <main>'
from /Users/sunhui/.pub-cache/hosted/pub.dev/fluwx-4.5.5/ios/wechat_setup.rb:54:in `each'
from /Users/sunhui/.pub-cache/hosted/pub.dev/fluwx-4.5.5/ios/wechat_setup.rb:54:in `<main>'
5.1.2
using sdk with normal
ignore_security:
universal_link:
Must provide a project directory and project name.
[!] Unable to find a specification for `AlicloudPush` depended upon by `aliyun_push`
You have either:
* mistyped the name or version.
* not added the source repo that hosts the Podspec to your Podfile.
My device is MacBookPro 2019 with Inter chip
My version of flutter is: 3.24.0; cocoapods version: 1.15.2; ruby version: 3.3.4
I have tried:
1、flutter clean;flutter pub get
2、pod repo update
Has anyone faced a similar issue or have a solution to this problem?
New contributor
sunhui is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.