Skip to content

[Bug]: The default column set does not fit a normal terminal #41

Description

@fedonman

Bug Description

The default column set is ten columns: eight percentage constraints summing to 55%, plus Name at Min(15) and WorkDir at Min(20). Two panels are visible by default and the layout splits 50/50, so on an 80-column terminal the table gets about 40 columns. The 35 characters of minimums eat nearly all of that, and the eight percentage columns collapse to nothing, including the job ID that every other action keys on.

Steps to Reproduce

Run sqwatch with the default configuration in an 80x24 terminal, which is the default size and what you get in a fresh SSH session to a login node.

Expected Behavior

The default columns fit the default terminal.

Actual Behavior

--- table gets 40 cols (80-column terminal) ---
|    Name                 WorkDir      |
| ▸  train_resnet5        /scratch/alic|

--- table gets 100 cols (200-column terminal) ---
|   ID     Name           State  Time    User  Node     Partiti CPU Memory WorkDir |
| ▸ 123456 train_resnet50 RUNNIN 4:32:10 alice gpu-node gpu     16  64G    /scratch|

Eight of the ten columns are gone at 80 columns rather than merely narrow, so the first thing a new user sees is a table with no job id, no state and no time. Worth noting separately from the width problem: even at 200 columns the ID is cut to six characters, because 6% only reaches seven characters on a terminal wider than 117, so a seven-digit job id never renders in full.

System Information

sqwatch 0.2.0, source checkout at 4c594fb
Ubuntu 26.04.1, rustc 1.97.1, ratatui 0.30

Trimming the defaults is the one-line half and is worth doing on its own. WorkDir is the obvious cut: it is the widest column, the least glanceable, and the script and log panes already show where the job lives, so dropping it frees 20 characters of minimum straight away.

Past that, a fixed 50/50 split cannot be right for both an 80-column and a 200-column terminal. Two things worth landing alongside an adjustable split: give the table a minimum width so the panels shrink before it does, and make the startup split width-aware so a narrow terminal opens one panel instead of two.

Not worth building: a column auto-hide that drops columns as the terminal narrows. It means no column can be relied on to be present, which interacts badly with #10.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingviewsTouches the views layer: job table, panes, widgets, theme

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions