move-language / move

Apache License 2.0
2.25k stars 684 forks source link

[move-package] Support overlapping resolution graphs #929

Closed awelc closed 1 year ago

awelc commented 1 year ago

Motivation

In the current implementation of external package resolution, the dependency graphs produced by each resolver invocation (each external resolver, and the internal resolver) must be pairwise disjoint.

This restriction needs to be loosened to allow overlap between the outputs of resolution invocations when the overlap is consistent to avoid problems in case the same important package (e.g., framework package) is a dependency of both a package provided by third-party resolver and a dependency explicitly specified by the programmer

Have you read the Contributing Guidelines on pull requests?

Yes

Test Plan

Tests added and modified accordingly

awelc commented 1 year ago

I think the approach you're taking here almost works, but

Yeah, I kind of realized this once I prototyped it and only then started thinking about cycles...

let me know what you think:

Sounds simple once the spark materializes so I am glad it happened :-) - trying it now. For better or worse I like working this way - prototype something and see if it works and use it to come up with something better if need be.