Skip to content

fix(extension): bound request-help cleanup wait - #284

Merged
iuyo5678 merged 2 commits into
Tencent:mainfrom
dvd233:codex/fix/request-help-cleanup-timeout-277
Sep 20, 2026
Merged

iuyo5678 merged 2 commits into
Tencent:mainfrom
dvd233:codex/fix/request-help-cleanup-timeout-277

Conversation

@dvd233

@dvd233 dvd233 commented Sep 18, 2026

Copy link
Copy Markdown
Contributor

Summary

  • Bound the request-help cleanup wait to 1 second when the content script has already reported a user decision.
  • Keep cleanup best-effort, but do not hold the daemon RPC open forever when tabs.sendMessage or notification cleanup never settles.
  • Added a regression test for a hanging cleanup transport.

Fixes #277

Root cause

finishHelpFromContent waits for cleanupHelp before resolving the request. That cleanup awaits browser messaging without a deadline, so a hung message channel can outlive the daemon's cleanup grace and surface as request-help timed out and cleanup could not be confirmed.

The fix preserves the existing wait when cleanup completes normally and only falls back after the bounded budget.

Validation

  • Regression red on the base commit: the new test timed out at 5 seconds.
  • vitest run src/tools/__tests__/human-loop.test.ts: 30 passed.
  • Extension typecheck: passed.
  • Full extension suite: 1,857 passed, 103 skipped, 14 files skipped by repository configuration.
  • Extension production build: passed.
  • git diff --check: passed.

dvd233 and others added 2 commits September 18, 2026 13:45
Start tab and notification cleanup concurrently so a stalled notification
cannot prevent cancellation messages from reaching the page overlays.

Cover content completion, timeout, and cancellation across multiple tabs.
@iuyo5678
iuyo5678 merged commit 2a4ecac into Tencent:main Sep 20, 2026
7 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.

Stuck 'Agent is controlling' overlay blocks all real clicks and makes bsk upload fail (extension reload required)

2 participants