Repository navigation
T40 — Split the daemon's exec dispatch into files by concern - #2838
mitodrummer merged 2 commits into
Conversation
exec.rs keeps the Exec and Process traits, request dispatch and trace adoption. The process implementations move to exec/process.rs, the channel bridge to exec/bridge.rs, the session run, build and check forms to exec/run.rs, and the git pack handlers to exec/git.rs. A pure move: items private to exec.rs become pub(super) in their new file, and nothing else changes.
…daemon-s-exec-dispatch-into-files-by-c
|
Important Review skippedBot user detected. To trigger a single review, invoke the
|
There was a problem hiding this comment.
arch-review: PASS · the full ruling
This change moves the exec dispatch in crates/minimald/src/exec.rs into four files by concern. A sorted line comparison against the base shows a pure move. Only visibility, module docs, mod/use lines and one rustfmt rewrap changed. The design of record does not state a file layout inside minimald, so this is a PASS by absence. The code stays in the same crate, and mod exec stays private.
Ruled at 81ee3b2 against gominimal/arch@8640f85e193d by claude-opus-5-5.
|
Approved: no findings at Nothing to do. Verdict APPROVE, posted as a comment: the App cannot review its own pull request; the check and the label carry it. Clobber: none: the base diff shows only the split. |
|
Round 1 of 10 on a failed check suite: the coder changed nothing. Revise round 1: no change. The directive excerpts do not name a failing test. The merge from main did not touch crates/minimald. On this box, minimald fmt and clippy are clean, and the full minimald nextest run passed 1287 of 1288 tests. The one failure was box_manager::tests::reap_hands_name_to_retained_holder. That test is outside the exec split, and it passed 3 of 3 reruns alone, so it is a flake under load. The CI nextest profile uses retries = 0, so a flake fails the tests job, and ci-linux-native-success only aggregates that job. Rerun the failed jobs. If the tests job fails again, the failing test name in the full job log is necessary for the next round. I was not able to run the doctests here because rustdoc is not installed. The split moved only a ```text doc block, and rustdoc does not run that kind of block. Fixing the box_manager flake is outside this task's layers. |
There was a problem hiding this comment.
Reviewed at 81ee3b2. A pure move of exec.rs into exec/{bridge,git,process,run}.rs. Beyond relocated lines, the diff adds only module docs, mod and use lines, and pub(super) visibility so the new files can reach each other. Its one CI failure was reap_hands_name_to_retained_holder, a race on main now tracked as T59 #2840, and it passed on rerun.
T40 — Split the daemon's exec dispatch into files by concern
slice: S2
kind: enablement
covers: none
size: M
est: 220 code, 60 tests
executor: agent
difficulty: routine
model: standard
diagnostics: none: a pure move, no behaviour
observability: none: a pure move, no signal
layers:
- exec:
- crates/minimald/src/exec.rs: traits and dispatch only
- crates/minimald/src/exec/process.rs (new): moved
- crates/minimald/src/exec/bridge.rs (new): moved
- crates/minimald/src/exec/run.rs (new): moved
- crates/minimald/src/exec/git.rs (new): moved
test: cargo nextest run -p minimald start_kill_sends_sigterm
produces: none
consumes: none
proof: Exec behaves as before, split by concern.
depends on:
- blocked by #2395
Proof
A reader of crates/minimald/src/exec.rs now finds only the Exec and Process traits, the request dispatch (handle_exec) and trace adoption. The process implementations are in exec/process.rs, the channel bridge is in exec/bridge.rs, the session run, build and check forms are in exec/run.rs, and the git pack handlers are in exec/git.rs. Exec behaviour does not change: the moved lines are identical apart from visibility, and the existing exec tests compile and run against them unchanged.
Notes from the agent: This change is a move by line range. Each new file starts with
use super::*;. exec.rs re-exports the new files with glob imports (pub use process::*,pub(crate) use bridge::*), so every crate::exec::* path and the exec/tests.rs imports resolve unchanged. Items, struct fields and inherent methods that were private in exec.rs are now pub(super), so the parent and its test modules can reach them. A sorted line diff of the old file against the new files shows only the new module docs, the mod and use lines, and one rustfmt line rewrap of destroy_signal. The trace adoption helpers (exec_span, adopt_trace and the others) stay in exec.rs as part of dispatch, because the task names no file for them. clippy -p minimald --all-targets is clean. I ran only the one test line, not the whole crate suite.Tests
cargo nextest run -p minimald start_kill_sends_sigtermVerify
min task run agent-verifyexited 100 under rustc 1.99.0, which the repository does not pin (1.99.1 in rust-toolchain.toml); the PR is not a draft on that alone — CI, which honours the pin, is the gate.Base
The base branch moved while the coder worked; it was merged in before the tests ran.
Closes #2398