Skip to content

Commit 479d62a

Browse files
committed
ci: enforce --wfail across all lean targets; fix String.dropRight deprecation
lean-test now compiles everything with warnings-as-errors: - lean-action builds the default target with --wfail (warms cache, checks lib) - `lake lint -- --wfail -v` runs the @[lint_driver] build-all script, building every lib/exe target (exes, benchmarks, Apps) under --wfail - both `lake test` steps run with --wfail Replace deprecated `String.dropRight` with `String.dropEnd` in ProfileCmd and ShardCmd — the deprecation these strict builds now catch.
1 parent 055a0e1 commit 479d62a

3 files changed

Lines changed: 9 additions & 4 deletions

File tree

.github/workflows/ci.yml

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,10 +22,15 @@ jobs:
2222
- uses: leanprover/lean-action@v1
2323
with:
2424
build-args: "--wfail -v"
25+
# build-all lint driver compiles every lib/exe target with --wfail, so a
26+
# warning in any target (exes, benchmarks, Apps) — not just the default lib
27+
# lean-action builds above — fails CI.
28+
- name: Build all targets
29+
run: lake lint -- --wfail -v
2530
- name: Test Ix CLI
26-
run: lake test -- cli
31+
run: lake test --wfail -- cli
2732
- name: Aiur tests
28-
run: lake test -- --ignored aiur aiur-hashes ixvm multi-stark recursive-verifier
33+
run: lake test --wfail -- --ignored aiur aiur-hashes ixvm multi-stark recursive-verifier
2934
- name: Check Lean versions match for Ix and compiler bench
3035
run: diff lean-toolchain Benchmarks/Compile/lean-toolchain
3136

Ix/Cli/ProfileCmd.lean

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ def runProfileCmd (p : Cli.Parsed) : IO UInt32 := do
3232
-- Default sidecar mirrors the env's base name: `init.ixe` → `init.ixprof`
3333
-- (not `init.ixe.ixprof`); a non-`.ixe` path just gets `.ixprof` appended.
3434
| none =>
35-
let base := if envPath.endsWith ".ixe" then envPath.dropRight 4 else envPath
35+
let base := if envPath.endsWith ".ixe" then (envPath.dropEnd 4).toString else envPath
3636
base ++ ".ixprof"
3737
let isolate := !(p.flag? "keep-caches" |>.isSome)
3838
let quiet := !(p.flag? "verbose" |>.isSome)

Ix/Cli/ShardCmd.lean

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ def runShardCmd (p : Cli.Parsed) : IO UInt32 := do
4040
-- Default manifest mirrors the profile's base name: `init.ixprof` →
4141
-- `init.ixes` (not `init.ixprof.ixes`).
4242
| none =>
43-
let base := if espPath.endsWith ".ixprof" then espPath.dropRight 7 else espPath
43+
let base := if espPath.endsWith ".ixprof" then (espPath.dropEnd 7).toString else espPath
4444
base ++ ".ixes"
4545
let shardsFlag : Option Nat := (p.flag? "shards").map (·.as! Nat)
4646
let maxCycles : Option Nat := (p.flag? "max-cycles").map (·.as! Nat)

0 commit comments

Comments
 (0)