Cache push step not working

#1

Failed to generate fingerprints! Why?

| (5) cache-push@0.9.4 |
±-----------------------------------------------------------------------------+
| id: cache-push |
| version: 0.9.4 |
| collection: https://github.com/bitrise-io/bitrise-steplib.git |
| toolkit: bash |
| time: 2017-02-13T14:26:45-08:00 |
±-----------------------------------------------------------------------------+
| |
$ cd /Users/vagrant/git

2017/02/13 14:26:50 => stepParams: main.StepParamsModel{PathItems:[]main.StepParamsPathItemModel{main.StepParamsPathItemModel{Path:"/var/folders/90/5stft2v13fb_m_gv3c8x9nwc0000gn/T/cache001714291", IndicatorFilePath:""}, main.StepParamsPathItemModel{Path:"./Gousto/Carthage", IndicatorFilePath:"./Gousto/Carthage/Cachefile"}}, IgnoreCheckOnPaths:[]string(nil), CacheAPIURL:“https://bitrise-build-cache.herokuapp.com/cache/f2ad2d7e50012d37/zU2N5cJMbWpdR_bBtznniQ”, CompareCacheInfoPath:"", IsDebugMode:true, FingerprintMethodID:“file-content-hash”}
2017/02/13 14:26:50 => Provided list of paths to cache:
2017/02/13 14:26:50 * /var/folders/90/5stft2v13fb_m_gv3c8x9nwc0000gn/T/cache001714291
2017/02/13 14:26:50 * ./Gousto/Carthage
2017/02/13 14:26:50 (!) Skipping (./Gousto/Carthage/Cachefile): Specified path does not exist

2017/02/13 14:26:50 => (Filtered) Paths to cache:
2017/02/13 14:26:50 * /var/folders/90/5stft2v13fb_m_gv3c8x9nwc0000gn/T/cache001714291

2017/02/13 14:26:50 No base Cache Info found for compare
2017/02/13 14:26:50 New cache will be created …

2017/02/13 14:26:50 => Calculating Fingerprint …
2017/02/13 14:26:50 ==> Fingerprint method: file-content-hash
2017/02/13 14:26:50 (i) No fingerprint generated for path: (/var/folders/90/5stft2v13fb_m_gv3c8x9nwc0000gn/T/cache001714291) - no file found to generate one
2017/02/13 14:26:50 [!] Failed to calculate fingerprint: Failed to generate fingerprint for paths - no file found to generate one
exit status 1
WARN[14:26:50] Step (cache-push@0.9.4) failed, but was marked as skippable
| |
±–±--------------------------------------------------------------±---------+
| ! | cache-push@0.9.4 (exit code: 1) | 6.54 sec |
±–±--------------------------------------------------------------±---------+
| Issue tracker: https://github.com/bitrise-steplib/steps-cache-push/issues |
| Source: https://github.com/bitrise-steplib/steps-cache-push.git |
±–±--------------------------------------------------------------±---------+

±-----------------------------------------------------------------------------+

0 Likes

#2

Hi @keran.marinov,

It seems the fingerprint generation failed because there was no file to calculate a fingerprint for. From the log:

...
2017/02/13 14:26:50 (!) Skipping (./Gousto/Carthage/Cachefile): Specified path does not exist
...
2017/02/13 14:26:50 (i) No fingerprint generated for path: (/var/folders/90/5stft2v13fb_m_gv3c8x9nwc0000gn/T/cache001714291) - no file found to generate one
...
2017/02/13 14:26:50 [!] Failed to calculate fingerprint: Failed to generate fingerprint for paths - no file found to generate one

In case there’s absolutely no file to cache, the step will fail - but because a missing cache is not an error, it’s just marked as a warning (“Step (cache-push@0.9.4) failed, but was marked as skippable”).

Based on the log, I’d say you wanted to cache Carthage dependencies, but it seems the path to the Carthage/Cachefile is not the right one.

Do you use our Carthage step to install the carthage dependencies? That should generate this Cachefile, carthage itself does not (and carthage in itself doesn’t really support any caching, or at least that was the case back when we created our step, and the built in cache handling mechanism in the Carthage step).

If you have any questions, just let us know! If you can’t figure out why that file is missing, although it should not, please contact us through the onsite chat support or through email, and include the build’s bitrise.io URL so that we can look into that!

0 Likes

#3

Yes I am using your Carthage build step. All I need is to make it work like before, i really did not change much, all i did was migrate to swift 3.0, then manually cleared the cache, I have not touched the folder locations, I would expect this step to cache the files inside this directory ./Gousto/Carthage as it was before, Question is ./Gousto/Carthage/Cachefile is this the cache destination folder ? i am really not sure

0 Likes

#4

Can you please include the Carthage step’s log here? It’s really hard to say without that, the step’s log should include all the related infos.

0 Likes

#5

Here are the step
Pull - fails since there is no cache
Carthage - builds
Push - fails

±-----------------------------------------------------------------------------+
| (3) cache-pull@0.9.2 |
±-----------------------------------------------------------------------------+
| id: cache-pull |
| version: 0.9.2 |
| collection: https://github.com/bitrise-io/bitrise-steplib.git |
| toolkit: bash |
| time: 2017-02-13T13:50:16-08:00 |
±-----------------------------------------------------------------------------+
| |
$ cd /Users/vagrant/git
2017/02/13 13:50:20 Cache pull…
2017/02/13 13:50:20 => stepParams: main.StepParamsModel{CacheAPIURL:“https://bitrise-build-cache.herokuapp.com/cache/f2ad2d7e50012d37/zU2N5cJMbWpdR_bBtznniQ”, IsDebugMode:true}
2017/02/13 13:50:20 => Downloading Cache …
2017/02/13 13:50:20 => cacheTempDir: /var/folders/90/5stft2v13fb_m_gv3c8x9nwc0000gn/T/bitrise-cache269186112
2017/02/13 13:50:21 [!] Failed to download cache archive: Failed to generate Download URL: Download URL was rejected (http-code:404): {“error”:“Build Cache Not Found”}
exit status 1
WARN[13:50:21] Step (cache-pull@0.9.2) failed, but was marked as skippable
| |
±–±--------------------------------------------------------------±---------+
| ! | cache-pull@0.9.2 (exit code: 1) | 6.89 sec |
±–±--------------------------------------------------------------±---------+
| Issue tracker: https://github.com/bitrise-steplib/steps-cache-pull/issues |
| Source: https://github.com/bitrise-steplib/steps-cache-pull.git |
±–±--------------------------------------------------------------±---------+

±-----------------------------------------------------------------------------+
| (4) carthage@2.4.0 |
±-----------------------------------------------------------------------------+
| id: carthage |
| version: 2.4.0 |
| collection: https://github.com/bitrise-io/bitrise-steplib.git |
| toolkit: bash |
| time: 2017-02-13T13:50:23-08:00 |
±-----------------------------------------------------------------------------+
| |
INFO[13:50:23] * [OK] Step dependency (carthage) installed, available.
*** Cloning SwiftyUserDefaults
*** Cloning Bolts-Swift
*** Cloning SwiftDate
*** Cloning Alamofire
*** Cloning fmdb
*** Cloning aws-sdk-ios
*** Cloning Kingfisher
*** Cloning DeviceKit
*** Cloning Cartography
*** Cloning XCGLogger
*** Skipped downloading Alamofire.framework binary due to the error:
“API rate limit exceeded for 208.52.166.156. (But here’s the good news: Authenticated requests get a higher rate limit. Check out the documentation for more details.)”
*** Checking out Alamofire at “4.3.0”
*** Skipped downloading aws-sdk-ios.framework binary due to the error:
“API rate limit exceeded for 208.52.166.156. (But here’s the good news: Authenticated requests get a higher rate limit. Check out the documentation for more details.)”
*** Checking out aws-sdk-ios at “2.5.0”
*** Skipped downloading Bolts-Swift.framework binary due to the error:
“API rate limit exceeded for 208.52.166.156. (But here’s the good news: Authenticated requests get a higher rate limit. Check out the documentation for more details.)”
*** Checking out Bolts-Swift at “1.3.0”
*** Skipped downloading Cartography.framework binary due to the error:
“API rate limit exceeded for 208.52.166.156. (But here’s the good news: Authenticated requests get a higher rate limit. Check out the documentation for more details.)”
*** Checking out Cartography at “1.0.1”
*** Skipped downloading DeviceKit.framework binary due to the error:
“API rate limit exceeded for 208.52.166.156. (But here’s the good news: Authenticated requests get a higher rate limit. Check out the documentation for more details.)”
*** Checking out DeviceKit at “1.0.1”
*** Skipped downloading fmdb.framework binary due to the error:
“API rate limit exceeded for 208.52.166.156. (But here’s the good news: Authenticated requests get a higher rate limit. Check out the documentation for more details.)”
*** Checking out fmdb at “2.6.2”
*** Skipped downloading Kingfisher.framework binary due to the error:
“API rate limit exceeded for 208.52.166.156. (But here’s the good news: Authenticated requests get a higher rate limit. Check out the documentation for more details.)”
*** Checking out Kingfisher at “3.4.0”
*** Skipped downloading SwiftDate.framework binary due to the error:
“API rate limit exceeded for 208.52.166.156. (But here’s the good news: Authenticated requests get a higher rate limit. Check out the documentation for more details.)”
*** Checking out SwiftDate at “4.0.13”
*** Skipped downloading SwiftyUserDefaults.framework binary due to the error:
“API rate limit exceeded for 208.52.166.156. (But here’s the good news: Authenticated requests get a higher rate limit. Check out the documentation for more details.)”
*** Checking out SwiftyUserDefaults at “3.0.1”
*** Skipped downloading XCGLogger.framework binary due to the error:
“API rate limit exceeded for 208.52.166.156. (But here’s the good news: Authenticated requests get a higher rate limit. Check out the documentation for more details.)”
*** Checking out XCGLogger at “Version_4.0.0”
*** xcodebuild output can be found in /var/folders/90/5stft2v13fb_m_gv3c8x9nwc0000gn/T/carthage-xcodebuild.4AJpsx.log
*** Building scheme “Alamofire iOS” in Alamofire.xcworkspace
*** Building scheme “AWSDynamoDB” in AWSiOSSDKv2.xcodeproj
*** Building scheme “AWSLambda” in AWSiOSSDKv2.xcodeproj
*** Building scheme “AWSAPIGateway” in AWSiOSSDKv2.xcodeproj
*** Building scheme “AWSRekognition” in AWSiOSSDKv2.xcodeproj
*** Building scheme “AWSSimpleDB” in AWSiOSSDKv2.xcodeproj
*** Building scheme “AWSKinesis” in AWSiOSSDKv2.xcodeproj
*** Building scheme “AWSEC2” in AWSiOSSDKv2.xcodeproj
*** Building scheme “AWSCognito” in AWSiOSSDKv2.xcodeproj
*** Building scheme “AWSSES” in AWSiOSSDKv2.xcodeproj
*** Building scheme “AWSCloudWatch” in AWSiOSSDKv2.xcodeproj
*** Building scheme “AWSSNS” in AWSiOSSDKv2.xcodeproj
*** Building scheme “AWSCore” in AWSiOSSDKv2.xcodeproj
*** Building scheme “AWSAutoScaling” in AWSiOSSDKv2.xcodeproj
*** Building scheme “AWSElasticLoadBalancing” in AWSiOSSDKv2.xcodeproj
*** Building scheme “AWSMachineLearning” in AWSiOSSDKv2.xcodeproj
*** Building scheme “AWSLex” in AWSiOSSDKv2.xcodeproj
*** Building scheme “AWSCognitoIdentityProvider” in AWSiOSSDKv2.xcodeproj
*** Building scheme “AWSMobileAnalytics” in AWSiOSSDKv2.xcodeproj
*** Building scheme “AWSPinpoint” in AWSiOSSDKv2.xcodeproj
*** Building scheme “AWSIoT” in AWSiOSSDKv2.xcodeproj
*** Building scheme “AWSSQS” in AWSiOSSDKv2.xcodeproj
*** Building scheme “AWSS3” in AWSiOSSDKv2.xcodeproj
*** Building scheme “AWSPolly” in AWSiOSSDKv2.xcodeproj
*** Building scheme “BoltsSwift-iOS” in BoltsSwift.xcworkspace
*** Building scheme “Cartography-iOS” in Cartography.xcworkspace
*** Building scheme “DeviceKit” in DeviceKit.xcodeproj
*** Building scheme “FMDB iOS” in fmdb.xcodeproj
*** Building scheme “Kingfisher” in Kingfisher.xcworkspace
*** Building scheme “SwiftDate_iOS” in SwiftDate.xcodeproj
*** Building scheme “SwiftyUserDefaults” in SwiftyUserDefaults.xcodeproj
*** Building scheme “XCGLogger (iOS)” in XCGLogger.xcodeproj
/Users/vagrant/git/Gousto/Carthage/Checkouts/aws-sdk-ios/AWSCognito/AWSCognitoDataset.m:356:102: warning: implicit conversion loses integer precision: ‘long long’ to ‘long’ [-Wshorten-64-to-32]
/Users/vagrant/git/Gousto/Carthage/Checkouts/aws-sdk-ios/AWSCognito/AWSCognitoDataset.m:356:102: warning: implicit conversion loses integer precision: ‘long long’ to ‘long’ [-Wshorten-64-to-32]
/Users/vagrant/git/Gousto/Carthage/Checkouts/aws-sdk-ios/AWSCognitoIdentityProvider/Internal/AWSCognitoIdentityProviderSrpHelper.m:213:5: warning: ignoring return value of function declared with warn_unused_result attribute [-Wunused-result]
/Users/vagrant/git/Gousto/Carthage/Checkouts/aws-sdk-ios/AWSCognitoIdentityProvider/Internal/AWSCognitoIdentityProviderSrpHelper.m:213:5: warning: ignoring return value of function declared with warn_unused_result attribute [-Wunused-result]
/Users/vagrant/git/Gousto/Carthage/Checkouts/aws-sdk-ios/AWSCognitoIdentityProvider/Internal/AWSCognitoIdentityProviderSrpHelper.m:213:5: warning: ignoring return value of function declared with warn_unused_result attribute [-Wunused-result]
/Users/vagrant/git/Gousto/Carthage/Checkouts/aws-sdk-ios/AWSCognitoIdentityProvider/Internal/AWSCognitoIdentityProviderSrpHelper.m:213:5: warning: ignoring return value of function declared with warn_unused_result attribute [-Wunused-result]
/Users/vagrant/git/Gousto/Carthage/Checkouts/aws-sdk-ios/AWSIoT/Internal/SocketRocket/AWSSRWebSocket.m:506:5: warning: ignoring return value of function declared with warn_unused_result attribute [-Wunused-result]
/Users/vagrant/git/Gousto/Carthage/Checkouts/aws-sdk-ios/AWSIoT/Internal/SocketRocket/AWSSRWebSocket.m:630:13: warning: enumeration value ‘NSURLNetworkServiceTypeCallSignaling’ not handled in switch [-Wswitch]
/Users/vagrant/git/Gousto/Carthage/Checkouts/aws-sdk-ios/AWSIoT/Internal/SocketRocket/AWSSRWebSocket.m:1444:9: warning: ignoring return value of function declared with warn_unused_result attribute [-Wunused-result]
/Users/vagrant/git/Gousto/Carthage/Checkouts/aws-sdk-ios/AWSIoT/Internal/SocketRocket/AWSSRWebSocket.m:506:5: warning: ignoring return value of function declared with warn_unused_result attribute [-Wunused-result]
/Users/vagrant/git/Gousto/Carthage/Checkouts/aws-sdk-ios/AWSIoT/Internal/SocketRocket/AWSSRWebSocket.m:630:13: warning: enumeration value ‘NSURLNetworkServiceTypeCallSignaling’ not handled in switch [-Wswitch]
/Users/vagrant/git/Gousto/Carthage/Checkouts/aws-sdk-ios/AWSIoT/Internal/SocketRocket/AWSSRWebSocket.m:1444:9: warning: ignoring return value of function declared with warn_unused_result attribute [-Wunused-result]
/Users/vagrant/git/Gousto/Carthage/Checkouts/aws-sdk-ios/AWSIoT/Internal/SocketRocket/AWSSRWebSocket.m:506:5: warning: ignoring return value of function declared with warn_unused_result attribute [-Wunused-result]
/Users/vagrant/git/Gousto/Carthage/Checkouts/aws-sdk-ios/AWSIoT/Internal/SocketRocket/AWSSRWebSocket.m:630:13: warning: enumeration value ‘NSURLNetworkServiceTypeCallSignaling’ not handled in switch [-Wswitch]
/Users/vagrant/git/Gousto/Carthage/Checkouts/aws-sdk-ios/AWSIoT/Internal/SocketRocket/AWSSRWebSocket.m:1444:9: warning: ignoring return value of function declared with warn_unused_result attribute [-Wunused-result]
/Users/vagrant/git/Gousto/Carthage/Checkouts/aws-sdk-ios/AWSIoT/Internal/SocketRocket/AWSSRWebSocket.m:506:5: warning: ignoring return value of function declared with warn_unused_result attribute [-Wunused-result]
/Users/vagrant/git/Gousto/Carthage/Checkouts/aws-sdk-ios/AWSIoT/Internal/SocketRocket/AWSSRWebSocket.m:630:13: warning: enumeration value ‘NSURLNetworkServiceTypeCallSignaling’ not handled in switch [-Wswitch]
/Users/vagrant/git/Gousto/Carthage/Checkouts/aws-sdk-ios/AWSIoT/Internal/SocketRocket/AWSSRWebSocket.m:1444:9: warning: ignoring return value of function declared with warn_unused_result attribute [-Wunused-result]
Running carthage command: -c carthage update --platform iOS --platform iOS
| |
±–±--------------------------------------------------------------±---------+
| ✓ | carthage@2.4.0 | 36.4 min |
±–±--------------------------------------------------------------±---------+
| Update available: 2.4.0 -> 3.0.5 |
±–±--------------------------------------------------------------±---------+

±-----------------------------------------------------------------------------+
| (5) cache-push@0.9.4 |
±-----------------------------------------------------------------------------+
| id: cache-push |
| version: 0.9.4 |
| collection: https://github.com/bitrise-io/bitrise-steplib.git |
| toolkit: bash |
| time: 2017-02-13T14:26:45-08:00 |
±-----------------------------------------------------------------------------+
| |
$ cd /Users/vagrant/git

2017/02/13 14:26:50 => stepParams: main.StepParamsModel{PathItems:[]main.StepParamsPathItemModel{main.StepParamsPathItemModel{Path:"/var/folders/90/5stft2v13fb_m_gv3c8x9nwc0000gn/T/cache001714291", IndicatorFilePath:""}, main.StepParamsPathItemModel{Path:"./Gousto/Carthage", IndicatorFilePath:"./Gousto/Carthage/Cachefile"}}, IgnoreCheckOnPaths:[]string(nil), CacheAPIURL:“https://bitrise-build-cache.herokuapp.com/cache/f2ad2d7e50012d37/zU2N5cJMbWpdR_bBtznniQ”, CompareCacheInfoPath:"", IsDebugMode:true, FingerprintMethodID:“file-content-hash”}
2017/02/13 14:26:50 => Provided list of paths to cache:
2017/02/13 14:26:50 * /var/folders/90/5stft2v13fb_m_gv3c8x9nwc0000gn/T/cache001714291
2017/02/13 14:26:50 * ./Gousto/Carthage
2017/02/13 14:26:50 (!) Skipping (./Gousto/Carthage/Cachefile): Specified path does not exist

2017/02/13 14:26:50 => (Filtered) Paths to cache:
2017/02/13 14:26:50 * /var/folders/90/5stft2v13fb_m_gv3c8x9nwc0000gn/T/cache001714291

2017/02/13 14:26:50 No base Cache Info found for compare
2017/02/13 14:26:50 New cache will be created …

2017/02/13 14:26:50 => Calculating Fingerprint …
2017/02/13 14:26:50 ==> Fingerprint method: file-content-hash
2017/02/13 14:26:50 (i) No fingerprint generated for path: (/var/folders/90/5stft2v13fb_m_gv3c8x9nwc0000gn/T/cache001714291) - no file found to generate one
2017/02/13 14:26:50 [!] Failed to calculate fingerprint: Failed to generate fingerprint for paths - no file found to generate one
exit status 1
WARN[14:26:50] Step (cache-push@0.9.4) failed, but was marked as skippable
| |
±–±--------------------------------------------------------------±---------+
| ! | cache-push@0.9.4 (exit code: 1) | 6.54 sec |
±–±--------------------------------------------------------------±---------+
| Issue tracker: https://github.com/bitrise-steplib/steps-cache-push/issues |
| Source: https://github.com/bitrise-steplib/steps-cache-push.git |
±–±--------------------------------------------------------------±---------+

0 Likes

#6

It seems you use the “update” carthage command (Carthage command to run input of the Carthage step). Can you please try to switch to “bootstrap”?

The 2.4.0 version of the step I believe only supported cache for “bootstrap”, but in any case “bootstrap” should work; update is designed to update every dependency every time (AFAIK).

Related links:

1 Like

#7

Ok thanks, i will try now

1 Like

#8

Please let us know how it goes!

0 Likes

#9

Thanks again, Victor. I owe you a beer :slight_smile:

1 Like

#10

No problem at all :wink:

In the meantime I checked the Carthage docs, and I think the step is right to only generate Cache infos for bootstrap and not for update, as update disregards any dependencies found locally and updates all dependencies every time you run it, so caching it would not help.

Added this to the #how-to guide:

0 Likes