mirror of
https://github.com/Homebrew/BrewUI.git
synced 2026-10-02 00:24:33 +08:00
The handoff guard matched only `.running`, so a self-upgrade could quit the app during `.reconciling` and kill the `brew info --installed` (and, with install-from-API off, the `brew update`) the reconcile runs. Those are read-only, and the app relaunches and refetches, but the guard's intent is that no mutating operation is left unfinished. Add `BrewOperationPhase.isUnfinishedMutation` and guard on it. The predicate lives in BrewCore so it is covered by the package suites; the app target is not. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>