Commit Graph

24 Commits

Author SHA1 Message Date
Nathan Baulch
8342a109ae Fix python typos (#38029)
Continuation of #37541 but focused on Python.

Top typos are:
* resolveable (5)
* dedecated (4)
* everyting (4)
* programatically (3)
* supercede (3)
* wil (3)
* acknowledgment (2)
* corutine (2)
* coversion (2)
* operaton (2)
* wich (2)

Closes #38029

PiperOrigin-RevId: 695759207
2024-11-12 09:15:38 -08:00
Marcel
ff7d726a91 [Python Bazel] Use PyInfo provider and py_* rules from rules_python (#37995)
The native one will be removed soon (Bazel 8?).

Closes #37995

PiperOrigin-RevId: 690671136
2024-10-28 10:47:26 -07: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
Richard Belleville
468768865b Make Buildifier Sanity Test Strict (#27807)
* Fix all lint errors in repo.

* Use strict buildifier by default

* Whoops. That file does not exist

* Attempt fix to buildifier invocation

* Add missing copyright
2021-11-03 14:57:04 -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
Sergii Tkachenko
8db79e2e71 Python style: reformat code using updated yapf 0.30.0 2021-01-13 14:00:12 -05:00
Lidi Zheng
e6dffc6fbe Adding three more AsyncIO examples
* Channelz or Debug
* Route guide
* Wait for ready
2021-01-06 10:52:39 -08:00
Esun Kim
e0ebe46ad3 Fix python examples 2020-12-23 09:23:32 -08:00
Esun Kim
e7afadc255 Refactor examples BUILD files 2020-12-23 09:23:32 -08:00
Esun Kim
7be821ac47 Yapf all target python sources 2020-01-03 09:25:10 -08:00
Lidi Zheng
c34bef4ca4 Format all Bazel files with buildifier 2019-11-05 14:03:52 -08:00
Richard Belleville
3d4f905775 Merge pull request #20141 from gnossen/python_strip_prefixes
Add strip_prefix to python protoc plugin and py_grpc_library
2019-09-06 11:55:58 -05:00
Richard Belleville
d649880044 Add strip_prefix to python protoc plugin and py_grpc_library 2019-08-30 16:47:22 -07:00
Richard Belleville
1444cd1dd3 Revert "Revert "Merge pull request #20097 from gnossen/dual_version_python_tests""
This reverts commit 24c562dbaa.
2019-08-29 10:51:36 -07:00
Richard Belleville
24c562dbaa Revert "Merge pull request #20097 from gnossen/dual_version_python_tests"
This reverts commit c9c847f334, reversing
changes made to 07ba4de392.
2019-08-29 10:47:44 -07:00
Richard Belleville
27990a5541 Explicitly add python versions to examples. 2019-08-27 17:47:52 -07:00
Richard Belleville
d932d2368e Merge pull request #19852 from gnossen/server_termination
Quit waiting for a day
2019-08-08 09:53:10 -07:00
Richard Belleville
3db8828876 Add TODOs for prefix stripping 2019-08-06 15:24:09 -07:00
Richard Belleville
e32980fba2 Quit waiting for a day 2019-08-05 16:19:49 -07:00
Richard Belleville
2b7ec3ad23 Fix up examples. 2019-08-01 16:18:45 -07:00
Lidi Zheng
9bd526260a Remove unused imports 2019-06-14 16:49:53 -07:00
Lidi Zheng
550dae1c47 Workaround the address contention issue 2019-06-14 10:41:35 -07:00
Lidi Zheng
559023c01d Adopt reviewer's advice 2019-06-13 10:45:46 -07:00
Lidi Zheng
f7cb9c9f3e Add Debug Example 2019-06-10 15:29:03 -07:00