我在自己的广告连播中引用了广告连播“ MatomoTracker”
我在掉毛时遇到此错误:pod lint spec
-> TrackerPod.v3 (0.0.1)
- ERROR | [iOS] unknown: Encountered an unknown error (CocoaPods could not find compatible versions for pod "Pods/MatomoTracker/MatomoTracker":
In Podfile:
TrackerPod.v3 (from `/Users/****/Documents/projects/ios/libs/TrackerPod.v3/TrackerPod.v3.podspec`) was resolved to 0.0.1, which depends on
TrackerPod.v3/Matomo (= 0.0.1) was resolved to 0.0.1, which depends on
Pods/MatomoTracker/MatomoTracker (= 5.2.0)
None of your spec sources contain a spec satisfying the dependency: `Pods/MatomoTracker/MatomoTracker (= 5.2.0)`.
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.
Note: as of CocoaPods 1.0, `pod repo update` does not happen on `pod install` by default.) during validation.
Analyzed 1 podspec.
[!] The spec did not pass validation, due to 1 error.
这是我的 podspec :
Pod::Spec.new do |spec|
spec.name = 'TrackerPod.v3'
spec.version = '0.0.1'
spec.license = 'Copyright ****'
spec.homepage = 'https://*******8/TrackerPod/blob/master/README.md'
spec.author = { '****' => '****@****.com' }
spec.summary = 'Some description'
spec.source = { :git => '****', :tag => spec.version.to_s }
spec.source_files = 'TrackerPod.v3/*.{h,m, swift}'
spec.ios.deployment_target = '8.0'
spec.osx.deployment_target = '10.10'
spec.requires_arc = true
spec.swift_version = '4.0'
spec.xcconfig = { 'SWIFT_VERSION' => '4.1' }
spec.dependency 'MatomoTracker', '5.2.0'
spec.subspec 'Matomo' do |lib|
lib.dependency 'Pods/MatomoTracker/MatomoTracker', '5.2.0'
lib.source_files = 'Pods/MatomoTracker/MatomoTracker/**/*.{h,m,swift}'
end
end
,这是屏幕截图,用于显示我的项目导航器。 您会看到MatomoTracker在“豆荚”内部嵌套了2个楼层
正在使用正确的路径引用MatomoTracker Pods/MatomoTracker/MatomoTracker
,似乎没有找到豆荚元?
我说得对吗?
答案 0 :(得分:0)
回答问题。我有点知道错误所在。
在我的podspec中,我正在使用spec.dependency 'MatomoTracker', '~> 5.2'
如果没有以上一行,则验证通过 似乎需要更高的最低部署目标。我到处都将部署目标设置为11.0 。 -Podfile -在Xcode中建立设置(吊舱目标) -Pod规格中的规格ios目标
而且,这是我得到的错误
ERROR | [iOS] xcodebuild: Returned an unsuccessful exit code. You can use `--verbose` for more information.
ERROR | [OSX] unknown: Encountered an unknown error (CocoaPods could not find compatible versions for pod "MatomoTracker":
In Podfile:
TrackerPod.v3 (from `/Users/*****/Documents/projects/ios/libs/TrackerPod.v3`) was resolved to 0.0.1, which depends on
MatomoTracker (~> 5.2)
Specs satisfying the `MatomoTracker (~> 5.2)` dependency were found, but they required a higher minimum deployment target.) during validation.
尽管我感觉像按照书本做的那样,按照cocoapods guide,我仍然缺少sthg。 MatomoTracker 未通过验证