From: Daniele Varrazzo Date: Tue, 5 Oct 2021 13:41:15 +0000 (+0200) Subject: Move mypy configuration to pyproject.toml X-Git-Tag: 3.0~26 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=894616a284f213ec1059311fd5a5257f833e43f9;p=thirdparty%2Fpsycopg.git Move mypy configuration to pyproject.toml --- diff --git a/.mypy.ini b/.mypy.ini deleted file mode 100644 index 2c6008cfa..000000000 --- a/.mypy.ini +++ /dev/null @@ -1,18 +0,0 @@ -[mypy] -files = psycopg/psycopg, psycopg_pool/psycopg_pool, psycopg_c/psycopg_c -warn_unused_ignores = True -show_error_codes = True -strict = True - -[mypy-pytest] -ignore_missing_imports = True - -[mypy-setuptools] -ignore_missing_imports = True - -[mypy-shapely.*] -ignore_missing_imports = True - -[mypy-tests.*] -disallow_untyped_defs = False -disallow_untyped_calls = False diff --git a/pyproject.toml b/pyproject.toml index 875b3c51c..6c48169e6 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -12,3 +12,23 @@ testpaths=[ # Note: On Travis they these options seem to leak objects # log_format = "%(asctime)s.%(msecs)03d %(levelname)-8s %(name)s:%(filename)s:%(lineno)d %(message)s" # log_level = "DEBUG" + + +[tool.mypy] +files = ["psycopg/psycopg", "psycopg_pool/psycopg_pool", "psycopg_c/psycopg_c"] +warn_unused_ignores = true +show_error_codes = true +strict = true + +[[tool.mypy.overrides]] +module = [ + "pytest", + "setuptools", + "shapely.*", +] +ignore_missing_imports = true + +[[tool.mypy.overrides]] +module = "tests.*" +disallow_untyped_defs = false +disallow_untyped_calls = false