-
-
Notifications
You must be signed in to change notification settings - Fork 229
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
v1.30.0 dependency resolution regression with subpackages in dependency #2587
Comments
readding toHash does not seem to fix this in current stable branch |
when readding toHash in the git history, 4e86806 seems to be the introducing commit |
possible factor: toHash + opEquals used to only check on the version range, ignoring path and repo based values - this might be altering the internal AA state Additional weirdness: packages in dub.d getPackageRaw (name, dep) don't match: old working calls:
new broken calls:
although there is also weirdness in both versions, that a would search inside the b folder, now it looks like b and b:sub also search both in the b and the c folder |
A major issue when dealing with the 'Dependency' type is that it evolved from a simple type, which stored a version range and perhaps one or two boolean, to one that stores 4 kinds of dependencies: version range (including exact version), branches, repository + hash, and path. Instead of using a discrete type (e.g. a tagged union), the type is a mix of style, and repository and branch are piggybacking on the field used for the version range. Switching to std.sumtype makes interaction between fields more obvious. Most importantly, it forces the programmer to answer the hard questions, such as how do we compare completely different dependency (version vs repository). Hopefully this will make the code easier to understand, and in the future, make it easier to add a new kind of dependency.
Reproduction:
In b the subpackage can be embedded in the recipe or standalone, it doesn't matter for the upgrade bug.
Trying to run
dub upgrade
ina
causesWorked with 1.29.2 and before.
The text was updated successfully, but these errors were encountered: