)]}'
{
  "commit": "112e0613ec3029c1f557e4876b5a38f2a5e14608",
  "tree": "eda5887672cf17890586a54bebf1198c935bcdb6",
  "parents": [
    "5cd6ecd4836ba03a61eff4b70f755b9049cc8a5f"
  ],
  "author": {
    "name": "Robin Lindén",
    "email": "dev@robinlinden.eu",
    "time": "Sun Oct 11 11:56:04 2026 +0000"
  },
  "committer": {
    "name": "GitHub",
    "email": "noreply@github.com",
    "time": "Sun Oct 11 11:56:04 2026 +0000"
  },
  "message": "fix(py_console_script_binary): only create _script_gen for the exec cfg (#4219)\n\nWithout this, `py_console_script_gen` exists for both the target and\nexec config which causes issues when cross-compiling.\n\nI use py_console_script_binary for glad2 which I pass as a tool to a\ngenrule, but starting with rules_python 2.0.0 I get the following error\nwhen e.g. cross-compiling to wasm:\n```\nDEBUG: /home/runner/.cache/bazel/_bazel_runner/a9f0723b1e9e47cd91eaa9d5188be59d/external/rules_python+/python/private/config_settings.bzl:248:14: The current configuration rules_python config flags is:\n    @@rules_python+//python/config_settings:pip_whl_osx_version: \"\"\n    @@rules_python+//python/config_settings:py_freethreaded: \"no\"\n    @@rules_python+//python/config_settings:py_linux_libc: \"glibc\"\n    @@rules_python+//python/config_settings:python_version: \"3.14\"\n\nIf the value is missing, then the default value is being used, see documentation:\nhttps://rules-python.readthedocs.io/en/latest/api/rules_python/python/config_settings\nERROR: /home/runner/.cache/bazel/_bazel_runner/a9f0723b1e9e47cd91eaa9d5188be59d/external/rules_python++pip+hastur_pypi/glad2/BUILD.bazel:6:12: configurable attribute \"actual\" in @@rules_python++pip+hastur_pypi//glad2:_no_matching_repository doesn\u0027t match this configuration: No matching wheel for current configuration\u0027s Python version and platform.\n\nThe current build configuration\u0027s Python version doesn\u0027t match any of the Python\nwheels available for this distribution. This distribution supports the following Python\nconfiguration settings:\n    //_config:is_cp314_linux_x86_64\n\nAs configured by the `pip.parse.target_platforms` attribute. Note that\n`requirements_by_platform` only affects the Bazel host platform unless\n`target_platforms` is also set.\n\nTo determine the current configuration\u0027s Python version, run:\n    `bazel config \u003cconfig id\u003e` (shown further below)\n\nFor the current configuration value see the debug message above that is\nprinting the current flag values. If you can\u0027t see the message, then re-run the\nbuild to make it a failure instead by running the build with:\n    --@@rules_python+//python/config_settings:current_config\u003dfail\n\nHowever, the command above will hide the `bazel config \u003cconfig id\u003e` message.\n\n\nThis instance of @@rules_python++pip+hastur_pypi//glad2:_no_matching_repository has configuration identifier 98696d4. To inspect its configuration, run: bazel config 98696d4.\n\nFor more help, see https://bazel.build/docs/configurable-attributes#faq-select-choose-condition.\n```\n\nWith this change, Bazel seems happy to only run the\n`py_console_script_gen` bits for the exec config and my\ncross-compilation works again.\n\n---------\n\nCo-authored-by: Ignas Anikevicius \u003c240938+aignas@users.noreply.github.com\u003e",
  "tree_diff": [
    {
      "type": "add",
      "old_id": "0000000000000000000000000000000000000000",
      "old_mode": 0,
      "old_path": "/dev/null",
      "new_id": "bf20cf30531bd11a6f16d6e638695bde3d340d55",
      "new_mode": 33188,
      "new_path": "news/4219.changed.md"
    },
    {
      "type": "modify",
      "old_id": "de016036b26b3b8228c409efd1a20a0146d39674",
      "old_mode": 33188,
      "old_path": "python/private/py_console_script_gen.bzl",
      "new_id": "091193d410ca481f68d2373c5dea87ed699d8de3",
      "new_mode": 33188,
      "new_path": "python/private/py_console_script_gen.bzl"
    }
  ]
}
