Marmot-TS
    Preparing search index...

    Type Alias AppliedForkResolution<TEnvelope>

    AppliedForkResolution:
        | {
            invalidated: {
                commitDigest?: Uint8Array;
                envelope: TEnvelope;
                epoch: number;
                message: MlsMessage;
                payload: Uint8Array;
                rumorId?: string;
                tag: string;
                transportId?: string;
            }[];
            notifications: StateNotification[]
            | undefined;
            outcome: "recovered";
            rejected?: RejectedForkCandidate[];
            result: ProcessMessageResult;
            selectedTerminal?: DisbandCandidateEvidence;
            tipCommitMessage: MlsMessage | undefined;
            withdrawnNotifications: StateNotification[];
        }
        | { outcome: "superseded"
        | "skip"; rejected?: RejectedForkCandidate[] }

    The applied outcome of a fork resolution, as the ingest loop consumes it.

    Type Parameters

    • TEnvelope

    Type Declaration

    • {
          invalidated: {
              commitDigest?: Uint8Array;
              envelope: TEnvelope;
              epoch: number;
              message: MlsMessage;
              payload: Uint8Array;
              rumorId?: string;
              tag: string;
              transportId?: string;
          }[];
          notifications: StateNotification[]
          | undefined;
          outcome: "recovered";
          rejected?: RejectedForkCandidate[];
          result: ProcessMessageResult;
          selectedTerminal?: DisbandCandidateEvidence;
          tipCommitMessage: MlsMessage | undefined;
          withdrawnNotifications: StateNotification[];
      }
      • invalidated: {
            commitDigest?: Uint8Array;
            envelope: TEnvelope;
            epoch: number;
            message: MlsMessage;
            payload: Uint8Array;
            rumorId?: string;
            tag: string;
            transportId?: string;
        }[]

        App payloads abandoned by the rewind, to report as invalidated (M7). Each carries the fork node (tag/epoch) it had decrypted against so the retraction names its losing branch.

      • notifications: StateNotification[] | undefined

        The StateNotifications derived from the WHOLE applied winner chain (D-10/D-11) — one derivation per ChainLink, in chain order, concatenated. A rewind that adopts an N-commit branch applies N commits, so reporting only the tip's diff would silently drop every intermediate commit's membership/component changes (CR-07). Each entry stays attributed to the commit digest that produced it, so the caller can still group by commit.

        Computed and ledger-recorded by #applyForkResolution — the same shared rewind-apply path used by both pool-replay recovery and tree-fed re-convergence — so every one of them is withdrawable by a later rewind. undefined when the winner tip is the fork root itself (no chain applied, mirroring tipCommitMessage).

      • outcome: "recovered"
      • Optionalrejected?: RejectedForkCandidate[]

        Pooled candidates refused against their parent (WR-01), reported as rejected rather than past-epoch.

      • result: ProcessMessageResult
      • OptionalselectedTerminal?: DisbandCandidateEvidence

        Present only when canonical selection chose authenticated disband evidence.

      • tipCommitMessage: MlsMessage | undefined

        The winning branch's tip commit MLS message, when the winner chain applied at least one commit to reach it (D-10/D-12) — lets the ingest loop attribute a selfRemoved notification to the exact commit that produced the removedFromGroup tombstone when the rewind lands on it. undefined only when the winner tip is the fork root itself (no chain applied), which never coincides with a fresh removal.

      • withdrawnNotifications: StateNotification[]

        Notifications withdrawn because the commit(s) that produced them were superseded by this rewind (D-11, CONV-03). Flat — not yet grouped by producing commit digest; the caller groups via groupWithdrawnNotificationsByCommit before yielding stateInvalidated results, since a rewind may supersede more than one commit at once.

    • { outcome: "superseded" | "skip"; rejected?: RejectedForkCandidate[] }