Some considerations: If the calling code is adding a WaitGroup, does it still make sense to keep the internal one? The internal wait group does ensure that all notifications are sent before closing the responses channel -- so that is useful.
Another option for the calling code is to use an unbuffered done channel to signal that all responses are processed. That's a little simpler and doesn't require the sync package for the caller.
ref #74
Some considerations: If the calling code is adding a WaitGroup, does it still make sense to keep the internal one? The internal wait group does ensure that all notifications are sent before closing the responses channel -- so that is useful.
Another option for the calling code is to use an unbuffered done channel to signal that all responses are processed. That's a little simpler and doesn't require the sync package for the caller.