{"categories":[{"label":"WWW/HTTP","url":"https://skillfed.io/packages/category/internet-www-http/2"}],"enrichment":{"capability":"Wraps the requests library to execute HTTP requests asynchronously using thread pools, returning futures instead of responses so multiple requests can be issued and resolved in parallel.","skillfed_tags":["concurrency","http-client","thread-pool"],"use_cases":["Fetch data from multiple APIs in parallel without blocking, then process all responses together","Implement concurrent web scraping that issues many requests simultaneously and collects results","Background HTTP operations in foreground-focused applications where you want requests to proceed while other work continues","Batch processing workflows that need to make many HTTP calls with controlled concurrency via thread pool size","Canceling pending requests in a context manager to avoid wasted resources on unneeded work"],"what_it_does":"requests-futures is a lightweight wrapper around the requests library that enables asynchronous HTTP requests using Python's concurrent.futures module. Instead of blocking on each request, you create a FuturesSession that returns Future objects immediately, allowing you to issue multiple requests in parallel and retrieve responses when ready. The API mirrors requests.Session closely, minimizing the learning curve\u2014you swap FuturesSession for Session and call .result() on the returned Future to get the Response.\n\nThe package uses a ThreadPoolExecutor by default with 8 workers, which you can customize or replace entirely. It preserves the requests API's behavior including hooks, session configuration, and exception handling, with the main difference being that exceptions are deferred to the .result() call rather than raised immediately. This makes it useful for scenarios where you need to make many HTTP calls concurrently without switching to a fully async framework.","worth_installing":"Yes, if you need concurrent HTTP requests and prefer a minimal, requests-compatible API over learning a full async framework. The low install friction, active maintenance, permissive license, and zero known vulnerabilities make it a safe choice. Not recommended if you require true async/await syntax or need to handle thousands of concurrent connections\u2014consider a modern async HTTP library instead."},"id":"requests-futures","links":{"html":"https://skillfed.io/packages/requests-futures","md":"https://skillfed.io/packages/requests-futures.md","pypi":"https://pypi.org/project/requests-futures/"},"maintenance":{"status":"active"},"meta":{"latest_release":"2024-11-15","license_spdx":null,"license_treatment":"permissive","name":"requests-futures","python_support":"unspecified","summary":"Asynchronous Python HTTP for Humans."},"popularity":{"monthly_downloads":4631678,"position":2271,"tier":"top_5000"},"security":{"n_vulnerabilities":0},"version":"1.0.2"}
