Skip to content

Commit

Permalink
tooling: Use updated pytooling deps (envoyproxy#19660)
Browse files Browse the repository at this point in the history
The pytooling packages have been updated to remove all non-async runners/checkers, and to refactor some of the code. This has reduced code complexity/paths/lines/tests etc.

This PR updates envoy-side to use the newer async-only pytooling packages, and updates the envoy tooling to use async or newer code paths as required/appropriate

In order to make this work i had to readd pytest-asyncio to the envoy deps, as the tests are again testing async fun. I also had to add nested-asyncio in order for the test runner to be able to start/stop test loops, inside the checkers loop.

Signed-off-by: Ryan Northey <[email protected]>
  • Loading branch information
phlax authored Jan 25, 2022
1 parent d343d41 commit a543e2b
Show file tree
Hide file tree
Showing 25 changed files with 270 additions and 380 deletions.
1 change: 1 addition & 0 deletions .bazelignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
api
examples/grpc-bridge/script
tools/clang_tools
tools/dev/src
1 change: 1 addition & 0 deletions pytest.ini
Original file line number Diff line number Diff line change
Expand Up @@ -2,3 +2,4 @@
addopts = -raq --ignore=tools/testing/external/*,__init__.py,testing/conf --color=yes --cov-append -p tools.testing.plugin --cov-config=.coveragerc -Werror -vv tools
testpaths =
tests
asyncio_mode = auto
12 changes: 0 additions & 12 deletions tools/base/BUILD
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
load("@rules_python//python:defs.bzl", "py_binary")
load("@base_pip3//:requirements.bzl", "requirement")
load("//bazel:envoy_build_system.bzl", "envoy_package")

licenses(["notice"]) # Apache 2
Expand All @@ -9,13 +7,3 @@ envoy_package()
exports_files([
"entry_point.py",
])

py_binary(
name = "bazel_query",
srcs = ["bazel_query.py"],
main = "bazel_query.py",
deps = [
"@envoy_repo",
requirement("envoy.base.utils"),
],
)
63 changes: 0 additions & 63 deletions tools/base/bazel_query.py

This file was deleted.

2 changes: 1 addition & 1 deletion tools/base/envoy_python.bzl
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
load("@rules_python//python:defs.bzl", "py_binary", "py_library")
load("@rules_python//python:defs.bzl", "py_binary")
load("@base_pip3//:requirements.bzl", base_entry_point = "entry_point")

def envoy_py_test(name, package, visibility, envoy_prefix = "@envoy"):
Expand Down
28 changes: 15 additions & 13 deletions tools/base/requirements.in
Original file line number Diff line number Diff line change
@@ -1,30 +1,32 @@
abstracts>=0.0.12
aio.functional>=0.0.10
aio.subprocess>=0.0.4
aio.tasks>=0.0.5
aio.api.bazel
aio.core>=0.2.0
aio.run.runner>=0.2.1
aio.run.checker>=0.2.1
colorama
coloredlogs
coverage
envoy.base.checker>=0.1.1
envoy.base.runner>=0.1.0
envoy.base.utils>=0.0.13
envoy.code_format.python_check>=0.0.4
envoy.dependency.cve_scan
envoy.dependency.pip_check>=0.0.6
envoy.distribution.release>=0.0.4
envoy.distribution.verify>=0.0.6
envoy.docs.sphinx-runner>=0.0.6
envoy.base.utils>=0.0.14
envoy.code_format.python_check>=0.0.7
envoy.dependency.cve_scan>=0.0.4
envoy.dependency.pip_check>=0.1.0
envoy.distribution.release>=0.0.7
envoy.distribution.repo>=0.0.5
envoy.distribution.verify>=0.0.8
envoy.docs.sphinx-runner>=0.0.8
envoy.gpg.identity>=0.0.6
envoy.gpg.sign>=0.0.7
envoy.gpg.sign>=0.0.9
flake8
frozendict
gitpython
jinja2
nest-asyncio
pep8-naming
ply
pygithub
pyreadline
pytest
pytest-asyncio
pytest-cov
pytest-patches
pyyaml
Expand Down
Loading

0 comments on commit a543e2b

Please sign in to comment.