I found pod install on my project succeeds in my local computer but not in my CI server after I decided to add Podfile.lock to my git repository. Here's an error message:
Analyzing dependencies
[!] Unable to satisfy the following requirements:
- `NSDate-Escort (from `https://github.com/akisute/NSDate-Escort.git`, tag `1.4.2`)` required by `Podfile`
- `NSDate-Escort (= 1.4.2)` required by `Podfile.lock`
As soon as I removed Podfile.lock from the CI server environment, pod install goes without any failures.
Here's a Podfile:
source 'https://github.com/CocoaPods/Specs.git'
platform :ios, '7.0'
pod 'AFNetworking', '~> 1.3.3'
pod 'MagicalRecord', '~> 2.2.0'
pod 'Bolts', '~> 1.1'
# From Personal CocoaPods repository:
# These pods had to be modified before use for reasons.
# Refer repositories for more information.
pod 'NSDate-Escort', :git => 'https://github.com/akisute/NSDate-Escort.git', :tag => '1.4.2'
pod 'Tweaks', :git => 'https://github.com/akisute/Tweaks.git', :branch => 'ios6'
And Podfile.lock in my local:
PODS:
- AFNetworking (1.3.4)
- Bolts (1.1.4)
- MagicalRecord (2.2):
- MagicalRecord/Core (= 2.2)
- MagicalRecord/Core (2.2)
- NSDate-Escort (1.4.2)
- Tweaks (1.1.0)
DEPENDENCIES:
- AFNetworking (~> 1.3.3)
- Bolts (~> 1.1)
- MagicalRecord (~> 2.2.0)
- NSDate-Escort (from `https://github.com/akisute/NSDate-Escort.git`, tag `1.4.2`)
- Tweaks (from `https://github.com/akisute/Tweaks.git`, branch `ios6`)
EXTERNAL SOURCES:
NSDate-Escort:
:git: https://github.com/akisute/NSDate-Escort.git
:tag: 1.4.2
Tweaks:
:branch: ios6
:git: https://github.com/akisute/Tweaks.git
CHECKOUT OPTIONS:
NSDate-Escort:
:git: https://github.com/akisute/NSDate-Escort.git
:tag: 1.4.2
Tweaks:
:commit: 702fb9340d826b464579055e06f4726d2aa79aa2
:git: https://github.com/akisute/Tweaks.git
SPEC CHECKSUMS:
AFNetworking: cf8e418e16f0c9c7e5c3150d019a3c679d015018
Bolts: f8e2f94edbf9fec7bb8de5ecaaa3aa6b7de6f64e
MagicalRecord: f8a56bb87ab6552f20c4bb8681a1958a197ea3cd
NSDate-Escort: 3ac2e9454e2d46e414f11d62d099294c1badc64f
Tweaks: fea40672d34a7185051b7786be0d587cd76d253c
COCOAPODS: 0.36.1
Interestingly, after I removed Podfile.lock from the CI server environment then reproduced it by pod install, its SPEC CHECKSUM for pods that has explicit URLs are changed, like this:
PODS:
- AFNetworking (1.3.4)
- Bolts (1.1.4)
- MagicalRecord (2.2):
- MagicalRecord/Core (= 2.2)
- MagicalRecord/Core (2.2)
- NSDate-Escort (1.4.2)
- Tweaks (1.1.0)
DEPENDENCIES:
- AFNetworking (~> 1.3.3)
- Bolts (~> 1.1)
- MagicalRecord (~> 2.2.0)
- NSDate-Escort (from `https://github.com/akisute/NSDate-Escort.git`, tag `1.4.2`)
- Tweaks (from `https://github.com/akisute/Tweaks.git`, branch `ios6`)
EXTERNAL SOURCES:
NSDate-Escort:
:git: https://github.com/akisute/NSDate-Escort.git
:tag: 1.4.2
Tweaks:
:branch: ios6
:git: https://github.com/akisute/Tweaks.git
CHECKOUT OPTIONS:
NSDate-Escort:
:git: https://github.com/akisute/NSDate-Escort.git
:tag: 1.4.2
Tweaks:
:commit: 702fb9340d826b464579055e06f4726d2aa79aa2
:git: https://github.com/akisute/Tweaks.git
SPEC CHECKSUMS:
AFNetworking: cf8e418e16f0c9c7e5c3150d019a3c679d015018
Bolts: f8e2f94edbf9fec7bb8de5ecaaa3aa6b7de6f64e
MagicalRecord: f8a56bb87ab6552f20c4bb8681a1958a197ea3cd
NSDate-Escort: 67da8c24f6ea8def8a6ccdb6e9a1a454af4dc310
Tweaks: 9337b5c9466d828bd6d69af3ccc124097472efad
COCOAPODS: 0.36.1
I suspect this might cause the problem.
This is correct behaviour, you have to run pod update to update your lockfile if you change the used versions of already installed Pods.
No, I mean I haven't changed anything. NSDate-Escort and Tweaks are my repositories that means none can update except me and both stable. I can definitely say I haven't change any versions of any pods in my Podfile in this case.
Sorry, I misread the issue. The change in checksums is curious, indeed.
@segiddins could this be a result of migrating the local spec to JSON?
Yes it is
-Samuel E. Giddins
On Mar 31, 2015, at 3:35 AM, Boris Bügling [email protected] wrote:
Sorry, I misread the issue. The change in checksums is curious, indeed.
@segiddins could this be a result of migrating the local spec to JSON?
—
Reply to this email directly or view it on GitHub.
@akisute can you check if this is fixed by https://github.com/CocoaPods/CocoaPods/pull/3343?
This should be fixed in 0.36.2.
Thanks! I'll give it a try and see it's actually fixed or not.
I'm having similar problem with CocoaPods 1.7.1. What should I do? Create new issue?
Most helpful comment
This is correct behaviour, you have to run
pod updateto update your lockfile if you change the used versions of already installed Pods.