Commit Graph

113 Commits

Author SHA1 Message Date
Esun Kim 78b9d84fd3 [Dep] Rollback Protobuf upgrade to v25.1 (#36247)
This is for gRPC Python that has an issue with Protobuf Python v26

Closes #36247

PiperOrigin-RevId: 621629528
2024-04-03 13:56:36 -07:00
Esun Kim 899aed0156 [Deps] Ruby uses protobuf 4.x (#36215)
Protobuf for Ruby bumped the major version to 4. [package](https://rubygems.org/gems/google-protobuf) so the Ruby gemspec should be updated to have 4 instead of 3.

But gRPC's other dependencies don't work with Protobuf 4.x so I fixed the version of google-protobuf for gRPC Ruby to 3.25 which was the last version gRPC used.

Closes #36215

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/36215 from veblush:ruby-protobuf 171a6d63bc
PiperOrigin-RevId: 620987535
2024-04-01 16:38:17 -07:00
Yash Tibrewal e06e45f2af [OTel C++] Do not add otel_plugin_test with CMake if the otel plugin is not enabled (#36128)
This should fix our interop builds

Closes #36128

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/36128 from yashykt:OTelPluginCIFix 98165a868b
PiperOrigin-RevId: 615923868
2024-03-14 15:33:36 -07:00
Stanley Cheung 18af795edf Update min PHP testing version from PHP 7.4 to 8.1 (#35964)
- PHP 7.4 and 8.0 have been EOL https://www.php.net/supported-versions.php
- See go/drop-php-8.0 for more details

Most of the changes came from `generate_projects.sh` after updating the `tools/buildgen/plugins/expand_version.py` file. The change to `tools/internal_ci/helper_scripts/prepare_build_macos_rc` is manual.

Closes #35964

COPYBARA_INTEGRATE_REVIEW=https://github.com/grpc/grpc/pull/35964 from stanley-cheung:php-update-to-8_1 0c24c4eac2
PiperOrigin-RevId: 609495798
2024-02-22 14:32:42 -08:00
Jan Tattermusch d3548a3941
[bazel] Upgrade bazel repo-wide to 6.3.2 (#34088)
- Upgrade bazel
- Reduce the number of places where bazel version needs to be upgraded
in future.
- also make sure the list of bazel versions to test by bazelified tests
is loaded from supported_versions.txt (it was hardcoded before).
- ~~Try upgrading windows RBE build to bazel 6.3.2 as well.~~

The core idea:
- the source of truth for supported bazel versions is in
`bazel/supported_versions.txt`
- the first version listed in `bazel/supported_versions.txt` is
considered to be the "primary" bazel version and is going to be used in
most places thoroughout the repo.
- use templates to include the primary bazel version in testing
dockerfiles and in a newly introduced `.bazelversion` files (which gets
loaded by our existing `tools/bazel` wrapper).


~~Supersedes https://github.com/grpc/grpc/pull/33880~~
2023-08-18 10:11:33 +02:00
Jan Tattermusch a8508ec465
[build metadata] Bazel to "other build systems" improvements (#33803)
- Extract build metadata for some external dependencies from bazel
build. This is achieved by letting extract_metadata_from_bazel_xml.py
analyze some external libraries and sources. The logic is basically the
same as for internal libraries, I only needed to teach
extract_metadata_from_bazel_xml.py which external libraries it is
allowed to analyze.
* currently, the list of source files is automatically determined for
`z`, `upb`, `re2` and `gtest` dependencies (at least for the case where
we're building in "embedded" mode - e.g. mostly native extensions for
python, php, ruby etc. - cmake has the ability to replace some of these
dependencies by actual cmake dependency.)
- Eliminate the need for manually written gen_build_yaml.py for some
dependencies.
- Make the info on target dependencies in build_autogenerated.yaml more
accurate and complete. Until now, there were some depdendencies that
were allowed to show up in build_autogenerated.yaml and some that were
being skipped. This made generating the CMakeLists.txt and Makefile
quite confusing (since some dependencies are being explicitly mentioned
and some had to be assumed by the build system).
- Overhaul the Makefile
* the Makefile is currently only used internally (e.g. for ruby and PHP
builds)
* until now, the makefile wasn't really using the info about which
targets depend on what libraries, but it was effectively hardcoding the
depedendency data (by magically "knowing" what is the list of all the
stuff that e.g. "grpc" depends on).
* After the overhaul, the Makefile.template now actually looks at the
library dependencies and uses them when generating the makefile. This
gives a more correct and easier to maintain makefile.
* since csharp is no longer on the master branch, remove all mentions of
"csharp" targets in the Makefile.

Other notable changes:
- make extract_metadata_from_bazel_xml.py capable of resolving workspace
bind() rules (so that it knows the real name of the target that is
referred to as e.g. `//external:xyz`)

TODO:
- [DONE] ~~pkgconfig C++ distribtest~~
- [DONE} ~~update third_party/README to reflect changes in how some deps
get updated now.~~


Planned followups:
- cleanup naming of some targets in build metadata and buildsystem
templates: libssl vs boringssl, ares vs cares etc.
- further cleanup of Makefile
- further cleanup of CMakeLists.txt
- remote the need from manually hardcoding extra metadata for targets in
build_autogenerated.yaml. Either add logic that determines the
properties of targets automatically, or use metadata from bazel BUILD.
2023-08-16 19:13:39 +02:00
Sergii Tkachenko de6ed9ba9f
[Python] Migrate from yapf to black (#33138)
- Switched  from yapf to black
- Reconfigure isort for black
- Resolve black/pylint idiosyncrasies 

Note: I used `--experimental-string-processing` because black was
producing "implicit string concatenation", similar to what described
here: https://github.com/psf/black/issues/1837. While currently this
feature is experimental, it will be enabled by default:
https://github.com/psf/black/issues/2188. After running black with the
new string processing so that the generated code merges these `"hello" "
world"` strings concatenations, then I removed
`--experimental-string-processing` for stability, and regenerated the
code again.

To the reviewer: don't even try to open "Files Changed" tab 😄 It's
better to review commit-by-commit, and ignore `run black and isort`.
2023-06-09 15:08:55 -07:00
Craig Tiller 72c296a3c2
[event_engine] Add SliceCast (#31831)
* [event_engine] Add SliceCast

* Automated change: Fix sanity tests

* windows-fix

* comments

* comments

* comments

* build-fix

* fix

* Update port_platform.h

Co-authored-by: ctiller <ctiller@users.noreply.github.com>
2022-12-20 19:46:27 -08:00
Stanley Cheung fa42edef83
Update PHP docker images PHP versions (#31779) 2022-12-07 13:20:48 -08:00
Lidi Zheng 99752b173c
[xDS Proto] Enhence gRPC buildgen for 3rd party proto compilation (#29254)
* [xDS Proto] Enhence gRPC buildgen for 3rd party proto compilation

* Rebase from master to update envoy-api version

* Address reviewer's comments

* Address reviewer's comment

* Regenerate project

* Rename external_library

* Address reviewer's comments

* Add comments for the internals of generate C++ proto code

* Add proto file as a dependency to the custom command
2022-04-13 14:26:08 -07:00
Richard Belleville e79b2a9b32
Add Documentation for Supported Bazel Versions (#29191)
* Create Bazel support range docs

* Review comments

* Move supported versions file
2022-03-25 10:45:06 -07:00
Richard Belleville 59693b7e72
Migrate Infrastructure Scripts to Python 3 (#27135)
* Run 2to3 on tools directory

* Delete github_stats_tracking

* Re-run 2to3

* Remove unused script

* Remove unused script

* Remove unused line count utility

* Yapf. Isort

* Remove accidentally included file

* Migrate tools/distrib directory to python 3

* Remove unnecessary shebang

* Restore line_count directory

* Immediately convert subprocess.check_output output to string

* Take care of Python 2 shebangs

* Invoke scripts using a Python 3 interpreter

* Yapf. Isort

* Try installing Python 3 first

* See if we have any Python 3 versions installed

* Add Python 3.7 to Windows path

* Try adding a symlink

* Try to symlink differently

* Install six for Python 3

* Run run_interop_tests with python 3

* Try installing six in python3.7 explicitly

* Revert "Try installing six in python3.7 explicitly"

This reverts commit 2cf60d72f3.

* And debug some more

* Fix issue with jobset.py

* Add debug for CI failure

* Revert microbenchmark changes
2021-11-08 08:55:25 -08:00
Craig Tiller 87a973f01d
Add structurally aware fuzzing support (#27405)
* Add a dependency on libprotobuf-mutator

* Changes for structured fuzzing

* fuzznificent

* add a config that will build fuzzers

* bazel run --config=fuzzer_asan //path/to:fuzzer fuzzes!

* fixes

* Automated change: Fix sanity tests

* Automated change: Fix sanity tests

* fixes

* fix

* sanitizer fix

* fix directory

* regen stuff

* compile error

* remove fuzzers from cmake build

* Automated change: Fix sanity tests

* review feedback

* remove unnecessary load

* review feedback

* review feedback

Co-authored-by: ctiller <ctiller@users.noreply.github.com>
2021-09-22 14:40:43 -07:00
AJ Heller 2d16865693
Delete libuv-iomgr implementation and GRPC_UV build option (#27188)
This has been unmaintained for years, last supported in gRPC-core v1.24.
2021-08-31 13:26:43 -07:00
Richard Belleville b6cc72f129
Revert "Run 2to3 on tools directory (#26002)" (#27183)
This reverts commit a388361c3d.
2021-08-30 12:29:20 -07:00
Richard Belleville a388361c3d
Run 2to3 on tools directory (#26002)
* Run 2to3 on tools directory

* Delete github_stats_tracking

* Re-run 2to3

* Remove unused script

* Remove unused script

* Remove unused line count utility

* Yapf. Isort

* Remove accidentally included file

* Restore line_count directory
2021-08-30 09:25:21 -07:00
Lidi Zheng 2231c2ba77
Introduce Python import sorting to our sanity test suite (#26768)
* Add isort_code.sh to sanity tests

* Run tools/distrib/isort_code.sh

* Fine tune the import order for relative imports

* Make pylint and project generation happy

* Fix a few corner cases

* Use --check instead of --diff

* The import order impacts test result somehow

* Make isort print diff and check output at the same time

* Let tools/run_tests/python_utils be firstparty library

* Run isort against latest HEAD
2021-07-26 12:31:21 -07:00
Jan Tattermusch 53d32b748f
Cleanup: Remove no-longer-needed expand_filegroups.py (#25532)
* get rid of expand_filegroups.py

* regenerate projects
2021-02-24 19:46:58 +01:00
Jan Tattermusch 6dbc6ed4e9 remove useless build plugin "generate_vsprojects.py" 2021-02-11 11:28:29 +01:00
Sergii Tkachenko 8db79e2e71 Python style: reformat code using updated yapf 0.30.0 2021-01-13 14:00:12 -05:00
Richard Belleville 9c0497a0b0 Yapf. Index from beginning 2020-12-07 13:41:18 -08:00
Richard Belleville 38124ab0c6 Review comments 2020-12-07 11:52:44 -08:00
Richard Belleville 010d62175e Pin protobuf version dependency for grpcio-tools 2020-12-04 17:40:31 -08:00
capstan 7267c8fcd9 Python3-ize tools/buildgen.
* Ran `2to3` on `tools/buildgen` and the `gen_build_yaml.py` files.
* Updated the invocations of python to be explicitly Python 3.
* Changed the loader in `mako_renderer.py` to allow pickle to find the module for pickling `external_version.Version`
* Added a few open-as-binary to placate readers/writers expecting bytes.
* Hand tweaked the templates to remove `iteritems` and fiddle with encodings.

Partially addresses #24359.
2020-11-04 01:18:57 +01:00
Jan Tattermusch 1a37d291ea
Merge pull request #23717 from jtattermusch/run_tests_using_cmake2
Use cmake for C/C++ build in run_tests.py
2020-08-13 17:44:09 +02:00
Micah Kornfield 35c0a4cfff Adds option of using ASM for BoringSSL in Python.
- Adds a new environment variable for turning on the build of ASM
  for boring SSL.
- Only enables for x86_64 for now.  I think this is likely the most
  common target and the only machine I have readily accessible.
2020-08-03 15:47:25 -07:00
Jan Tattermusch a407c2c7b5 turn generated fuzzer tests from tests.json to c++ to match build_autogenerated.yaml 2020-08-03 19:18:39 +02:00
Muxi Yan 590415e1f3 Merge remote-tracking branch 'upstream/master' into boringssl-prefix-header 2020-04-03 11:43:05 -07:00
Jan Tattermusch 41ac287f7b generate build metadata from bazel BUILD 2020-02-26 19:56:49 -05:00
Esun Kim 4a576907c8 Added verify_duplicate_sources 2020-01-16 08:59:53 -08:00
Esun Kim 7be821ac47 Yapf all target python sources 2020-01-03 09:25:10 -08:00
Esun Kim eba3d123be
Merge pull request #21508 from veblush/cmake-abseil
Add cmake_target field to abseil targets
2019-12-18 16:28:47 -08:00
Esun Kim 24021c9bab Add cmake_target field to abseil targets 2019-12-18 14:49:33 -08:00
Esun Kim 4a68e396a2 Make transitive_deps as a topologically sorted list 2019-12-18 14:21:59 -08:00
Muxi Yan 771dd24548 Remove gRPC's custom prefix headers 2019-11-13 15:18:23 -08:00
Jan Tattermusch aba7f7bd2b
Merge pull request #20100 from jtattermusch/update_boringssl
Update boringssl and boringssl-with-bazel to latest master
2019-10-21 16:25:28 +02:00
Stanley Cheung 542fb566d7
Merge pull request #20411 from stanley-cheung/php-docker-tests
PHP: add various scenarios to test PECL extension
2019-10-02 10:57:23 -07:00
Stanley Cheung f47d14160a PHP: add various scenarios to test PECL extension 2019-10-01 14:39:48 -07:00
chentanjun 4ecc1fe6a4 fix the wrong word 2019-10-01 05:13:33 +08:00
Jan Tattermusch b39d49db75 fix nits in grpc_shadow_boringssl.py 2019-09-20 08:43:19 +02:00
Esun Kim feb263ba6d Add check_attrs & clean-up build.yaml 2019-08-16 13:41:12 -07:00
Jan Tattermusch 6b86d4706b yapf code 2019-07-30 11:54:55 -07:00
Jan Tattermusch f0b53e1f1b set C# major version to 2, adjust expand_version.py 2019-07-30 10:33:34 -07:00
Esun Kim e6d58923df Add a detection of missing file in filegroup.uses 2019-07-26 14:29:42 -07:00
Muxi Yan b24b212ee5 Make symbols of BoringSSL private to gRPC 2018-08-23 09:42:24 -07:00
Nicolas "Pixel" Noble 6f3c4f0aab Adding back nodejs version override support. 2018-03-14 23:11:29 +01:00
Stanley Cheung ac3c69b99e PHP: make generate_projects.sh smarter for package.xml 2018-01-19 15:27:19 -08:00
Mehrdad Afshari 87cd994b04 Upgrade yapf to 0.20.0
Upgrade yapf version to 0.20.0 and reformat Python files.
2018-01-02 14:40:00 -08:00
ncteisen 26d70b1653 yapf tools/buildgen 2017-12-11 16:40:56 -08:00
Yash Tibrewal d9da7387b8
Merge pull request #13147 from yashykt/testc++ize
Convert test/core to C++
2017-11-07 17:02:23 -08:00