Commit Graph

10 Commits

Author SHA1 Message Date
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
Richard Belleville 3439cc29d2
Update xds-protos package to pull in new generated code (#31113) 2022-09-23 13:41:25 -07:00
Lidi Zheng 9978223a26
Add python_requires field to grpcio-* packages (#27495)
- Update the run_tests.py and distrib tests
- Update the Dockerfiles
2021-09-28 16:01:15 -07:00
Lidi Zheng eb4b65ae5a
Add opentelemetry as a submodule for latest xDS API (#26850)
* Add opentelemetry

* Python changes for opentelemetry

* Add opentelemetry to check submodules
2021-08-02 12:42:44 -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
Lidi Zheng 5820e152cd
Remove Python 2.7 binary wheel generations (#26691)
* Remove Python 2.7 binary wheels

* Make sure pip won't pick-up newer versions

* Attempt to fix the distribtest

* Fallback to virtualenv==16.7.9 for 34 and 35

* Remove 34 from binary wheel distribtests
2021-07-23 08:20:39 -07:00
Lidi Zheng dc63d6a53e
Add CSDS API to Python (#26114)
* Add grpcio-csds pacakge

* Remove unused file

* Fix the proto import path issue

* Update the CSDS package and xds-protos for PY2

* Make tests happy

* Fix Bazel proto dependency

* Add Python2 tests for CSDS
2021-05-03 11:54:34 -07:00
Lidi Zheng 0657787b13
Compile source wheels for xds-protos (#26034) 2021-04-21 12:45:54 -07:00
Lidi Zheng cca9277963
Fix some issues with the xds-protos package (#25999)
* Fix issues with xds-protos && add a README

* Split the build process from setup.py
2021-04-20 09:23:07 -07:00
Lidi Zheng 980ccba493
Introduce new Python package "xds_protos" (#25975)
* New Python package xds_protos

* Polish the setup.py

* Adding install requirements and improve wheel validation

* Add xds-protos to the update procedure of envoy-api

* Add setup requirements
2021-04-16 16:31:23 -07:00