Repository navigation
fix(process): honor disabled PID normalization in samples - #703
Merged
kaoru0822-kitauji merged 1 commit intoOct 6, 2026
Merged
kaoru0822-kitauji merged 1 commit into
kaoru0822-kitauji merged 1 commit into
Conversation
Collaborator
Author
|
@codex review |
darsrc
pushed a commit
to darsrc/rea
that referenced
this pull request
Oct 10, 2026
…-normalization fix(process): honor disabled PID normalization in samples
Closed
2 tasks done
22 tasks
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
Honor
normalization.pids: falsefor numeric process-sample identities.No separate issue: this is a reproduced caller-option/output mismatch.
Problem and expected behavior
An owned Linux Node process reports its real PID, parent PID, process group and session. With PID normalization explicitly disabled,
capture-processstill replaces those sample fields with1/2/1/1, while the emitted Evidence and manifest commitpids: false.The command-text path already respects the flag. The numeric sample projection should respect it too, without changing the default normalized behavior.
Change and scope
Condition only the four output identity fields on the PID-normalization setting. False preserves sampled values; true and the omitted/default setting retain the existing mapping.
Keep time bucketing, command normalization and independently selected path/port/pattern processing intact. Preserve null/zero sentinels, fresh output arrays and the explicit six-field output whitelist.
Contract and boundary impact
Evidence and regression coverage
On unchanged main
217e8cf, six regression cases fail while seven controls pass.Tests cover false/true/omitted settings, root/child/parent/group/session associations, null/zero values, all PID/path/port toggle combinations, independent time/pattern handling, immutable inputs and exclusion of extra runtime metadata.
An owned Linux fixture reads its identity independently from
/proc/self/stat. Public capture and actual compiled CLI runs verify agreement among producer output, samples, Evidence parameters and manifest commitments. Both false and true captures exit successfully, quiesce and verify cleanup.Validation performed
After fast-forwarding the unchanged reviewed patch to main
7f1fa64:npm run check: passed; all five tasks succeeded (101 warnings, no errors; none reference changed files).npm run jscpd,npm run scan:todos, andgit diff --check: passed.Linux x64, Node.js 24.19.0, npm 11.9.0, exact locked dependencies. Hosted CI is tracked separately; no full local suite pass is claimed.
Compatibility, safety, and release
Default PID normalization is unchanged. No ownership, sampling, signaling, cleanup, schema, dependency, packaging or execution-authority changes.
The real process regression is Linux-specific; no real macOS/Windows, package-install, browser or Hopper/Ghidra claim is made.
Prepared with AI assistance.