Skip to content

[Bug]: claude-picker-runtime busy-picker-port test races on a released port #7812

Closed

Description

@lidge-jun

Client or integration

Other

Area

Other

Summary

tests/claude-integration/claude-picker-runtime.test.ts:780 ("a busy picker port leaves the applied profile for the next restart to retry") picks a port pair by probing and releasing (freePortPair), squats the picker port, then releases it and expects the next start to rebind the same port. If another process takes the port in between, the second start reports EADDRINUSE and the test fails although the product behavior is correct. Observed once on Linux in Cross-platform CI run 40457212804 (job 122033294440) for the v2.93.0 release commit; the same tree passed in three other runs. Expected: the test does not depend on re-acquiring a released port (same class as the fix in #7740).

Reproduction

Intermittent. Run the test file repeatedly under parallel load on Linux; it fails when another listener takes the released picker port before the second start.

Version

2.93.0 (88aaa75)

Operating system

Ubuntu (GitHub-hosted runner)

Provider and model

No response

Logs or error output

Claude Desktop picker proxy could not start: listen EADDRINUSE: address already in use 127.0.0.1:33317
expect(second?.pickerProxyPort).toBe(pickerPort) -> Expected: 33317, Received: null

Screenshots and supporting files

No response

Redacted configuration

n/a

Checks

  • I searched existing issues and documentation.
  • I removed secrets, tokens, account details, request credentials, and personal data.

Activity

  1. coderabbitai commented on Oct 27, 2026

    @coderabbitai
    Contributor
    🔗 Related PRs

    #7740 - test(cli): let the forged sibling-env start bind its own port [open]


    📝 Issue Planner

    Check the box below or use the @coderabbitai plan command to generate an implementation plan and prompts that you can use with your favorite coding assistant.

    • Create Plan

    🧪 Issue enrichment is currently in open beta.

    To disable automatic issue enrichment, add the following to your .coderabbit.yaml:

    issue_enrichment:
      auto_enrich:
        enabled: false

    💬 Have feedback or questions? Drop into our discord!

  2. lidge-jun commented on Oct 28, 2026

    @lidge-jun
    OwnerAuthor

    Fixed on dev by #7847 (a4e4cda). The busy-picker-port case keeps the conflicting listener held for the whole test and lets the restart bind through the existing bind seam, so it no longer depends on re-acquiring a released port. The other release-then-rebind sites in the suite were converted the same way.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions