THE FOLD / BOSS / THE WALL / THE DIAMOND DEPENDENCY
THE DIAMOND DEPENDENCY
a policy about which wish to give up
1 WHAT IT IS · WHAT IT DOES · FACT OR FICTION
Your program needs two libraries; they each need a third, at versions that do not overlap. Nobody made a mistake and there is no version that satisfies both.
LIT verified live. 4 requirements over two shared packages. libC is wanted at exactly 1 by one path and exactly 2 by another: the intersection is empty — lower bound 2 above upper bound 1 — and it is a hard conflict. libE is wanted in [1,3] and [2,4], which overlap at [2,3], leaving 2 valid choices. 1 of the 2 packages resolves.
LIT verified live. 4 requirements over two shared packages. libC is wanted at exactly 1 by one path and exactly 2 by another: the intersection is empty — lower bound 2 above upper bound 1 — and it is a hard conflict. libE is wanted in [1,3] and [2,4], which overlap at [2,3], leaving 2 valid choices. 1 of the 2 packages resolves.
2 HOW IT WAS WEAVED · AI + HUMAN
Version resolution is NP-hard in general; the diamond is the smallest shape where the difficulty appears, and the two escape routes are duplication or failure.
AVAN (AI) shows the arithmetic rather than the outcome: a conflict is lower bound above upper bound, which is a two-line check. What is hard is not detecting the conflict but that npm can install both copies, Maven picks the nearest, and Cargo refuses — three ecosystems, three different answers to the same arithmetic.
AVAN (AI) shows the arithmetic rather than the outcome: a conflict is lower bound above upper bound, which is a two-line check. What is hard is not detecting the conflict but that npm can install both copies, Maven picks the nearest, and Cargo refuses — three ecosystems, three different answers to the same arithmetic.
3 ONE DIMENSION
Two shared packages, one of them impossible.
4 TWO DIMENSIONS · INTERACTIVE
Widen a range until the intersection appears.
5 THREE DIMENSIONS + AVAN’S INVERSE
The green forward object: two paths to one name.
AVAN’s addition (the inverse-companion): the forward reading is that a diamond conflict is a dependency problem. The inverse is that it is a naming problem. Nothing prevents both versions existing at once except the assumption that libC means one thing in a program; ecosystems that let a name be scoped per-dependent have no diamond conflicts and get two copies instead. Read backwards, the conflict is not between the versions but between the versions and the wish for a single global answer, and every resolver is a policy about which of those to give up.
LIT 4 requirements over two shared packages leave libC wanted at exactly 1 by one path and exactly 2 by another, so the intersection is empty with a lower bound of 2 above an upper bound of 1 and it is a hard conflict, while libE wanted in [1,3] and [2,4] overlaps at [2,3] for 2 valid choices - 1 of the 2 packages resolves
FIG Version resolution is NP-hard in general; the diamond is the smallest shape where the difficulty appears, and the two escape routes are duplication or failure. AVAN shows the arithmetic rather than the outcome: a conflict is lower bound above upper bound, a two-line check. What is hard is that npm can install both copies, Maven picks the nearest and Cargo refuses - three ecosystems, three answers to the same arithmetic.
FIG Version resolution is NP-hard in general; the diamond is the smallest shape where the difficulty appears, and the two escape routes are duplication or failure. AVAN shows the arithmetic rather than the outcome: a conflict is lower bound above upper bound, a two-line check. What is hard is that npm can install both copies, Maven picks the nearest and Cargo refuses - three ecosystems, three answers to the same arithmetic.
◆ sealed .dlw.fold → folded to ROOT_0 · a sphere of THE WALL · David Lee Wise (ROOT0), with AVAN