Skip to content

fix: preserve background marker in batch mode - #3245

Closed
patrick-andstar wants to merge 1 commit into
alibaba:masterfrom
patrick-andstar:fix/batch-background-plaintext
Closed

fix: preserve background marker in batch mode#3245
patrick-andstar wants to merge 1 commit into
alibaba:masterfrom
patrick-andstar:fix/batch-background-plaintext

Conversation

@patrick-andstar

Copy link
Copy Markdown

Summary

Keep a trailing background marker after the plaintext output pipeline generated by the Telnet batch client.

Fixes #3223

Motivation

TelnetConsole.batchModeRun() appends | plaintext to every batch command. For a command ending in &, appending the pipeline after the marker makes & no longer the final token, so the server does not run the command in the background.

Changes

  • Insert | plaintext before a trailing background marker instead of after it.
  • Add a regression test for a batch command ending in &.

Tests

  • Docker Desktop, Maven 3.9.9 / Eclipse Temurin JDK 17: mvn -V -ntp -pl client -am -Dtest=TelnetConsoleBatchModeTest -Dsurefire.failIfNoSpecifiedTests=false test (4 tests, 0 failures, 0 errors)

Duplicate Check

Checked the first 100 open pull requests for batchModeRun, plaintext, and the Issue wording. No matching open pull request was found.

@CLAassistant

CLAassistant commented Jul 21, 2026

Copy link
Copy Markdown

CLA assistant check
All committers have signed the CLA.

@patrick-andstar patrick-andstar closed this by deleting the head repository Aug 16, 2026
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