Skip to content

enhance: enhance cdp#1094

Merged
nitpicker55555 merged 1 commit intofeat/browser_external_cdpfrom
enhance_cdp_st
Feb 17, 2026
Merged

enhance: enhance cdp#1094
nitpicker55555 merged 1 commit intofeat/browser_external_cdpfrom
enhance_cdp_st

Conversation

@fengju0213
Copy link
Copy Markdown
Collaborator

  • Problem: CDP port occupancy is tracked in a global pool and workforce shutdown
    clears the entire pool, causing parallel tasks to reuse the same port; clone
    temporarily mutates the parent toolkit’s CDP config without guaranteed restoration
    and leaks pre-acquired ports on failure; cdp_browsers uses a mutable default and
    can leak state across requests.
  • Fix: Track session/task ownership in the CDP pool and release by task instead of
    clearing globally; wrap clone mutation in try/finally with cleanup on failure;
    switch cdp_browsers to Field(default_factory=list).

What is the purpose of this pull request?

  • Bug fix
  • New Feature
  • Documentation update
  • Other

@fengju0213 fengju0213 self-assigned this Feb 11, 2026
@nitpicker55555 nitpicker55555 merged commit bd161a7 into feat/browser_external_cdp Feb 17, 2026
2 checks passed
@nitpicker55555
Copy link
Copy Markdown
Collaborator

Thanks @fengju0213 !

nitpicker55555 added a commit that referenced this pull request Feb 17, 2026
- listen_chat_agent.py: keep lock-protected clone with try/except/finally
- workforce.py: adopt release_by_task instead of clear_all for precise cleanup

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
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