Skip to content

Commit 4dd99e3

Browse files
fix(ci): apply cargo fmt (Rust CI red on main) + drop stale verisim TODO note (#305)
## Summary - Rust CI on main is red **solely** on `cargo fmt --check` (run 28736074839). This applies rustfmt output: mechanical line-wraps of the `gnn_augment_tactics` call site across 62 prover backends plus `src/interfaces/graphql/{resolvers,schema}.rs`. - Removes the stale `docs/handover/TODO.md` entry claiming `--features verisim` fails with 22 errors — `cargo check --lib --features verisim` now compiles clean (0 errors, 6m02s). Closes #245. ## Why it matters The L3→L1 Cap'n Proto hand-off gate (TODO.md P-gates) requires Tier-1 green on main for ≥7 days; this fmt red was blocking that clock from starting. ## Verification - `cargo fmt --check` clean after change - `cargo check --lib` clean (formatting-only Rust changes) Closes #245 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-authored-by: Claude Fable 5 <noreply@anthropic.com>
1 parent 8873d41 commit 4dd99e3

65 files changed

Lines changed: 321 additions & 82 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

docs/handover/TODO.md

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -167,7 +167,6 @@ Existing POC: `chapel_poc/parallel_proof_search.chpl` (420 LoC) + the self-linki
167167
- **TypeDiscipline deep native wiring** (phase-2 deferred) — per-discipline proof encoding, Idris2 validator tagging, family-aware GNN features, per-discipline integration tests under `tests/disciplines/`, Katagoria fixture round-trip, per-discipline dispatch scoring.
168168
- **HP type-checker ecosystem backends** — 13 corpus-only provers (KatagoriaVerifier, Modal/Session/Choreographic/Epistemic/Refinement/Echo/Dependent/QTT/Effect-Row/Tropical/TypeLL etc.) need Rust backends shelling out to the HP stack (Ephapax, Wokelang, AffineScript) — corpus contributes to vocab/training only until backends wire up dispatch.
169169
- **CR-1..CR-10 cross-repo tests** from standards `TESTING-TAXONOMY.adoc` — notably CR-2 foreign-enum exhaustive-match lint, CR-3 FFI roundtrip over all variants, CR-6 upstream-HEAD sentinel.
170-
- **`verisim` feature compile errors**`cargo check --lib --features verisim` fails with 22 errors (missing `warn` import, unresolved `Goal`/`theorem`, private-field access in `VeriSimDBClient`). Unrelated to main build; gate off by default.
171170
- **Remaining CI infra failures** — Mirror to Git Forges Radicle SSH key unset; Instant Sync `.git-private-farm` bad credentials. Tokens human-owned — see `YOUR-ACTIONS-todo.md §0c`.
172171

173172
## Non-goals (explicit)

src/interfaces/graphql/resolvers.rs

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -637,10 +637,8 @@ impl EchidnaContext {
637637
.iter()
638638
.filter_map(|s| {
639639
let name = s["tactic"].as_str()?;
640-
let confidence =
641-
s["confidence"].as_f64().unwrap_or(0.5);
642-
let explanation =
643-
s["explanation"].as_str().map(|t| t.to_string());
640+
let confidence = s["confidence"].as_f64().unwrap_or(0.5);
641+
let explanation = s["explanation"].as_str().map(|t| t.to_string());
644642
Some(crate::schema::SuggestedTactic {
645643
tactic: name.to_string(),
646644
confidence,

src/interfaces/graphql/schema.rs

Lines changed: 27 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -483,11 +483,7 @@ impl QueryRoot {
483483
/// list-query for the common single-prover case. Backend construction
484484
/// + a `version()` probe is the strongest "available right now"
485485
/// signal we can give without actually dispatching a proof.
486-
async fn prover_status(
487-
&self,
488-
_ctx: &Context<'_>,
489-
prover: String,
490-
) -> Result<ProverStatusInfo> {
486+
async fn prover_status(&self, _ctx: &Context<'_>, prover: String) -> Result<ProverStatusInfo> {
491487
let core_kind = match CoreProverKind::from_str(&prover) {
492488
Ok(k) => k,
493489
Err(e) => {
@@ -1115,7 +1111,10 @@ mod tests {
11151111
/// `/api/verify` handler emits must map onto a distinct enum variant.
11161112
#[test]
11171113
fn verify_outcome_from_rest_str_covers_taxonomy() {
1118-
assert_eq!(VerifyOutcome::from_rest_str("PROVED"), VerifyOutcome::Proved);
1114+
assert_eq!(
1115+
VerifyOutcome::from_rest_str("PROVED"),
1116+
VerifyOutcome::Proved
1117+
);
11191118
assert_eq!(
11201119
VerifyOutcome::from_rest_str("NO_PROOF_FOUND"),
11211120
VerifyOutcome::NoProofFound
@@ -1128,7 +1127,10 @@ mod tests {
11281127
VerifyOutcome::from_rest_str("UNSUPPORTED_FEATURE"),
11291128
VerifyOutcome::UnsupportedFeature
11301129
);
1131-
assert_eq!(VerifyOutcome::from_rest_str("TIMEOUT"), VerifyOutcome::Timeout);
1130+
assert_eq!(
1131+
VerifyOutcome::from_rest_str("TIMEOUT"),
1132+
VerifyOutcome::Timeout
1133+
);
11321134
assert_eq!(
11331135
VerifyOutcome::from_rest_str("INCONSISTENT_PREMISES"),
11341136
VerifyOutcome::InconsistentPremises
@@ -1142,10 +1144,7 @@ mod tests {
11421144
VerifyOutcome::from_rest_str("WAT"),
11431145
VerifyOutcome::SystemError
11441146
);
1145-
assert_eq!(
1146-
VerifyOutcome::from_rest_str(""),
1147-
VerifyOutcome::SystemError
1148-
);
1147+
assert_eq!(VerifyOutcome::from_rest_str(""), VerifyOutcome::SystemError);
11491148
}
11501149

11511150
/// `loose_status` covers the four labels echidnabot's existing
@@ -1256,7 +1255,10 @@ mod tests {
12561255
"#;
12571256
let resp = schema.execute(Request::new(query)).await;
12581257
// Unknown prover -> resolver Err -> top-level GraphQL error.
1259-
assert!(!resp.errors.is_empty(), "expected an error for unknown prover");
1258+
assert!(
1259+
!resp.errors.is_empty(),
1260+
"expected an error for unknown prover"
1261+
);
12601262
assert!(resp.errors[0].message.contains("Unknown prover"));
12611263
}
12621264

@@ -1328,9 +1330,16 @@ mod tests {
13281330
}
13291331
"#;
13301332
let resp = schema.execute(Request::new(q)).await;
1331-
assert!(resp.errors.is_empty(), "introspection errors: {:?}", resp.errors);
1333+
assert!(
1334+
resp.errors.is_empty(),
1335+
"introspection errors: {:?}",
1336+
resp.errors
1337+
);
13321338
let body = serde_json::to_string(&resp.data).unwrap();
1333-
assert!(body.contains("\"verifyProof\""), "missing verifyProof mutation");
1339+
assert!(
1340+
body.contains("\"verifyProof\""),
1341+
"missing verifyProof mutation"
1342+
);
13341343
assert!(
13351344
body.contains("\"suggestTactics\""),
13361345
"missing new suggestTactics mutation"
@@ -1353,7 +1362,10 @@ mod tests {
13531362
let resp = schema.execute(Request::new(q)).await;
13541363
assert!(resp.errors.is_empty());
13551364
let body = serde_json::to_string(&resp.data).unwrap();
1356-
assert!(body.contains("\"proverStatus\""), "missing proverStatus query");
1365+
assert!(
1366+
body.contains("\"proverStatus\""),
1367+
"missing proverStatus query"
1368+
);
13571369
assert!(
13581370
body.contains("\"suggestTacticsByProofId\""),
13591371
"missing renamed suggestTacticsByProofId query"

src/rust/provers/acl2.rs

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1550,7 +1550,10 @@ impl ProverBackend for ACL2Backend {
15501550
args: vec![],
15511551
});
15521552

1553-
Ok(crate::provers::gnn_augment_tactics(&self.config, state, "acl2", suggestions, limit).await)
1553+
Ok(
1554+
crate::provers::gnn_augment_tactics(&self.config, state, "acl2", suggestions, limit)
1555+
.await,
1556+
)
15541557
}
15551558

15561559
async fn search_theorems(&self, pattern: &str) -> Result<Vec<String>> {

src/rust/provers/agsyhol.rs

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -167,7 +167,10 @@ impl ProverBackend for AgsyholBackend {
167167
command: "timeout".to_string(),
168168
args: vec![format!("{}", self.config.timeout)],
169169
}];
170-
Ok(crate::provers::gnn_augment_tactics(&self.config, state, "agsyhol", tactics, limit).await)
170+
Ok(
171+
crate::provers::gnn_augment_tactics(&self.config, state, "agsyhol", tactics, limit)
172+
.await,
173+
)
171174
}
172175

173176
async fn search_theorems(&self, _pattern: &str) -> Result<Vec<String>> {

src/rust/provers/altergo.rs

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -238,7 +238,10 @@ impl ProverBackend for AltErgoBackend {
238238
args: vec!["--sat-solver CDCL-Tableaux".to_string()],
239239
},
240240
];
241-
Ok(crate::provers::gnn_augment_tactics(&self.config, state, "altergo", tactics, limit).await)
241+
Ok(
242+
crate::provers::gnn_augment_tactics(&self.config, state, "altergo", tactics, limit)
243+
.await,
244+
)
242245
}
243246

244247
async fn search_theorems(&self, _pattern: &str) -> Result<Vec<String>> {

src/rust/provers/athena.rs

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -136,7 +136,10 @@ impl ProverBackend for AthenaBackend {
136136
},
137137
Tactic::Simplify,
138138
];
139-
Ok(crate::provers::gnn_augment_tactics(&self.config, state, "athena", tactics, limit).await)
139+
Ok(
140+
crate::provers::gnn_augment_tactics(&self.config, state, "athena", tactics, limit)
141+
.await,
142+
)
140143
}
141144

142145
async fn search_theorems(&self, _pattern: &str) -> Result<Vec<String>> {

src/rust/provers/boogie.rs

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -165,7 +165,10 @@ impl ProverBackend for BoogieBackend {
165165
args: vec!["/proverOpt:O:smt.qi.max_multi_patterns=1000".to_string()],
166166
},
167167
];
168-
Ok(crate::provers::gnn_augment_tactics(&self.config, state, "boogie", tactics, limit).await)
168+
Ok(
169+
crate::provers::gnn_augment_tactics(&self.config, state, "boogie", tactics, limit)
170+
.await,
171+
)
169172
}
170173

171174
async fn search_theorems(&self, _pattern: &str) -> Result<Vec<String>> {

src/rust/provers/cadical.rs

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -419,7 +419,10 @@ impl ProverBackend for CaDiCaLBackend {
419419
Tactic::Simplify,
420420
];
421421

422-
Ok(crate::provers::gnn_augment_tactics(&self.config, state, "cadical", tactics, limit).await)
422+
Ok(
423+
crate::provers::gnn_augment_tactics(&self.config, state, "cadical", tactics, limit)
424+
.await,
425+
)
423426
}
424427

425428
async fn search_theorems(&self, _pattern: &str) -> Result<Vec<String>> {

src/rust/provers/cameleer.rs

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -163,7 +163,10 @@ impl ProverBackend for CameleerBackend {
163163
args: vec!["split_vc".to_string()],
164164
},
165165
];
166-
Ok(crate::provers::gnn_augment_tactics(&self.config, state, "cameleer", tactics, limit).await)
166+
Ok(
167+
crate::provers::gnn_augment_tactics(&self.config, state, "cameleer", tactics, limit)
168+
.await,
169+
)
167170
}
168171

169172
async fn search_theorems(&self, _pattern: &str) -> Result<Vec<String>> {

0 commit comments

Comments
 (0)