Skip to content

ui-server: recognize Pi grep empty results without taint #4276

Open

Description

@schlessera

Part of #3596. Confirmed at main 63bb400.

The shipped Pi brain grep (packages/ui-backend-pi/src/file-tools.ts:75) emits exactly No matches. for an empty result. outputTaintSignals (packages/ui-server/src/activity/ingestion-taint.ts:204) treats it as an unparseable path and creates a spurious legacy_unknown occurrence.

A real writer/collector test begins grep on an ordinary root and returns that exact empty sentinel. PI_EMPTY_GREP_CREATES_NO_SPURIOUS_TRIGGER fails, and a previously normal chat is restricted despite no returned file content.

Acceptance criteria:

  • Recognize only supported tool-specific empty-result formats as empty evidence; ordinary no-match Pi grep remains normal with complete healthy coverage.
  • Do not suppress malformed output, truncated remainders, genuine matched files or independent input signals.
  • Verify the exact emitted format against the shipped tool and exercise the real grep implementation and collector/writer offline.
  • Include failing-first and restored mutation receipts.

No source trust exemption, wire change or provider history change is intended.

Activity

  1. added
    type: fix
    area: ui-server
    priority: p2
    agent-ready
    on Nov 20, 2026
  2. self-assigned this
    on Nov 20, 2026
  3. added this to the 0.45.0 milestone on Nov 20, 2026
  4. schlessera commented on Nov 20, 2026

    @schlessera
    OwnerAuthor

    Claim safety-epic-followups-20261120, branch fix/safety-epic-followups-20261120, dedicated checkout from main 63bb400b31403ee319926d38e223711a9bf0e7e1. Failing-first real writer/collector and held-wait backend tests confirm the issue. Shared proof collisions are being checked; proposed implementation avoids #4270/#4273's source files, with any necessary shared contract edit to be coordinated before review.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

agent-readyarea: ui-serverpriority: p2type: fix

Projects

No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions