I've been playing a bit more with visibility rules...
# general
c
I've been playing a bit more with visibility rules, trying to make the most out of them to keep our monorepo well segmented. Anyone had great success with them? I'm experimenting with using tags to control who can depend on who (core project with no 3rd party dependency can depends on other core project, project with sql can import either
core
or
sql
utilities , etc.) and have some kind of "sub-project" dependencies (I can depend on Project X models, but not Project X web API services code). Mix that with macro to define "projects" and generate their dependency rules based on the kind of project, I think it should end up with something somewhat manageable. I also did hit a few small limitation (https://github.com/pantsbuild/pants/issues/20732, https://github.com/pantsbuild/pants/issues/20733) . Curious to hear about other people experience.
šŸ‘€ 2
c
Hi šŸ‘‹ Happy to see some feedback on the visibility feature. Been ooo but will take a look on those tickets in the coming days, now that I’m back.
c
thanks! it seems I can probably contribute quick PR to fix these limitation. I will look at this in the coming week
c
Awesome! although I may have beaten you to the easy one: https://github.com/pantsbuild/pants/pull/20769
c
haha great!