Do you want to request a feature or report a bug?
feature
What is the current behavior?
We sometimes introduce changes to cache logic which make cache from previous version incompatible with the next one.
What is the expected behavior?
Yarn should ignore caches generated by another version.
This has been the solution for most issues posted. yarn cache clean.
Perhaps we should version the cache, and clear it if the version doesn't match (similar to how lockfiles are versioned). So, the current cache would have a version of 1, then we'd bump it to 2 if any breaking changes are made.
It would require some discipline but I agree with you, @Daniel15
Bootcamped the issue
Done!
Most helpful comment
Perhaps we should version the cache, and clear it if the version doesn't match (similar to how lockfiles are versioned). So, the current cache would have a version of
1, then we'd bump it to2if any breaking changes are made.