Skip to content

fix: scrub complete sectioned Pi documentation across blank lines - #14

Merged
rynfar merged 1 commit into
mainfrom
codex/sectioned-pi-docs-13-20261001
Oct 1, 2026
Merged

rynfar merged 1 commit into
mainfrom
codex/sectioned-pi-docs-13-20261001

Conversation

@rynfar

@rynfar rynfar commented Oct 1, 2026 •

Copy link
Copy Markdown
Owner

Pi's sectioned documentation could stop being scrubbed at its first blank line, leaving later documentation and an orphan closing tag in the upstream prompt. Remove the complete docs section when its leading header identifies Pi documentation, while preserving foreign docs and subsequent project context.

Fixes #13.

Two direct tests fail on baseline main 23c98fac (15 pass / 2 fail); corrected suite is 17 pass / 0 fail. Build, standalone TypeScript check, script syntax and pack dry run pass. Adversarial controls preserve adjacent foreign docs byte-for-byte, project instructions, tools, date/cwd and idempotence. No plugin API, adapter scope or version metadata changed.

Actual headless Pi 0.87.1 is installed from its renamed canonical package @earendil-works/pi-coding-agent. The probe inserts a blank line into its native-built docs through a real extension, sends actual CLI requests through built Meridian/SDK, and checks the installed plugin at the SDK boundary.

  • Published scrub 0.2.2: later docs and closing tag remain; project context remains. Client observed billing_error. This is transformation evidence, not universal billing causation or a guaranteed billing remedy.
  • Independently installed fixed tarball, Opus 5.5 / SDK 0.2.141 / Claude Code 2.1.284 / Node 22.22.3 / macOS arm64: all docs removed and project instructions retained on all three requests; actual read executes once, random client-only receipt reaches a real tool-result request, followed by a continuation in the same Pi session file. Both turns exit 0 with zero errors.
  • Real flow arrives as adapter=opencode; the existing content scope correctly scrubs it.
  • Committed runnable scripts/e2e-pi-sectioned-docs.mjs and durable before/after proof in docs/evidence/13-sectioned-pi-docs.md. Raw client logs stay private.

Final-head CI remains a merge gate. No publication authorized; local tarball proof does not claim a registry release.

Final-head build CI passed. Merged as 188115f355f423cbff50b20a2e5fd7d932ec1746; merged tree e4002e54eb2ed3c9822f27425befabf9a8a9b347 equals validated head. Issue #13 is closed. No package publication performed.

@rynfar
rynfar merged commit 188115f into main Oct 1, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Pi 0.87.1 sectioned documentation leaves content and closing tag after scrubbing

1 participant