66import tempfile
77from functools import partial
88from pathlib import Path
9- from typing import List , Mapping , Optional
9+ from typing import List , Mapping
1010
1111base_dir = Path (__file__ ).parent .parent
1212proto_dir = (
2525 v
2626 for v in proto_dir .glob ("**/*.proto" )
2727 if not str (v ).startswith (str (testsrv_proto_dir / "dependencies" ))
28- and not "health" in str (v )
29- and not "google" in str (v )
28+ and "health" not in str (v )
29+ and "google" not in str (v )
3030]
3131proto_paths .extend (test_proto_dir .glob ("**/*.proto" ))
3232proto_paths .extend (additional_proto_dir .glob ("**/*.proto" ))
@@ -95,7 +95,7 @@ def fix_generated_output(base_path: Path):
9595 message_names = sorted (message_names )
9696 if message_names :
9797 f .write (
98- f '\n __all__ = [\n "' + '",\n "' .join (message_names ) + '",\n ]\n '
98+ '\n __all__ = [\n "' + '",\n "' .join (message_names ) + '",\n ]\n '
9999 )
100100 # gRPC imports
101101 if "service_pb2_grpc" in imports :
@@ -115,7 +115,7 @@ def fix_generated_output(base_path: Path):
115115 message_names .append (message )
116116 # __all__
117117 message_names = sorted (message_names )
118- f .write (f ' __all__.extend(["' + '", "' .join (message_names ) + '"])\n ' )
118+ f .write (' __all__.extend(["' + '", "' .join (message_names ) + '"])\n ' )
119119 f .write ("except ImportError:\n pass" )
120120
121121
0 commit comments