Repository navigation
air: Fit air list Experiment and User columns to the terminal width - #7583
Merged
Merged
Conversation
The MLflow column of `air list` cut a long run name to its first characters, but showed the last characters of the run ID when the run had no name. Rows with long names sharing a prefix looked identical. The column now shows the run's name, or its ID when the name is unknown, and shortens either one the same way: a label that doesn't fit keeps its end behind a leading "…". Co-authored-by: Isaac <no-reply@databricks.com>
Co-authored-by: Isaac <no-reply@databricks.com>
The interactive list sized every column from its content, capped at 36 cells, and never looked at the terminal width. Long Experiment and User values pushed the columns to their right past the window edge. The list now tracks the width from WindowSizeMsg and shrinks Experiment and User, widest first, down to floors of 12 and 8 cells. The one-shot table (piped, NO_COLOR, --limit) is unchanged. Co-authored-by: Isaac <no-reply@databricks.com>
Co-authored-by: Isaac <no-reply@databricks.com>
Collaborator
✅ Integration test reportCommit: e004948
Top 6 slowest tests (at least 2 minutes):
|
Covers the list row's width budget when a retry note follows a shortened label, and the whole run ID in the info pane. Also corrects the label's doc comment and widens the changelog entry to cover run IDs. Co-authored-by: Isaac <no-reply@databricks.com>
truncate measured display width but cut by character count, so a cell with wide (for example CJK) text overflowed its column. It now cuts by display width. truncateStart is the keep-the-end variant, and the MLflow label uses it instead of its own loop. Co-authored-by: Isaac <no-reply@databricks.com>
Experiment names often share a prefix and differ at the end, so a cell shrunk to fit the terminal showed the same text for different experiments. The interactive list now keeps the end of the name behind a leading "…", the same rule the MLflow column uses. User still keeps its start, and the one-shot table is unchanged. Co-authored-by: Isaac <no-reply@databricks.com>
Co-authored-by: Isaac <no-reply@databricks.com>
Co-authored-by: Isaac <no-reply@databricks.com>
caroline-db
approved these changes
Nov 13, 2026
Collaborator
❌ Integration test reportCommit: 8bc778f
16 interesting tests: 12 RECOVERED, 4 flaky
Top 50 slowest tests (at least 2 minutes):
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Changes
In the interactive
air listtable, the Experiment and User columns now shrink to fit the terminal width instead of pushing the columns to their right past the window edge.WindowSizeMsgand lays the columns out against it, on resize and when a lazily loaded page arrives.…, the rule air: Shorten MLflow run names and IDs the same way inair list#7582 uses for the MLflow column, because experiment names often share a prefix. A shortened User keeps its start, since emails differ there.NO_COLOR,--limit) is unchanged, including which end of a long Experiment it keeps.This PR builds on #7582 (merged), which provides
truncateStartand the display-widthtruncate.Known gaps:
i), which showsN/Afor many runs today. air: Show the experiment, accelerators and config in theair listinfo pane #7587 fixes that.Why
Every column was sized from its content, with Experiment and User capped at 36 cells, and nothing looked at the terminal width. With long experiment names the table was about 180 cells wide, so the columns to the right of Experiment were unreadable in most terminals. Internal ticket: CNXT-2610.
In a 133-column terminal against real runs, cutting 14 distinct experiment names to 12 cells at their end left 7 distinct labels; keeping the end leaves all 14 distinct.
Tests
go test ./cmd/air,./task lint-q.Manual test
air list --all-status --all-usersagainst a staging workspace in a 133-column terminal: Experiment shrank to 12 cells and User to 8. All 20 Experiment cells kept their end behind a leading…, and all 20 User cells kept their start. The table was 136 cells wide, so theAcceleratorsheader lost its last 3 characters.The list model with fixture rows, long Experiment and User values:
160 columns, w/o fix (cut at the window edge):
160 columns, w/ fix:
120 columns, w/ fix (Accelerators still cut off):
This pull request and its description were written by Isaac.