Skip to content

fix: Stop the rollout watch when sign-in is refused - #639

Merged
scotwells merged 1 commit into
mainfrom
claude/project-thread-n44hjj
Nov 11, 2026
Merged

scotwells merged 1 commit into
mainfrom
claude/project-thread-n44hjj

Conversation

@scotwells

@scotwells scotwells commented Nov 11, 2026 •

Copy link
Copy Markdown
Contributor

Requested by Scot Schuchert-Wells · project thread

When a user's sign-in expires while deploy or rollout is watching a rollout, the watch keeps polling every two seconds forever and prints nothing. With this change the watch stops as soon as the platform refuses the credentials, either as unauthenticated or as forbidden. The user sees that the rollout continues in the background and is told to run datumctl login. Other errors still retry as before.

This covers the first acceptance criterion of #505 and adds the test it asks for. Backoff with a deadline for other errors, and refreshing the token in long-running commands, are left for follow-up PRs, so the issue stays open.

Test plan

  • New unit test refuses the credentials partway through a watch and checks it stops with the sign-in hint, for both unauthenticated and forbidden
  • Confirmed the new test fails (watch keeps polling) without the fix
  • Existing compute CLI tests pass
  • CI build, test and lint pass

Related to #505


Generated by Claude Code

The rollout watch treated every List error as transient and polled every
2 seconds forever. Once the sign-in token expired, each poll was refused
as unauthenticated, nothing was printed, and the process never exited.

Key changes:
- stop the watch on 401 or 403 and tell the user to run 'datumctl login'
- add a test where the credentials are refused partway through a watch
@scotwells
scotwells requested a review from a team as a code owner November 11, 2026 14:59
@scotwells scotwells self-assigned this Nov 11, 2026

@kevwilliams kevwilliams 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.

Verified only Unauthorized and Forbidden stop the watch, other List errors still retry, and the test fails without the fix.

@scotwells
scotwells merged commit aad2783 into main Nov 11, 2026
12 checks passed
@scotwells
scotwells deleted the claude/project-thread-n44hjj branch November 11, 2026 20:10
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.

2 participants