Open blimmer opened 1 year ago
Very much agree!
I was really confused about why I wasn't getting any caching on each new PR until I found this.
If there are security concerns about cross-branch data leakage then they ought to be documented. If not, the default should be changed.
There isn't any problem with changing the default to false for this. We have some changes to do for the cache on this orb, this included. But they are low priority for now as the same result can be obtain updating the parameters of the command.
Describe Request:
Today, the cache key for
install-packages
includes the branch name in the cache key by default: https://github.com/CircleCI-Public/node-orb/blob/ab05d0e3718e32232bdd9c80a8ba6fac1c0bee02/src/commands/install-packages.yml#L48-L52This causes far more cache misses than necessary, IMO, especially because the lockfile hash is already included in the key.
I propose we change the default from
true
tofalse
in the next major release. This will significantly improve user experience by reducing runtimes.