Skip to content

0.38.0

Compare
Choose a tag to compare
@github-actions github-actions released this 08 Nov 00:37
· 42 commits to main since this release
251eb37

For more detailed setup instructions, see https://rules-python.readthedocs.io/en/latest/getting-started.html

Using Bzlmod

Add to your MODULE.bazel file:

bazel_dep(name = "rules_python", version = "0.38.0")

pip = use_extension("@rules_python//python/extensions:pip.bzl", "pip")

pip.parse(
    hub_name = "pip",
    python_version = "3.11",
    requirements_lock = "//:requirements_lock.txt",
)

use_repo(pip, "pip")

Using WORKSPACE

Paste this snippet into your WORKSPACE file:

load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive")

http_archive(
    name = "rules_python",
    sha256 = "ca2671529884e3ecb5b79d6a5608c7373a82078c3553b1fa53206e6b9dddab34",
    strip_prefix = "rules_python-0.38.0",
    url = "https://github.com/bazelbuild/rules_python/releases/download/0.38.0/rules_python-0.38.0.tar.gz",
)

load("@rules_python//python:repositories.bzl", "py_repositories")

py_repositories()

Gazelle plugin

Paste this snippet into your WORKSPACE file:

load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive")
http_archive(
    name = "rules_python_gazelle_plugin",
    sha256 = "ca2671529884e3ecb5b79d6a5608c7373a82078c3553b1fa53206e6b9dddab34",
    strip_prefix = "rules_python-0.38.0/gazelle",
    url = "https://github.com/bazelbuild/rules_python/releases/download/0.38.0/rules_python-0.38.0.tar.gz",
)

# To compile the rules_python gazelle extension from source,
# we must fetch some third-party go dependencies that it uses.

load("@rules_python_gazelle_plugin//:deps.bzl", _py_gazelle_deps = "gazelle_deps")

_py_gazelle_deps()

What's Changed

  • docs: give user-friendly permalinks in changelog by @rickeylev in #2315
  • ci: upgrade to rbe_ubuntu2004 by @rickeylev in #2316
  • chore: set 7.x in bazelversion by @rickeylev in #2317
  • docs: rules_python bzlmod GA and 1.0 prep by @aignas in #2296
  • test(bzlmod): refactor pip_parse to make it more testable by @aignas in #2314
  • build(deps): bump sphinx from 8.0.2 to 8.1.3 in /docs by @dependabot in #2322
  • build(deps): bump charset-normalizer from 3.3.2 to 3.4.0 in /tools/publish by @dependabot in #2323
  • build(deps): bump charset-normalizer from 3.3.2 to 3.4.0 in /docs by @dependabot in #2321
  • docs: fix typo in precompiling docs by @rickeylev in #2324
  • fix(rules): remove rules_python --incompatible_python_disallow_native_rules checking by @rickeylev in #2327
  • fix: fix errors with bazel@head by @rickeylev in #2332
  • docs: update changelog for 0.37.1 by @rickeylev in #2330
  • docs: tell how to setup readthedocs integration with sphinxdocs by @rickeylev in #2331
  • deps: use rules_cc 0.0.13 to support newer bazel versions by @rickeylev in #2335
  • docs: link to main docs in generated release notes by @rickeylev in #2338
  • chore: bump twine dependencies and cleanup for 1.0 by @aignas in #2333
  • chore: remove an accidental file by @aignas in #2348
  • fix(bzlmod): generate config_setting values for all python toolchains by @aignas in #2350
  • docs: document the is_python config settings by @rickeylev in #2336
  • docs: tell how to create a release branch for patch releases by @rickeylev in #2329
  • chore: add aignas to the BCR maintainers by @aignas in #2352
  • fix: breakages in unused codepaths after recent refactors by @oprypin in #2353
  • refactor(pypi): use a macro to define whl_library targets by @aignas in #2347
  • feat: add features.version value by @rickeylev in #2357
  • refactor: fold bazel-specific code into main files by @rickeylev in #2358
  • fix: allow spaces in whl_librarys by @mark-thm in #2334
  • tests: don't restrict python versions in bzlmod example by @rickeylev in #2362
  • fix: Remove --no-build-isolation from pip install command by @mark-thm in #2360
  • docs: clarify that PyInfo.transitive_sources may not include py files by @rickeylev in #2367
  • fix(pypi): correctly pass extra_pip_args when building sdists by @aignas in #2368
  • fix(pypi): use local version specifiers for patched whl output by @aignas in #2365
  • fix(bzlmod): allow users to specify extra targets to be added to hub repos by @aignas in #2369
  • fix: make sphinxdocs support directory inputs by @rickeylev in #2375
  • feat(bzlmod): cross-platform builds without experimental_index_url by @aignas in #2325
  • chore: cleanup and fix some bzl_library deps in //python/private by @rickeylev in #2381
  • tests: fix the job name for the debian bzlmod gazelle job by @rickeylev in #2382
  • chore: move code out of WORKSPACE.bzlmod and into MODULE by @rickeylev in #2380
  • chore: prepare CHANGELOG for 0.38.0 release by @aignas in #2384

Full Changelog: 0.37.0...0.38.0