Skip to content

Write the RFC 0015 INCOMPLETE marker before verification #4983

Description

@ivmat

RFC 0015 says Kani replaces any earlier --export-json file with an atomic INCOMPLETE marker when
verification begins. #4941 writes only the final document, so the marker is still missing. This
issue tracks the stale-export problem from #4731, which was closed on the understanding that the
marker fixes it.

Reproduction (from the #4941 review): export one harness to out/stale.json, start a second run to
the same path, and send SIGKILL to kani-driver during verification. The file still says
"run_state": "COMPLETE", has the first run's started_at, and lists only the first run's harness.

What the fix needs:

  • In verify_project (kani-driver/src/main.rs), write the marker after harness selection and
    before verification starts. Build the run context once and use it for the marker and the final
    document.
  • Use the same atomic write as the final document (write_json_atomically), including the mode
    handling for an existing file. A failed marker write stops the run.
  • Follow the RFC presence matrix: the marker has the pre-verification fields and
    run_state: "INCOMPLETE", and no outcome, wall_time_s, summary or harnesses.
  • Tests: a killed run leaves the marker; a normal run replaces it; a bad export path stops the run
    before verification; a rejected harness filter leaves an earlier file unchanged.

A failure before harness selection (for example, a build error) still leaves an earlier file in
place; the docs should say so.

Activity

  1. added
    [C] Feature / Enhancement
    on Nov 6, 2026
  2. added a commit that references this issue on Nov 10, 2026
    e08fef2
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    [C] Feature / Enhancement

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions