Closed wojcikstefan closed 7 years ago
Bonus point against async code - due to monkey patching upon import, grequests can cause warnings/bugs that might be very hard to find. See:
Looks good (but didn't test).
@closeio/engineering I believe that once we add unit tests to this PR, we can release it as v1.0. Agreed?
👍
Sounds good. So what's happening to async? Are there any plans for it?
Given the arguments I laid out in https://github.com/closeio/closeio-api/pull/78#issuecomment-275871159 and in the description for #79, I think it might make sense to drop it altogether. This way we maintain a simple & readable helper library w/o any quirks while the users can choose to run multiple concurrent api.get/post/put/delete
requests via threading
, multiprocessing
, concurrent.futures
, gevent
, etc. depending on their specific use case and environment.
@wojcikstefan Let's move forward with merging this? Can you handle conflicts and publish?
@thomasst @jkemp101 @philfreo This should be ready to go, please review. If you give the go ahead, I'll merge the changes, bump up the version, create a new release, and deploy to PyPI.
Right now the async client makes the code more complex and doesn't really add much value. I doubt it's used in the wild and if it is, then the usage is probably quite confusing and hacky. I think we might as well get rid of it.
Examples of current confusing behavor:
api.get/post/put/delete
is still synchronousapi.map
expects a list ofgrequests.AsyncRequest
, but there's no easy way to construct them.This PR introduces breaking changes and should be published along with a major version bump.
TODO: