Skip to content

Commit e9600e9

Browse files
mjerrisclaude
andcommitted
fix(docs): drop porting-process jargon from stripControlChars' public doc comment
65a1a1c renamed the parameter to `eventDict` and explained WHY in the shipped doc comment — naming the enumerator, the camelCase->snake_case fold, the rename table, and "the oracle". The nightly PUBLIC-JARGON gate caught the last of those: src/Logger.ts:237: banned public-doc jargon 'oracle' [public-jargon] typescript: 1 jargon leak(s) in 1 file(s) It is a nightly-tier gate, which is why the per-PR run-ci was green locally. The gate is right, and not only about the one banned word. An SDK consumer reading `stripControlChars` in their editor does not have a porting matrix, an enumerator, or a reference oracle; every sentence of that paragraph described OUR process, not what the parameter is or does. That reasoning belongs in the commit that made the decision (65a1a1c, where it still is), not in shipped API documentation. The parameter description is now what a caller needs: the log event record whose string values get sanitized. Nothing about the behaviour changed. Verified: run-ci.sh --rules PUBLIC-JARGON -> PASS. run-tests.sh -> 2884 passed. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01KKwgPbehDoAMdG3hPL79oi
1 parent 65a1a1c commit e9600e9

1 file changed

Lines changed: 0 additions & 3 deletions

File tree

src/Logger.ts

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -232,9 +232,6 @@ const CONTROL_CHAR_RE = /[\x00-\x08\x0b\x0c\x0e-\x1f\x7f-\x9f]/g;
232232
* processor. Processes nested objects and arrays recursively.
233233
*
234234
* @param eventDict - The log event record whose string values should be sanitized.
235-
* Named for the reference's `event_dict` (`logging_config.py:33`) — the enumerator
236-
* camelCase->snake_case folds this to `event_dict`, so the recorded signature matches
237-
* the oracle without needing a rename-table entry.
238235
* @returns A shallow copy of `eventDict` with control characters removed from strings.
239236
*/
240237
export function stripControlChars<T extends Record<string, unknown>>(eventDict: T): T {

0 commit comments

Comments
 (0)