Repository navigation
feat: auto-expand projects that need attention - #3
Merged
Merged
Conversation
A project row now opens by itself when its stoplight goes red or yellow and closes when it recovers. Expansion is edge-triggered: it changes only when a project's stoplight changes or on its first sighting, so a row collapsed by hand stays collapsed until something actually happens to it. Resource rows are still expanded by hand, since expanding one fetches its deploy log. Expansion inserts rows, so after each snapshot the cursor is put back on the same logical row instead of the same index. Existing tests that hard-coded cursor positions below the red Beta project shift down one row. Ported from aws-green #60. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
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.
A project row opens by itself when its stoplight goes red or yellow, and closes when it recovers. It's edge-triggered: expansion changes only on a stoplight change or a first sighting, so a hand-collapsed row stays collapsed. Resource rows still open by hand, since that fetches the deploy log. After each snapshot the cursor goes back to the same logical row. Documented in README and CONTEXT.md. Ported from aws-green #60.
Tests:
internal/ui/autoexpand_test.gocovers first sighting, status change and recovery, a manual collapse surviving identical polls, a status change overriding a manual collapse, the cursor staying on its row, and a removed project being forgotten. Mutation-checked: making it level-triggered or removing the cursor restore fails the tests. Existing tests with hard-coded cursor positions below the red Beta project shift down one row.🤖 Generated with Claude Code