Repository navigation
CLI: pass --hf-token to the export checkpoint load - #10218
Conversation
a8dfb98 to
de378e8
Compare
07c5368 to
e03da59
Compare
Review + GitHub Actions reproductionPinned head Review — no P1. Two items found and pushed:
The formatting-only hunk in A/B on Actions. Two disposable fork branches, same harness, same runner (
The second leg runs the real command — Negative transcript — every request anonymous, so every one 401s: PR head — the repo reads authenticate, and the four Both legs then stop at No UI surface: the change is confined to Upstream checks: 43 pass, 4 skip. The two reds — |
|
Codex Review: Didn't find any major issues. Delightful! 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". |
|
Codex Review: Didn't find any major issues. 🎉 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". |
|
Confirmed the load call in unsloth_cli/commands/export.py drops the token even though ExportBackend.load_checkpoint accepts it, so a gated checkpoint 401s despite --hf-token being passed. Will get this reviewed. |
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. |
|
I reproduced the 401 against a real gated repo with One consequence worth recording here: now that the token reaches transformers tier resolution, a gated model whose config asks for a specific version can provision a sidecar venv during a CLI export, which is what the Studio export route has always done for the same model, and the pre-existing case where that install cannot be fetched is a separate issue from this fix. I also confirmed that |
unsloth export sends the token to the Hub push but not to the checkpoint load, so a gated model fails at the load with a 401 even though the token was given. The Studio export page works with the same token, and both the Studio route and the export worker already pass it.
Tested with every Hub request logged: before, 71 requests went out and none carried the token, after, 34 did, including the security check and the weight download.
The test file also needed a small harness fix to carry the new case: it stubs
studio.backendinsys.modules, whichunsloth_cli/__init__.pyneeds throughcommands/start.py, so whichever test ran first errored in setup (6 passed, 2 errorson main for the file on its own). Loading the real CLI before the stubs go in makes the file9 passedand the new test runnable on its own, which matters because the suite runs sharded.