Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: Preserve DPUTS output in comptest-based tests



On Wed, Jun 17, 2026 at 5:45 PM Philippe Altherr
<philippe.altherr@xxxxxxxxx> wrote:
>
> One thing I don't like too much with the current patch is that it doesn't respect the output order.
> The DPUTS messages appear in between other messages, presumably in the order they were found in the output.
> I'm wondering whether tackling this ordering issue would be worth the added complexity.

This is probably happening because the PTY output is being buffered --
I suspect in the case where they are grouped together it's not
line-buffered and where they are separated it is line-buffered, though
what you may have done to change it I don't immediately see.

It's probably more helpful to have the DPUTS output appear adjacent to
the input that triggered it, even though strictly speaking DPUTS
should be treated like stderr rather than like "normal" test output.
You could experiment with having zpty_handle_dputs use "print -u2".




Messages sorted by: Reverse Date, Date, Thread, Author