How to deal with inconsistent cache issue on CI machine?
In order to speed up the pipelines execution time, we cache mint packages on CI machine. The location of cached packages:
/usr/local/lib/mint/packages
Recently, when we added a new package to Mintfile and called bootstrap command, we faced the error:
$ mint bootstrap -m /Project/Mintfile
🌱 Finding latest version of metrics
🌱 Inconsistent cache, clear it up.
Error: Inconsistent metadata: git repository not found for package at path '/usr/local/lib/mint/packages/github.com_realm_SwiftLint'
The 'mint' command exited with error code 1
SwiftLint package has been pulled from cache successfully before calling the command.
We couldn't find any recommendations how to deal with such scenario in the documentation.
💡 Ideas
- Could
mintcould prune outdated cache transparently to a user? - Could
mintprovide acleancommand to clean outdated cache?
I'd be happy to help with the implementation 🙋♂️
Experiencing the same issue - also happy to contribute
Is it perhaps a case insensitivity issue? Is the CI machine Linux?
Is it perhaps a case insensitivity issue? Is the CI machine Linux?
My issue was on a mac machine, but I cleared it up by cleaning my cache and then re-linking after downloading from the cache.