Skip to content

Commit 9931fb5

Browse files
committed
Add type ignores to distutils.command.install SCHEMES
1 parent e8b735f commit 9931fb5

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

src/pip/_internal/locations/__init__.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,7 @@ def _looks_like_bpo_44860() -> bool:
8080
8181
See <https://bugs.python.org/issue44860>.
8282
"""
83-
from distutils.command.install import INSTALL_SCHEMES
83+
from distutils.command.install import INSTALL_SCHEMES # type: ignore
8484

8585
try:
8686
unix_user_platlib = INSTALL_SCHEMES["unix_user"]["platlib"]
@@ -105,7 +105,7 @@ def _looks_like_red_hat_lib() -> bool:
105105
106106
This is the only way I can see to tell a Red Hat-patched Python.
107107
"""
108-
from distutils.command.install import INSTALL_SCHEMES
108+
from distutils.command.install import INSTALL_SCHEMES # type: ignore
109109

110110
return all(
111111
k in INSTALL_SCHEMES
@@ -117,7 +117,7 @@ def _looks_like_red_hat_lib() -> bool:
117117
@functools.cache
118118
def _looks_like_debian_scheme() -> bool:
119119
"""Debian adds two additional schemes."""
120-
from distutils.command.install import INSTALL_SCHEMES
120+
from distutils.command.install import INSTALL_SCHEMES # type: ignore
121121

122122
return "deb_system" in INSTALL_SCHEMES and "unix_local" in INSTALL_SCHEMES
123123

src/pip/_internal/locations/_distutils.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
import logging
2020
import os
2121
import sys
22-
from distutils.command.install import SCHEME_KEYS
22+
from distutils.command.install import SCHEME_KEYS # type: ignore
2323
from typing import TYPE_CHECKING
2424

2525
from pip._internal.models.scheme import Scheme

0 commit comments

Comments
 (0)