{"categories":[{"label":"Python Modules","url":"https://skillfed.io/packages/category/software-development-libraries-python-modules/14"}],"enrichment":{"capability":"Provides decorators to wrap functions for execution in thread pools, individual threads, or asyncio tasks, eliminating boilerplate code for common concurrency patterns.","skillfed_tags":["concurrency","decorators","asyncio"],"use_cases":["Offload blocking I/O operations (file reads, network calls) to a thread pool without writing submit/future boilerplate","Launch long-running background tasks as daemon threads with a single decorator instead of manual Thread instantiation","Wrap synchronous functions to run as asyncio tasks within an event loop for mixed sync/async codebases","Reduce copy-paste of concurrent.futures or threading setup code across a codebase by standardizing on decorators","Integrate blocking library calls into async code by scheduling them on a thread pool executor"],"what_it_does":"threaded is a decorator library that wraps ordinary Python functions to run them concurrently using standard library primitives\u2014ThreadPoolExecutor, threading.Thread, or asyncio.Task. Instead of writing boilerplate like `loop.create_task()` or `thread_pool.submit()` every time you want to run a function concurrently, you decorate it once and call it normally; the decorator handles the concurrency setup and returns a future or thread object. It supports Python 3.8 through 3.12 on CPython and PyPy, with no external dependencies beyond the standard library.\n\nThe library provides three main decorators: ThreadPooled (submits to a thread pool with configurable worker count), Threaded (wraps in a threading.Thread with optional daemon and auto-start modes), and AsyncIOTask (wraps in an asyncio.Task). Each decorator can be configured with custom event loops or loop-extraction logic for integration with existing async code. The thread pool can be shut down explicitly during application shutdown.","worth_installing":"Yes, if you frequently write concurrent code and want to reduce boilerplate. The package is stable (Production/Stable classifier), has no dependencies, and works across modern Python versions. The aging maintenance status (last release 996 days ago) is not a blocker for a mature decorator library, but means you should not expect rapid bug fixes or new features. No known vulnerabilities."},"id":"threaded","links":{"html":"https://skillfed.io/packages/threaded","md":"https://skillfed.io/packages/threaded.md","pypi":"https://pypi.org/project/threaded/"},"maintenance":{"status":"aging"},"meta":{"latest_release":"2023-11-22","license_spdx":null,"license_treatment":"permissive","name":"threaded","python_support":"supports_current","summary":"Decorators for running functions in Thread/ThreadPool/IOLoop"},"popularity":{"monthly_downloads":295355,"position":7923,"tier":"top_15000"},"security":{"n_vulnerabilities":0},"version":"4.2.0"}
