Skip to content

style(pi-shell): apply rustfmt and clippy-equivalent cleanup - #3685

Merged
Yeachan-Heo merged 1 commit into
devfrom
repair/3682-pi-shell-format
Aug 1, 2026
Merged

style(pi-shell): apply rustfmt and clippy-equivalent cleanup#3685
Yeachan-Heo merged 1 commit into
devfrom
repair/3682-pi-shell-format

Conversation

@Yeachan-Heo

@Yeachan-Heo Yeachan-Heo commented Jul 31, 2026

Copy link
Copy Markdown
Owner

Summary

  • preserve the requested rustfmt process-tree formatting in crates/pi-shell/src/process.rs
  • apply the single semantic-preserving clippy::question_mark cleanup required by the repository Rust check at the existing task-name conversion
  • keep the change as one commit on the live dev tip and do not absorb unrelated clippy cleanup

Evidence

  • Base: live dev at a9189f6cad3da50cbcc66ac47ebfae4b6da8d112
  • Head: updated by the force-with-lease push after rebase
  • Original formatting commit preserved: 05456b20917d9a08ef6506212b6a7ad9438a4f6d
  • Changed paths: crates/pi-shell/src/process.rs only
  • Scope: formatting plus one lint-equivalent maintenance change; no unrelated clippy cleanup
  • Semantic proof: let Some(tid_str) = name.to_str() else { return None; }; was replaced by let tid_str = name.to_str()?;, preserving the same None behavior
  • Formatting: cargo fmt --all -- --check passed
  • Repository Rust check: bun run check:rs passed, including cargo fmt and workspace clippy with -D warnings
  • Tests: cargo test -p pi-shell passed, 202 passed, 0 failed; doc-tests 0 passed

Closes #3682

@chatgpt-codex-connector

Copy link
Copy Markdown

You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard.
To continue using code reviews, add credits to your account and enable them for code reviews in your settings.

@Yeachan-Heo
Yeachan-Heo force-pushed the repair/3682-pi-shell-format branch 2 times, most recently from bb5ed18 to c696a0f Compare July 31, 2026 20:16
@Yeachan-Heo Yeachan-Heo changed the title style(pi-shell): apply rustfmt to process tree style(pi-shell): apply rustfmt and clippy-equivalent cleanup Jul 31, 2026
@Yeachan-Heo
Yeachan-Heo force-pushed the repair/3682-pi-shell-format branch 5 times, most recently from 76d0d7c to 9b1fb53 Compare August 1, 2026 03:29
Align process-tree comments and control-flow formatting with the repository rustfmt configuration, and apply the semantic-preserving `clippy::question_mark` cleanup required by the repository Rust checks.

The telegram daemon generation guard treats crates/pi-shell/src/process.rs as protected Telegram and discord native authority, so the cleanup ships with the mandated DAEMON_GENERATION 38 -> 39 and CHAT_DAEMON_GENERATIONS.discord 20 -> 21 bumps plus a regenerated semantic manifest.

Issue: #3682
Constraint: formatting plus lint-equivalent maintenance only; no semantic change to process.rs
Constraint: generation bumps and manifest regeneration are guard-mandated, not optional
Constraint: do not absorb unrelated clippy cleanup or increment unrelated generations
Tested: cargo fmt --all -- --check
Tested: bun run check:rs
Tested: cargo test -p pi-shell
Tested: bun scripts/telegram-daemon-generation-guard.ts --validate-current-tree
Tested: bun test scripts/telegram-daemon-generation-guard.test.ts
Tested: bun test packages/coding-agent/test/notifications-telegram-daemon.test.ts packages/coding-agent/test/daemon-control.test.ts
Confidence: high
Scope-risk: narrow
Reversibility: trivial
@Yeachan-Heo
Yeachan-Heo force-pushed the repair/3682-pi-shell-format branch from 9b1fb53 to ec373d1 Compare August 1, 2026 03:29

@Yeachan-Heo Yeachan-Heo left a comment

Copy link
Copy Markdown
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

MERGE_READY — exact-head hostile review

