{
 "number": 36686,
 "input_hash": "a9119627f87e4726",
 "model": "ledger",
 "prompt_hash": null,
 "created": "2026-11-02T01:11:51+00:00",
 "result": {
  "summary": "Extends the `checktxinputs_invalid_transactions_test` helper in `transaction_tests.cpp` to support transactions with multiple inputs. Adds a test case where two inputs are individually valid under `MoneyRange` but their sum exceeds `MAX_MONEY`. This verifies that `Consensus::CheckTxInputs` rejects transactions whose cumulative input values exceed consensus limits.",
  "problem": "Existing unit tests for `Consensus::CheckTxInputs` only tested single-input transactions where `coin.out.nValue == nValueIn`. Consequently, mutations or bugs in the cumulative value check `!MoneyRange(nValueIn)` (such as switching `||` to `&&` in the out-of-range condition) passed unit tests undetected.",
  "card": "This PR updates CheckTxInputs unit tests to support multiple inputs and adds a test case where individually valid input amounts exceed MAX_MONEY when summed. Previously, unit tests only checked single-input transactions, leaving a mutation that changes the out-of-range check from logical OR to logical AND undetected. The change is restricted to transaction unit tests.",
  "evidence": [
   "PR description points to MutantHub mutant #275 showing `if (!MoneyRange(coin.out.nValue) || !MoneyRange(nValueIn))` mutated to `&&` survived the test suite."
  ],
  "scope_notes": "",
  "changed_since_previous": "No changes; diff matches the previously described implementation.",
  "thread": {
   "last_event_at": "2026-11-01T09:06:21Z",
   "events": 5,
   "head_sha": "133714d1695bc40277b213afd252c3e320cac73e",
   "schema_floor": 2,
   "schema": 2
  },
  "waiting_on": [
   {
    "at": "2026-11-01",
    "id": "rc:4434999674",
    "on": "author",
    "url": "https://github.com/bitcoin/bitcoin/pull/36686#discussion_r4434999674",
    "what": "mercie-ux's optional suggestion regarding adding a case for the per-coin check"
   }
  ],
  "risk": {
   "level": "low",
   "touches": [
    "tests"
   ],
   "why": "Touches only unit tests in transaction_tests.cpp."
  },
  "discussion": {
   "author_status": "last statement processed 2026-11-01",
   "open_concerns": [
    "mercie-ux: add a test case for the per-coin check"
   ],
   "resolved_concerns": [
    "ValeraFinebits: use output_value = 1 so the mutant passes the fee check and incorrectly returns true, catching erroneous acceptance directly (answered by KY-U 2026-10-29)",
    "ValeraFinebits: keep the zero-output case and add a separate case with output_value = 1 to verify error precedence (answered by KY-U 2026-10-29)"
   ]
  },
  "reviewability": {
   "state": "Ready",
   "label": "Ready",
   "reason": "Nothing known that would invalidate a review now."
  },
  "agreement": {
   "state": "Strong",
   "summary": "Strong: substantive support, no open objection (mercie-ux)",
   "reason": "Added support ACK and suggestion for per-coin check coverage from mercie-ux.",
   "evidence": [
    "mercie-ux (suggestion, approach, must be answered, open): add a test case for the per-coin check",
    "mercie-ux: ACK \u2014 Verified the mutant is killed"
   ],
   "objections": [
    {
     "reviewer": "ValeraFinebits",
     "association": "NONE",
     "type": "suggestion",
     "kind": "approach",
     "harm": "",
     "request": "use output_value = 1 so the mutant passes the fee check and incorrectly returns true, catching erroneous acceptance directly",
     "question": "",
     "text": "use output_value = 1 so the mutant passes the fee check and incorrectly returns true, catching erroneous acceptance directly",
     "clears_with": "answer",
     "blocking": false,
     "status": "answered",
     "status_note": "author adopted the suggestion to change output_value to 1",
     "cleared": true,
     "author_replied": true,
     "others_replied": false,
     "fix_pushed": false,
     "replies": [
      "rc:4414167199"
     ],
     "evidence": "2026-10-29: 'Optional: use `output_value = 1` here so the `||` -> `&&` mutant passes the fee check and incorrectly returns `true`.'",
     "url": "https://github.com/bitcoin/bitcoin/pull/36686#discussion_r4412916786",
     "id": "rc:4412916786",
     "at": "2026-10-29",
     "status_at": "2026-10-29",
     "status_by": "KY-U",
     "resolution_evidence": "2026-10-29: KY-U: 'Changed the output value to 1 as suggested in the first comment.'",
     "pin": null,
     "from_schema": 2
    },
    {
     "reviewer": "ValeraFinebits",
     "association": "NONE",
     "type": "suggestion",
     "kind": "approach",
     "harm": "",
     "request": "keep the zero-output case and add a separate case with output_value = 1 to verify error precedence",
     "question": "",
     "text": "keep the zero-output case and add a separate case with output_value = 1 to verify error precedence",
     "clears_with": "answer",
     "blocking": false,
     "status": "answered",
     "status_note": "author preferred modifying the existing case to keep new tests minimal",
     "cleared": true,
     "author_replied": true,
     "others_replied": false,
     "fix_pushed": false,
     "replies": [
      "rc:4414167199"
     ],
     "evidence": "2026-10-29: 'Or we could keep the zero-output case and add another with `output_value = 1`.'",
     "url": "https://github.com/bitcoin/bitcoin/pull/36686#discussion_r4412967818",
     "id": "rc:4412967818",
     "at": "2026-10-29",
     "status_at": "2026-10-29",
     "status_by": "KY-U",
     "resolution_evidence": "2026-10-29: KY-U: 'I'd prefer to change the existing case rather than add another one'",
     "pin": null,
     "from_schema": 2
    },
    {
     "reviewer": "mercie-ux",
     "association": "CONTRIBUTOR",
     "type": "suggestion",
     "kind": "approach",
     "harm": "",
     "request": "add a test case for the per-coin check",
     "question": "",
     "text": "add a test case for the per-coin check",
     "clears_with": "answer",
     "blocking": false,
     "status": "open",
     "status_note": "",
     "cleared": false,
     "author_replied": false,
     "others_replied": false,
     "fix_pushed": false,
     "replies": [],
     "evidence": "2026-11-01: 'Could add a case for the per-coin check too, removing it currently doesn't break any test.'",
     "url": "https://github.com/bitcoin/bitcoin/pull/36686#discussion_r4434999674",
     "id": "rc:4434999674",
     "at": "2026-11-01",
     "status_at": null,
     "status_by": null,
     "resolution_evidence": "",
     "pin": null,
     "from_schema": 2
    }
   ],
   "support": [
    {
     "reviewer": "mercie-ux",
     "reason": "Verified the mutant is killed",
     "substantive": true,
     "verdict": "ACK",
     "id": "r:5727312289",
     "url": "https://github.com/bitcoin/bitcoin/pull/36686#pullrequestreview-5727312289",
     "at": "2026-11-01",
     "association": "CONTRIBUTOR",
     "evidence": "tested",
     "areas": []
    }
   ],
   "participants": [
    {
     "login": "ValeraFinebits",
     "stance": "neutral",
     "note": "suggested setting output_value = 1 or adding a second case to check erroneous acceptance directly",
     "association": "NONE",
     "comments": 2,
     "first": "2026-10-29",
     "last": "2026-10-29"
    },
    {
     "login": "mercie-ux",
     "stance": "support",
     "note": "ACKed after verifying the mutant is killed; optionally suggested covering per-coin check",
     "association": "CONTRIBUTOR",
     "comments": 2,
     "first": "2026-11-01",
     "last": "2026-11-01"
    }
   ],
   "derivation": "substantive support, no open objection (mercie-ux)",
   "model_state": null,
   "corrections": [],
   "notes": "Added support ACK and suggestion for per-coin check coverage from mercie-ux."
  },
  "dependencies": {
   "depends_on": [],
   "enables": []
  },
  "categories": [
   {
    "name": "tests",
    "member": true,
    "evidence": "Touches `src/test/transaction_tests.cpp` with the `Tests` label, extending a test helper and unit test coverage for consensus validation.",
    "band": "P3",
    "reason_tag": "test coverage",
    "score": 0.35,
    "factors": {
     "bug_severity": 0,
     "leverage": 0,
     "performance": 0,
     "security_stability": 0,
     "user_value": 0
    },
    "rationale": "Extends unit test coverage for `Consensus::CheckTxInputs` to ensure transactions with cumulative input values exceeding `MAX_MONEY` are rejected. As noted in the description, mutant analysis revealed that changing `||` to `&&` in the `MoneyRange` check survived the test suite, making this a worthwhile addition to consensus test coverage."
   }
  ],
  "confidence": "high",
  "uncertainties": [],
  "needs": []
 },
 "cost_usd": 0.0,
 "source": {
  "record": "2026-11-02T01:11:51+00:00",
  "code": "2026-10-30T01:17:06+00:00",
  "judgments": 1
 }
}