)]}'
{
  "commit": "1f3d46a3893dec31fabe05e931011e3653e044a9",
  "tree": "5bc075de45177f540e4af19c644282ee00b05931",
  "parents": [
    "c68d56a943c7796cffc4853f3bedc7262b7c5da0"
  ],
  "author": {
    "name": "Henry Schreiner",
    "email": "HenrySchreinerIII@gmail.com",
    "time": "Sun Nov 15 23:07:50 2026 -0500"
  },
  "committer": {
    "name": "GitHub",
    "email": "noreply@github.com",
    "time": "Sun Nov 15 20:07:50 2026 -0800"
  },
  "message": "fix(stl): determine the sequence length only once in array_caster (#6278)\n\n* fix(stl): determine the sequence length only once in array_caster\n\nThe element loops of `array_caster` asked the sequence for its length\nmore than once: one time to size the storage, and again for the end of\nthe iteration. A sequence that reports different lengths could cause\nout-of-bounds accesses (a write for `std::valarray`, a read for\n`std::array`).\n\nThe loops now read the length one time and index up to it.\n\nAssisted-by: ClaudeCode:claude-fable-5-2\n\n* fix(stl): construct each element caster before its item is fetched\n\nThis keeps the order that the loops had when they iterated over the\nsequence.\n\nAssisted-by: ClaudeCode:claude-fable-5-2",
  "tree_diff": [
    {
      "type": "modify",
      "old_id": "0790074534792913759397f8d28d95c15d72b7ba",
      "old_mode": 33188,
      "old_path": "include/pybind11/stl.h",
      "new_id": "b73d0e95b2c82d27b31c521b9146148f41a831e7",
      "new_mode": 33188,
      "new_path": "include/pybind11/stl.h"
    },
    {
      "type": "modify",
      "old_id": "b5d1979d04e31dc145b47da015c065adeb113902",
      "old_mode": 33188,
      "old_path": "tests/test_stl.cpp",
      "new_id": "9306b20670a5bacfdf406801b751c84ac08e9e11",
      "new_mode": 33188,
      "new_path": "tests/test_stl.cpp"
    },
    {
      "type": "modify",
      "old_id": "32ee539f505adc77c1b7e964b71c17a460f20779",
      "old_mode": 33188,
      "old_path": "tests/test_stl.py",
      "new_id": "7c1f76daa6072a83631b95f25d0525d219d7eeb0",
      "new_mode": 33188,
      "new_path": "tests/test_stl.py"
    }
  ]
}
