Improve generate script

- Fix issue with __pycache__ dirs getting picked up
- parallelise code generation with asyncio for 3x speedup
- silence protoc output unless -v option is supplied
- Use pathlib ;)
This commit is contained in:
Nat Noordanus
2020-06-07 17:53:06 +02:00
parent 4b6f55dce5
commit 3185c67098
3 changed files with 99 additions and 72 deletions

View File

@@ -23,7 +23,7 @@ from google.protobuf.json_format import Parse
class TestCases:
def __init__(self, path, services: Set[str], xfail: Set[str]):
_all = set(get_directories(path))
_all = set(get_directories(path)) - {"__pycache__"}
_services = services
_messages = _all - services
_messages_with_json = {