Skip to content

fix: fall back to flat output when stderr is not a terminal (RIG-3585) - #7

Draft
rigel-mintaka wants to merge 1 commit into
mainfrom
upstream-vcs/rig-3585-tty-progress
Draft

rigel-mintaka wants to merge 1 commit into
mainfrom
upstream-vcs/rig-3585-tty-progress

Conversation

@rigel-mintaka

Copy link
Copy Markdown
Contributor

run_stdout chose the indicatif spinner (InteractiveOutput) whenever a command supported it and verbose was off, without checking whether stderr is a terminal. indicatif suppresses its own drawing on a non-tty, so a submit run with stderr piped or captured (CI, an agent shell, 2>file) showed no progress at all and looked hung.

Gate the choice on std::io::stderr().is_terminal() through a small pure use_interactive_output() helper, so a non-tty falls back to FlatOutput, which logs each step through tracing and stays visible. Unit-tested across all combinations of verbose / command-supports-interactive / tty.

Spec-impact: none. Refs RIG-3585

Co-authored-by: Matt Wilkinson matt@rigel.build

@linear-code

linear-code Bot commented Sep 11, 2026

Copy link
Copy Markdown

RIG-3585

`run_stdout` chose the `indicatif` spinner (`InteractiveOutput`) whenever a command supported it and `verbose` was off, without checking whether stderr is a terminal. `indicatif` suppresses its own drawing on a non-tty, so a submit run with stderr piped or captured (CI, an agent shell, `2>file`) showed no progress at all and looked hung.

Gate the choice on `std::io::stderr().is_terminal()` through a small pure `use_interactive_output()` helper, so a non-tty falls back to `FlatOutput`, which logs each step through `tracing` and stays visible. Unit-tested across all combinations of verbose / command-supports-interactive / tty.

Spec-impact: none. Refs RIG-3585

Co-authored-by: Matt Wilkinson <matt@rigel.build>
@rigel-mintaka
rigel-mintaka force-pushed the upstream-vcs/rig-3585-tty-progress branch from 94174fc to 72b2c94 Compare September 11, 2026 23:24
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