cirrus-ci-docs
cirrus-ci-docs copied to clipboard
Problem with cache hit permissions (macOS, Linux?)
Expected Behavior
Restored from CI cache executable has correct permissions.
After cache reset: https://cirrus-ci.com/build/5438662258196480
Real Behavior
codecov/uploader
/var/folders/xx/vl5f934s6k927z1vyyl9cxth0000gn/T/scripts5fb90badb37c5821b6d95526a41a9504.sh: line 5: codecov/uploader: cannot execute binary file
Exit status: 126
https://cirrus-ci.com/task/6095845136269312?logs=codecov#L0
Related Info
This is a (tick one of the following):
- [ ] Website issue
- Link to page:
- [x] Task issue
- OS:
macOS - Task name:
Test on darwin - Script/cache name (if applies):
codecov_cache
- OS:
Configuration
env:
CODECOV_OS: macos
codecov_uploader_cache:
folder: codecov
fingerprint_script:
- curl -Os https://uploader.codecov.io/latest/${CODECOV_OS}/codecov.SHA256SUM
populate_script:
- mkdir -p codecov
- curl -s https://uploader.codecov.io/latest/${CODECOV_OS}/codecov -o codecov/uploader
- chmod +x codecov/uploader
codecov_script: codecov/uploader
Probably it's not only about macOS:
- https://cirrus-ci.com/task/4925892018307072
- https://cirrus-ci.com/task/5488841971728384
Unfortunately, I wasn't able to reproduce your example: https://cirrus-ci.com/task/5442098164924416.
Here's a full .cirrus.yml:
env:
CODECOV_OS: macos
task:
macos_instance:
image: monterey-base
codecov_uploader_cache:
folder: codecov
fingerprint_script:
- curl -Os https://uploader.codecov.io/latest/${CODECOV_OS}/codecov.SHA256SUM
populate_script:
- mkdir -p codecov
- curl -s https://uploader.codecov.io/latest/${CODECOV_OS}/codecov -o codecov/uploader
- chmod +x codecov/uploader
codecov_script: codecov/uploader
Or I am missing something here?
Or I am missing something here?
I don't see any valuable difference.
The project is open, you can see current complete configuration here: https://github.com/filewatcher/filewatcher/blob/0ad47c5/.cirrus.yaml
I've cleared cache today and PR had successful runs: https://cirrus-ci.com/task/6080908112429056
After merge there is the same problem: https://cirrus-ci.com/task/4662261959622656
Have you tried clearing caches on master/main? It seems that you're using a custom cache fingerprint, which may result in re-using of an older cache entry (if any) without chmod +x instruction.
Have you tried clearing caches on
master/main? It seems that you're using a custom cache fingerprint, which may result in re-using of an older cache entry (if any) withoutchmod +xinstruction.
- The checkbox is "Clean all repository caches", not "branch caches".
- From the issue description: https://cirrus-ci.com/build/5438662258196480
It's in
mainbranch, as you can see. Successful after cleaning. And failing again.
I don't think this is related, but I saw that Cirrus CI is moving from Intel to M1 instances, and Codecov (the problematic executable) doesn't support it yet: https://github.com/codecov/uploader/issues/523#issuecomment-1318842102
So, theoretically this issue will be non-relevant sometimes.