Cotal TypeScript packages
    Preparing search index...

    Type Alias LookupVerdict

    LookupVerdict:
        | { verdict: "miss" }
        | { entry: JournalEntry; verdict: "replay" }
        | { entry: JournalEntry; verdict: "replay-failed" }
        | { entry: JournalEntry; verdict: "replay-cancelled" }
        | { entry: JournalEntry; verdict: "refused" }
        | { entry: JournalEntry; verdict: "pending" }
        | {
            entry: JournalEntry;
            programHash: string;
            recordedHash: string;
            verdict: "diverged";
        }

    What the interpreter should do when it reaches an effect.

    Type Declaration

    • { verdict: "miss" }

      Nothing recorded: perform the effect live.

    • { entry: JournalEntry; verdict: "replay" }

      Recorded and successful: return the result, perform nothing.

    • { entry: JournalEntry; verdict: "replay-failed" }

      Recorded as failed: throw the recorded error, perform nothing.

    • { entry: JournalEntry; verdict: "replay-cancelled" }

      Recorded as cancelled: re-raise cancellation in this branch.

    • { entry: JournalEntry; verdict: "refused" }

      Recorded as refused: no host could perform it yet. Perform it live, as a fresh attempt.

    • { entry: JournalEntry; verdict: "pending" }

      Started but never settled: re-bind to entry.external and await its terminal.

    • {
          entry: JournalEntry;
          programHash: string;
          recordedHash: string;
          verdict: "diverged";
      }

      Recorded with different inputs: abort, mutate nothing, and report the diff.