)]}'
{
  "commit": "7896f7318db92b525ba2cdbd446301e464943b4c",
  "tree": "5e6a4bd2fb59b582a142fc2f38453f51865ca7a1",
  "parents": [
    "accb2deae5f74bf5ce104ab4a4088bb852a0d740"
  ],
  "author": {
    "name": "Malte Poll",
    "email": "1780588+malt3@users.noreply.github.com",
    "time": "Tue May 05 08:31:32 2026 -0700"
  },
  "committer": {
    "name": "Copybara-Service",
    "email": "copybara-worker@google.com",
    "time": "Tue May 05 08:33:28 2026 -0700"
  },
  "message": "{r,m}ctx.download*: report size of downloaded file (https://github.com/bazelbuild/bazel/pull/29463)\n\n### Description\n\nAdds a new structure field `size_bytes` in the return value of `rctx.download` (and friends) containing the file size of the downloaded file.\n\n### Motivation\n\nThis is a useful piece of metadata Bazel provides to repository rules and module extensions. Motivation for adding this: I need the ability to annotate BUILD files with sizes of downloaded files in rules_runfiles_group (https://github.com/hermeticbuild/rules_runfiles_group). This makes it possible to merge runfiles groups based on their \"weight\", which may include actual file sizes of *_import targets (java_import, cc_import, ...).\n\n### Build API Changes\n\nIt does affect the Build API, but is backwards compatible (adding a new field).\nExisting users will not be impacted.\n\n### Checklist\n\n- [x] I have added tests for the new use cases (if any).\n- [x] I have updated the documentation (if applicable).\n\n### Release Notes\n\nRELNOTES[NEW]: {r,m}ctx.download* report the size of downloaded files\nRELNOTES: Addition to the user-facing Build API\n\nCloses #29463.\n\nPiperOrigin-RevId: 910706646\nChange-Id: I980cdee803810e1fb6222f69782fcad2648af68d\n",
  "tree_diff": [
    {
      "type": "modify",
      "old_id": "fa57460e5da168ee4a35b5a6d32ff5d8a4fdd12f",
      "old_mode": 33188,
      "old_path": "src/main/java/com/google/devtools/build/lib/bazel/repository/starlark/StarlarkBaseExternalContext.java",
      "new_id": "19f6f27299b678699305d4bf3f8c06ec4bae0451",
      "new_mode": 33188,
      "new_path": "src/main/java/com/google/devtools/build/lib/bazel/repository/starlark/StarlarkBaseExternalContext.java"
    },
    {
      "type": "modify",
      "old_id": "a3cd07ded56a2db0dac69a49fd06e3e34ad36258",
      "old_mode": 33188,
      "old_path": "src/test/java/com/google/devtools/build/lib/bazel/repository/starlark/StarlarkBaseExternalContextTest.java",
      "new_id": "be25dc062c0b7602eccf7807f61c85b8d2c90ad0",
      "new_mode": 33188,
      "new_path": "src/test/java/com/google/devtools/build/lib/bazel/repository/starlark/StarlarkBaseExternalContextTest.java"
    }
  ]
}
