From 3dc23f7a22c01f9a3002aae9e535e0806aa6ed80 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Henrik=20tom=20W=C3=B6rden?= <henrik@trineo.org> Date: Wed, 11 Aug 2021 14:03:16 +0200 Subject: [PATCH] MAINT: add mypy to check type hints --- .gitlab-ci.yml | 6 ++++++ unittests/docker/Dockerfile | 2 +- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 9f8c1319..98975f61 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -50,6 +50,12 @@ pylint: - pylint3 --unsafe-load-any-extension=y -d all -e E,F src/caosdb/common allow_failure: true +mypy: + tags: [ docker ] + stage: linting + script: + - mypy src/caosdb + allow_failure: true # pylint tests for pycaosdb test: diff --git a/unittests/docker/Dockerfile b/unittests/docker/Dockerfile index 7fa3f75b..286d235f 100644 --- a/unittests/docker/Dockerfile +++ b/unittests/docker/Dockerfile @@ -7,4 +7,4 @@ RUN apt-get update && \ ARG COMMIT="dev" RUN git clone -b dev https://gitlab.indiscale.com/caosdb/src/caosdb-pylib.git && \ cd caosdb-pylib && git checkout $COMMIT && pip3 install . -RUN pip3 install recommonmark sphinx-rtd-theme +RUN pip3 install recommonmark sphinx-rtd-theme mypy -- GitLab