Repository navigation
fix(engine): raise WeightLoadError when the checkpoint cannot be read - #518
Merged
Merged
Conversation
JUNQINGV587
added a commit
to JUNQINGV587/FreeToken
that referenced
this pull request
Sep 19, 2026
- FlashML-org#521 fix(kernel): pin tvm-ffi jit arch to the bound gpu (kernel/utils.py) - FlashML-org#518 fix(engine): raise WeightLoadError when the checkpoint cannot be read (engine.py) -- this PR is the upstream squash of our own 73f8661 + e912542, and it supersedes them (same intent plus the load_expert_banks wrap). Resolution: take the upstream side for the conflicting hunks. - FlashML-org#524 fix(install): resolve sglang-kernel from PyPI, not the sglang index (install.sh, pyproject.toml) Our delta in these four files before the merge was exactly 'lacking these three upstream commits', so no fork-specific change is dropped.
This was referenced Sep 19, 2026
Open
trcwebdesign
pushed a commit
to trcwebdesign/FreeToken
that referenced
this pull request
Sep 21, 2026
…FlashML-org#518) * fix(engine): raise WeightLoadError when the checkpoint cannot be read * fix(engine): wrap the FTW index read and pass host allocation failures through
danielamadori
pushed a commit
to danielamadori/DFlash-FreeToken
that referenced
this pull request
Sep 22, 2026
…FlashML-org#518) * fix(engine): raise WeightLoadError when the checkpoint cannot be read * fix(engine): wrap the FTW index read and pass host allocation failures through (cherry picked from commit 6410c97)
CraigStone-Dev
pushed a commit
to CraigStone-Dev/FreeToken
that referenced
this pull request
Sep 24, 2026
…b1f0) Reapply of the PR FlashML-org#337 net diff (fb7f732..badf5f4) onto current upstream main (v0.1.3 + 4). Upstream moved 16 commits past the old merge base; conflicts were limited to: - engine/engine.py: the new _weight_load_context() wrapper (WeightLoadError, FlashML-org#518) now wraps load_expert_banks; the disk_tier= argument is passed inside it. The v0 precondition ValueError and the no-disk-index NotImplementedError stay outside the wrapper, so their error types/messages are unchanged. - models/nvfp4_banks.py: upstream dropped the direct index-json read in favour of loader.safetensors_weight_map (index json, or shard headers when the checkpoint ships none); the json import is gone, itertools stays (used by the disk-skip pieces). - moe/disk_tier.py: Nvfp4DiskIndex now resolves its weight map through the same loader.safetensors_weight_map helper as the NVFP4 reader, keeping the index-reads-the-same-rows-invariant the previous rebase established. Everything else (O_DIRECT fetch workers, MAP_PRIVATE banks, pin_prefix/release, mincore tail check, FT_DISK_TIER_VERIFY probes, CLI, tests) applied clean.
lucaspirola
pushed a commit
to lucaspirola/FreeToken
that referenced
this pull request
Sep 28, 2026
…FlashML-org#518) * fix(engine): raise WeightLoadError when the checkpoint cannot be read * fix(engine): wrap the FTW index read and pass host allocation failures through
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.
Wrap the checkpoint reads (dense weights, expert banks, PLE table) so a broken or mismatched FTW fails as
WeightLoadError: <cause>on/healthand in the log, telling the user the weights could not be loaded rather than leaving a bareKeyError; OOM, MemoryError and PinFailed pass through unchanged.