GeezerVisonThe World Wide Web, restored to 800 pixels of glory. | ||||||||||||||||||||||||||
| Home|About|Gaming cabinet|Archives|How it works|Starter sites | ||||||||||||||||||||||||||
GeezerVison is showing github.com — fix: Stop add_cpu_torch_hashes failing on a universal torch split by haoxu0 · Pull Request #6959 · feast-dev/feast Conversation
Collaborator
What is broken
Because the target begins with Why
For the second pin of each pair that asks for Why the tests did not catch it
The changeThe Returning it, rather than normalising the lookup key to A genuine version mismatch still raises, which the existing third test covers unchanged. VerificationTwo tests added, for a single marker split and for the torch + torchvision pair the lock actually contains, both asserting idempotency. Checked against real data —
I found this trying to satisfy a review on #6958, which asks for regenerated locks and cannot be done until this is fixed.
Sorry, something went wrong. Uh oh!
There was an error while loading. Please reload this page. All reactions`make lock-python-dependencies-all` aborts before it writes a single
requirements file:
ValueError: Missing CPU hashes for torch==2.14.1+cpu
make: *** [lock-python-dependencies-all] Error 1
`uv pip compile --universal --torch-backend cpu` splits torch by marker,
so the lock it produces holds two pins per package:
torch==2.14.1 ; sys_platform == 'darwin'
torch==2.14.1+cpu ; sys_platform != 'darwin'
`add_hashes` looked each entry up by appending `+cpu` to its version. For
the second pin that asks for `2.14.1+cpu+cpu`, which cannot exist, so the
lookup missed and the script raised.
The `+cpu` pin is already the CPU wheel and so needs nothing added, and it
is now returned untouched. Returning it rather than normalising the lookup
key keeps its hash set exactly as the resolver wrote it, so this cannot
alter any artifact a lock already accepts.
The existing tests passed because their input carries only a bare
`torch==2.13.0`, never the split a real `--universal` resolve emits. Two
tests are added for that shape, including the torch and torchvision pair
the lock actually contains, and both assert idempotency. Checked against
all three committed `py3.*-ci-requirements.txt`: each now runs clean and is
idempotent, where each raised before.
The genuine mismatch case still raises, which the untouched third test
covers.
Signed-off-by: hao-xu5 <[email protected]>
|
There was an error while loading. Please reload this page.
|
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@ ## master #6959 +/- ## ========================================== - Coverage 49.32% 49.32% -0.01% ========================================== Files 443 443 Lines 55094 55094 Branches 8017 8017 ========================================== - Hits 27176 27175 -1 Misses 26035 26035 - Partials 1883 1884 +1
Continue to review full report in Codecov by Harness.
🚀 New features to boost your workflow:
|
Sorry, something went wrong.
There was an error while loading. Please reload this page.
|
Superseded: #6906 merged the same fix (identical approach -- The regression tests from here are still missing on master, so I have reopened just that part as #6980. Closing this to avoid proposing a change that is already in. |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was an error while loading. Please reload this page.
Successfully merging this pull request may close these issues.
There was an error while loading. Please reload this page.