From a77b6f8171c5e663e718fb4cd8f39ba662595375 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Mon, 27 Jul 2026 09:10:25 +0000 Subject: [PATCH] [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci --- studio/backend/core/inference/sd_cpp_backend.py | 5 +---- studio/backend/tests/test_sd_cpp_args.py | 6 +++--- 2 files changed, 4 insertions(+), 7 deletions(-) diff --git a/studio/backend/core/inference/sd_cpp_backend.py b/studio/backend/core/inference/sd_cpp_backend.py index ffb562cfd9..34024cb72e 100644 --- a/studio/backend/core/inference/sd_cpp_backend.py +++ b/studio/backend/core/inference/sd_cpp_backend.py @@ -999,10 +999,7 @@ class SdCppDiffusionBackend: return images, seeds def _restart_server_on_cpu_backend( - self, - state: _SdState, - error_text: str, - cancel: threading.Event, + self, state: _SdState, error_text: str, cancel: threading.Event ) -> Optional[SdCppServer]: """Relaunch this checkpoint's sd-server with ``--backend cpu``; None if that does not apply. diff --git a/studio/backend/tests/test_sd_cpp_args.py b/studio/backend/tests/test_sd_cpp_args.py index f93051edc9..c0f8ee01d8 100644 --- a/studio/backend/tests/test_sd_cpp_args.py +++ b/studio/backend/tests/test_sd_cpp_args.py @@ -541,9 +541,9 @@ def test_ggml_unsupported_op_abort_is_recognised_only_with_both_markers(): ) assert is_ggml_unsupported_op_abort(abort) is True # The RMS_NORM shape of the same abort (text encoder) counts too. - assert is_ggml_unsupported_op_abort( - "error: unsupported op 'RMS_NORM'\nggml_abort + 156" - ) is True + assert ( + is_ggml_unsupported_op_abort("error: unsupported op 'RMS_NORM'\nggml_abort + 156") is True + ) # Neither marker alone is enough, and an unrelated death is never a match. assert is_ggml_unsupported_op_abort("unsupported op 'MUL_MAT'") is False assert is_ggml_unsupported_op_abort("ggml_abort + 156") is False