From 14dc0077dca91b1c388c866b8de49f9ff41e1003 Mon Sep 17 00:00:00 2001 From: Sorin Sbarnea Date: Thu, 8 Feb 2024 16:28:23 +0000 Subject: [PATCH] Fix background color on matrix command (#4133) Fixes: #4123 --- src/molecule/util.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/molecule/util.py b/src/molecule/util.py index e2c727d70c..5e8f1bdefb 100644 --- a/src/molecule/util.py +++ b/src/molecule/util.py @@ -391,5 +391,6 @@ def bool2args(data: bool) -> list[str]: def print_as_yaml(data: Any) -> None: """Render python object as yaml on console.""" - result = Syntax(safe_dump(data), "yaml") + # https://github.com/Textualize/rich/discussions/990#discussioncomment-342217 + result = Syntax(code=safe_dump(data), lexer="yaml", background_color="default") console.print(result)