Error while Installing Crashlytics (3.14.0) – 无法找到压缩文件目录

huangapple go评论61阅读模式
英文:

Error while Installing Crashlytics (3.14.0) - cannot find zipfile directory

问题

背景故事

我们刚刚将 macOS 更新到 macOS Catalina,问题就出现了;在较旧的 macOS 上它运行得非常完美。我们不得不手动信任 fabric.io 证书才能进行下载:

> 下载依赖项
> 安装 Alamofire (4.9.1)
> 安装 Crashlytics (3.14.0)
>
> [!] 安装 Crashlytics 时出错
> [!] /usr/bin/curl -f -L -o
> /var/folders/l0/whv35ab91t90r2ksnt6v01872000gn/T/d20200102-10389-1do3j4/file.zip
> https://kit-downloads.fabric.io/cocoapods/crashlytics/3.14.0/crashlytics.zip
> --create-dirs --netrc-optional --retry 2
>
> % Total % Received % Xferd Average Speed Time Time Time
> Current
> Dload Upload Total Spent Left Speed
>
> 0 0 0 0 0 0 0 0 --:--:-- --:--:--
> --:--:-- 0 0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0 curl: (60) SSL 证书问题: 证书链中的自签名证书。更多详细信息请参阅:
> https://curl.haxx.se/docs/sslcerts.html
>
> curl 无法验证服务器的合法性,因此无法建立安全连接。要了解更多关于这种情况以及如何解决它的信息,请访问上述网页。

当前问题

一旦证书问题解决了,我们遇到了安装错误。

> 下载依赖项
> 安装 Alamofire (4.9.1)
> 安装 Crashlytics (3.14.0)
>
> [!] 安装 Crashlytics 时出错
> [!] /usr/bin/unzip
> /var/folders/l0/whv35ab91t90r2ksnt6v01872000gn/T/d20200106-92577-1do3j4/file.zip
> -d /var/folders/l0/whv35ab91t90r2ksnt6v01872000gn/T/d20200106-92577-1do3j4
>
>
> 归档:
> /var/folders/l0/whv35ab91t90r2ksnt6v01872000gn/T/d20200106-92577-1do3j4/file.zip
> 未找到中央目录签名。要么这个文件不是
> 一个 zipfile,要么它构成多部分档案的一个磁盘。在
> 后一种情况下,中央目录和 zipfile 评论将位于
> 此档案的最后一个磁盘(磁盘)上。
>
> unzip: 无法找到 zipfile
> 目录位于以下位置之一
> /var/folders/l0/whv35ab91t90r2ksnt6v01872000gn/T/d20200106-92577-1do3j4/file.zip
> 或
> /var/folders/l0/whv35ab91t90r2ksnt6v01872000gn/T/d20200106-92577-1do3j4/file.zip.zip,
> 且无法找到
> /var/folders/l0/whv35ab91t90r2ksnt6v01872000gn/T/d20200106-92577-1do3j4/file.zip.ZIP,
> 期间。

该文件夹不存在,所以我不确定是 curl 出了问题还是他们清理了文件夹。有什么想法为什么会发生这种情况以及如何解决它?

英文:

Backstory

We just updated the macOS to macOS Catalina and the problems came; it was working perfectly on on an older macOS. We had to manually trust the fabric.io cert for the download to go through:

> Downloading dependencies
> Installing Alamofire (4.9.1)
> Installing Crashlytics (3.14.0)
>
> [!] Error installing Crashlytics
> [!] /usr/bin/curl -f -L -o
> /var/folders/l0/whv35ab91t90r2ksnt6v01872000gn/T/d20200102-10389-1do3j4/file.zip
> https://kit-downloads.fabric.io/cocoapods/crashlytics/3.14.0/crashlytics.zip
> --create-dirs --netrc-optional --retry 2
>
> % Total % Received % Xferd Average Speed Time Time Time
> Current
> Dload Upload Total Spent Left Speed
>
> 0 0 0 0 0 0 0 0 --:--:-- --:--:--
> --:--:-- 0 0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0 curl: (60) SSL certificate problem: self signed certificate in certificate chain More details here:
> https://curl.haxx.se/docs/sslcerts.html
>
> curl failed to verify the legitimacy of the server and therefore could
> not establish a secure connection to it. To learn more about this
> situation and how to fix it, please visit the web page mentioned
> above.

Current problem

Once the cert issue was solved we got an installation error.

> Downloading dependencies
> Installing Alamofire (4.9.1)
> Installing Crashlytics (3.14.0)
>
> [!] Error installing Crashlytics
> [!] /usr/bin/unzip
> /var/folders/l0/whv35ab91t90r2ksnt6v01872000gn/T/d20200106-92577-1do3j4/file.zip
> -d /var/folders/l0/whv35ab91t90r2ksnt6v01872000gn/T/d20200106-92577-1do3j4
>
>
> Archive:
> /var/folders/l0/whv35ab91t90r2ksnt6v01872000gn/T/d20200106-92577-1do3j4/file.zip
> End-of-central-directory signature not found. Either this file is not
> a zipfile, or it constitutes one disk of a multi-part archive. In the
> latter case the central directory and zipfile comment will be found on
> the last disk(s) of this archive.
>
> unzip: cannot find zipfile
> directory in one of
> /var/folders/l0/whv35ab91t90r2ksnt6v01872000gn/T/d20200106-92577-1do3j4/file.zip
> or
> /var/folders/l0/whv35ab91t90r2ksnt6v01872000gn/T/d20200106-92577-1do3j4/file.zip.zip,
> and cannot find
> /var/folders/l0/whv35ab91t90r2ksnt6v01872000gn/T/d20200106-92577-1do3j4/file.zip.ZIP,
> period.

The folder does not exists, so I am not sure if curl went wrong or they did a cleanup of the folder. Any idea why this is happening and how to solve it?

答案1

得分: 0

原来我们的计算机正在使用自签名证书(而且更复杂的是,我们在代理后面),出现了证书信任错误。转到Safari并加载URL,访问该站点,然后提示我批准该站点。这将证书存储到“钥匙串访问”中。然后进入“钥匙串访问”中相关的证书,获取其信息并将其更改为“始终信任”。问题解决了。

英文:

Turns out that our computer were using a self-signed certificate (and to make things even more complicated we were behind proxies), and certificate trust errors were appearing. Went to Safari and load the url, accessed the site, and it prompted me to approve the site. This stores the certificate into the Keychain Access. Went to the certificate in the Keychain Access in question, get its info and changed it to Always Trust. Problem solved.

huangapple
  • 本文由 发表于 2020年1月6日 17:15:51
  • 转载请务必保留本文链接:https://go.coder-hub.com/59609399.html
匿名

发表评论

匿名网友

:?: :razz: :sad: :evil: :!: :smile: :oops: :grin: :eek: :shock: :???: :cool: :lol: :mad: :twisted: :roll: :wink: :idea: :arrow: :neutral: :cry: :mrgreen:

确定