【问题标题】:Flutter BoringSSL-GRPC unable to installFlutter BoringSSL-GRPC 无法安装
【发布时间】:2020-08-19 13:34:33
【问题描述】:

我正在尝试安装包:cloud_firestore,并且在安装依赖项BoringSSL-GRPC 时运行 pod install 时出现错误。
我是否可以以另一种方式安装依赖项并引用它/是否还有另一个我遗漏的问题。提前感谢任何可以提供帮助的人!

    Downloading dependencies

    -> Installing BoringSSL-GRPC (0.0.3)
     > Git download
     > Git download
         $ /usr/bin/git clone https://github.com/google/boringssl.git /var/folders/2g/mfqr5f5148nd_w6g9f1g72p80000gn/T/d20200505-3960-17lhqyp --template=

    [!] Error installing BoringSSL-GRPC
    [!] /usr/bin/git clone https://github.com/google/boringssl.git /var/folders/2g/mfqr5f5148nd_w6g9f1g72p80000gn/T/d20200505-3960-17lhqyp --template=

    Cloning into '/var/folders/2g/mfqr5f5148nd_w6g9f1g72p80000gn/T/d20200505-3960-17lhqyp'...
    error: RPC failed; curl 18 transfer closed with outstanding read data remaining
    fatal: the remote end hung up unexpectedly
    fatal: early EOF
    fatal: index-pack failed

    /Library/Ruby/Gems/2.6.0/gems/cocoapods-1.9.1/lib/cocoapods/downloader.rb:142:in `rescue in execute_command'
    /Library/Ruby/Gems/2.6.0/gems/cocoapods-1.9.1/lib/cocoapods/downloader.rb:139:in `execute_command'
    /Library/Ruby/Gems/2.6.0/gems/cocoapods-downloader-1.3.0/lib/cocoapods-downloader/base.rb:154:in `block in executable'
    /Library/Ruby/Gems/2.6.0/gems/cocoapods-downloader-1.3.0/lib/cocoapods-downloader/git.rb:79:in `block in clone'
    /Library/Ruby/Gems/2.6.0/gems/cocoapods-1.9.1/lib/cocoapods/downloader.rb:173:in `block in ui_sub_action'
    /Library/Ruby/Gems/2.6.0/gems/cocoapods-1.9.1/lib/cocoapods/user_interface.rb:64:in `section'
    /Library/Ruby/Gems/2.6.0/gems/cocoapods-1.9.1/lib/cocoapods/downloader.rb:172:in `ui_sub_action'
    /Library/Ruby/Gems/2.6.0/gems/cocoapods-downloader-1.3.0/lib/cocoapods-downloader/git.rb:77:in `clone'
    /Library/Ruby/Gems/2.6.0/gems/cocoapods-downloader-1.3.0/lib/cocoapods-downloader/git.rb:45:in `download!'
    /Library/Ruby/Gems/2.6.0/gems/cocoapods-downloader-1.3.0/lib/cocoapods-downloader/base.rb:82:in `block in download'
    /Library/Ruby/Gems/2.6.0/gems/cocoapods-1.9.1/lib/cocoapods/downloader.rb:157:in `block in ui_action'
    /Library/Ruby/Gems/2.6.0/gems/cocoapods-1.9.1/lib/cocoapods/user_interface.rb:64:in `section'
    /Library/Ruby/Gems/2.6.0/gems/cocoapods-1.9.1/lib/cocoapods/downloader.rb:156:in `ui_action'
    /Library/Ruby/Gems/2.6.0/gems/cocoapods-downloader-1.3.0/lib/cocoapods-downloader/base.rb:80:in `download'
    /Library/Ruby/Gems/2.6.0/gems/cocoapods-1.9.1/lib/cocoapods/downloader.rb:108:in `download_source'
    /Library/Ruby/Gems/2.6.0/gems/cocoapods-1.9.1/lib/cocoapods/downloader.rb:75:in `download_request'
    /Library/Ruby/Gems/2.6.0/gems/cocoapods-1.9.1/lib/cocoapods/downloader/cache.rb:171:in `download'
    /Library/Ruby/Gems/2.6.0/gems/cocoapods-1.9.1/lib/cocoapods/downloader/cache.rb:154:in `block in uncached_pod'
    /Library/Ruby/Gems/2.6.0/gems/cocoapods-1.9.1/lib/cocoapods/downloader/cache.rb:181:in `in_tmpdir'
    /Library/Ruby/Gems/2.6.0/gems/cocoapods-1.9.1/lib/cocoapods/downloader/cache.rb:153:in `uncached_pod'
    /Library/Ruby/Gems/2.6.0/gems/cocoapods-1.9.1/lib/cocoapods/downloader/cache.rb:33:in `download_pod'
    /Library/Ruby/Gems/2.6.0/gems/cocoapods-1.9.1/lib/cocoapods/downloader.rb:42:in `download'
    /Library/Ruby/Gems/2.6.0/gems/cocoapods-1.9.1/lib/cocoapods/installer/pod_source_installer.rb:117:in `download_source'
    /Library/Ruby/Gems/2.6.0/gems/cocoapods-1.9.1/lib/cocoapods/installer/pod_source_installer.rb:69:in `install!'
    /Library/Ruby/Gems/2.6.0/gems/cocoapods-1.9.1/lib/cocoapods/installer.rb:557:in `install_source_of_pod'
    /Library/Ruby/Gems/2.6.0/gems/cocoapods-1.9.1/lib/cocoapods/installer.rb:508:in `block (2 levels) in install_pod_sources'
    /Library/Ruby/Gems/2.6.0/gems/cocoapods-1.9.1/lib/cocoapods/user_interface.rb:86:in `titled_section'
    /Library/Ruby/Gems/2.6.0/gems/cocoapods-1.9.1/lib/cocoapods/installer.rb:507:in `block in install_pod_sources'
    /Library/Ruby/Gems/2.6.0/gems/cocoapods-1.9.1/lib/cocoapods/installer.rb:490:in `each'
    /Library/Ruby/Gems/2.6.0/gems/cocoapods-1.9.1/lib/cocoapods/installer.rb:490:in `install_pod_sources'
    /Library/Ruby/Gems/2.6.0/gems/cocoapods-1.9.1/lib/cocoapods/installer.rb:249:in `block in download_dependencies'
    /Library/Ruby/Gems/2.6.0/gems/cocoapods-1.9.1/lib/cocoapods/user_interface.rb:64:in `section'
    /Library/Ruby/Gems/2.6.0/gems/cocoapods-1.9.1/lib/cocoapods/installer.rb:248:in `download_dependencies'
    /Library/Ruby/Gems/2.6.0/gems/cocoapods-1.9.1/lib/cocoapods/installer.rb:157:in `install!'
    /Library/Ruby/Gems/2.6.0/gems/cocoapods-1.9.1/lib/cocoapods/command/install.rb:52:in `run'
    /Library/Ruby/Gems/2.6.0/gems/claide-1.0.3/lib/claide/command.rb:334:in `run'
    /Library/Ruby/Gems/2.6.0/gems/cocoapods-1.9.1/lib/cocoapods/command.rb:52:in `run'
    /Library/Ruby/Gems/2.6.0/gems/cocoapods-1.9.1/bin/pod:55:in `<top (required)>'
    /usr/local/bin/pod:23:in `load'
    /usr/local/bin/pod:23:in `<main>'

