diff --git a/WORKSPACE b/WORKSPACE index 93700300..cf69f7f5 100644 --- a/WORKSPACE +++ b/WORKSPACE @@ -18,11 +18,13 @@ load("@com_google_protobuf//:protobuf_deps.bzl", "protobuf_deps") protobuf_deps() -# Force rules_python at a bleeding edge version (for pip3_import). +# Force rules_python at a bleeding edge version (for setuptools >44). +rules_python_version = "929d5a13d4eb1b930086d9353fc6f2d6ad306e43" http_archive( name = "rules_python", - url = "https://github.com/bazelbuild/rules_python/releases/download/0.0.3/rules_python-0.0.3.tar.gz", - sha256 = "e46612e9bb0dae8745de6a0643be69e8665a03f63163ac6610c210e80d14c3e4", + strip_prefix = "rules_python-{}".format(rules_python_version), + url = "https://github.com/bazelbuild/rules_python/archive/{}.zip".format(rules_python_version), + sha256 = "b590e4fc07ec842b8cc8a39a4ca0336f44d7d5f96753229d240884cd016dc1e3", ) # Download Go/Gazelle rules @@ -47,24 +49,17 @@ http_archive( # Python rules # Important: rules_python must be loaded before protobuf (and grpc) because they load an older version otherwise load("@rules_python//python:repositories.bzl", "py_repositories") - py_repositories() load("@rules_python//python:pip.bzl", "pip_repositories") - pip_repositories() -load("@rules_python//python:pip.bzl", "pip3_import") - -pip3_import( +load("@rules_python//python:pip.bzl", "pip_install") +pip_install( name = "pydeps", requirements = "//third_party/py:requirements.txt", ) -load("@pydeps//:requirements.bzl", "pip_install") - -pip_install() - # Setup Go toolchain. load("@io_bazel_rules_go//go:deps.bzl", "go_register_toolchains") go_register_toolchains()