Skip to content

Scan baseline: re-review the twelve unsloth-zoo sites 2026.10.11 moved - #16264

Merged
danielhanchen merged 1 commit into
mainfrom
dh/scan-baseline-unsloth-zoo-2026-10-11
Oct 31, 2026
Merged

danielhanchen merged 1 commit into
mainfrom
dh/scan-baseline-unsloth-zoo-2026-10-11

Conversation

@danielhanchen

Copy link
Copy Markdown
Member

pip scan-packages :: hf-stack now fails on PRs whose closure resolves unsloth-zoo 2026.10.11, for example #16258:

Summary: 5 CRITICAL, 7 HIGH, 172 MEDIUM
  12 of the 184 finding(s) above are at a site already reviewed in scripts/scan_packages_baseline.json. What differs from the reviewed entry:
    HIGH      unsloth-zoo  unsloth_zoo/compiler.py              same matched code, file digest outside the pin
    CRITICAL  unsloth-zoo  unsloth_zoo/device_type.py           same matched code, file digest outside the pin
    ...

All twelve are the same kind: the scanner's matched code is byte-identical to a reviewed entry (the same evidence_hash), and only the pinned file_sha256 moved because other lines in the file changed in the release.

File Check Reviewed evidence_hash matches
unsloth_zoo/device_type.py env + network yes
unsloth_zoo/llama_cpp.py env + network yes
unsloth_zoo/triton_kernels_compat.py downloads and executes remote code yes
unsloth_zoo/vision_utils.py env + network yes
unsloth_zoo/vision_utils.py cloud metadata + network yes
unsloth_zoo/compiler.py obfuscation + exec/eval yes
unsloth_zoo/vllm_gdn_replayssm.py obfuscation + exec/eval yes
unsloth_zoo/vllm_utils.py obfuscation + exec/eval yes
unsloth_zoo/mlx/decision.py obfuscation + exec/eval yes
unsloth_zoo/mlx/loader.py obfuscation + exec/eval yes
unsloth_zoo/mlx/speculative.py obfuscation + exec/eval yes
unsloth_zoo/temporary_patches/moe_utils.py obfuscation + exec/eval yes

Change

As in #16114, each new entry sits next to the reviewed one it matches, pinned at the 2026.10.11 file digest. Nothing is removed, so shards that still resolve older zoo releases are unaffected. I did not regenerate the whole file with --write-baseline, since a single-package scan would drop every other package's entries. The diff is 108 added lines and no removed ones.

Verification

  • scripts/scan_packages.py unsloth-zoo==2026.10.11 on main gives 5 CRITICAL, 7 HIGH with exit 1, matching the CI hf-stack run. On this branch it exits 0 (24 finding(s) suppressed by baseline, 13 MEDIUM left).
  • The tests that read the scanner or its baseline, under tests/security and the others that import it: 638 passed.

pip scan-packages :: hf-stack fails on PRs that resolve unsloth-zoo 2026.10.11: twelve CRITICAL/HIGH
findings whose matched code is byte-identical to a reviewed entry (same evidence_hash), with only the
pinned file digest moved. Add an entry at the new digest next to each reviewed one; nothing is removed.
@danielhanchen

Copy link
Copy Markdown
Member Author

@codex review

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 31, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-10-31T08:30:45.395029Z c1daabe Manual request
ℹ️ 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" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. More of your lovely PRs please.

Reviewed commit: c1daabe786

ℹ️ 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".

@danielhanchen
danielhanchen merged commit 1341718 into main Oct 31, 2026
@danielhanchen
danielhanchen deleted the dh/scan-baseline-unsloth-zoo-2026-10-11 branch October 31, 2026 09:45
danielhanchen added a commit that referenced this pull request Nov 4, 2026
…16624)

`pip scan-packages :: hf-stack` fails on main (run 41772420551) and on
every PR whose closure resolves unsloth-zoo 2026.11.1, which #16554 made
the installer floor:

```
Summary: 5 HIGH, 13 MEDIUM
  5 of the 18 finding(s) above are at a site already reviewed in scripts/scan_packages_baseline.json. What differs from the reviewed entry:
    HIGH  unsloth-zoo  unsloth_zoo/compiler.py                            same matched code, file digest outside the pin
    HIGH  unsloth-zoo  unsloth_zoo/mlx/loader.py                          same matched code, file digest outside the pin
    HIGH  unsloth-zoo  unsloth_zoo/mlx/speculative.py                     9 matched line(s) added and 2 gone
    HIGH  unsloth-zoo  unsloth_zoo/temporary_patches/granitemoehybrid.py  2 matched line(s) appended to a reviewed file, none gone
    HIGH  unsloth-zoo  unsloth_zoo/temporary_patches/moe_utils.py         same matched code, file digest outside the pin
```

## Review

| File | What changed in 2026.11.1 | Verdict |
|---|---|---|
| `unsloth_zoo/compiler.py` | Matched code identical to the reviewed
entry; other lines in the file moved the pin | Same as reviewed |
| `unsloth_zoo/mlx/loader.py` | Same | Same as reviewed |
| `unsloth_zoo/temporary_patches/moe_utils.py` | Same | Same as reviewed
|
| `unsloth_zoo/mlx/speculative.py` | Every new match is `mx.eval(...)`
(MLX array materialisation) or `model.eval()`, not Python `eval` |
Benign |
| `unsloth_zoo/temporary_patches/granitemoehybrid.py` | New
`_build_norm_forward`: takes `inspect.getsource` of the installed
transformers `GraniteMoeHybridRMSNorm.forward`, replaces the single
`return self.weight * hidden_states.to(input_dtype)` line with a fixed
dtype-cast template, and `exec(compile(...))`s it into the transformers
module namespace | Benign: the same source-patching pattern as the
reviewed `compiler.py` sites; nothing is decoded, fetched or read from
the environment |

I read both files in the 2026.10.11 and 2026.11.1 wheels downloaded from
PyPI.

## Change

As in #16264, each new entry sits next to the reviewed entries for its
file, pinned at the 2026.11.1 file digest. The entries were produced by
`scripts/scan_packages.py unsloth-zoo==2026.11.1 --write-baseline` and
copied in; the baseline was not regenerated, so every other package's
entries are untouched. Nothing is removed, so shards that still resolve
older zoo releases are unaffected. 45 added lines, one file.

## Testing

- `scripts/scan_packages.py unsloth-zoo==2026.11.1`: exit 1 on main (5
HIGH), exit 0 with this change (13 MEDIUM, unchanged).
- `scripts/scan_packages.py unsloth-zoo==2026.10.11`: exit 0 before and
after.
- `tests/security/test_scan_packages.py`,
`tests/security/test_lint_av_shapes.py`,
`tests/test_scripts_write_lf.py`: 181 passed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant