Skip to content

fix: honor explicit fallbacks and preserve finished shell calls - #2020

Merged
AbirAbbas merged 3 commits into
devfrom
salvage/1738-explicit-fallbacks-and-cancellation
Oct 28, 2026
Merged

AbirAbbas merged 3 commits into
devfrom
salvage/1738-explicit-fallbacks-and-cancellation

Conversation

@AbirAbbas

Copy link
Copy Markdown
Collaborator

A cancellation watcher that starts after a shell call has returned can find both completion and cancellation ready. If it picks cancellation, it can kill a background server or watcher that the completed call left running. This checks for completion before signalling the process group. Commands that are still running keep their existing cancellation behavior.

On dev, a fallback list that names only the failing model also falls through to catalog guesses. This respects any nonblank configured list before the catalog is consulted. The original blank-only-list control stays, so an effectively empty setting can still use catalog suggestions.

This carries forward santoshkumarradha's fixes and regressions for completed calls and fallback lists from #1738, originally b11e3d7a1b523464490e6b5cf87ccbb00da695cd and a8039c5cf387fdb1a90cfa2e1273a254bf7b8ab3. The completion check is adapted to current dev, and both original regressions are kept. The manual and a change entry describe the result.

Most of #1738's pair/continue work is already on dev through #1888, #1950, #1967 and #1990. This PR covers only these two independent defects. The rest of #1738 (task/checker pin fallback policy, a deadline for blocked skill imports, and harness question-publication ordering) needs scope decisions and is tracked separately.

app/v3 already has a narrower fix for the self-only list. The full original regression still fails there for a blank-only list, so a port to app/v3 is a possible follow-up.

Validation (two commits on dev 3bf6072fd):

  • With internal/exec/bare/promote.go reverted to dev and the regression kept, go test -count=1 -p 1 ./internal/exec/bare -run '^TestACallThatReturnedLeavesItsBackgroundProcessAlone$' fails with "the cancellation after a finished call killed the group it left running". With the fix restored, it passes.
  • With internal/provider/endpoints.go reverted to dev, TestAFallbackListNamingOnlyTheFailingModelIsAPin fails by returning catalog guesses for a self-only list. With the fix restored, it passes, including the blank-only control.
  • Named tests pass:
    • four in internal/provider: the original regression, explicit-list precedence, no provider-layer model hop, and pacing;
    • five in internal/exec/bare: the regression, cancellation before start, cancellation while running, a leaked pipe, and timeout;
    • two in internal/manual.
  • go vet on all three packages, gofmt and whitespace checks are clean. The process-group regression is POSIX-only. Full suites and live-provider tests were not run locally; CI covers them.

🤖 Generated with Claude Code

AbirAbbas and others added 3 commits October 28, 2026 18:29
Carry forward the completed-call cancellation fix and regression from santoshkumarradha in #1738 (original commit b11e3d7). Pairing and moving chats already shipped; preserve only this missing cancellation behavior on current dev.

Co-authored-by: santoshkumarradha <instrument.santosh@gmail.com>
Carry forward santoshkumarradha PR #1738 commit a8039c5: naming only the failing model must not permit a catalog guess, while a list of blanks still permits inference. Retain the original regression and document the behavior.

Co-authored-by: santoshkumarradha <instrument.santosh@gmail.com>
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
@AbirAbbas
AbirAbbas merged commit af03038 into dev Oct 28, 2026
6 checks passed
@AbirAbbas
AbirAbbas deleted the salvage/1738-explicit-fallbacks-and-cancellation branch October 28, 2026 22:47
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