Skip to content

fix(tui): keep session status current in the app - #45

Merged
kerem-kaynak merged 1 commit into
mainfrom
fix/app-status-refresh
Sep 30, 2026
Merged

kerem-kaynak merged 1 commit into
mainfrom
fix/app-status-refresh

Conversation

@kerem-kaynak

Copy link
Copy Markdown
Collaborator

What does this PR do and why?

The app's session status could freeze. A refresh carries the last status read onto the new list so rows don't blink, then ran the new status read on that carried copy. The read only covers sessions in plain running state, so a session last seen idle or working was skipped on every later refresh, manual ones included. Its state, strain and setup status stayed at whatever was read first, such as a finished setup still showing · setup. The read now gets the list as the cloud returned it, and the carried copy is used only for display.

The app also refreshed on its own only while a create, delete, fill or bake was underway. It now also polls quickly while a setup runs, and every 30 seconds otherwise, because sessions go idle, work and park themselves with no local signal. A failed read no longer ends the refreshing.

Related issue

None.

Tests

  • TestRefreshReadsStatusFresh: the carried reading stays on screen, and the new status read gets the cloud's list. It fails without the fix (got idle/"running").
  • go test -race ./..., go vet ./... and gofmt -l pass.

Checklist

  • gofmt -l . produces no output and go vet ./... passes
  • make build succeeds (if this touches supervisor/session code)
  • Tests added or updated for behavior changes
  • Docs updated if applicable

A refresh carried the last status read onto the new list for display, then ran the new read on that carried copy. The read only covers sessions in plain running state, so every session last seen idle or working was skipped from then on and its status froze: a finished setup kept showing as running, manual refresh included. The read now gets the list as the cloud returned it. The app also refreshes on its own while a setup runs and every 30 seconds otherwise, since sessions go idle, work and park themselves, and a failed read no longer ends the refreshing.

@greptile-apps greptile-apps Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Your trial has ended. Reactivate Greptile to resume code reviews.

@kerem-kaynak
kerem-kaynak merged commit 486cd3d into main Sep 30, 2026
3 checks passed
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