$npx skillfedfor your agent

aiojobs

Job scheduler for managing background tasks (asyncio)

Worth itPyPI Software DevelopmentReleased Apr 2025354.1K downloads / moApache 2Pure Python

Decision gist · record as of 2026-08-14

pure-Python wheel — aiojobs-1.4.0-py3-none-any.whl
v1.4.0 · released 2025-04-05 · Python >=3.9 · 1 runtime deps: async-timeout

Yes. aiojobs is actively maintained, production-stable, has no known vulnerabilities, and solves a real problem in asyncio applications—uncontrolled task loss during shutdown. Low install friction and permissive licensing make it a safe, practical choice for any asyncio project needing reliable background task management.AI-flagged interpretation of the facts on this page — verify before relying

Before you install

  • Requires Python 3.9 or later; asyncio is built-in but the application must use async/await syntax.
  • Low install friction with a single runtime dependency (async-timeout).
  • Actively maintained with recent commits and stable production status across Python 3.9–3.13.

License · maintenance · safety

Apache 2 (permissive) — Licensed under Apache 2 (permissive), allowing free use, modification, and distribution in both open and proprietary projects with minimal restrictions.

last release 2025-04-05 (496 days) · last repo commit 2026-08-11 · 927 stars

0 known vulnerabilities (OSV.dev, 2026-08-14) · 354,079 downloads/mo, #7,298 on PyPI

Verify before relying

pip install aiojobs

import asyncio
import aiojobs

async def background_task(delay):
    await asyncio.sleep(delay)

async def main():
    async with aiojobs.Scheduler() as scheduler:
        await scheduler.spawn(background_task(1.0))
        await asyncio.sleep(0.5)

asyncio.run(main())
  • Whether the scheduler supports priority queues or task ordering beyond FIFO spawn order
  • Maximum recommended number of concurrent jobs before performance degrades
  • Whether aiohttp integration is required or optional for core scheduler functionality
Same gist for agents: .md · .json

What it is and what it does

aiojobs is a task scheduler for asyncio applications that manages the lifecycle of background jobs spawned during runtime. It solves the problem of uncontrolled task cancellation during application shutdown by providing a context manager that tracks all spawned tasks and waits for them to complete before closing. The library includes a Scheduler class that accepts coroutines via spawn(), tracks their execution, and ensures graceful termination.

The package is typically used in asyncio web applications (especially with aiohttp) to run background work—such as cleanup, notifications, or long-running operations—without losing tasks on shutdown. It also provides a shield() method to protect tasks from cancellation while keeping them tracked, solving a gap in asyncio.shield() that loses visibility of shielded tasks. The single runtime dependency (async-timeout) keeps installation lightweight.

Use it for

  • Run background cleanup or maintenance tasks in web handlers without losing them on shutdown
  • Spawn multiple long-running coroutines and ensure all complete before application exit
  • Shield critical tasks from cancellation while maintaining scheduler visibility for graceful shutdown
  • Integrate background job management into aiohttp.web applications via the built-in aiohttp plugin
  • Manage task lifecycle in asyncio applications where manual task tracking is error-prone

Worth the install?

AI-flagged interpretation of the facts on this page. Verify before relying on it.

Worth it

Yes.

aiojobs is actively maintained, production-stable, has no known vulnerabilities, and solves a real problem in asyncio applications—uncontrolled task loss during shutdown. Low install friction and permissive licensing make it a safe, practical choice for any asyncio project needing reliable background task management.

Install

aiojobs on PyPI

Before you install

Low install friction with a single runtime dependency (async-timeout). Actively maintained with recent commits and stable production status across Python 3.9–3.13.

Requires Python 3.9 or later; asyncio is built-in but the application must use async/await syntax.

License in practice

Licensed under Apache 2 (permissive), allowing free use, modification, and distribution in both open and proprietary projects with minimal restrictions.

Quickstart

pip install aiojobs

import asyncio
import aiojobs

async def background_task(delay):
    await asyncio.sleep(delay)

async def main():
    async with aiojobs.Scheduler() as scheduler:
        await scheduler.spawn(background_task(1.0))
        await asyncio.sleep(0.5)

