Skip to content

Commit cccd359

Browse files
committed
feat: enable mypy session for documentai-toolbox
1 parent ef62df4 commit cccd359

File tree

1 file changed

+15
-4
lines changed
  • packages/google-cloud-documentai-toolbox

1 file changed

+15
-4
lines changed

packages/google-cloud-documentai-toolbox/noxfile.py

Lines changed: 15 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -480,10 +480,21 @@ def prerelease_deps(session, protobuf_implementation):
480480
@nox.session(python=DEFAULT_PYTHON_VERSION)
481481
def mypy(session):
482482
"""Run the type checker."""
483-
484-
# TODO(https://github.com/googleapis/google-cloud-python/issues/16014):
485-
# Enable mypy once this bug is fixed.
486-
session.skip("Temporarily skip mypy. See issue 16014")
483+
session.install(
484+
"mypy<1.16.0",
485+
"types-requests",
486+
"types-protobuf",
487+
"pandas-stubs",
488+
)
489+
session.install("-e", ".")
490+
session.run(
491+
"mypy",
492+
"-p",
493+
"google.cloud.documentai_toolbox",
494+
"--check-untyped-defs",
495+
"--ignore-missing-imports",
496+
*session.posargs,
497+
)
487498

488499

489500
@nox.session(python=DEFAULT_PYTHON_VERSION)

0 commit comments

Comments
 (0)