{
  "schema": 1,
  "sqlstate": "2D000",
  "condition_name": "invalid_transaction_termination",
  "sources": [
    {
      "id": "src.errcodes.18.6",
      "kind": "upstream_source",
      "source_role": "condition_definition",
      "tag": "REL_18_6",
      "commit": "724edf9bde9d356724ad384a2e196edc3c9f80f7",
      "path": "src/backend/utils/errcodes.txt",
      "sha256": "6e8de346643ba84aa3c9c6a73360acfc7b2dfb89162c06c08ce9bf5bcd5bbcba",
      "url": "https://github.com/postgres/postgres/blob/724edf9bde9d356724ad384a2e196edc3c9f80f7/src/backend/utils/errcodes.txt"
    },
    {
      "id": "src.calls.REL_18_6",
      "kind": "local_artifact",
      "source_role": "source_call_scan",
      "sha256": "9ee8a0e81d8f0825c5c1ae45583439859a26e602bdd4ce2f2a62aa278867ccbf"
    },
    {
      "id": "src.spi.18.6",
      "kind": "upstream_source",
      "source_role": "source_path",
      "tag": "REL_18_6",
      "commit": "724edf9bde9d356724ad384a2e196edc3c9f80f7",
      "path": "src/backend/executor/spi.c",
      "sha256": "7244b45f632583c72530832df901b788fe403c8857425dd13edb49d9f84b0c78",
      "url": "https://github.com/postgres/postgres/blob/724edf9bde9d356724ad384a2e196edc3c9f80f7/src/backend/executor/spi.c#L239-L241"
    }
  ],
  "claims": [
    {
      "id": "identity",
      "statement": "2D000 is the invalid_transaction_termination condition in Class 2D.",
      "sources": [
        "src.errcodes.18.6"
      ],
      "method": "Read the fixed errcodes.txt row and macro mapping.",
      "limits": "This records the protocol definition and does not imply a natural PostgreSQL throw path."
    },
    {
      "id": "source-boundary",
      "statement": "invalid transaction termination is a source-confirmed path for 2D000.",
      "sources": [
        "src.spi.18.6",
        "src.calls.REL_18_6"
      ],
      "method": "Trace the fixed source call scan and classify the path before selecting a safe runner case.",
      "limits": "No representative runtime case is claimed; the path requires a specialized internal or trigger/procedure context."
    }
  ],
  "messages": [
    {
      "id": "message.invalid-transaction-termination",
      "sqlstate": "2D000",
      "primary_template": "invalid transaction termination",
      "severity_source": "ERROR",
      "sources": [
        "src.spi.18.6"
      ],
      "limits": "The same source path also emits more specific subtransaction messages."
    },
    {
      "id": "message.commit-subtransaction",
      "sqlstate": "2D000",
      "primary_template": "cannot commit while a subtransaction is active",
      "severity_source": "ERROR",
      "sources": [
        "src.spi.18.6"
      ],
      "limits": "Only the active-subtransaction branch uses this wording."
    },
    {
      "id": "message.rollback-subtransaction",
      "sqlstate": "2D000",
      "primary_template": "cannot roll back while a subtransaction is active",
      "severity_source": "ERROR",
      "sources": [
        "src.spi.18.6"
      ],
      "limits": "Only the active-subtransaction rollback branch uses this wording."
    }
  ],
  "usage_evidence": [
    {
      "scope": "definition-and-source-boundary",
      "status": "source_path_confirmed",
      "evidence_ids": [
        "identity",
        "source-boundary"
      ],
      "notes": "No runtime SQLSTATE observation is selected for this code in batch constraints-transactions-3-4; the page remains not_run."
    }
  ],
  "runtime": []
}
