Repository navigation
Inkling 2 tests: utf-8 source reads, and pin the shared compile-disable helper - #19133
Merged
Merged
Conversation
…le helper test_source_read_encoding is red on main in the rest-2 shard: #19016 added a read of the checked-in unsloth/save.py without an encoding, which breaks on Windows once that file gains a non-ASCII byte. Pass utf-8 there and on the loader source read in the same file. test_fastmodel_keeps_inkling2_eager_unless_told_otherwise still pinned the inline UNSLOTH_COMPILE_DISABLE assignment that #19073 replaced with _set_partial_compile_disable(), so it fails wherever the file runs (transformers >= 5.24). Pin the helper call in the Inkling 2 branch and the helper's behaviour instead: partial by default, a full disable kept.
Member
Author
|
@codex review |
Codex Review Summary: ✅ CompletedThis 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. |
|
Codex Review: Didn't find any major issues. You're on a roll. 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". |
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.
Problem
Two tests are broken on
main.tests/test_source_read_encoding.py::test_checked_in_file_reads_name_an_encodingis red inRepo tests (CPU, rest-2)for every PR based onmain, for example Studio: keep different GGUF quants of the same repo alongside (#19072) #19122:Inkling 2: merged 16-bit save and GGUF export #19016 added
(_ROOT / "unsloth" / "save.py").read_text(). It reads a checked-in file with the platform default encoding, which breaks on Windows as soon assave.pygains a non-ASCII byte. The guard is right and the new line is wrong.tests/test_inkling2_support.py::test_fastmodel_keeps_inkling2_eager_unless_told_otherwisefails wherever the file runs:It still pins the inline assignment that Inkling 2: partly disable compile through the shared helper #19073 replaced with the shared
_set_partial_compile_disable()helper. CI does not show it yet: the file skips below transformers 5.24, and the HF=latest legs are held below 5.24. It fails locally on 5.24.0, so it would turn red as soon as that cap lifts.Fix
Tests only, in
tests/test_inkling2_support.py:encoding = "utf-8":save.pyread the guard flags;__file__, which the guard does not see._set_partial_compile_disable();partialfrom unset,0orpartial;1,true) as1, so an explicit user choice is still left alone.Verification
test_source_read_encoding.py,maintest_source_read_encoding.py, this branchtest_inkling2_support.py, transformers 5.24.0,maintest_inkling2_support.py, transformers 5.24.0, this branchtest_inkling2_support.py, transformers 5.17Sabotage, each with only the product line changed:
loader.py: the test fails on the call check.partial: the test fails withassert 'partial' == '1'for a full disable.