-
Notifications
You must be signed in to change notification settings - Fork 12
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
gather
drop-in replacement
#41
Comments
Hi @prophile This is interesting at first, but I’m not sure. Like you said, gather has its own quirks. For example, I believe it’s possible to pass a flag that changes its behavior quite substantially. The library already has run_all and run_any helpers which build on top of amap. Don’t those do the trick? |
Potentially yes, and switching over to them would be an aspiration. But changing something from using For me (us) I think that's useful to do, but it would also be useful to get metering in the short term before doing the bigger job of changing over to |
I think I understand where you’re at, but let me rephrase this. What piece of public API do you think we could add to aiometer that would address this use case? If we were to add a gather « like for like but with metering », what would be its signature and a few code usage examples? |
Hello!
asyncio's own
gather
is a bit of a dated design but still pretty common, at least in codebases I'm dealing with at the moment—converting them toamap
would be nice but it would also be dead useful to be able to drop-in replace with anaiometer.gather
in a like-for-like fashion to add metering separately.It's not impossible to shim on top of
amap
but would it be something you'd consider bringing into scope in the library itself? Especially since the exception handling semantics ofgather
can be a bit subtle.The text was updated successfully, but these errors were encountered: