Fähigkeiten apscheduler
⏰

apscheduler

Sicher ⚙️ Externe Befehle

Schedule background tasks with APScheduler

Automate recurring tasks and background jobs in Python applications. APScheduler provides cron-style, interval-based, and date-based scheduling with support for async execution and multiple persistence backends.

UnterstĂĽtzt: Claude Codex Code(CC)
📊 70 Angemessen
1

Die Skill-ZIP herunterladen

2

In Claude hochladen

Gehe zu Einstellungen → Fähigkeiten → Skills → Skill hochladen

3

Einschalten und loslegen

Teste es

Verwendung von "apscheduler". Schedule my send_daily_report function to run every day at 9 AM

Erwartetes Ergebnis:

  • Added schedule 'send_daily_report' with CronTrigger (hour=9, minute=0)
  • Next run time: tomorrow at 09:00:00
  • Job will execute: send_daily_report()
  • Scheduler is running in background

Verwendung von "apscheduler". Add a job that runs refresh_cache() every 30 minutes

Erwartetes Ergebnis:

  • Added schedule with ID: cache_refresh
  • Trigger: interval, every 30 minutes
  • Job executor: threadpool (default)
  • Next run: [calculated next fire time]

Sicherheitsaudit

Sicher
v4 • 1/16/2026

This is a documentation-only skill containing code examples for the APScheduler Python library. All 82 static findings are FALSE POSITIVES. The analyzer misinterpreted markdown code fences (backticks) as shell command execution, placeholder URLs as hardcoded endpoints, standard Python keywords as cryptographic algorithms, and job scheduling patterns as system reconnaissance. No actual executable code, network calls, or file operations exist in this skill. It is safe for publication.

3
Gescannte Dateien
1,272
Analysierte Zeilen
1
befunde
4
Gesamtzahl Audits

Risikofaktoren

⚙️ Externe Befehle (1)
Auditiert von: claude Audit-Verlauf anzeigen →

Qualitätsbewertung

38
Architektur
100
Wartbarkeit
85
Inhalt
31
Community
100
Sicherheit
83
Spezifikationskonformität

Was du bauen kannst

Automated report generation

Schedule daily, weekly, or monthly report generation jobs that run without manual intervention

Periodic data sync

Sync data from external APIs or databases at regular intervals with configurable triggers

Health check monitoring

Run background monitoring tasks that check system health and trigger alerts

Probiere diese Prompts

Basic scheduling
Use APScheduler to run my cleanup function every minute with an interval trigger
Cron scheduling
Schedule a function to run at 9 AM every weekday using cron trigger
With persistence
Set up AsyncScheduler with PostgreSQL persistence so jobs survive application restarts
Distributed workers
Create a distributed APScheduler setup with separate scheduler and worker nodes using AsyncpgEventBroker

Bewährte Verfahren

  • Use persistent data stores in production to survive application restarts
  • Set appropriate misfire_grace_time to handle system delays gracefully
  • Subscribe to job events for monitoring and alerting on job failures

Vermeiden

  • Storing credentials directly in job kwargs - use environment variables instead
  • Scheduling very short intervals without proper coalesce configuration
  • Ignoring job exceptions without error handling or retry policies

Häufig gestellte Fragen

How does APScheduler compare to Celery?
APScheduler is lighter and simpler for single-application scheduling. Celery is better for complex distributed task queues.
Can I run APScheduler in FastAPI?
Yes, use the lifespan pattern with AsyncScheduler to run the scheduler alongside your FastAPI application.
What happens to jobs when the app restarts?
With in-memory storage, jobs are lost. Use SQLAlchemyDataStore or MongoDBDataStore to persist jobs across restarts.
How do I run jobs in the background?
Call scheduler.start_in_background() after adding your schedules. This runs the scheduler loop without blocking.
Can I pass arguments to scheduled functions?
Yes, use args for positional arguments and kwargs for named arguments in add_schedule or add_job.
What executors are available?
ThreadPoolExecutor (default, good for I/O tasks) and ProcessPoolExecutor (good for CPU-intensive tasks).

Entwicklerdetails

Dateistruktur

đź“„ evaluation.json

đź“„ SKILL.md