Use mypy's inline configuration syntax for opt-outs

This commit is contained in:
Pradyun Gedam 2019-07-20 12:06:59 +05:30
parent 800f866600
commit f377148f6d
No known key found for this signature in database
GPG Key ID: DA17C4B29CB32E4B
24 changed files with 74 additions and 76 deletions

View File

@ -26,81 +26,6 @@ ignore = W504
follow_imports = silent
ignore_missing_imports = True
[mypy-pip/_internal/build_env]
strict_optional = False
[mypy-pip/_internal/cache]
strict_optional = False
[mypy-pip/_internal/cli/base_command]
strict_optional = False
[mypy-pip/_internal/cli/cmdoptions]
strict_optional = False
[mypy-pip/_internal/configuration]
strict_optional = False
[mypy-pip/_internal/index]
strict_optional = False
[mypy-pip/_internal/legacy_resolve]
strict_optional = False
[mypy-pip/_internal/locations]
strict_optional = False
[mypy-pip/_internal/models/format_control]
strict_optional = False
[mypy-pip/_internal/operations/check]
strict_optional = False
[mypy-pip/_internal/operations/freeze]
strict_optional = False
[mypy-pip/_internal/operations/prepare]
strict_optional = False
[mypy-pip/_internal/pep425tags]
strict_optional = False
[mypy-pip/_internal/req/*]
disallow_untyped_defs = True
[mypy-pip/_internal/req]
strict_optional = False
[mypy-pip/_internal/req/constructors]
strict_optional = False
[mypy-pip/_internal/req/req_file]
strict_optional = False
[mypy-pip/_internal/req/req_install]
strict_optional = False
[mypy-pip/_internal/req/req_set]
strict_optional = False
[mypy-pip/_internal/req/req_tracker]
strict_optional = False
[mypy-pip/_internal/utils/encoding]
strict_optional = False
[mypy-pip/_internal/utils/glibc]
strict_optional = False
[mypy-pip/_internal/utils/misc]
strict_optional = False
[mypy-pip/_internal/utils/ui]
strict_optional = False
[mypy-pip/_internal/wheel]
strict_optional = False
[mypy-pip/_vendor/*]
follow_imports = skip
ignore_errors = True

View File

@ -1,6 +1,9 @@
"""Build Environment used for isolation during sdist building
"""
# The following comment should be removed at some point in the future.
# mypy: strict-optional=False
import logging
import os
import sys

View File

@ -1,6 +1,9 @@
"""Cache Management
"""
# The following comment should be removed at some point in the future.
# mypy: strict-optional=False
import errno
import hashlib
import logging

View File

@ -1,4 +1,8 @@
"""Base Command class, and related routines"""
# The following comment should be removed at some point in the future.
# mypy: strict-optional=False
from __future__ import absolute_import, print_function
import logging

View File

@ -5,8 +5,11 @@ The principle here is to define options once, but *not* instantiate them
globally. One reason being that options with action='append' can carry state
between parses. pip parses general options twice internally, and shouldn't
pass on state. To be consistent, all options will follow this design.
"""
# The following comment should be removed at some point in the future.
# mypy: strict-optional=False
from __future__ import absolute_import
import logging

View File

@ -11,6 +11,9 @@ Some terminology:
A single word describing where the configuration key-value pair came from
"""
# The following comment should be removed at some point in the future.
# mypy: strict-optional=False
import locale
import logging
import os

View File

@ -1,4 +1,8 @@
"""Routines related to PyPI, indexes"""
# The following comment should be removed at some point in the future.
# mypy: strict-optional=False
from __future__ import absolute_import
import cgi

View File

@ -10,6 +10,9 @@ for sub-dependencies
a. "first found, wins" (where the order is breadth first)
"""
# The following comment should be removed at some point in the future.
# mypy: strict-optional=False
import logging
import sys
from collections import defaultdict

View File

@ -1,4 +1,8 @@
"""Locations where we look for configs, install stuff, etc"""
# The following comment should be removed at some point in the future.
# mypy: strict-optional=False
from __future__ import absolute_import
import os

View File

@ -1,3 +1,6 @@
# The following comment should be removed at some point in the future.
# mypy: strict-optional=False
from pip._vendor.packaging.utils import canonicalize_name
from pip._internal.utils.typing import MYPY_CHECK_RUNNING

View File

@ -1,6 +1,9 @@
"""Validation of dependencies of packages
"""
# The following comment should be removed at some point in the future.
# mypy: strict-optional=False
import logging
from collections import namedtuple

View File

@ -1,3 +1,6 @@
# The following comment should be removed at some point in the future.
# mypy: strict-optional=False
from __future__ import absolute_import
import collections

View File

@ -1,6 +1,9 @@
"""Prepares a distribution for installation
"""
# The following comment should be removed at some point in the future.
# mypy: strict-optional=False
import logging
import os

View File

@ -1,3 +1,6 @@
# The following comment should be removed at some point in the future.
# mypy: strict-optional=False
from __future__ import absolute_import
import logging

View File

@ -8,6 +8,9 @@ These are meant to be used elsewhere within pip to create instances of
InstallRequirement.
"""
# The following comment should be removed at some point in the future.
# mypy: strict-optional=False
import logging
import os
import re

View File

@ -2,6 +2,9 @@
Requirements file parsing
"""
# The following comment should be removed at some point in the future.
# mypy: strict-optional=False
from __future__ import absolute_import
import optparse

View File

@ -1,3 +1,6 @@
# The following comment should be removed at some point in the future.
# mypy: strict-optional=False
from __future__ import absolute_import
import logging

View File

@ -1,3 +1,6 @@
# The following comment should be removed at some point in the future.
# mypy: strict-optional=False
from __future__ import absolute_import
import logging

View File

@ -1,3 +1,6 @@
# The following comment should be removed at some point in the future.
# mypy: strict-optional=False
from __future__ import absolute_import
import contextlib

View File

@ -1,3 +1,6 @@
# The following comment should be removed at some point in the future.
# mypy: strict-optional=False
import codecs
import locale
import re

View File

@ -1,3 +1,6 @@
# The following comment should be removed at some point in the future.
# mypy: strict-optional=False
from __future__ import absolute_import
import os

View File

@ -1,3 +1,6 @@
# The following comment should be removed at some point in the future.
# mypy: strict-optional=False
from __future__ import absolute_import
import contextlib

View File

@ -1,3 +1,6 @@
# The following comment should be removed at some point in the future.
# mypy: strict-optional=False
from __future__ import absolute_import, division
import contextlib

View File

@ -1,6 +1,10 @@
"""
Support for installing and building the "wheel" binary package format.
"""
# The following comment should be removed at some point in the future.
# mypy: strict-optional=False
from __future__ import absolute_import
import collections