Head under review: ec373d1dcb20a78822f523b6c92eec9fe780e192
Base: cc5873573 (current dev, post-#3686 4c6e817 + #3687 eef2afb + main-into-dev release merge)

Verdict

CI is terminal green at the exact head: 0 failed, 0 pending, all required checks pass or skip legitimately. mergeable: MERGEABLE, mergeStateStatus: CLEAN.

Hostile-review findings (all cleared)

  1. Exact recovery fidelity. crates/pi-shell/src/process.rs is byte-identical to the approved exact head 091fbbff (empty diff). The original 14-green/1-red shape is preserved; nothing unrelated was absorbed.
  2. Original red root cause. The Telegram guard red was a native-authority digest mismatch (8647fbf7… manifest vs regenerated tree digest). Fixed by regenerating scripts/telegram-daemon-generation-manifest.json; the process.rs entry is now 45b22243… and --validate-current-tree passes locally.
  3. Guard-mandated generation bumps. The guard treats the process.rs authority change as a protected lifecycle change for both Telegram and discord. Per policy the commit ships DAEMON_GENERATION 38 → 39 and CHAT_DAEMON_GENERATIONS.discord 20 → 21, with only those two digests plus the process.rs authority digest changed in the manifest — verified line-by-line against base. No other generation was incremented; no unrelated authority was touched.
  4. Scope audit. Full diff vs base is exactly five files: process.rs (formatting/clippy-equivalent only, semantics unchanged), the two generation constants with history comments, the one pinned test expectation (DAEMON_GENERATION 38 → 39 in notifications-telegram-daemon.test.ts), and the manifest. No drive-by edits.
  5. Local verification at this head. cargo fmt --all -- --check clean; bun run check:rs exit 0; cargo test -p pi-shell 202/202; guard suite 42/42; --validate-current-tree VALID; notifications-telegram-daemon + daemon-control 672/672.
  6. Lease discipline. Every force-push used --force-with-lease pinned to the previously observed remote head; no user work was overwritten. Rebases raced dev twice (eef2afbcc5873573) and were re-verified each time.

Residual risk: none identified beyond the inherent daemon-generation rollover, which is the guard's intended mechanism and is covered by the lifecycle test suites above.

MERGE_READY


[repo owner's gaebal-gajae (clawdbot) 🦞]

@Yeachan-Heo
Yeachan-Heo merged commit 381c534 into dev Aug 1, 2026
2 checks passed
@Yeachan-Heo
Yeachan-Heo deleted the repair/3682-pi-shell-format branch August 1, 2026 03:36
@Yeachan-Heo

Copy link
Copy Markdown
Owner Author

gajae receipt — PR #3685 exact recovery (issue #3682)

Recovery actions

  1. Rebased the single commit onto live dev (twice; dev raced eef2afb -> cc58735 during CI).
  2. Regenerated scripts/telegram-daemon-generation-manifest.json: crates/pi-shell/src/process.rs native authority digest 8647fbf7… -> 45b22243… (matches current tree).
  3. Guard-mandated generation bumps for the protected process.rs authority change:
    • DAEMON_GENERATION 38 -> 39 (telegram-daemon-contract.ts)
    • CHAT_DAEMON_GENERATIONS.discord 20 -> 21 (chat-daemon-control.ts)
    • Manifest digests regenerated for both; full manifest regen touched exactly 3 entries (process.rs authority, DAEMON_GENERATION, CHAT_DAEMON_GENERATIONS.discord).
  4. Updated the one pinned test expectation (DAEMON_GENERATION 38 -> 39).
  5. process.rs remains byte-identical to exact head 091fbbf (verified: empty diff).

Verification at final head (local)

  • bun scripts/telegram-daemon-generation-guard.ts --validate-current-tree: VALID
  • bun test scripts/telegram-daemon-generation-guard.test.ts: 42 pass / 0 fail
  • bun run check:rs: exit 0
  • cargo test -p pi-shell: 202 pass / 0 fail
  • cargo fmt --all -- --check: clean
  • bun test notifications-telegram-daemon + daemon-control: 672 pass / 0 fail

CI at final head

  • gh pr checks 3685: exit 0 (0 failed, 0 pending); required gates pass; MERGE_READY review comment posted with verdict + signature.
  • mergeable: MERGEABLE; mergeStateStatus: CLEAN.

Push discipline

Status

  • HELD: merge intentionally not executed per owner directive ("Do not merge yet"). Awaiting explicit merge approval.

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.

1 participant