question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Tasks in the queue are not being processed

See original GitHub issue

Hi, I’m not sure if I’m misunderstanding something about how django-q works, but any tasks which I push on to the queue using async() seem to just stay in the queue and never get processed, and I’m not sure why.

Here’s an example of how I’m pushing tasks onto the queue:

async('django.core.mail.send_mail',
              'Test Subject',
              'Test Message',
              'from@example.com',
              [user.email])

Below you can see that the tasks are getting registered to the queue, but they just stay in the “Queued tasks” and never get processed.

screen shot 2016-11-10 at 8 26 49 am

My configuration for django-q is:

Q_CLUSTER = {
    'name': 'DjangoORM',
    'timeout': 30,  # Timeout in secs for a task
    'save_limit': 10,  # Store latest 10 results only
    'orm': 'default'  # Django database connection
}

Issue Analytics

  • State:closed
  • Created 7 years ago
  • Comments:8

github_iconTop GitHub Comments

4reactions
jordanmkonczcommented, Nov 13, 2016

Disregard; as I suspected, I was misunderstanding how to use django-q. I wasn’t running the python manage.py qcluster command so I never had a cluster running to actually process tasks in the queue.

It might be beneficial to update the docs so that the “Installation” or “Configuration” sections include some brief instructions or just a mention that the user needs to manually start the cluster so that queued tasks get processed. As someone who had no prior experience with this sort of async queueing functionality before, I didn’t actually know this was necessary. It was only when I went through every section of the docs that I eventually realised I needed to manually start the cluster when reading the “Cluster” section.

1reaction
karimonecommented, Nov 1, 2019

I have the same problem the task in the queue are not processed, but the task in scheduling are processed.

Q_CLUSTER = {
    "label": "Tasks",
    "workers": 1,
    "orm": "default",
    "ack_failures": True,
    "timeout": HOUR_IN_SECONDS * 4,
    "retry": HOUR_IN_SECONDS * 24 * 7
}

The cache is memcache 1.5.16

Read more comments on GitHub >

github_iconTop Results From Across the Web

Why is the task.queue not being processed? - Hivelocity Hosting
It should be deleted every minute. If it exists, check it's contents. If there are more than just 1 or 2 lines, then...
Read more >
Solved: NiFi tasks are queued up but never being processed...
When I feed that to the FetchAzureBlobStorage processor however, the queue starts to fill up but not a single task in the queue...
Read more >
The task.queue is not being processed | Knowledgebase
The task.queue is not being processed. 1) check for /usr/local/directadmin/data/task.queue. It should be deleted every minute.
Read more >
Google Cloud Tasks: some tasks remain in queue instead of ...
New incoming tasks are processed as usual but those ones are blocked and stay on the queue for some minutes, even when worker...
Read more >
task.queue is not being processed - DirectAdmin Forums
hello, task.queue is not being processed on my server , i read and did instruction on this guide : but problem exist again......
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found