feat(agent): update itself between tests, asked in Setup and on by default #19

Merged
HumanBean merged 1 commit from HumanBean/Beanstalk:feat/auto-update into main 2026-11-15 21:47:49 +00:00
Owner

Why: testers shouldn't have to press Update Beanstalk to stay current. The farm works best when every agent runs the newest version.

What changed

  • A new setting, auto_update, in config.json. Setup asks "Update Beanstalk by itself", with a hint, beside the tray setting; it is in both the first setup and Settings. It is on by default, and a config.json from before the setting reads as on.
  • With it on:
    • The window looks for a new version every hour (AgentUpdate.AutoEvery) instead of every 6 hours.
    • A newer version on its own channel is put in place the same way the banner's button does it (ShouldAutoUpdate, then the button's command), so the banner shows the download and each step. With no test running, it updates at once. With one running, the runner is held so no new test starts, and the update comes once the test ends.
    • Switching to the other channel is never done automatically; that stays the person's choice.
  • Off: it looks every 6 hours and only offers the update, as before.
  • CheckDue decides whether a check is due; the timer ticks every hour.
  • Settings' channel row now has three columns, one per channel (there were four, left from Beta).
  • Docs: agent/README.md (Updates) and docs/using.md.

Testing

  • test_agent_core.py: 1560 checks pass. New checks:
    • auto_update defaults to on, including for an older config.json, and off is kept on save;
    • ShouldAutoUpdate only when the setting is on and the offer is newer, never for a channel switch or a development build;
    • the cadence: hourly when on, 6-hourly when off, and at once after starting.
  • The app builds (dotnet build App).
  • Not run: a real update from one published release to the next. The first chance is two nightlies in a row once this is in one.

Risks

  • beanstalk-agent serve (no window) doesn't update itself. self-update covers it there, and it can be added later.
  • A release that keeps failing to install is retried each hour, with the failure line each time.
**Why:** testers shouldn't have to press **Update Beanstalk** to stay current. The farm works best when every agent runs the newest version. **What changed** - **A new setting, `auto_update`**, in `config.json`. Setup asks "Update Beanstalk by itself", with a hint, beside the tray setting; it is in both the first setup and Settings. It is on by default, and a `config.json` from before the setting reads as on. - **With it on:** - The window looks for a new version every hour (`AgentUpdate.AutoEvery`) instead of every 6 hours. - A newer version on its own channel is put in place the same way the banner's button does it (`ShouldAutoUpdate`, then the button's command), so the banner shows the download and each step. With no test running, it updates at once. With one running, the runner is held so no new test starts, and the update comes once the test ends. - Switching to the other channel is never done automatically; that stays the person's choice. - **Off:** it looks every 6 hours and only offers the update, as before. - `CheckDue` decides whether a check is due; the timer ticks every hour. - Settings' channel row now has three columns, one per channel (there were four, left from Beta). - Docs: `agent/README.md` (Updates) and `docs/using.md`. **Testing** - `test_agent_core.py`: 1560 checks pass. New checks: - `auto_update` defaults to on, including for an older `config.json`, and off is kept on save; - `ShouldAutoUpdate` only when the setting is on and the offer is newer, never for a channel switch or a development build; - the cadence: hourly when on, 6-hourly when off, and at once after starting. - The app builds (`dotnet build App`). - Not run: a real update from one published release to the next. The first chance is two nightlies in a row once this is in one. **Risks** - `beanstalk-agent serve` (no window) doesn't update itself. `self-update` covers it there, and it can be added later. - A release that keeps failing to install is retried each hour, with the failure line each time.
feat(agent): update itself between tests, asked in Setup and on by default
Some checks failed
CI / Conventional Commit title (pull_request) Successful in 3s
CI / Workflow lint (actionlint) (pull_request) Successful in 3s
CI / Coordinator tests (pull_request) Has been cancelled
CI / Agent build and checks (pull_request) Has been cancelled
CI / Coordinator image (pull_request) Has been cancelled
5d12c72539
A new setting, auto_update (Setup: "Update Beanstalk by itself", on by
default, a config.json from before reads as on). With it on, the window
looks for a new version every hour instead of every 6, and a newer one
on its own channel is put in place as the banner's button would: at
once between tests, or after the running test ends (the runner is held,
so no next test starts). A switch of channel is never made by itself.
Off, it looks every 6 hours and only offers the update, as before.

Settings' channel row now has three columns, one per channel.

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Sign in to join this conversation.
No reviewers
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
MagicBeanDev/Beanstalk!19
No description provided.