From 9d4d382b3653e054595d2b54de1fe2e542ccf4d9 Mon Sep 17 00:00:00 2001 From: Ayaz Salikhov Date: Mon, 24 Feb 2025 11:50:39 +0000 Subject: [PATCH] Revert wrong usage of textwrap.dedent --- tagging/utils/quoted_output.py | 14 +++++--------- 1 file changed, 5 insertions(+), 9 deletions(-) diff --git a/tagging/utils/quoted_output.py b/tagging/utils/quoted_output.py index 8110b9f1..4df8b34e 100644 --- a/tagging/utils/quoted_output.py +++ b/tagging/utils/quoted_output.py @@ -1,7 +1,5 @@ # Copyright (c) Jupyter Development Team. # Distributed under the terms of the Modified BSD License. -import textwrap - from docker.models.containers import Container from tagging.utils.docker_runner import DockerRunner @@ -16,11 +14,9 @@ def quoted_output(container: Container, cmd: str) -> str: assert cmd_output, f"Command `{cmd}` returned empty output" - return textwrap.dedent( - f"""\ - `{cmd}`: + return f"""\ +`{cmd}`: - ```text - {cmd_output} - ```""" - ) +```text +{cmd_output} +```"""