Fix a little thinko in sending events to secondary listeners. (#71997)
If `unique` is true, I was redoing the uniqueness check for the secondary listeners, which is racy since a "duplicate" event could come in between deciding to send the event to the main listener and checking for the shadow listener, and then the two streams would get out of sync. There's not a good way to write a direct test for this, but the test_shadow_listeners test has been flakey and this is the only racy part of that system I can find. So the test would be that that test_shadow_listeners becomes not flakey.
Loading
Please sign in to comment