Skip to content

[codex] Add quiet terminal mode for agents#3213

Merged
hengyunabc merged 3 commits into
masterfrom
codex/quiet-terminal
Jun 9, 2026
Merged

[codex] Add quiet terminal mode for agents#3213
hengyunabc merged 3 commits into
masterfrom
codex/quiet-terminal

Conversation

@hengyunabc

Copy link
Copy Markdown
Collaborator

Summary

  • add session-level quiet mode and suppress welcome output for agent sessions
  • pass quiet session creation through MCP command execution and HTTP websocket terminal setup
  • add arthas-client --quiet support with the arthas-agent terminal type
  • remove the compatibility no-arg/default CommandExecutor.createSession() path so session creation is explicit

Validation

  • ./mvnw -pl arthas-mcp-server -Dtest=ArthasCommandSessionManagerQuietTest,ArthasCommandContextAuthTest,DefaultCreateTaskContextAuthTest test
  • ./mvnw -pl core -am -Dtest=ShellImplQuietTest,TtyWebSocketFrameHandlerQuietTest,CommandExecutorImplQuietSessionTest -Dsurefire.failIfNoSpecifiedTests=false test
  • ./mvnw -pl client -DskipTests compile
  • ./mvnw -pl core -am -DskipITs test
  • git diff --check

@hengyunabc hengyunabc requested a review from Copilot June 9, 2026 06:33
@hengyunabc hengyunabc marked this pull request as ready for review June 9, 2026 06:33

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: b5f170c32d

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment on lines +283 to +285
final TelnetClient telnet = telnetConsole.isQuiet()
? new TelnetClient("arthas-agent")
: new TelnetClient();

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Handle prompts at column 0 for quiet batch sessions

When --quiet is combined with -c/-f, this terminal type suppresses the welcome banner, so the first server output can be the prompt itself at the start of the stream. batchModeRun only releases the command loop when line.indexOf(PROMPT) > 0, so a prompt at index 0 is ignored and the client hangs indefinitely with the default timeout before sending the first command. Either avoid quiet mode for batch runs or update the prompt detection to accept index 0.

Useful? React with 👍 / 👎.

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot encountered an error and was unable to review this pull request. You can try again by re-requesting a review.

@hengyunabc hengyunabc merged commit 518238a into master Jun 9, 2026
10 of 15 checks passed
@hengyunabc hengyunabc deleted the codex/quiet-terminal branch June 9, 2026 08:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants