CDN: trunk URL couldn't be downloaded

created at 07-10-2021 views: 1

error description

CDN: trunk URL couldn't be downloaded:

https://raw.githubusercontent.com/CocoaPods/Specs/master/Specs/f/e/9/CocoaMQTT/1.0.0/CocoaMQTT.podspec.json

Since the project is managed by CocoaPods, CocoaPods 1.8 will switch the CDN to the default spec repo source with some enhancements! CDN support was first introduced in version 1.7 and was finally completed in version 1.7.2. It is designed to greatly speed up initial setup and dependency analysis.

The current project using pods is version 1.8.4:

Ribers-Mac:ZNB_Country2.0Riber$ pod --version

1.8.4

I used pods recently, but an error occurred!

!]CDN:trunkRepoupdatefailed-17error(s):
CDN:trunkURLcouldn'tbe downloaded:https://raw.githubusercontent.com/CocoaPods/Specs/master/Specs/1/d/4/CocoaAsyncSocket/0.0.1/CocoaAsyncSocket.podspec.json,error:Operationtimedout-SSL_connect

...

According to the official document, add the source source in the podfile file:

source 'https://github.com/CocoaPods/Specs.git'

After adding the source source to the podfile file, pod install and pod update can operate normally, but some libraries in pod search are abnormal.

Ribers-Mac:ZNB_Country2.0Riber$podsearchmj

[!]CDN:trunkRepoupdatefailed-3error(s):
CDN:trunkURLcouldn'tbe downloaded:https://raw.githubusercontent.com/CocoaPods/Specs/master/Specs/0/f/b/MJRefresh/0.0.1/MJRefresh.podspec.json,error:Operationtimedout-SSL_connect
CDN:trunkURLcouldn'tbe downloaded:https://raw.githubusercontent.com/CocoaPods/Specs/master/Specs/0/f/b/MJRefresh/1.4.4/MJRefresh.podspec.json,error:Operationtimedout-SSL_connect
CDN:trunkURLcouldn'tbe downloaded:https://raw.githubusercontent.com/CocoaPods/Specs/master/Specs/0/f/b/MJRefresh/2.4.9/MJRefresh.podspec.json,error:Operationtimedout-SSL_connect
Ribers-Mac:ZNB_Country2.0Riber$podsearchrbtitle

->RBTitleView(2.0.1)

Simple and practical titleView

pod'RBTitleView','~> 2.0.1'
-Homepage:https://github.com/RiberWang/RBTitleDemo
-Source:https://github.com/RiberWang/RBTitleDemo.git
-Versions:2.0.1,1.0.1,1.0.0[masterrepo]

Solution:

1. Specify the source source as master in the podfile file:

source 'https://github.com/CocoaPods/Specs.git'

2. Execute pod repo remove trunk to remove the trunk source

After execution, pod search is all normal!

Ribers-Mac:ZNB_Country2.0Riber$ pod repo list

master
-Type:git (master)
-URL:https://github.com/CocoaPods/Specs.git
-Path:/Users/Riber/.cocoapods/repos/master
trunk
-Type:CDN
-URL:https://cdn.cocoapods.org/
-Path:/Users/Riber/.cocoapods/repos/trunk
2repos
Ribers-Mac:ZNB_Country2.0Riber$ pod repo remove trunk
Removing spec repo `trunk`

Note: The master source must be specified in the podfile file, because now the default is the trunk source

source 'https://github.com/CocoaPods/Specs.git'
Please log in to leave a comment.

Table of Conents