feat(pkg): constrain package versions across platforms - #15983
Closed
Alizter wants to merge 3 commits into
Closed
Conversation
Solve every requested platform before writing a portable lock directory. If any platform fails, report the failures together and leave no partial lock directory behind; otherwise merge the platform-specific package data into conditional lock-file entries. This replaces the previous partial-success behavior and keeps the watch-server regression test tolerant of the additional solve work. Signed-off-by: Ali Caglayan <alizter@gmail.com>
Build one solver universe containing every requested platform and invoke SAT once instead of solving each platform independently. Platform-aware roles, availability checks, conflict classes, and result extraction preserve which platforms selected each package while diagnostics are deduplicated by package. Generate conditional lock-file data directly from the joint result and remove the per-platform result-merging APIs. A post-solve invariant still rejects different versions of the same package; the next commit moves that restriction into SAT. Signed-off-by: Ali Caglayan <alizter@gmail.com>
A joint solve could select different versions of one package on different platforms and only reject the result after SAT completed. Add equality constraints between the per-platform roles so SAT must choose one version that works everywhere. This lets SAT fall back to an older common version when one exists and report an unsatisfiable platform set when no common version exists. Signed-off-by: Ali Caglayan <alizter@gmail.com>
Alizter
force-pushed
the
push-stpxklwkyzmr
branch
from
August 17, 2026 10:48
d94fc9e to
512a19b
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Stacked on #15982. Only the final commit is new in this draft.
Summary
Tests
dune runtest test/blackbox-tests/test-cases/pkg/portable-lockdirs/portable-lockdirs-older-common-version.t test/blackbox-tests/test-cases/pkg/portable-lockdirs/portable-lockdirs-platform-dependant-version.t test/blackbox-tests/test-cases/pkg/portable-lockdirs/portable-lockdirs-platform-dependant-version-extra-files.tdune build @fmt @check