Error output from CocoaPods:
↳
         Cloning into '/var/folders/2g/mfqr5f5148nd_w6g9f1g72p80000gn/T/d20200505-3960-17lhqyp'...
         error: RPC failed; curl 18 transfer closed with outstanding read data remaining
         fatal: the remote end hung up unexpectedly
         fatal: early EOF
         fatal: index-pack failed

Error running pod install
Error launching application on iPhone 11.

【问题讨论】:

  • 在 Stack Overflow 上,请不要显示文字图片。将文本复制到问题本身并设置格式,以便于阅读、复制和搜索。
  • Cocoapods 在 git clone 步骤中失败。我不确定您系统上的根本原因是什么,但我建议您使用 --verbose 标志运行 pod install 命令,看看该命令到底是什么,然后尝试在 Cocoapods 之外运行它以进行调试。
  • 我在终端上尝试了以下命令,但也未能安装。 git config --global http.postBuffer 1048576000 git config --global http.lowSpeedLimit 0 git config --global http.lowSpeedTime 999999 你能找到解决办法吗?
  • 我可以通过 Muhamad Jalal 的回答来解决这个问题。

标签: ios xcode flutter cocoa google-cloud-firestore


【解决方案1】:

这个方法对我有用。

通过杀死并关闭它然后重新启动来重新启动您的终端/代码编辑器。

