
Security News
Open VSX Unblocks Extension IDs Used in Malware Campaign
Open VSX has removed three extension IDs from its malicious-extension list as the legitimate publishers they impersonated move to claim the names for themselves.
libasync
Advanced tools
Affected versions:
libasync is a lightweight, high-performance Python library that extends asyncio with a flexible thread pool, advanced task scheduling, and efficient async I/O multiplexing. Designed for modern concurrent applications, it bridges the gap between asynchronous and synchronous code, allowing you to run CPU-bound and I/O-bound tasks seamlessly.
asyncio codebases; use await with any blocking call.pip install libasync
import asyncio
import libasync
async def main():
# Initialize the async engine
libasync.init()
# Schedule a CPU-bound task to run in the thread pool
result = await libasync.run_in_executor(
lambda: sum(range(10_000_000))
)
print(f"Result: {result}")
# Schedule multiple tasks concurrently
tasks = [
libasync.run_in_executor(lambda: i * i)
for i in range(10)
]
results = await asyncio.gather(*tasks)
print(f"Squares: {results}")
if __name__ == "__main__":
asyncio.run(main())
libasync.init()Initializes the async engine and thread pool. This function must be called before using the thread pool or other functionality. It is idempotent, so calling it multiple times has no effect.
libasync.run_in_executor(func, *args, **kwargs)Schedules func to be executed in the thread pool and returns an awaitable that resolves to its result. Accepts any callable and passes *args and **kwargs to it.
libasync.shutdown(timeout=None)Gracefully shuts down the thread pool and releases system resources. Pending tasks are allowed to complete up to the specified timeout.
import libasync
# Schedule a task with a specific priority
# Lower number = higher priority
future = libasync.schedule_task(
my_function,
priority=1
)
# Schedule a recurring task
task_id = libasync.schedule_recurring(
lambda: print("Tick"),
interval=1.0
)
# Cancel the recurring task later
libasync.cancel_task(task_id)
# Set the maximum number of threads
# Default = CPU cores * 2
libasync.set_max_threads(16)
# Set the queue size limit
# Default = 1000
libasync.set_queue_limit(5000)
# Retrieve current pool statistics
stats = libasync.get_stats()
print(f"Active threads: {stats.active_threads}")
print(f"Pending tasks: {stats.pending_tasks}")
print(f"Completed tasks: {stats.completed_tasks}")
| Feature | libasync | Standard asyncio + ThreadPoolExecutor |
|---|---|---|
| Dynamic thread pool | ✅ Yes | ❌ Fixed size |
| Priority queue | ✅ Yes | ❌ No |
| Zero-copy data sharing | ✅ Yes | ❌ Serialization overhead |
| Native I/O polling | ✅ Yes (IOCP/epoll) | ❌ Select/poll |
| Recurring tasks | ✅ Built-in | ❌ Manual loop |
MIT
Marko Bernard – marko_bernard@gmail.com
Contributions are welcome! Please open an issue or submit a pull request on GitHub.
Inspired by the need for a more efficient async runtime on Windows, libasync combines the best of asyncio with native thread management to deliver a fast, responsive concurrency toolkit.
FAQs
High-performance asynchronous task and thread pool library for Python
The pypi package libasync receives a total of 71 weekly downloads. As such, libasync popularity was classified as not popular.
We found that libasync demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 0 open source maintainers collaborating on the project.

Security News
Open VSX has removed three extension IDs from its malicious-extension list as the legitimate publishers they impersonated move to claim the names for themselves.

Product
Socket’s PHP and Composer support is now in Beta for all customers, with PHP reachability analysis generally available.

Product
Socket is bringing experimental protection to Firefox, scanning 97,000+ extensions in Mozilla's official directory for malware and risky updates.