asyncio.run(main())

Verify before relying

  • Whether the scheduler supports priority queues or task ordering beyond FIFO spawn order
  • Maximum recommended number of concurrent jobs before performance degrades
  • Whether aiohttp integration is required or optional for core scheduler functionality

Package facts

LicenseApache 2 permissive
Python supportSupports the current Python release >=3.9
Install frictionLow. Pure-Python wheel
Runtime dependencies
1 package
async-timeout
MaintenanceActively maintained 496 days since the last release
Last repo commit
First released
Downloads354,079 / month, #7,298 on PyPI 30-day window, as of 2026-08-14
Known vulnerabilitiesNone known OSV.dev, checked 2026-08-14
Classifiers
Development Status :: 5 - Production/StableFramework :: AsyncIOIntended Audience :: DevelopersLicense :: OSI Approved :: Apache Software LicenseOperating System :: MacOS :: MacOS XOperating System :: Microsoft :: WindowsOperating System :: POSIXProgramming Language :: PythonProgramming Language :: Python :: 3Programming Language :: Python :: 3.10Programming Language :: Python :: 3.11Programming Language :: Python :: 3.12Programming Language :: Python :: 3.13Programming Language :: Python :: 3.9Topic :: Software Development

Evidence: aiojobs-1.4.0-py3-none-any.whl

Tags

Capabilities
asyncio background task schedulermanage concurrent async jobsasyncio task lifecycle controlbackground task queue asyncioasync job schedulinggraceful asyncio shutdownshield asyncio tasks
Topics
asynciobackground-jobstask-scheduling

Let your AI agent find packages like this

Example. Real query, live index.

You found this page by searching. An agent finds it by wishing: SkillFed indexes 14,416 PyPI packages by what they can do, searchable in plain language.

wish › “asyncio background task scheduler”

  • aiojobsaiojobs provides a scheduler for spawning and managing background…
  • arqarq provides a job queue system for Python that uses asyncio and…
  • saqSAQ is an async job queue framework that runs background tasks using…

Give your agent the search over MCP, or paste the wish link into any chat.

More Software Development packages

typing-extensions Worth it
PyPI · Software Development · released Jul 2026

Provides backported and experimental type hints for Python 3.9+, allowing use of newer typing features on older Python versions and enabling early experimentation with type system PEPs before they enter the standard library.

PSF-2.0pure Python · 3.9+
1.9Bdownloads / mo
numpy Worth it
PyPI · Software Development · released Aug 2026

NumPy provides an N-dimensional array object and a comprehensive suite of mathematical, linear algebra, Fourier transform, and random number functions for scientific computing in Python.

BSD-3-Clause AND 0BSD AND MIT AND Zlib AND CC0-1.0compiled wheel · 3.12+
1.1Bdownloads / mo
fastapi Worth it
PyPI · Software Development · released Jul 2026

FastAPI is a Python web framework for building REST APIs using type hints, with automatic request validation, serialization, and interactive API documentation.

MITpure Python · 3.10+
568.6Mdownloads / mo
annotated-doc With conditions
PyPI · Software Development · released Jul 2026

Provides a way to document function parameters, class attributes, return types, and variables inline using Python's `Annotated` type hint syntax instead of traditional docstrings.

MITpure Python · 3.9+
456.2Mdownloads / mo
typer Worth it
PyPI · Software Development · released Aug 2026

Typer builds command-line applications from Python functions using type hints, automatically generating help text, argument parsing, and shell completion.

Install it if you are building CLIs in Python.

MITpure Python · 3.10+
369.3Mdownloads / mo
distlib With conditions
PyPI · Software Development · released Jun 2026

Distlib provides low-level packaging utilities for building, distributing, and managing Python software—including metadata handling, version specifiers, wheel support, script installation, and dependency resolution.

permissive licensepure Python
323.3Mdownloads / mo

See also aiorun · aiotools · aiomonitor · APScheduler · django-apscheduler · scheduler · django-background-tasks · timeloop · aiometer · aiodebug