Skip to content

Commit

Permalink
ubuntu-latest -> ubuntu 20.04 in CI + black 23 formatting (#490)
Browse files Browse the repository at this point in the history
* ubuntu-latest -> ubuntu 20.04 in CI

* Apply black 23 formatting
  • Loading branch information
nipunn1313 authored Feb 12, 2023
1 parent 7692825 commit 5f92223
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
4 changes: 3 additions & 1 deletion .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,9 @@ on:
jobs:
run_test:
name: ${{ matrix.py-ver-mypy-protobuf }}
runs-on: ubuntu-latest
runs-on: ubuntu-20.04
# Some CI issues regarding ubuntu-latest
# runs-on: ubuntu-latest
env:
PY_VER_MYPY: 3.8.13
PY_VER_UNIT_TESTS_3: 3.8.13
Expand Down
6 changes: 2 additions & 4 deletions mypy_protobuf/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -892,7 +892,7 @@ def write(self) -> str:

for pkg, items in sorted(self.from_imports.items()):
self._write_line(f"from {pkg} import (")
for (name, reexport_name) in sorted(items):
for name, reexport_name in sorted(items):
if reexport_name is None:
self._write_line(f" {name},")
else:
Expand Down Expand Up @@ -972,9 +972,7 @@ def generate_mypy_grpc_stubs(


@contextmanager
def code_generation() -> Iterator[
Tuple[plugin_pb2.CodeGeneratorRequest, plugin_pb2.CodeGeneratorResponse],
]:
def code_generation() -> Iterator[Tuple[plugin_pb2.CodeGeneratorRequest, plugin_pb2.CodeGeneratorResponse],]:
if len(sys.argv) > 1 and sys.argv[1] in ("-V", "--version"):
print("mypy-protobuf " + __version__)
sys.exit(0)
Expand Down

0 comments on commit 5f92223

Please sign in to comment.