This is probably easy enough to test out, but maybe someone already has a quick answer. Let's say in one repo I want to make a distribution (D1) that includes modules A and B and another distribution (D2) that includes modules B and C. Now, in another repo, I want to depend on both D1 and D2. Does that cause problems given the mutual definition of B or are they isolated in some way?
Yeah, I would be. I'm more curious what happens on the repo that's using D1 and D2.
e
enough-analyst-54434
04/12/2022, 5:28 PM
Pants refuses to multiple package B. It will error if its amiguous whether D1 owns B or D2 owns it. If that happens, you'll pretty much be forced to define a
python_distributuon
to own B. so you'll get D1->D3 and D2->D3.
👍 1
Those docs say all that of course.
This was a lesson learned and a hard opinion gained after dealing with the JVM jar ecosystem in the early days of Pants. In that ecosystem, re-packaging things you don't own is commonplace and leads to super-mysterious errors at runtime.