Skip to content

Commit 9ee0acc

Browse files
committed
fix(logging[load]): move reattach output to structured extra
why: Inlining tmux stdout in the log message string defeats structured log aggregation and filtering. what: - Move display-message output from format arg to extra tmux_stdout key
1 parent 476a550 commit 9ee0acc

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

src/tmuxp/cli/load.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -184,7 +184,10 @@ def _reattach(builder: WorkspaceBuilder, colors: Colors | None = None) -> None:
184184
proc = builder.session.cmd("display-message", "-p", "'#S'")
185185
for line in proc.stdout:
186186
tmuxp_echo(colors.info(line) if colors else line)
187-
logger.debug("reattach display-message output: %s", line.strip())
187+
logger.debug(
188+
"reattach display-message output",
189+
extra={"tmux_stdout": [line.strip()]},
190+
)
188191

189192
if "TMUX" in os.environ:
190193
builder.session.switch_client()

0 commit comments

Comments
 (0)