Skip to content

Tests: excuse the uv copy in the CUDA runtime wheel test from the AV009 lint - #17748

Merged
danielhanchen merged 1 commit into
mainfrom
av009-uv-copy-allow
Nov 14, 2026
Merged

danielhanchen merged 1 commit into
mainfrom
av009-uv-copy-allow

Conversation

@danielhanchen

Copy link
Copy Markdown
Member

Summary

Source lint, workflow-trigger lint and Repo tests (CPU, rest-2) fail on main and every PR based on it since #17675, in tests/security/test_lint_av_shapes.py::test_the_repository_is_clean_against_its_baseline:

tests/studio/install/test_no_torch_cuda_runtime_wheels.py:308: [AV009] error: copies a Windows system binary
1 new error(s).

The test #17675 added copies the uv executable found on PATH into a fake home (shutil.copy2(uv, home / ".local" / "bin" / ...)), then builds the child's PATH from the venv plus %SystemRoot% and System32. AV009 fires on any file copy within a few lines of a System32 path, which is the shape of renaming a Microsoft-signed tool. Here the copied file is uv, and System32 is only put on the child's PATH, so the finding is a false positive. Both the test and the lint rule are right about what they check; they only meet by proximity.

Change

A lint-allow: AV009 <reason> comment above that one copy, the escape hatch the linter's own message names for a line that has to stay. No other line, rule or baseline entry changes, so a real System32 copy anywhere else, including in this file, still fails.

Testing

  • python scripts/lint_av_shapes.py: 0 new errors (1 on main).
  • pytest tests/security/test_lint_av_shapes.py: 19 passed (the baseline test fails on main).

@danielhanchen

Copy link
Copy Markdown
Member Author

@codex review

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Nov 14, 2026 •

Copy link
Copy Markdown
Codex Review Summary: ✅ Completed

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

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-11-14T10:48:49.226431Z 60731dd 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. You're on a roll.

Reviewed commit: 60731dd1c9

ℹ️ 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 6ea6541 into main Nov 14, 2026
@danielhanchen
danielhanchen deleted the av009-uv-copy-allow branch November 14, 2026 10:51
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