diff --git a/.github/workflows/mypy.yml b/.github/workflows/mypy.yml deleted file mode 100644 index 8363e721..00000000 --- a/.github/workflows/mypy.yml +++ /dev/null @@ -1,22 +0,0 @@ -on: - pull_request: - branches: - - main -name: mypy -jobs: - mypy: - runs-on: ubuntu-latest - steps: - - name: Checkout - uses: actions/checkout@v4 - - name: Setup Python - uses: actions/setup-python@v5 - with: - python-version: "3.14" - - name: Install nox - run: | - python -m pip install --upgrade setuptools pip wheel - python -m pip install nox - - name: Run mypy - run: | - nox -s mypy diff --git a/noxfile.py b/noxfile.py index 37ef2caf..98da50ef 100644 --- a/noxfile.py +++ b/noxfile.py @@ -70,6 +70,17 @@ def lint(session): ) session.run("flake8", "google", "tests") + """Run type-checking.""" + session.install(".[grpc,async_rest]", "mypy") + session.install( + "types-setuptools", + "types-requests", + "types-protobuf", + "types-dataclasses", + "types-mock; python_version=='3.7'", + ) + session.run("mypy", "google", "tests") + @nox.session(python=DEFAULT_PYTHON_VERSION) def blacken(session): @@ -265,27 +276,6 @@ def lint_setup_py(session): session.run("python", "setup.py", "check", "--restructuredtext", "--strict") -@nox.session(python=DEFAULT_PYTHON_VERSION) -def pytype(session): - """Run type-checking.""" - session.install(".[grpc]", "pytype") - session.run("pytype") - - -@nox.session(python=DEFAULT_PYTHON_VERSION) -def mypy(session): - """Run type-checking.""" - session.install(".[grpc,async_rest]", "mypy") - session.install( - "types-setuptools", - "types-requests", - "types-protobuf", - "types-dataclasses", - "types-mock; python_version=='3.7'", - ) - session.run("mypy", "google", "tests") - - @nox.session(python=DEFAULT_PYTHON_VERSION) def cover(session): """Run the final coverage report.