{
  "schema_version": "1.0.0",
  "record_id": "dn-next42-20261205-q35",
  "record_version": "1.0.0",
  "title": "A batch of blockchain calls is not automatically one atomic transaction",
  "canonical_url": "https://decentralised.news/rpc-batch-wallet-calls-atomicity-failure-boundary",
  "evidence_type": "documentary_analysis_with_synthetic_worked_example",
  "source_review_date": "2026-12-05",
  "last_verified_utc": null,
  "observation_window": null,
  "methodology_url": "https://decentralised.news/rpc-batch-wallet-calls-atomicity-failure-boundary",
  "methodology_version": "1.0.0",
  "input_schema": {
    "columns": [
      "scenario",
      "initial_allowance_token_units",
      "final_allowance_token_units",
      "initial_balance_token_units",
      "final_balance_token_units",
      "completed_spend_token_units",
      "allowance_change_token_units"
    ],
    "rows_file": "https://decentralised.news/data/dn-next42-20261205/v1/q35.csv"
  },
  "units": {
    "definition": "Units are named in the CSV columns, manuscript and calculation labels. Do not combine quantities without resolving their dimensions."
  },
  "sources": [
    {
      "id": 1,
      "title": "JSON-RPC 2.0 specification: Batch",
      "url": "https://www.jsonrpc.org/specification",
      "reviewDate": "2026-12-05",
      "supports": "Batch request processing can be concurrent and unordered; responses are matched by ID rather than position.",
      "evidenceType": "Protocol specification"
    },
    {
      "id": 2,
      "title": "EIP-5792: Wallet Call API",
      "url": "https://eips.ethereum.org/EIPS/eip-5792",
      "reviewDate": "2026-12-05",
      "supports": "wallet_sendCalls atomicRequired semantics, capabilities and batch status distinctions.",
      "evidenceType": "Protocol specification"
    },
    {
      "id": 3,
      "title": "Multicall3 aggregate3 implementation",
      "url": "https://github.com/mds1/multicall3/blob/main/src/Multicall3.sol",
      "reviewDate": "2026-12-05",
      "supports": "Per-call allowFailure controls reversion and result flags; calls use ordinary CALL context.",
      "evidenceType": "Primary implementation"
    }
  ],
  "calculations": [
    {
      "label": "Unexpected retained permission",
      "expression": "500-50",
      "expected": 450
    },
    {
      "label": "Allowance after successful spend",
      "expression": "500-300",
      "expected": 200
    },
    {
      "label": "Wallet balance after spend",
      "expression": "1000-300",
      "expected": 700
    },
    {
      "label": "Atomic permission change after failure",
      "expression": "50-50",
      "expected": 0
    }
  ],
  "example": {
    "synthetic": true,
    "description": "Original DN synthetic worked example. All scenario inputs are hypothetical; no live transaction, return, quote or account is represented. Distinguish RPC batching, wallet atomicRequired and per-call allowFailure using a synthetic permission-and-balance ledger.",
    "rows": [
      [
        "atomic_second_call_failure",
        50,
        50,
        1000,
        1000,
        0,
        0
      ],
      [
        "partial_approval_survives",
        50,
        500,
        1000,
        1000,
        0,
        450
      ],
      [
        "both_succeed_assumed_allowance_consumption",
        50,
        200,
        1000,
        700,
        300,
        150
      ]
    ]
  },
  "limitations": [
    "Examples use declared invented inputs, not observed fills, customer outcomes, provider rankings or predictive backtests.",
    "Source-review date is not a measurement time, publication date of the source or assurance that terms will remain current.",
    "Documentation does not establish individual access, legal eligibility, service reliability or investment suitability."
  ],
  "falsification_or_recheck_triggers": [
    "Changed governing document or applicable software version.",
    "Evidence of different account, product, timing, unit or legal-entity scope.",
    "An arithmetic error or reproducible counterexample to the stated mechanism."
  ],
  "rights": {
    "original_DN_analysis": "Cite Decentralised News, the canonical URL and record version when reusing this worked example.",
    "third_party_sources": "Third-party material remains subject to its original terms. Linking does not grant redistribution rights."
  },
  "commercial_disclosure": "This article includes a link to DN’s own separately scoped research service. No provider purchase is required to use the example.",
  "corrections": []
}
