NewYour coding agent can read the release notes before it upgrades.Set up the MCP server →
PyPI · #1095 most downloaded on PyPI
RQ is a simple, lightweight, library for creating background jobs, and processing them.
Last release 19 days ago
30 Aug 2026
Ships fairly regularly
a new release about every 5 weeks
Nearly every release is documented
notes for 54 of the last 60 stable releases
Nothing withdrawn
no release was ever pulled
13 years old
98 releases · first in 2013
Refactored APIs to allow custom Connection, Job, Worker and Queue classes via CLI. Thanks @jezdez!
Connection, Job, Worker and Queue classes via CLI. Thanks @jezdez!job.delete() now properly cleans itself from job registries. Thanks @selwin!Worker should no longer overwrite job.meta. Thanks @WeatherGod!job.save_meta() can now be used to persist custom job data. Thanks @katichev!Worker.find_by_key() more efficient. Thanks @selwin!timeout using strings such as queue.enqueue(foo, timeout='1m'). Thanks @luojiebin!HerokuWorker termination logic. Thanks @samuelcolvin!Fixes a bug that prevents fetching jobs from FailedQueue (#765). Thanks @jsurloppe!
FailedQueue (#765). Thanks @jsurloppe!enqueue_job should use Redis pipeline when available (#761). Thanks mtdewulf!One column per quarter.
Better support for Heroku workers (#584, #715)
fetch_job now checks that a job requested actually comes from the
intended queue (#728, #733)request_force_stop_sigrtmin failing for Python 3 (#727)Job.cancel() method on failed queue (#707)Jobs that depend on job with result_ttl == 0 are now properly enqueued.
cancel_job now works properly. Thanks @jlopex!Worker.work() now accepts logging_level argument. Thanks @jlopex!@job decorator now accepts ttl argument. Thanks @javimb!Worker.__init__ now accepts queue_class keyword argument. Thanks @antoineleclair!Worker now saves warm shutdown time. You can access this property from worker.shutdown_requested_date. Thanks @olingerc!Worker now correctly deletes current_job_id after failed job execution. Thanks @olingerc!Job.create() and queue.enqueue_call() now accepts meta argument. Thanks @tornstrom!job.started_at property. Thanks @samuelcolvin!job.cancel() and job.delete(). Thanks @glaslos!Worker.execute_job() now exports RQ_WORKER_ID and RQ_JOB_ID to OS environment variables. Thanks @mgk!rqinfo now accepts --config option. Thanks @kfrendrich!Worker class now has request_force_stop() and request_stop() methods that can be overridden by custom worker classes. Thanks @samuelcolvin!Job results are now logged on DEBUG level. Thanks @tbaugis!
DEBUG level. Thanks @tbaugis!patch_connection so Redis connection can be easily mockedAdd support for --exception-handler command line flag
--exception-handler command line flagFix compatibility with raven>=5.4.0
(July 8th, 2015)
Better API for instantiating Workers. Thanks @RyanMTB!
(June 3rd, 2015)
FailedQueue now have their statuses set properlyenqueue_call() no longer ignores ttl. Thanks @mbodock!Support SSL connection to Redis (requires redis-py>=2.10)
(April 14th, 2015)
Resolve performance issue when queues contain many jobs
(March 9th, 2015)
birth_date and death_date on WorkerREDIS_SSL config option)RQ workers can now be paused and resumed using rq suspend and rq resume commands. Thanks Jonathan Tushman!
(Jan 30th, 2015)
rq suspend and
rq resume commands. Thanks Jonathan Tushman!StartedJobRegistry
for monitoring purposes. This also prevents currently active jobs from
being orphaned/lost in the case of hard shutdowns.FinishedJobRegistry.
Thanks Nic Cope for helping!deferred as their
status. You can monitor deferred jobs by checking DeferredJobRegistry.queue.enqueue(func, at_front=True). Thanks Travis Johnson!click. Thanks Lyon Zhang!SimpleWorker that does not fork when executing jobs.
Useful for testing purposes. Thanks Cal Leeming!--queue-class and --job-class arguments to rqworker script.
Thanks David Bonner!Raise a warning when RQ workers are used with Sentry DSNs using asynchronous transports. Thanks Wei, Selwin & Toms!
(May 21st, 2014)
Fix where rqworker broke on Python 2.6. Thanks, Marko!
(May 8th, 2014)
Properly declare redis dependency.
(May 7th, 2014)
Make job and queue classes overridable. Thanks, Marko!
(May 6th, 2014)
Add missing depends_on kwarg to @job decorator. Thanks, Sasha!
(April 28th, 2014)
Fix bug where RQ 0.4 workers could not unpickle/process jobs from RQ < 0.4.
(April 22nd, 2014)
Emptying the failed queue from the command line is now as simple as running rqinfo -X or rqinfo --empty-failed-queue.
(April 22nd, 2014)
Emptying the failed queue from the command line is now as simple as running
rqinfo -X or rqinfo --empty-failed-queue.
Job data is unpickled lazily. Thanks, Malthe!
Removed dependency on the times library. Thanks, Malthe!
Job dependencies! Thanks, Selwin.
Custom worker classes, via the --worker-class=path.to.MyClass command line
argument. Thanks, Selwin.
Queue.all() and rqinfo now report empty queues, too. Thanks, Rob!
Fixed a performance issue in Queue.all() when issued in large Redis DBs.
Thanks, Rob!
Birth and death dates are now stored as proper datetimes, not timestamps.
Ability to provide a custom job description (instead of using the default function invocation hint). Thanks, İbrahim.
Fix: temporary key for the compact queue is now randomly generated, which should avoid name clashes for concurrent compact actions.
Fix: Queue.empty() now correctly deletes job hashes from Redis.
Bug fix where the worker crashes on jobs that have their timeout explicitly removed. Thanks for reporting, @algrs.
(December 17th, 2013)
Bug fix where a worker could time out before the job was done, removing it from any monitor overviews (#288).
(December 16th, 2013)
Some more fixes in command line scripts for Python 3
(August 23th, 2013)
(August 20th, 2013) - Bug fix in setup.py
(August 20th, 2013)
Python 3 compatibility (Thanks, Alex!)
(August 20th, 2013)
Python 3 compatibility (Thanks, Alex!)
Minor bug fix where Sentry would break when func cannot be imported
rqworker and rqinfo have a --url argument to connect to a Redis url.
(June 17th, 2013)
rqworker and rqinfo have a --url argument to connect to a Redis url.
rqworker and rqinfo have a --socket option to connect to a Redis server
through a Unix socket.
rqworker reads SENTRY_DSN from the environment, unless specifically
provided on the command line.
Queue has a new API that supports paging get_jobs(3, 7), which will
return at most 7 jobs, starting from the 3rd.
Fixed bug where workers would not execute builtin functions properly.
(February 26th, 2013)
Worker registrations now expire. This should prevent rqinfo from reporting about ghosted workers. (Thanks, @yaniv-aknin!)
(February 18th, 2013)
Worker registrations now expire. This should prevent rqinfo from reporting
about ghosted workers. (Thanks, @yaniv-aknin!)
rqworker will automatically clean up ghosted worker registrations from
pre-0.3.6 runs.
rqworker grew a -q flag, to be more silent (only warnings/errors are shown)
ended_at is now recorded for normally finished jobs, too. (Previously only for failed jobs.)
(February 6th, 2013)
ended_at is now recorded for normally finished jobs, too. (Previously only
for failed jobs.)
Adds support for both Redis and StrictRedis connection types
Makes StrictRedis the default connection type if none is explicitly provided
Restore compatibility with Python 2.6.
(January 23rd, 2013)
Fix bug where work was lost due to silently ignored unpickle errors.
(January 18th, 2013)
Fix bug where work was lost due to silently ignored unpickle errors.
Jobs can now access the current Job instance from within. Relevant
documentation here.
Custom properties can be set by modifying the job.meta dict. Relevant
documentation here.
Custom properties can be set by modifying the job.meta dict. Relevant
documentation here.
rqworker now has an optional --password flag.
Remove logbook dependency (in favor of logging)
Improve compatibility with Python < 2.7.
(September 3rd, 2012)
Fixes broken rqinfo command.
Improve compatibility with Python < 2.7.
.enqueue() now takes a result_ttl keyword argument that can be used to change the expiration time of results.
(August 30th, 2012)
.enqueue() now takes a result_ttl keyword argument that can be used to
change the expiration time of results.
Queue constructor now takes an optional async=False argument to bypass the
worker (for testing purposes).
Jobs now carry status information. To get job status information, like
whether a job is queued, finished, or failed, use the property status, or
one of the new boolean accessor properties is_queued, is_finished or
is_failed.
Jobs return values are always stored explicitly, even if they have to
explicit return value or return None (with given TTL of course). This
makes it possible to distinguish between a job that explicitly returned
None and a job that isn't finished yet (see status property).
Custom exception handlers can now be configured in addition to, or to fully replace, moving failed jobs to the failed queue. Relevant documentation here and here.
rqworker now supports passing in configuration files instead of the
many command line options: rqworker -c settings will source
settings.py.
rqworker now supports one-flag setup to enable Sentry as its exception
handler: rqworker --sentry-dsn="http://public:secret@example.com/1"
Alternatively, you can use a settings file and configure SENTRY_DSN = 'http://public:secret@example.com/1' instead.
Warm shutdown now exits immediately when Ctrl+C is pressed and worker is idle
(August 5th, 2012)
Reliability improvements
.enqueue() does not consume the timeout kwarg anymore. Instead, to pass
RQ a timeout value while enqueueing a function, use the explicit invocation
instead:
```python
q.enqueue(do_something, args=(1, 2), kwargs={'a': 1}, timeout=30)
```
Add a @job decorator, which can be used to do Celery-style delayed
invocations:
```python
from redis import StrictRedis
from rq.decorators import job
# Connect to Redis
redis = StrictRedis()
@job('high', timeout=10, connection=redis)
def some_work(x, y):
return x + y
```
Then, in another module, you can call some_work:
```python
from foo.bar import some_work
some_work.delay(2, 3)
```
Fix bug where return values that couldn't be pickled crashed the worker
(August 1st, 2012)
Fix important bug where result data wasn't restored from Redis correctly (affected non-string results only).
(July 20th, 2012)
q.enqueue() accepts instance methods now, too. Objects will be pickle'd along with the instance method, so beware.
(July 18th, 2012)
q.enqueue() accepts instance methods now, too. Objects will be pickle'd
along with the instance method, so beware.q.enqueue() accepts string specification of functions now, too. Example:
q.enqueue("my.math.lib.fibonacci", 5). Useful if the worker and the
submitter of work don't share code bases.(May 15, 2012) - Fix broken PyPI deployment.
(May 15, 2012)
Thread-safety by using context locals
(May 14, 2012)
(March 28, 2012) - Initially released version.
(March 28, 2012)
Your coding agent can read these notes before it upgrades. Set up the MCP server →