Skip to content

Commit f8cb5bf

Browse files
[pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
1 parent 31d6fa4 commit f8cb5bf

File tree

3 files changed

+11
-3
lines changed

3 files changed

+11
-3
lines changed

mypy/build.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1050,7 +1050,10 @@ def generate_deps_for_cache(manager: BuildManager, graph: Graph) -> dict[str, di
10501050
def write_plugins_snapshot(manager: BuildManager) -> None:
10511051
"""Write snapshot of versions and hashes of currently active plugins."""
10521052
snapshot = json_dumps(manager.plugins_snapshot)
1053-
if not manager.metastore.write(PLUGIN_SNAPSHOT_FILE, snapshot) and manager.options.cache_dir != os.devnull:
1053+
if (
1054+
not manager.metastore.write(PLUGIN_SNAPSHOT_FILE, snapshot)
1055+
and manager.options.cache_dir != os.devnull
1056+
):
10541057
manager.errors.set_file(_cache_dir_prefix(manager.options), None, manager.options)
10551058
manager.errors.report(0, 0, "Error writing plugins snapshot", blocker=True)
10561059

mypy/dmypy_server.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -903,7 +903,9 @@ def _find_changed(
903903

904904
return changed, removed
905905

906-
def add_explicitly_new(self, sources: list[BuildSource], changed: list[tuple[str, str]]) -> None:
906+
def add_explicitly_new(
907+
self, sources: list[BuildSource], changed: list[tuple[str, str]]
908+
) -> None:
907909
# Always add modules that were (re-)added, since they may be detected as not changed by
908910
# fswatcher (if they were actually not changed), but they may still need to be checked
909911
# in case they had errors before they were deleted from sources on previous runs.

mypy/server/update.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -403,7 +403,10 @@ def update_module(
403403
# builtins and friends could potentially get triggered because
404404
# of protocol stuff, but nothing good could possibly come from
405405
# actually updating them.
406-
if is_stdlib_file(self.manager.options.abs_custom_typeshed_dir, path) or module in SENSITIVE_INTERNAL_MODULES:
406+
if (
407+
is_stdlib_file(self.manager.options.abs_custom_typeshed_dir, path)
408+
or module in SENSITIVE_INTERNAL_MODULES
409+
):
407410
return [], (module, path), None
408411

409412
manager = self.manager

0 commit comments

Comments
 (0)