cd your-project-dir

cd ios

运行

吊舱安装

这将下载所有依赖项。这可能需要一些时间,所以请确保等待。

NB: Ensure to have stable internet.

【讨论】:

  • 我试过这个,但我运行了 pod update,所有库都是最新的,但它仍然给出同样的错误
【解决方案2】:

我有一个非常相似的问题。将解决方案留给任何可能有帮助的人。

这很难相信。我将这个问题归咎于我正在使用的有线以太网适配器。 wifi 和另外两个有线以太网适配器工作正常。

请注意,以太网适配器似乎可以正常工作。 git clone 在命令行中运行良好,问题仅在 ruby​​ Process.spawn 执行时才出现!

【讨论】:

    【解决方案3】:

    我通过这样做解决了它:

    1. 删除所有 pod 并添加 BoringSSL-GRPC:

    播客文件

    # Uncomment the next line to define a global platform for your project
    # platform :ios, '9.0'
    
    target 'XXXXX' do
      # Comment the next line if you don't want to use dynamic frameworks
      use_frameworks!
    
      pod 'BoringSSL-GRPC'
    end
    
    1. 执行 (bash) pod install --repo-update
    2. 删除 pod 'BoringSSL-GRPC' 并再次添加其他库

    播客文件

    ...
      pod 'Firebase/Analytics'
      pod 'Firebase/Auth'
      pod 'Firebase/Storage'
      pod 'Firebase/Functions'
      pod 'Firebase/RemoteConfig'
      pod 'FirebaseFirestoreSwift', '~> 7.9-beta'
    ...
    

    【讨论】:

    • 这对我也不起作用。第 2 步( pod install --repo-update )有同样的问题。
    【解决方案4】:

    我尝试了很多方法,但都没有奏效。然后,我重新启动我的机器。它有效。不明白原因!

    【讨论】:

      【解决方案5】:

      将我使用的所有 firebase 依赖项更改为此版本解决了我的问题

       firebase_messaging: ^10.0.2
       firebase_auth: ^1.4.1
       cloud_firestore: ^2.2.1
       firebase_storage: ^8.1.3
       firebase_core: ^1.3.0
      

      【讨论】:

      • 安装 Boringssl 0.0.7 在 2021.4 之前一直使用旧版本,但从上个月开始我突然无法再安装它。我已经尝试了所有其他答案,但在我的情况下无法解决这个问题。今天我找到了你的答案并解决了我的问题。非常感谢。
      • @persec10000 很高兴知道,继续保持兄弟。
      【解决方案6】:

      这是我为解决问题所做的:

      1. 扑干净
      2. 已移除 pod 锁定文件
      3. 删除了 pubspec.lock
      4. 颤振酒吧获取
      5. 吊舱安装

      【讨论】:

        猜你喜欢
        • 2020-11-21
        • 2021-01-11
        • 2020-07-27
        • 2022-08-09
        • 1970-01-01
        • 2020-04-22
        • 2020-10-22
        • 2021-08-26
        • 1970-01-01
        相关资源
        最近更新 更多