Repository navigation
fix(lint): the helper guard scans files that wrap launchers in functools.partial (#5052) - #5068
Merged
Merged
Conversation
…rtial (#5052) Co-authored-by: Copilot App <[email protected]> Co-authored-by: copilot-swe-agent[bot] <[email protected]>
…ols.partial (#5052) Co-authored-by: Copilot App <[email protected]> Co-authored-by: copilot-swe-agent[bot] <[email protected]>
Daniel Meppiel (danielmeppiel)
requested a review
from Sergio Sisternes (sergio-sisternes-epam)
as a code owner
November 23, 2026 16:07
Contributor
There was a problem hiding this comment.
🟢 Approval recommended
No active review issues are reported for the partial-call prefilter change and its accompanying regression mutation.
No open issues 🎉
What changed in this PR
Fixes #5052 by closing a prefilter gap in the external-executable architecture guard introduced in #5006. Files using functools.partial now reach the existing tree scan, allowing it to flag literal helper executable names.
Changes:
- Admit files with a
partialcall fact to the guard’s tree scan. - Add a regression mutation covering
functools.partial(subprocess.run, executable="git").
| File | Description |
|---|---|
tests/integration/test_architecture_owner_rule_mutations.py |
Adds a mutation case for a partial-wrapped launcher. |
scripts/architecture_linter/checks/transport_external_executables.py |
Includes partial in the call-fact prefilter. |
Review effort: Balanced
This was referenced Nov 23, 2026
Daniel Meppiel (danielmeppiel)
merged commit Nov 23, 2026
a3226b8
into
main
117 of 118 checks passed
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.
Description
Stacked on #5006 (base:
windows-trusted-executables); retarget tomainonce #5006 lands.The
transport-platform-external-executable-ownerguard prefilters files by call facts before its tree scan. A launch wrapped asfunctools.partial(subprocess.run, executable="git")records only apartialcall fact, so a file with a plainimport subprocessand no other launcher call was skipped. The prefilter now also admits files with apartialcall fact; the tree scan already flags the literalexecutable=keyword.Issue and approved scope
Issue: Fixes #5052
Human scope-approval comment: follow-up filed by the program desk from the #5006 review; scope as stated in the issue.
Does this PR complete the issue, or what remains? It completes the issue.
Type of change
Testing
Red first: the first commit adds a MutationCase that wraps the lock-evidence git probe in
functools.partial(subprocess.run, executable="git"). The guard stayed silent before the fix and catches it after. All 47 external-executable mutation cases pass, and the architecture boundary lint is clean.Changelog
changelog.d/<pr>.<section>.md.Spec conformance (OpenAPM v0.1)