• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

moeyensj / difi / 24795249500
90%

Build:
DEFAULT BRANCH: main
Ran 22 Apr 2026 06:25PM UTC
Jobs 1
Files 14
Run time 1min
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

22 Apr 2026 06:22PM UTC coverage: 88.939% (+2.2%) from 86.704%
24795249500

push

github

moeyensj
Add difi CLI binary

New `difi` binary gated behind the `cli` Cargo feature so lib-only
consumers (thor-rust, precovery) don't compile clap/toml/anyhow/sha2.

Subcommands:
- `difi analyze-observations` (alias `cifi`) — runs CIFI, writes
  all_objects / findable_observations / partition_summaries parquet
  plus a run_manifest.json with version, argv, input sha256-prefix,
  host info, and per-scenario timings.
- `difi analyze-linkages` (alias `analyze`) — runs CIFI then DIFI in
  one shot, adds all_linkages.parquet.

Also:
- `--scenarios <FILE>.toml` on analyze-observations for batch CIFI
  runs with per-scenario observations/metric/partition overrides.
- `--progress-json` emits NDJSON progress events on stdout; human
  messages always go to stderr regardless. A panic hook additionally
  emits `{"event":"error"}` on stdout before the default hook runs,
  so the NDJSON contract survives library panics.
- Scenario observations-path precedence: per-scenario entry >
  --observations CLI flag > [defaults] (most explicit wins; CLI
  overrides file defaults for ephemeral re-runs).
- Exit codes per proposal: 1 (config/args), 2 (I/O), 3 (data); chain
  inspection prefers the library's classified error over a raw
  io::Error, since parquet/arrow errors can carry an inner io::Error.
- README updated with a CLI section (install, subcommand examples,
  partitions, scenarios TOML, --progress-json) and feature-gated dev
  commands.

Tests (`tests/cli.rs`, 16 cases via assert_cmd + predicates): subcommand
outputs, cifi / analyze aliases, sliding partitions, scenarios TOML,
CLI-observations overrides TOML defaults, missing-input returns exit
code 2, missing-window error path, NDJSON validity, error events
dual-emitted to stdout+stderr, --help / --version.

Library (`src/lib.rs` and below) untouched — the CLI is pure glue.

Verified:
- `cargo build --no-default-features`   # no CLI deps leak into lib builds
- `cargo build --features cli`
- `cargo fmt -- --check`
- `cargo... (continued)

619 of 669 new or added lines in 4 files covered. (92.53%)

2187 of 2459 relevant lines covered (88.94%)

244.37 hits per line

Uncovered Changes

Lines Coverage ∆ File
21
63.16
src/bin/difi/main.rs
17
94.12
src/bin/difi/common.rs
7
96.57
src/bin/difi/analyze_observations.rs
5
95.8
src/bin/difi/analyze_linkages.rs
Jobs
ID Job ID Ran Files Coverage
1 24795249500.1 22 Apr 2026 06:25PM UTC 14
88.94
GitHub Action Run
Source Files on build 24795249500
  • Tree
  • List 14
  • Changed 2
  • Source Changed 0
  • Coverage Changed 2
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Repo
  • Github Actions Build #24795249500
  • b4ebf50d on github
  • Prev Build on main (#24152175537)
  • Next Build on main (#24798476321)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc