Commit Graph

76 Commits

Author SHA1 Message Date
Jan Tattermusch cdb3d823fd migrate windows RBE to win2019 pool 2020-05-13 14:39:59 +02:00
Richard Belleville 3d876a656f Buildifier 2019-11-06 13:24:59 -08:00
Richard Belleville 959945705a Merge branch 'master' of https://github.com/grpc/grpc into blaze_modifications 2019-11-06 11:00:47 -08:00
Lidi Zheng c34bef4ca4 Format all Bazel files with buildifier 2019-11-05 14:03:52 -08:00
Richard Belleville 4b49a95801 Fix internal lint warnings 2019-10-29 17:33:44 -07:00
Eytan Kidron c97ce9057b Simplify the platform and constraints settings for remote execution
* Remove the toolchains //third_party/toolchains:local and //third_party/toolchains:local_large.
* Remove the platforms :rbe_ubuntu1604, :rbe_ubuntu1604_large, :local and :local_large.
* No longer inherit from @rbe_default//config:platform but instead use it directly. It is now the only non-windows platform.
* When creating @rbe_default//config:platform directly with rbe_autoconfig, set dockerAddCapabilities and dockerPrivileged directly in the exec_properties field. No need to set dockerNetwork to "off" and dockerSiblingContainers to false since these are the defaults.
* Also set gceMachineType = "n1-highmem-2" on the default platform. This value can be overridden by specific targets that want to use LARGE_MACHINE.
* Use create_exec_properties_dict where appropriate.
* Use custom_exec_properties to define LARGE_MACHINE.

I wasn't able to test thoroughly that this PR does not break any existing targets. I was not able to run anything on windows/mac and I also don't have access to gRPC's RBE setup.
2019-10-29 15:40:28 -04:00
Jan Tattermusch e5e3f70a1a Revert "Revert "Upgrade to bazel 1.0.0"" 2019-10-29 06:31:38 -04:00
Danjie Wenren c22c215ea5 Move extra dependencies out of WORKSPACE to its own macro.
This could be useful for projects that use gRPC as an external
repository. This could not be done within the same grpc_deps.bzl due to
the problem discussed in
- https://github.com/bazelbuild/bazel/issues/1550
- https://github.com/bazelbuild/bazel/issues/1943
2019-10-12 22:10:57 -07:00
Rafi Kamal fac04ffe6e
Add protobuf_deps to WORKSPACE
See https://github.com/grpc/grpc/pull/20224#issuecomment-531355209
2019-09-13 12:32:54 -07:00
Richard Belleville 3638167e40 Call grpc_python_deps() from grpc_deps(). 2019-08-05 12:57:50 -07:00
Richard Belleville e1980a7a5a Merge remote-tracking branch 'origin/master' into py_proto_library 2019-08-02 15:02:31 -07:00
Richard Belleville 9ac75a6d16 Merge remote-tracking branch 'origin/master' into py_proto_library 2019-08-01 15:25:16 -07:00
Richard Belleville 7b2c8c27b0 Separate py_grpc_library and py_proto_library.
By popular demand, we'll now be offering separate py_grpc_library and
py_proto_library targets sharing the same interface as within google3.
This change necessitated some modifications to how we pull in our own
Python-level dependencies and how we make those available to those
pulling in our project via Bazel.

There is now a grpc_python_deps() Bazel workspace rule that pulls in the
appropriate dependencies, which should be called from the client
project's WORKSPACE file. A test has been added to the bazel/test/
directory to verify that this behavior works as intended.

It's worth noting that the protobuf repository's usage of Starlark
bind() caused a great deal of trouble in ensuring that we could also
pull in six.

This change also required a change in the way generated proto code is
imported in the channelz and health-check modules, as well as in their
associated tests. We were importing them two different ways, each
relative. This resulted in two different module objects being imported
into the process, which were incompatible. I am not sure exactly what
caused this behavior to begin, as this should have been possible before
this PR. As a workaround, I am simply trying two different absolute
imports and using the one that works. This should function both inside
and outside of Bazel environments.
2019-08-01 15:16:22 -07:00
Tony Lu 44868ae12a Starting a new branch with same changes from https://github.com/grpc/grpc/pull/19621 2019-07-30 16:30:51 -07:00
Nicolas "Pixel" Noble 5495a7f7b1 Merge branch 'master' of https://github.com/grpc/grpc into moiz-upb 2019-07-16 19:07:24 +02:00
Nicolas "Pixel" Noble 3de02bc8cd Merge branch 'master' of https://github.com/grpc/grpc into moiz-upb 2019-07-03 19:54:22 +02:00
Marcel Hlopko 49f0fb9035 Migrate from dep.proto to dep[ProtoInfo] 2019-06-20 18:55:56 +02:00
Nicolas "Pixel" Noble 8de64087a3 Clean bazel 0.26 upgrade. 2019-06-14 00:20:29 +02:00
Moiz Haidry 49e7f4b2e4 Added more rules to resolve deps 2019-05-24 16:04:43 -07:00
Moiz Haidry 4995670257 Add support to import envoy protos 2019-05-24 14:31:52 -07:00
Moiz Haidry 6c3e3aeb77 Removed git repo from WORKSPACE as that was the incorrect location. Added the code to grpc_deps.bzl instead 2019-05-22 16:35:29 -07:00
Moiz Haidry e8a18969bb Added upb repo to grpc workspace 2019-05-22 15:30:21 -07:00
Richard Belleville 930cec4e27 Revert "Merge pull request #18912 from grpc/revert-bazel-changes"
This reverts commit c9a259aa3a, reversing
changes made to 9c882bc725.
2019-04-30 11:17:11 -07:00
Richard Belleville 50b5240d0a Revert "Merge pull request #18859 from grpc/internal_py_proto_library"
This reverts commit 5b720f19c1, reversing
changes made to a64ae3c0d5.
2019-04-29 17:47:56 -07:00
Richard Belleville afdc59712d Merge branch 'master' into internal_py_proto_library 2019-04-25 10:01:41 -07:00
Richard Belleville 05f37c8143 Remove dependency on pubref/rules_proto.
This commit resolves #18331.
This commit resolves #18256.
This commit resolves... another TODO that apparently didn't have an
associated github issue.

We swap out pubref's implementation of py_proto_library with our own,
which more closely mirrors the interface of the internal
py_proto_library, taking the descriptor file output of a proto_library
rule as input.

One minor change in behavior was introduced for simplicity. When a
py_proto_library depends on a proto_library with a source proto file in
a subdirectory of the bazel package, the import module of the resultant
python library will reflect the package, *not* the full directory of the
proto file, including both the bazel package and the subdirectories, as
pubref did previously. This behavior also more closely mirrors google
internal behavior.

This commit also introduces a slightly more stringent bazel format
script. Buildifier on its own will not take care of long lines, but by
running yapf first, we end up with a more legible file. At the moment,
there is no sanity check associated with this formatter.
2019-04-24 17:36:08 -07:00
Nicolas Lopez a32b1eb765
Merge branch 'master' into master 2019-04-11 15:00:34 -04:00
Bill Feng 5158c3db27 naming update, documentation fix 2019-04-08 14:39:09 -07:00
Bill Feng df89d8e157 bazel RBE Windows build 2019-04-05 11:40:11 -07:00
Richard Belleville 615c95ed5c Mitigate #18256 2019-04-03 18:13:52 -07:00
Nicolas Lopez bdbe0483b0 update docs 2019-03-28 09:56:50 -04:00
Nicolas Lopez a9ffc03d1b remove ubsan rbe_autoconfig target 2019-03-28 09:56:50 -04:00
Nicolas Lopez ad4926d5c6 avoid local runs from accessing remote platforms
This should fix Bazel Basic Tests for Python (Local) and other
local CI runs that are now failing.
I also have a plan to fix Bazel RBE Opt C/C++.
Bazel RBE UBSAN C/C++ might need to wait for gRPC to upgrade to
using 0.23.0
2019-03-28 09:56:50 -04:00
Nicolas Lopez d6dbaeee74 doc fixes 2019-03-28 09:56:50 -04:00
Nicolas Lopez d1640057f2 use rbe_autoconfig 2019-03-28 09:56:50 -04:00
Lidi Zheng 8bed44b2c4 Make WORKSPACE compatible with Bazel 0.20.0 for Python 2018-12-04 19:43:04 -08:00
Nicolas Noble dc930c7868
Workarounding bazelbuild/bazel#6831
This will take care of the bazel crash until we have a proper fix upstream.
2018-12-03 19:16:21 -08:00
Nicolas "Pixel" Noble dc4b538c4d Merge branch 'master' of https://github.com/grpc/grpc into fix-bazel-0.20 2018-11-30 23:27:24 +01:00
Nicolas "Pixel" Noble f0fbee5932 Bazel 0.20.0 workspace fixes. 2018-11-30 23:24:59 +01:00
Bill Feng 1e53e3c17f added back platform registration to WORKSPACE 2018-11-26 10:26:07 -08:00
Bill Feng 70f9992d77 modified execution platform registration, added host platform 2018-11-26 10:10:53 -08:00
Bill Feng a548f1cc64 fixed typo on WORKSPACE file 2018-11-20 15:43:24 -08:00
Bill Feng c04583f647 registered toolchain and platform 2018-11-20 15:23:08 -08:00
Naresh 873e0757cb
Bazel rules for Python grpcio_health_checking
Add Bazel rules for building and testing grpcio_health_checking.

An unofficial fork for rules_protobuf is used for now as it incorporates
a change (#196 by duduko on the upstream repo pubref/rules_protobuf)
which allows the protoc compiler to compile generated protos too. This
was not merged because the change was failing for golang, but works as
expected for Python.

This is needed because grpcio_health_checking fetches it's proto file
from a different directory (previously achived through setup.py) and
thus needs to be moved to the required location within bazel-genfiles
using a genrule.
2018-10-09 17:04:11 +00:00
Naresh 11f199e34d
Workspace changes to build gRPC Python with Bazel
- Include new rules from bazelbuild/rules_python, which allow for
importing pip dependencies with Bazel.
- Make Cython BUILD file visible to WORKSPACE.
- Use a custom requirements file for Bazel python. This is added to
allow for requirements previously added only during build steps.
2018-07-27 14:44:09 +00:00
Alex Polcyn aa56034b58 Add python bazel deps needed to run resolver component tests 2018-02-14 14:06:00 -08:00
Ning Ren 174e02ae3e Packs contents of WORKSPACE into a bzl function, so that it can be resued by other projects, and simplifies cares build. 2017-12-14 17:37:55 -08:00
Adele Zhou 0384127aa8 Copy key data 2017-11-30 17:10:27 -08:00
Adele Zhou b9cb3379d5 Add bazel_toolchains 2017-11-30 17:10:27 -08:00
Mehrdad Afshari 28661ea6e1 Bump third_party/protobuf submodule to v3.5.0 2017-11-24 17:56:04 -08:00