Repository navigation
Conversation
… files PR #824 (merged as 379f712) fixed #822 by scrubbing a leaked local checkout path out of trap.d/804.edit-op-defaulted-to-main-clone-not-worktree.md, but put the same real maintainer path/username back into two other tracked files it added in that same commit: - changelog.d/822.fixed.md's own prose quoted the literal /Users/floriandavid/... path it was describing the scrub of. - tests/test_trap_fragment_no_leaked_home_paths_822.py's docstring, regex comments and positive-control fixture all spelled out the same real path. Both now use a generic made-up path/username (/Users/someone/...) instead. The positive-control fixture keeps the same shape (an absolute POSIX home path under a worktree directory naming issue #804), so it still exercises the detector's regex identically -- only the value is fake now, not the shape. tests/test_no_real_home_paths_467.py::test_no_tracked_file_leaks_the_current_machine_username was red before this change (found floriandavid in exactly these two files) and is green after. Co-Authored-By: Claude Sonnet 5 <[email protected]>
… real username Not a code fix -- a trap.d fragment for the curation pass, per the developer brief's "log it and carry on" for something observed but not decided: tests/test_no_real_home_paths_467.py's username scan skips itself under CI (by design, to avoid false positives on CI runner account names like runneradmin), so this whole class of leak only surfaces on a maintainer's own local run. #822's own fix (PR #824) already shipped this exact shape once, and #825 is a second occurrence. Deciding what to do about it -- new jit-context rule, filed issue, or leave as-is -- is left to the curation pass, per this issue's own text. Co-Authored-By: Claude Sonnet 5 <[email protected]>
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.
Summary
PR #824 (merged as 379f712) fixed #822 by scrubbing a leaked local checkout path out of
trap.d/804.edit-op-defaulted-to-main-clone-not-worktree.md, but reintroduced the same realmaintainer path/username into two other tracked files that same commit added:
changelog.d/822.fixed.md-- prose literally quoted/Users/floriandavid/....tests/test_trap_fragment_no_leaked_home_paths_822.py-- docstring, two regex comments, andthe positive-control fixture all spelled out the real path.
This fix replaces every occurrence with a generic placeholder (
/Users/someone/...), keeping thedetector test's own logic and fixture shape unchanged -- only the value is fake now, not the
shape. A new
changelog.d/825.fixed.mdfragment documents the fix without itself quoting a realusername.
This branch also carries a second, non-required commit:
trap.d/825.ci-skip-lets-username-leaks-reach-main.md,a trap.d fragment (not a code fix) logging why
tests/test_no_real_home_paths_467.py'susername scanner can miss this exact class of regression under CI (it skips itself whenever
CI/GITHUB_ACTIONS is set, by design, to avoid false positives on CI runner account names). #822's
own fix shipped this shape once already; #825 is the second occurrence. The issue text itself
flagged this as optional / not required for #825's own scope, so it is logged for the curation
pass rather than fixed here -- a real fix needs a genuinely CI-safe way to tell a maintainer's
real username apart from a CI runner's account name, which is a design decision better made
holding all trap fragments at once.
Adjacent findings (not required, not blocking)
under CI -- which is why this whole class of leak reached main twice with a green CI run.
Logged as
trap.d/825.ci-skip-lets-username-leaks-reach-main.mdrather than fixed, per theissue's own suggestion that this is a design decision for the curation pass.
leak, but no fixture exercises that boundary. Pre-existing, unchanged by this diff.
not applicable to it.
Test plan
python3 -m pytest tests/test_no_real_home_paths_467.py -k username -q-- RED at 379f712(1 failed, found
floriandavidin both files), GREEN at 242fae4 (4 passed, 11 deselected).python3 -m pytest tests/test_no_real_home_paths_467.py tests/test_trap_fragment_no_leaked_home_paths_822.py -q-- 15 passed, before and after.
pytest-- not run locally; CI (13 legs, 3 OSes, 4 interpreters) is the gate.Closes #825
🤖 Generated with Claude Code
[AI-generated]