fix(cli): refuse --trace on sweep/walkforward instead of silently dropping it (#168)
The clap help promised "persists each member's/OOS window's taps" and the chart NotFound hint recommended `aura sweep --trace`, but every blueprint-mode arm discarded the flag (run_blueprint_sweep's `let _ = persist`, the --real sugar's persist_taps: vec![]) — the surface advertised trace-recording the code dropped. Refuse --trace up front on both verbs (exit 2, "--trace is not yet available on <verb>; see #224"), mirroring the existing aura run / aura mc refusals; drop the false promise from the two help lines and the chart NotFound hint. Delivering per-member trace-writing is deferred to #224. Collateral: four synthetic-sweep tests that used --trace as a family-name handle move to --name (same handle, still accepted); the walkforward name/trace test now pins the up-front #224 refusal. Workspace suite green (62 groups / 0 failed), clippy -D warnings clean. refs #168
This commit is contained in:
@@ -1936,10 +1936,10 @@ fn walkforward_dissolved_refuses_an_unknown_select_token() {
|
||||
assert!(stderr.contains("Usage: aura walkforward"), "unknown-select refusal: {stderr}");
|
||||
}
|
||||
|
||||
/// `--trace`'s own help text ("mutually exclusive with --name") is a contract the
|
||||
/// inline path already enforces via `name_persist`; the dissolved r-sma-real path
|
||||
/// must refuse the same combination (exit 2) rather than silently letting --name
|
||||
/// win over --trace.
|
||||
/// `--trace` is now refused up front on every blueprint-mode arm (#168, before the
|
||||
/// `--name`/`--trace` mutual-exclusion check even runs) — the dissolved r-sma-real
|
||||
/// path must surface that #224 forward-pointer refusal (exit 2), not the generic
|
||||
/// mutual-exclusion message which its early return now pre-empts.
|
||||
#[test]
|
||||
fn walkforward_dissolved_refuses_name_and_trace_together() {
|
||||
let cwd = temp_cwd("walkforward-name-and-trace");
|
||||
@@ -1954,9 +1954,10 @@ fn walkforward_dissolved_refuses_name_and_trace_together() {
|
||||
.current_dir(&cwd)
|
||||
.output()
|
||||
.expect("spawn aura");
|
||||
assert_eq!(out.status.code(), Some(2), "--name and --trace together is a usage refusal");
|
||||
assert_eq!(out.status.code(), Some(2), "--trace is refused up front (exit 2)");
|
||||
let stderr = String::from_utf8_lossy(&out.stderr);
|
||||
assert!(stderr.contains("mutually exclusive"), "name/trace refusal: {stderr}");
|
||||
assert!(stderr.contains("--trace"), "refusal names the flag: {stderr}");
|
||||
assert!(stderr.contains("#224"), "refusal points forward to #224: {stderr}");
|
||||
}
|
||||
|
||||
/// Property (#210 T3, dispatch split): a successful real-data walkforward
|
||||
@@ -2717,7 +2718,7 @@ fn aura_sweep_loads_a_blueprint_and_persists_a_sweep_family() {
|
||||
"sweep", &fixture,
|
||||
"--axis", "sma_signal.fast.length=2,4",
|
||||
"--axis", "sma_signal.slow.length=8,16",
|
||||
"--trace", "f",
|
||||
"--name", "f",
|
||||
])
|
||||
.current_dir(&cwd)
|
||||
.output()
|
||||
@@ -2804,7 +2805,7 @@ fn aura_sweep_persists_the_canonical_blueprint_keyed_by_topology_hash() {
|
||||
"sweep", &fixture,
|
||||
"--axis", "sma_signal.fast.length=2,4",
|
||||
"--axis", "sma_signal.slow.length=8,16",
|
||||
"--trace", "f",
|
||||
"--name", "f",
|
||||
])
|
||||
.current_dir(&cwd)
|
||||
.output()
|
||||
@@ -2881,7 +2882,7 @@ fn aura_reproduce_re_derives_a_persisted_sweep_family() {
|
||||
"sweep", &fixture,
|
||||
"--axis", "sma_signal.fast.length=2,4",
|
||||
"--axis", "sma_signal.slow.length=8,16",
|
||||
"--trace", "f",
|
||||
"--name", "f",
|
||||
])
|
||||
.current_dir(&cwd)
|
||||
.output()
|
||||
@@ -2922,7 +2923,7 @@ fn aura_reproduce_reports_a_diverged_member_and_exits_one() {
|
||||
"sweep", &fixture,
|
||||
"--axis", "sma_signal.fast.length=2,4",
|
||||
"--axis", "sma_signal.slow.length=8,16",
|
||||
"--trace", "f",
|
||||
"--name", "f",
|
||||
])
|
||||
.current_dir(&cwd)
|
||||
.output()
|
||||
|
||||
Reference in New Issue
Block a user