Hi team, I'd would like to report an issue when we...
# general
Hi team, I'd would like to report an issue when we migrate to pants 2.15 from 2.14. We use Pants in our Jenkins CI/CD pipeline. In our setup, Jenkins will work on each pipeline in different folders. For example, a branch name AB would be under
, and branch name CD would be under
. We notice that Pants will not be able to share mypy cache across branch after 2.15. I believe the issue comes from this pull request https://github.com/pantsbuild/pants/pull/18061. It seems that Pants now replies on buildroot (e.g. a path) to differentiate repos. This wont work in the setup I mentioned. I am wondering if there is a better way to implement it. or is there any workaround? Thanks!
Some additional information: we already use different named_caches dir for different projects. I am not sure the current implementation is better than asking users to config different named_caches dirs for different repo, or is there any better alternative?
No, one of the cornerstones (there are many) is that users should be able to run pants with minimal configuration, so asking them to specify multiple named caches wouldn't fly. It also means worse performance for many other tools relying on the named caches, and additional space overhead.
FWIW it was always a bug that we didn't separate the mypy caches per repo, we just fixed it and backported it.
All that said, it's possible there's a way we can control this with an option, but I don't think we'd be able to cherry pick it, so it'd be in Pants 2.17. Feel free to file an issue
hi @bitter-ability-32190, fyi, I filled an issue here.