)]}'
{
  "commit": "381dfc3aae6cf185d12bf54691ce5f1d19aeb69d",
  "tree": "8661da9633432fc63fbe88abb73b11803f16dd8c",
  "parents": [
    "9a739a4fd38f9da8bd3e3141fc4782bb2706bb4f"
  ],
  "author": {
    "name": "Fabian Meumertzheim",
    "email": "fabian@meumertzhe.im",
    "time": "Wed Aug 12 19:15:04 2026 +0200"
  },
  "committer": {
    "name": "GitHub",
    "email": "noreply@github.com",
    "time": "Wed Aug 12 13:15:04 2026 -0400"
  },
  "message": "Prefer the runfiles manifest over the runfiles directory (#68)\n\n`runfiles_rlocation_checked` looked up a path in the runfiles directory\nbefore consulting the manifest. Whether the runfiles directory is\npopulated is a property of how the action or test is executed and is not\nknown at analysis time, so the directory may exist while holding the\nstale contents of a previous execution. Consult the manifest first and\nonly fall back to the runfiles directory if no manifest exists.\n\nThis also fixes `runfiles_current_repository` on Windows with\n`--enable_runfiles`. That mode is the only one in which both\n`RUNFILES_DIR` and `RUNFILES_MANIFEST_FILE` are set: Windows does not\nsandbox, so the runfiles tree used at runtime contains the `MANIFEST`\nfile that `runfiles_export_envvars` promotes to\n`RUNFILES_MANIFEST_FILE`. `rlocation` then returned a path inside the\nrunfiles tree, but the manifest maps rlocation paths to the locations of\nthe original files, so the caller could never be the target of a\nmanifest entry and `runfiles_current_repository` reported every caller\nas belonging to the main repository. With the manifest taking\nprecedence, callers are manifest targets again and the lookup succeeds.\n\n`runfiles_current_repository` had no test coverage at all, which is why\nthis went unnoticed. Cover all three combinations of the two envvars:\ndirectory only, manifest only, and both set at the same time. The last\ncase also asserts that a stale copy in the runfiles directory is never\npreferred over the manifest.\n\nFuture work (https://github.com/bazelbuild/bazel/pull/30674) will allow\nthe directory to be used again in both functions, assuming it\u0027s\nmaterialized.",
  "tree_diff": [
    {
      "type": "modify",
      "old_id": "3dfe3e27ded2243c4249ac51f4830a55ccc6455f",
      "old_mode": 33188,
      "old_path": "shell/runfiles/runfiles.bash",
      "new_id": "b6bbdfe40972baccc31a43e46e5dc5804f2d7594",
      "new_mode": 33188,
      "new_path": "shell/runfiles/runfiles.bash"
    },
    {
      "type": "modify",
      "old_id": "f738b3d2cdc7a8abf47a9ca4adcbb88cd7c72e19",
      "old_mode": 33261,
      "old_path": "tests/runfiles/runfiles_test.bash",
      "new_id": "fd60eee1b2c5c209b7fa94a1bcabb2ba6cbf467b",
      "new_mode": 33261,
      "new_path": "tests/runfiles/runfiles_test.bash"
    }
  ]
}
