fix(host): a workspace's people stream opened as the last one closes keeps its follow
Follow-up to Devin's review of #3942 (thread).
The act port counted each workspace's people streams and asked the host to follow or unfollow outside any turn. So if the last stream's unfollow was still on its way when a new stream opened, the unfollow could land after the new follow and take it away. The new stream stayed open, but nothing reached it.
Each count change and its ask of the host now take the workspace's turn (one semaphore per workspace), as chatChanges in agent-inbox-procedures.ts already does. The unfollow always reaches the host first.
Test: workspace-procedures.test.ts opens a stream while the last one's unfollow is held. The new follow is asked only once the unfollow is done. Without the fix the test fails.
The invitations stream that #3956 adds goes through the same helper, so it gets the same guard when that PR rebases.
Made with Luke