Skip to content

fix: Disable grapheme cluster probe on Windows PosixSysTerminal#1696

Merged
gnodet merged 1 commit intomasterfrom
fix/grapheme-probe-windows-2
Mar 11, 2026
Merged

fix: Disable grapheme cluster probe on Windows PosixSysTerminal#1696
gnodet merged 1 commit intomasterfrom
fix/grapheme-probe-windows-2

Conversation

@gnodet
Copy link
Copy Markdown
Member

@gnodet gnodet commented Mar 11, 2026

Summary

  • The 4.0.3 fix (fix: Skip grapheme cluster probe on Windows to prevent output corruption #1695) was insufficient — Maven CI still fails on Windows with [?2027$p leaking into subprocess output
  • The isSystemStream() check is unreliable on Windows MSYSTEM environments (can return true for streams that are being captured by a parent process)
  • Simplify the guard to disable the DECRQM probe entirely on Windows PosixSysTerminal, since the slave output always goes to a raw FileDescriptor which makes probing inherently risky

Fixes the remaining CI failure: https://github.com/apache/maven/actions/runs/22931697655/job/66554940328

Test plan

  • All 16 GraphemeClusterModeTest tests pass
  • All 184 terminal module tests pass

The previous fix (#1695) only blocked the DECRQM probe when using
ExecPty and the output stream was not detected as a system stream.
This was insufficient because the isSystemStream() check is unreliable
on Windows MSYSTEM environments — it can return true for streams that
are being captured by a parent process.

Simplify the guard to disable the probe entirely on Windows
PosixSysTerminal. On Windows, PosixSysTerminal only exists for
Cygwin/MSYSTEM environments where the slave output goes to a raw
FileDescriptor, making the probe inherently risky.
@gnodet gnodet merged commit 2b64601 into master Mar 11, 2026
9 checks passed
@gnodet gnodet deleted the fix/grapheme-probe-windows-2 branch March 11, 2026 07:16
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.

1 participant