node icon indicating copy to clipboard operation
node copied to clipboard

net: improve network family autoselection handle handling

Open ShogunPanda opened this issue 1 year ago • 3 comments

This PR fixes network family autoselections in three area:

  1. Moves handle swapping before trying a new connection, as suggested in https://github.com/npm/cli/issues/6409#issuecomment-1577019656
  2. Avoids spawning two different connection attempts, which could happen if a TLSSocket with a manually set backing Socket was used. See: https://github.com/KararTY/dank-twitch-irc/issues/13#issuecomment-1591251579
  3. Correctly handles AbortSignal when using network family auto selection.

Fixes: https://github.com/npm/cli/issues/6409 Fixes: https://github.com/KararTY/dank-twitch-irc/issues/13 Fixes: #47644

CC: @tniessen @silverwind

ShogunPanda avatar Jun 15 '23 08:06 ShogunPanda

CI: https://ci.nodejs.org/job/node-test-pull-request/52262/

nodejs-github-bot avatar Jun 15 '23 09:06 nodejs-github-bot

CI: https://ci.nodejs.org/job/node-test-pull-request/52263/

nodejs-github-bot avatar Jun 15 '23 10:06 nodejs-github-bot

CI: https://ci.nodejs.org/job/node-test-pull-request/52340/

nodejs-github-bot avatar Jun 22 '23 08:06 nodejs-github-bot

I'll check the failing test locally this evening and then I'll update and finally merge this.

ShogunPanda avatar Jun 24 '23 08:06 ShogunPanda

CI: https://ci.nodejs.org/job/node-test-pull-request/52487/

nodejs-github-bot avatar Jun 26 '23 08:06 nodejs-github-bot

CI: https://ci.nodejs.org/job/node-test-pull-request/52499/

nodejs-github-bot avatar Jun 26 '23 20:06 nodejs-github-bot

Landed in fddd3ffa5947417ee9e65f1fc1e9e091cc52f8c3

nodejs-github-bot avatar Jun 27 '23 09:06 nodejs-github-bot

This commit does not land cleanly on v18.x-staging and will need manual backport in case we want it in v18.

ruyadorno avatar Sep 10 '23 03:09 ruyadorno