File tree Expand file tree Collapse file tree 2 files changed +8
-4
lines changed Expand file tree Collapse file tree 2 files changed +8
-4
lines changed Original file line number Diff line number Diff line change 9191from mypy .renaming import LimitedVariableRenameVisitor , VariableRenameVisitor
9292from mypy .stats import dump_type_stats
9393from mypy .stubinfo import (
94- is_legacy_bundled_package ,
9594 legacy_bundled_packages ,
9695 non_bundled_packages ,
9796 stub_distribution_name ,
@@ -2672,7 +2671,10 @@ def find_module_and_diagnose(
26722671 # negatives. (Unless there are stubs but they are incomplete.)
26732672 global_ignore_missing_imports = manager .options .ignore_missing_imports
26742673 if (
2675- any ("." .join (id_components [:i ]) in legacy_bundled_packages for i in range (len (id_components ), 0 , - 1 ))
2674+ any (
2675+ "." .join (id_components [:i ]) in legacy_bundled_packages
2676+ for i in range (len (id_components ), 0 , - 1 )
2677+ )
26762678 and global_ignore_missing_imports
26772679 and not options .ignore_missing_imports_per_module
26782680 and result is ModuleNotFoundReason .APPROVED_STUBS_NOT_INSTALLED
Original file line number Diff line number Diff line change @@ -3138,9 +3138,11 @@ import bleach.xyz
31383138from bleach.abc import fgh
31393139[file bleach/__init__.pyi]
31403140[out]
3141- main:1: error: Cannot find implementation or library stub for module named "bleach.xyz"
3141+ main:1: error: Library stubs not installed for "bleach.xyz"
3142+ main:1: note: Hint: "python3 -m pip install types-bleach"
3143+ main:1: note: (or run "mypy --install-types" to install all missing stub packages)
31423144main:1: note: See https://mypy.readthedocs.io/en/stable/running_mypy.html#missing-imports
3143- main:2: error: Cannot find implementation or library stub for module named "bleach.abc"
3145+ main:2: error: Library stubs not installed for "bleach.abc"
31443146
31453147[case testMissingSubmoduleOfInstalledStubPackageIgnored]
31463148# flags: --ignore-missing-imports
You can’t perform that action at this time.
0 commit comments