Skip to content

Commit 747679f

Browse files
committed
Refactor print_chunk function for improved readability and maintainability.
1 parent 9907a41 commit 747679f

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

src/mcp_client_cli/cli.py

+1-2
Original file line numberDiff line numberDiff line change
@@ -144,7 +144,6 @@ def print_chunk(chunk: any) -> None:
144144
Print the chunk of agent response to the console.
145145
It will stream the response to the console as it is received.
146146
"""
147-
148147
# If this is a message chunk
149148
if isinstance(chunk, tuple) and chunk[0] == "messages":
150149
message_chunk = chunk[1][0] # Get the message content
@@ -176,7 +175,7 @@ def print_chunk(chunk: any) -> None:
176175
for arg, value in args.items():
177176
lines.append(f" {arg}: {value}")
178177
print("\n".join(lines))
179-
print()
178+
print()
180179

181180
def main() -> None:
182181
"""Entry point of the script."""

0 commit comments

Comments
 (0)