Repository navigation
Compare a full pass to a skipping one without the click both record as unmet - #11578
Conversation
…s unmet Unsloth Update CI has failed on Linux and macOS since #11405 (last success 12:04Z): test_full_deps_forces_every_step_and_still_changes_nothing and test_the_install_is_left_working see click 8.5.0 against 8.3.0 and nothing else. sqlfluff<4 caps click at 8.3.0 and huggingface-hub 1.23+ needs 8.4.2, so click lands wherever the last step that resolved it put it. #11405 added Diffusers main as a direct reference after the data-designer deps; installing it re-resolves hub's closure. install.sh and a full-deps pass run it (8.5.0); the settle run re-ran data-designer deps and skipped it (8.3.0). The update logs in the run's studio-update-log artifact show exactly that. A distribution both manifests record as known_unmet is now set aside. It must still be installed on both sides, and every other name and version must match.
|
@codex review |
|
You have reached your Codex usage limits for security reviews. Please try again later. |
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 1bd6a91756
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| main from a direct reference after the data-designer deps, re-resolving hub's closure, and a | ||
| pass that skips that step leaves the data-designer answer. Nothing else is set aside. | ||
| """ | ||
| torn = _known_unmet_names(before) & _known_unmet_names(after) |
There was a problem hiding this comment.
Validate known-unmet evidence against its installed-set digest
When a dependency changes after its manifest was written—for example, because a late resolver step introduces the ordering regression this test is intended to detect—the stale manifest can still name that dependency in known_unmet; intersecting names here then filters out its changed version and lets both assertions pass. Production deliberately trusts this field only when known_unmet_index matches the current installed-set digest, so this helper should apply the same freshness check, or derive the exception from a current audit, before ignoring a distribution.
Useful? React with 👍 / 👎.
There was a problem hiding this comment.
Agreed. snapshot() now computes the installed-set digest in the venv with the installer's own installed_dependency_index, hashed as _installed_index_digest does (checked equal to _installed_index_digest on a real venv), and a record whose known_unmet_index does not match it names nothing. A stale record on either side now fails the comparison. Fixed in ca95428.
The installer reads the record only when known_unmet_index matches the current installed-set digest, and so should the test: a stale record could otherwise set aside a distribution a later step moved. snapshot() now computes that digest in the venv with the installer's own installed_dependency_index, hashed as _installed_index_digest hashes it; a record whose index does not match names nothing.
|
@codex review |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: ca95428f23
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| assert {_dist_name(n) for n, _ in before["distributions"]} == { | ||
| _dist_name(n) for n, _ in after["distributions"] | ||
| }, f"{message}: a distribution was installed or removed" | ||
| assert [d for d in after["distributions"] if _dist_name(d[0]) not in torn] == [ | ||
| d for d in before["distributions"] if _dist_name(d[0]) not in torn |
There was a problem hiding this comment.
Preserve multiplicity for exempted distributions
When a full pass introduces an extra metadata record for a known-unmet package, this comparison still passes: the set comparison collapses both records to one normalized name, and the next comparison filters every row with that name. This is reachable with pip backup/duplicate metadata—installed_dependency_index() intentionally ignores ~...dist-info backups, so the manifest digest can remain fresh while DIST_LIST contains the extra record—and verify-install does not generally reject duplicates for non-core packages such as click. Compare the per-name record counts/identities before exempting only the version difference, otherwise the end-to-end test no longer detects this install corruption.
Useful? React with 👍 / 👎.
There was a problem hiding this comment.
Agreed. The names are now compared as per-name counts, so a second click record fails before any version is set aside. Fixed in 9faa90c.
A set of names collapses a second metadata record for an exempted distribution (a pip backup the installer's index skips, a duplicate dist-info), and the version filter then hides it. Compare per-name counts instead, so an extra or missing record fails even for a known_unmet name.
|
@codex review |
|
Codex Review: Didn't find any major issues. Another round soon, please! Reviewed commit: ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. Codex can also answer questions or update the PR. Try commenting "@codex address that feedback". |
…s unmet (unslothai#11578) * Compare a full pass to a skipping one without the click both record as unmet Unsloth Update CI has failed on Linux and macOS since unslothai#11405 (last success 12:04Z): test_full_deps_forces_every_step_and_still_changes_nothing and test_the_install_is_left_working see click 8.5.0 against 8.3.0 and nothing else. sqlfluff<4 caps click at 8.3.0 and huggingface-hub 1.23+ needs 8.4.2, so click lands wherever the last step that resolved it put it. unslothai#11405 added Diffusers main as a direct reference after the data-designer deps; installing it re-resolves hub's closure. install.sh and a full-deps pass run it (8.5.0); the settle run re-ran data-designer deps and skipped it (8.3.0). The update logs in the run's studio-update-log artifact show exactly that. A distribution both manifests record as known_unmet is now set aside. It must still be installed on both sides, and every other name and version must match. * Trust known_unmet only against the installed set it was written for The installer reads the record only when known_unmet_index matches the current installed-set digest, and so should the test: a stale record could otherwise set aside a distribution a later step moved. snapshot() now computes that digest in the venv with the installer's own installed_dependency_index, hashed as _installed_index_digest hashes it; a record whose index does not match names nothing. * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * Count records per name before setting a known_unmet version aside A set of names collapses a second metadata record for an exempted distribution (a pip backup the installer's index skips, a duplicate dist-info), and the version filter then hides it. Compare per-name counts instead, so an extra or missing record fails even for a known_unmet name. --------- Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Summary
Unsloth Update CI(Unsloth Updating Testson Linux and macOS) has failed on every run that finished since #11405. The last success was at 12:04Z today. Two tests fail on one difference:The per-run update logs in the failing run's
studio-update-logartifact (run 35761917436) show why:install.shstudio update)UNSLOTH_STUDIO_FULL_DEPS=1)No click satisfies both requirements. Every sqlfluff 3.x caps
click<=8.3.0, anddata-designer-deps.txtrequiressqlfluff<4. huggingface-hub 1.32 needsclick>=8.4.2. The installer already records this asknown_unmet. Before #11405 the only diffusers step after data designer was the release pin, and reinstalling an already-satisfied version pin re-resolves nothing, so every pass ended on the data-designer answer. #11405 added Diffusers main as a direct reference, which does get resolved, and that resolve pulls hub's closure and moves click. Which way click lands now depends on whether that step ran. It is not a skip that failed to do its work.Change
_assert_same_distributionsreplaces the two exact list comparisons:known_unmet, and only if each record is fresh. As in the installer, a record counts only when itsknown_unmet_indexmatches the digest of the installed set it is read against.snapshot()computes that digest in the venv with the installer's owninstalled_dependency_index; it matches_installed_index_digest()on a real venv.<...>entries (an audit that could not run) name nothing, so they exempt nothing.Checked against synthetic snapshots:
known_unmet_indexis stale<...>entriesNot changed, and worth deciding
The installer itself is untouched. The step order is deliberate: the diffusers steps "must run after every other requirements file so nothing re-resolves Diffusers back to a release". The effect for users is that a
--localupdate or full pass leaves click on either side of the conflict, depending on which steps ran. Neither side meets both requirements; ending on one fixed side would need a constraint on one of the steps.Verification
This test only runs against a real install (
UNSLOTH_IDEMPOTENCY_E2E=1), so the end-to-end check is this PR's ownUnsloth Update CIrun, which triggers on this file.