feat(python): classify executable source surfaces - #579
chrisknvidia wants to merge 45 commits into
Conversation
Signed-off-by: Christopher Kevin <christopherk@nvidia.com>
Signed-off-by: Christopher Kevin <christopherk@nvidia.com>
Signed-off-by: Christopher Kevin <christopherk@nvidia.com>
Signed-off-by: Christopher Kevin <christopherk@nvidia.com>
Signed-off-by: Christopher Kevin <christopherk@nvidia.com>
Signed-off-by: Christopher Kevin <christopherk@nvidia.com>
Signed-off-by: Christopher Kevin <christopherk@nvidia.com>
Signed-off-by: Christopher Kevin <christopherk@nvidia.com>
Signed-off-by: Christopher Kevin <christopherk@nvidia.com>
Signed-off-by: Christopher Kevin <christopherk@nvidia.com>
Signed-off-by: Christopher Kevin <christopherk@nvidia.com>
Signed-off-by: Christopher Kevin <christopherk@nvidia.com>
Signed-off-by: Christopher Kevin <christopherk@nvidia.com>
Signed-off-by: Christopher Kevin <christopherk@nvidia.com>
Signed-off-by: Christopher Kevin <christopherk@nvidia.com>
Signed-off-by: Christopher Kevin <christopherk@nvidia.com>
Signed-off-by: Christopher Kevin <christopherk@nvidia.com>
Signed-off-by: Christopher Kevin <christopherk@nvidia.com>
Signed-off-by: Christopher Kevin <christopherk@nvidia.com>
Signed-off-by: Christopher Kevin <christopherk@nvidia.com>
Signed-off-by: Christopher Kevin <christopherk@nvidia.com>
Signed-off-by: Christopher Kevin <christopherk@nvidia.com>
Signed-off-by: Christopher Kevin <christopherk@nvidia.com>
Signed-off-by: Christopher Kevin <christopherk@nvidia.com>
Signed-off-by: Christopher Kevin <christopherk@nvidia.com>
Signed-off-by: Christopher Kevin <christopherk@nvidia.com>
Signed-off-by: Christopher Kevin <christopherk@nvidia.com>
Signed-off-by: Christopher Kevin <christopherk@nvidia.com>
Signed-off-by: Christopher Kevin <christopherk@nvidia.com>
Signed-off-by: Christopher Kevin <christopherk@nvidia.com>
Signed-off-by: Christopher Kevin <christopherk@nvidia.com>
rng1995
left a comment
There was a problem hiding this comment.
Reviewed exact draft head 266d42e050493dad869fe50be420ace97914ea82. I found no additional blocker in the focused Python execution-surface range (d856d88..266d42e): 1,118 affected tests passed with 1 skip, 732 current-main merged-tree regressions passed, and lint/format/diff checks are clean.
I am requesting changes because the current combined tree still contains the confirmed #576/#577 blockers: a three-row ledger cap drops a second distinct fatal fact, and a definitely true bound shell= value evades TM1 when a later argument is effectful. This PR also inherits draft #578 and explicitly requires the dependency stack to land, rebase onto current main, fresh exact-head CI, and current-head review.
Please propagate the dependency fixes and rebase. If the focused range remains semantically unchanged and CI stays green, I found it otherwise suitable for approval.
…e-475-shell-truthiness-core Signed-off-by: Christopher Kevin <christopherk@nvidia.com>
…rsive-fail-closed-reporting Signed-off-by: Christopher Kevin <christopherk@nvidia.com>
Signed-off-by: Christopher Kevin <christopherk@nvidia.com>
Signed-off-by: Christopher Kevin <christopherk@nvidia.com>
Signed-off-by: Christopher Kevin <christopherk@nvidia.com> # Conflicts: # src/skillspector/nodes/analyzers/static_patterns_tool_misuse.py # src/skillspector/nodes/analyzers/static_runner.py
Signed-off-by: Christopher Kevin <christopherk@nvidia.com>
Signed-off-by: Christopher Kevin <christopherk@nvidia.com> # Conflicts: # src/skillspector/nodes/analyzers/static_patterns_tool_misuse.py # src/skillspector/nodes/analyzers/static_python_shell_truthiness.py # tests/nodes/analyzers/test_tool_misuse_python_ast.py
…ssification Signed-off-by: Christopher Kevin <christopherk@nvidia.com>
…surface-classification Signed-off-by: Christopher Kevin <christopherk@nvidia.com>
Signed-off-by: Christopher Kevin <christopherk@nvidia.com>
Signed-off-by: Christopher Kevin <christopherk@nvidia.com>
…urface-classification Signed-off-by: Christopher Kevin <christopherk@nvidia.com>
Signed-off-by: Christopher Kevin <christopherk@nvidia.com>
Signed-off-by: Christopher Kevin <christopherk@nvidia.com>
|
@rng1995 The dependency fixes are included, the merge conflicts are resolved, and the bare-uv and parser-limit findings are fixed. This PR is ready for review. PTAL. |
rng1995
left a comment
There was a problem hiding this comment.
The focused #579 bare-uv and execution-type parse-limit changes look correct, but this stacked head inherits the exact #577 receiver-invalidation blocker: an effectful argument after shell= may replace the trusted subprocess receiver, yet later proxy calls are still classified as subprocess and receive false-positive TM1 findings. Please update the stack after #577 clears trusted_names on this effectful path and add the regression. The current head is otherwise conflict-free and its affected/integration suites are clean.
Summary
.py,.pyw, PEP 263 encodings, extensionless shebangs, and ambiguous inputs/usr/bin/envbehavior for CPython, PyPy, and uv script launchers, failing closed when execution depends on platform, aliases, options, or invocation spellingReview context
This is the Python decoding, shebang/platform-command parsing, and execution-surface split requested in the review of #497.
Open stacked dependency: #578 at
1404c29671c35e48e13f0da2c602d6cf16d4e5af, which contains the current #576 headfb86cf753c8e4a15cbaca12f39f106bc4a6cf8dfand #577 headc3b0ff945013f2cc0eeaeb66515ba099d184478a. All three dependency PRs are ready for review but remain open and unmerged. This branch integrates them and currentorigin/main(d162d9b343e559be13df8ebba093df3bc9d58c90) with normal signed merge commits.The current PR-specific review diff against the exact #578 dependency head is:
That delta is 23 files (+5,380/-90). The current head is an empty DCO-signed CI retrigger commit whose tree is identical to reviewed commit
9cf3d3109091c93c7477a0a9204b0007bdc76e8b. The original Python-only range remains unchanged atd856d88c289c5ef3389060ef69651c9981aae38f..266d42e050493dad869fe50be420ace97914ea82(23 files, +5,211/-89); the additional delta contains review fixes for selectable bare-uv sources and execution-type-aware parser-limit accounting.Validation
gpt-5.6-soldefault; Gemini CLI absent; hosted OpenAI/Anthropic/NVIDIA provider tests skipped because their API keys are not configuredpython_ast.pytargeted mypy clean (the broader stack surfaces six pre-existing errors on older main-owned lines)python_source_ambiguous, andstatic_parse_limitoutputrunand option-like source names, script selectors, global options, macOS case aliases, and option-like pathsAll six hosted checks pass at
9e05e2987a8dd9d502c5ce6845d3e5ab275fbb12, including the Linux unit and Docker smoke jobs. GitHub reports the branch conflict-free (MERGEABLE); the stacked dependencies remain open and unmerged.