Scope
Port Bun corpus position 3986, js/third_party/grpc-js/test-pick-first.test.ts (22 active tests).
Required contracts
- preserve shuffle multisets and randomize selection when configured
- create and observe subchannels across endpoint/address lists
- implement CONNECTING, READY, IDLE, and sticky TRANSIENT_FAILURE transitions
- retain a READY subchannel while a replacement address list connects
- hand off to READY replacements and react correctly when the old subchannel disconnects
- request resolver updates for exhausted/failing address generations
- reconnect the same address list from
exitIdle - expose picker, load-balancer helper, address, and fixture surfaces
- preserve causes and add operation/address/source context for invalid updates
Verification
- all 22 focused upstream tests pass without unsupported cases
- permanent diagnostics cover invalid updates and state handoff
- existing gRPC, SQL adapter, and third-party gates remain green