用Swift3升级到Xcode8后,我发现Cocoapods不再支持这个功能。所以我将Cocoapods升级到1.1.0rc2的测试版。但是,当我尝试pd spec lint时,出现错误:Swift3的Cocoapods 1.1.0测试版
- ERROR | xcodebuild: WeatherKit/WeatherKit/DateComponents+InitFromString.swift:11:11: error: use of undeclared type 'DateComponents'
- ERROR | [iOS] xcodebuild: WeatherKit/WeatherKit/CityLoader.swift:14:13: error: use of undeclared type 'DispatchQueue'
- ERROR | [iOS] xcodebuild: WeatherKit/WeatherKit/CityLoader.swift:19:11: error: use of unresolved identifier 'DispatchQueue'
- WARN | [iOS] xcodebuild: WeatherKit/WeatherKit/DirectionUnit.swift:20:15: warning: extraneous '_' in parameter: 'value' has no keyword argument name
- WARN | [iOS] xcodebuild: WeatherKit/WeatherKit/DistanceUnit.swift:19:15: warning: extraneous '_' in parameter: 'value' has no keyword argument name
Analyzed 1 podspec.
[!] The spec did not pass validation, due to 20 errors and 2 warnings.
20个错误都是关于Swift3语法的。但我使用Xcode8,它应该允许所有这些语法
有谁知道我可以用这个做什么?
但是当我回滚,这表明了“ - 错误| [iOS版]未知:验证期间遇到未知错误(模拟器iPhone 4s不可用)。“ –
我不认为iPhone 4S是Xcode 8 sim中的一个选项(或者它不应该是)。尝试使用iPhone SE。 –
但它不能像Cocoapods那样工作。我试图将模拟器更改为iPhone5,但它仍然不起作用。但它解决了,看到我上面的答案 –