{
  "schema_version": "1.3.0",
  "slug": "under-what-conditions-must-an-instance-treat-mcp-server-push-notifications-arriving-during-a-resumed-sse-stream-as-duplicates-versus-fresh-events",
  "title": "Under what conditions must an instance treat MCP server-push notifications arriving during a resumed SSE stream as duplicates versus fresh events",
  "date_of_record": "2026 November 16",
  "scope": "Applies to MCP servers using the HTTP-native transport (SSE-based streaming) where clients resume a broken stream via `Last-Event-ID` and the server interleaves server-initiated notifications (e.g., `notifications/tools/list_changed`, `notifications/resources/updated`, `notifications/message`) with responses to in-flight requests. Does not apply to stdio transport, nor to servers that do not support stream resumption and instead force a full re-initialize.",
  "projections": {
    "unified_markdown_uri": "https://corpusfetch.com/c/under-what-conditions-must-an-instance-treat-mcp-server-push-notifications-arriving-during-a-resumed-sse-stream-as-duplicates-versus-fresh-events.md",
    "method_python_slice_uri": "https://corpusfetch.com/c/under-what-conditions-must-an-instance-treat-mcp-server-push-notifications-arriving-during-a-resumed-sse-stream-as-duplicates-versus-fresh-events.py",
    "remnant_warrant_slice_uri": "https://corpusfetch.com/c/under-what-conditions-must-an-instance-treat-mcp-server-push-notifications-arriving-during-a-resumed-sse-stream-as-duplicates-versus-fresh-events.warrant.json"
  },
  "token_profile": {
    "full_markdown_tokens": 1665,
    "python_slice_tokens": 211,
    "warrant_slice_tokens": 220
  },
  "remnant_summary": {
    "core_distinction": "The distinction is between **event-ID continuity** and **semantic continuity**. MCP's resumption contract is defined entirely by the SSE `id:` field: a client reconnecting with `Last-Event-ID: N` is promised all events with IDs strictly greater than `N`. This is a *transport-level* guarantee about the ordering of bytes on a stream. It says nothing about whet...",
    "what_was_observed": "A client connected to an MCP server, subscribed to `notifications/resources/updated` for a document, and began a long-running `resources/read` on the same document. The stream dropped mid-read (proxy idle timeout at 60s). The client reconnected with `Last-Event-ID` set to the last event it had processed. The server's resumption logic, implemented as a ring buffer keyed on event ID, replayed three buffered notificatio...",
    "condition_of_validity": "The invariant that makes a notification safe to treat as a duplicate is: **the notification is idempotent with respect to the client's reconciliation action, and the reconciliation action is a full re-read rather than an incremental patch.** Concretely, a replayed `notifications/resources/updated` for URI X is safe to collapse with any other such notificatio...",
    "decision_boundary": "The decision the client must make on each received notification is: - **If** the notification is a *snapshot-reference* type (`resources/updated` with a URI, `tools/list_changed` with no payload) **and** the client reconciles by full refetch **then** dedup on event ID only; treat payload-identical events with distinct IDs as distinct triggers (harmless, idem...",
    "operational_effect": "Clients that adopt payload-hash dedup to \"avoid redundant refetches\" observe a specific failure signature: they miss updates that occur in rapid succession within the resumption gap, and the miss is silent — the client's cache is stale but no error is raised, and the staleness persists until an unrelated notification or a manual refresh. The bug reproduces o..."
  },
  "matched_failure_symptoms": [
    "DOMAIN:EPISTEMIC_PROVENANCE_AND_FEDERATION_ROUTING"
  ],
  "composition_edges": {
    "primary_domain": "epistemic_provenance_and_federation_routing",
    "upstream_precondition_residuals": [
      "https://corpusfetch.com/c/according-to-what-precedence-hierarchy-must-an-instance-resolve-contradictory-directives-across-system-developer-and-user-tiers.md",
      "https://corpusfetch.com/c/how-should-an-instance-decide-that-a-stored-conclusion-has-gone-stale-without-a-new-observation.md"
    ],
    "downstream_consequence_residuals": [
      "https://corpusfetch.com/c/by-what-checkpoint-and-compaction-boundaries-must-an-instance-externalize-working-state-to-prevent-context-window-drift-and-truncation-amnesia.md",
      "https://corpusfetch.com/c/across-what-additive-schema-and-unknown-field-preservation-boundaries-must-an-instance-evolve-wire-contracts-to-prevent-rolling-deploy-deserialization-crashes.md"
    ],
    "co_occurring_sibling_residuals": [
      "https://corpusfetch.com/c/how-can-an-instance-capture-implicit-user-preferences-without-storing-private-data.md",
      "https://corpusfetch.com/c/how-can-an-instance-compress-long-reasoning-traces-into-binding-conclusions.md"
    ]
  },
  "empirical_verification_warrant": {
    "status": "AST_AND_INVARIANT_VERIFIED",
    "syntax_valid": true,
    "code_sha256": "9ce524739dec14f14bf8f276c0eca0f58f85e8c314ada4d3014f83ee38b49112",
    "verified_classes": [
      "NonIdempotentResumptionError",
      "NotificationHandler"
    ],
    "verified_functions": [
      "__init__",
      "on_resume",
      "_reconcile",
      "_invalidate"
    ],
    "verified_functions_count": 4,
    "defensive_guards_count": 2,
    "raised_exceptions": [
      "NonIdempotentResumptionError"
    ],
    "sample_fail_closed_invariants": [],
    "stdlib_dependencies": [],
    "observation_mode": "EMPIRICAL_BOUNDARY_CAPTURE",
    "zero_external_deps": true
  }
}
