)]}'
{
  "commit": "ea4714d33adb82c68739bdfd74038faa4d60b061",
  "tree": "15a2d8023fc0a8a514ffccb8d0f8b888a4a497e4",
  "parents": [
    "ee8d7d618cff43811779bb710d330ccd9bd577f2"
  ],
  "author": {
    "name": "Philipp Schrader",
    "email": "philipp.schrader@gmail.com",
    "time": "Thu May 15 19:11:34 2025 -0700"
  },
  "committer": {
    "name": "GitHub",
    "email": "noreply@github.com",
    "time": "Fri May 16 02:11:34 2025 +0000"
  },
  "message": "feat: Add support for REPLs (#2723)\n\nThis patch adds a new target that lets users invoke a REPL for a given\n`PyInfo` target.\n\nFor example, the following command will spawn a REPL for any target\nthat provides `PyInfo`:\n```console\n$ bazel run --//python/config_settings:bootstrap_impl\u003dscript //python/bin:repl --//python/bin:repl_dep\u003d//tools:wheelmaker\nPython 3.11.1 (main, Jan 16 2023, 22:41:20) [Clang 15.0.7 ] on linux\nType \"help\", \"copyright\", \"credits\" or \"license\" for more information.\n(InteractiveConsole)\n\u003e\u003e\u003e import tools.wheelmaker\n\u003e\u003e\u003e\n```\n\nIf the user wants an IPython shell instead, they can create a file like\nthis:\n```python\nimport IPython\nIPython.start_ipython()\n```\nThen they can set this up in their `.bazelrc` file:\n```\n# Allow the REPL stub to import ipython. In this case, @my_deps is the name\n# of the pip.parse() repository.\nbuild --@rules_python//python/bin:repl_stub_dep\u003d@my_deps//ipython\n# Point the REPL at the stub created above.\nbuild --@rules_python//python/bin:repl_stub\u003d//path/to:ipython_stub.py\n```\n\n---------\n\nCo-authored-by: Ignas Anikevicius \u003c240938+aignas@users.noreply.github.com\u003e",
  "tree_diff": [
    {
      "type": "modify",
      "old_id": "94487219bc6d77defcc6a060455246e6c5fb3eba",
      "old_mode": 33188,
      "old_path": "CHANGELOG.md",
      "new_id": "a6ba65eb2ffd831e31dca632637cda3b2cd8b2e0",
      "new_mode": 33188,
      "new_path": "CHANGELOG.md"
    },
    {
      "type": "modify",
      "old_id": "b10b4459832e0e66095fac985107c9cfb7b55e91",
      "old_mode": 33188,
      "old_path": "docs/index.md",
      "new_id": "285b1cd66e2aedc4fb2043cc4a4a3f56d74d4054",
      "new_mode": 33188,
      "new_path": "docs/index.md"
    },
    {
      "type": "add",
      "old_id": "0000000000000000000000000000000000000000",
      "old_mode": 0,
      "old_path": "/dev/null",
      "new_id": "edcf37e811415853f04b36ec07b7dade5cebc1c4",
      "new_mode": 33188,
      "new_path": "docs/repl.md"
    },
    {
      "type": "modify",
      "old_id": "c8305e8f0d26411839cb7b13b2ad50deca2e69d5",
      "old_mode": 33188,
      "old_path": "docs/toolchains.md",
      "new_id": "121b398f7aafd794b0a20512e27c6998dfcc52aa",
      "new_mode": 33188,
      "new_path": "docs/toolchains.md"
    },
    {
      "type": "modify",
      "old_id": "57bee343788d8226736a8814b54b059732214919",
      "old_mode": 33188,
      "old_path": "python/bin/BUILD.bazel",
      "new_id": "30af7d1b9fa98713fddcc5ddff1c96c46b48e904",
      "new_mode": 33188,
      "new_path": "python/bin/BUILD.bazel"
    },
    {
      "type": "add",
      "old_id": "0000000000000000000000000000000000000000",
      "old_mode": 0,
      "old_path": "/dev/null",
      "new_id": "86452aa8693dad89e5a3509e43b25c149b16f87f",
      "new_mode": 33188,
      "new_path": "python/bin/repl_stub.py"
    },
    {
      "type": "modify",
      "old_id": "0b50ccf0b7542bdfe2e1913586ecf72e2ffd76f6",
      "old_mode": 33188,
      "old_path": "python/private/BUILD.bazel",
      "new_id": "ce224213000129e9d6624183a1889ff3f7bc5b68",
      "new_mode": 33188,
      "new_path": "python/private/BUILD.bazel"
    },
    {
      "type": "add",
      "old_id": "0000000000000000000000000000000000000000",
      "old_mode": 0,
      "old_path": "/dev/null",
      "new_id": "838166a187fdf281ccb7d9aa6ef8f7f14f6689af",
      "new_mode": 33188,
      "new_path": "python/private/repl.bzl"
    },
    {
      "type": "add",
      "old_id": "0000000000000000000000000000000000000000",
      "old_mode": 0,
      "old_path": "/dev/null",
      "new_id": "0e058b23aec458dfa3d3710211bdccf53057d54d",
      "new_mode": 33188,
      "new_path": "python/private/repl_template.py"
    },
    {
      "type": "add",
      "old_id": "0000000000000000000000000000000000000000",
      "old_mode": 0,
      "old_path": "/dev/null",
      "new_id": "62c7377d533f7a72913aeb5b71d8491cb2a1657f",
      "new_mode": 33188,
      "new_path": "tests/repl/BUILD.bazel"
    },
    {
      "type": "add",
      "old_id": "0000000000000000000000000000000000000000",
      "old_mode": 0,
      "old_path": "/dev/null",
      "new_id": "0c4a309b01473f8424cc74b029a2f519097b4bcc",
      "new_mode": 33188,
      "new_path": "tests/repl/helper/test_module.py"
    },
    {
      "type": "add",
      "old_id": "0000000000000000000000000000000000000000",
      "old_mode": 0,
      "old_path": "/dev/null",
      "new_id": "51ca95111052e803aad4f2ae5848594e59410ed0",
      "new_mode": 33188,
      "new_path": "tests/repl/repl_test.py"
    },
    {
      "type": "modify",
      "old_id": "9c8134ff40e310a67f4425616791685169267b68",
      "old_mode": 33188,
      "old_path": "tests/support/sh_py_run_test.bzl",
      "new_id": "f6ebc506cc15d8e77769d7b4838567a80b300b00",
      "new_mode": 33188,
      "new_path": "tests/support/sh_py_run_test.bzl"
    }
  ]
}
