Skip to content

id(repl): PR #3096 removed the functional " -\n" pipe replacement — newline-separated mid-line placeholders are no longer substituted #4428

Closed

Description

@dezren39

Finding

PR #3096 (merged, head 1b0327c346) removed the pipe stage's " -\n" replacement on the grounds that the dead literal replaces never matched. That is true of " -$", but " -\n" was functional: it substituted a mid-line - placeholder that is followed by a newline (a form a substitution can produce). Without it, a newline-separated mid-line placeholder is no longer substituted — the content is appended at the end instead and the literal - stays in the command, which the stdin-content handler then rejects, so nothing is stored. Codex raised this as a P2 on the PR (comment 4432995820); it was never replied to, and the PR's final Codex review state on the merged head is has_unresolved_findings: true.

Evidence

Why it matters

A supported placeholder form silently changed meaning in a merged PR: content that used to be stored under the intended name now makes the whole command fail downstream with an unrelated "unknown command" error. Either the form should keep working, or it should be rejected at preprocessing with the clear placeholder diagnostic — the current fall-through does neither.

Acceptance criteria

  • echo hi |> $(printf 'put -\n name') once again yields a Ready line that handle_stdin_content accepts and stores under name (placeholder substituted in place), OR the form is rejected during preprocessing with the trailing/misplaced-placeholder diagnostic — with the chosen behavior pinned by a test.
  • A regression test covers a mid-line placeholder followed by a newline in the pipe stage.
  • Existing fix(id/repl): reject trailing "-" content placeholders (#2280) #3096 tests still pass (trailing placeholders still rejected before execution; mid-line space-separated placeholders unchanged).
  • cargo test --lib repl:: passes in CI.

Activity

  1. added
    kind/bugSomething isn't working (prefixed form of the classic bug label)
    task/triageQueue packet kind: verify, reproduce, and route this item
    priority/normalOrdinary priority (the default)
    app/idPackage/app: id (pkgs/ or apps/ in this repo)
    effort/sSmall: expected under 2 hours of work
    on Nov 2, 2026
  2. dezren39 commented on Nov 2, 2026

    @dezren39
    MemberAuthor

    🤖 Agent note · filed

  3. dezren39 commented on Nov 2, 2026

    @dezren39
    MemberAuthor

    🤖 Agent note · picked up

  4. added
    work/assignedQueue worker lifecycle state
    queue/claimedQueue worker lifecycle state
    and removed on Nov 2, 2026
  5. 3 remaining items

  6. added and removed
    work/assignedQueue worker lifecycle state
    on Nov 2, 2026
  7. dezren39 commented on Nov 2, 2026

    @dezren39
    MemberAuthor

    Intake review

    Related: PR #3096 (merged 2026-11-01, head 1b0327c) — the removing PR; its final Codex review state was has_unresolved_findings: true, and this is that unaddressed P2, filed by pr-diff-review.

    Notes: Fully labelled at filing; acceptance criteria + meta/enriched only.

    Risks: restoring the replacement must not resurrect the dead-literal behavior for end-of-line placeholders — the test should pin the newline-separated mid-line case specifically.

    Suggested approach: re-add only the -\n arm in the pipe stage at pkgs/id/src/repl/input.rs, with the regression test.

    — fleet monitor intake enrichment, 2026-11-02.

  8. added
    meta/enrichedIntake review done: acceptance criteria, links, and normalized labels added
    work/assignedQueue worker lifecycle state
    queue/claimedQueue worker lifecycle state
    and removed on Nov 2, 2026
  9. dezren39 commented on Nov 2, 2026

    @dezren39
    MemberAuthor

    agent-note:v1
    task 6311 picked up by lane code-j (repo-worker-code, direct lane). Revalidated fresh: issue #4428 OPEN, no held/user-owned/do-not labels, PR #3096 MERGED (the regression source), no competing fix PR found. Next: laptop worktree, restore " -\n" pipe substitution in pkgs/id/src/repl/input.rs + regression test, keeping #3096 trailing rejection intact.

  10. added a commit that references this issue on Nov 2, 2026
  11. dezren39 commented on Nov 2, 2026

    @dezren39
    MemberAuthor

    agent-note:v1
    task 6311 done (fixed_merged) by lane code-j. PR #4524 merged (merge commit c208824): restored the pipe stage newline replace in pkgs/id/src/repl/input.rs (" -\n" -> marker + newline, before the " - " replace) + regression test test_preprocess_pipe_newline_midline_placeholder_substitutes covering both the $(printf ...) end-to-end form and the direct form. Verified on laptop: pipe tests 6/6 (incl. both #3096 trailing-rejection tests), full repl:: suite 111/111. Guard check SUCCESS on PR #4524; no Codex findings posted; #3096 trailing rejection untouched.

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    app/idPackage/app: id (pkgs/ or apps/ in this repo)effort/sSmall: expected under 2 hours of workkind/bugSomething isn't working (prefixed form of the classic bug label)meta/enrichedIntake review done: acceptance criteria, links, and normalized labels addedpriority/normalOrdinary priority (the default)source/pr-diff-reviewFiled by the pr-diff-review jobtask/triageQueue packet kind: verify, reproduce, and route this item

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions