Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7742501
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 1, 20262026-06-01T09:17:30+00:00 2026-06-01T09:17:30+00:00

In docs link about expires # Task expires after one minute from now. add.apply_async(args=[10,

  • 0

In docs link about expires

# Task expires after one minute from now.
add.apply_async(args=[10, 10], expires=60) 

I use:

from tasks import add
result = add.apply_async(args=[10, 10], expires=6000)
printus(result)

def printus(result):
    print (result) #task id
    print (result.ready()) # returns True if the task has finished processing.
    print (result.result) # task is not ready, so no return value yet.
    print (result.get())  # Waits until the task is done and returns the retval.
    print (result.result) # direct access to result, doesn't re-raise errors.
    print (result.successful()) # returns True if the task didn't end in failure.)

tasks.py

from celery.task import task
@task
def add(x, y):
    return x + y

In celeryd:

[2012-03-21 19:50:03,012: WARNING/MainProcess] Skipping revoked task: tasks.add[4ffcff91-b12b-4bce-8d47-159314759859]

In console:

4ffcff91-b12b-4bce-8d47-159314759859
True

Traceback (most recent call last):
  File "/home/echeg/Dropbox/my_py/opoveshun/tests/celery/run_task.py", line 53, in <module>
    tr.countdown()
  File "/home/echeg/Dropbox/my_py/opoveshun/tests/celery/run_task.py", line 26, in countdown
    self.printus(result)
  File "/home/echeg/Dropbox/my_py/opoveshun/tests/celery/run_task.py", line 48, in printus
    print (result.get())  # Waits until the task is done and returns the retval.
  File "/usr/local/lib/python2.7/dist-packages/celery/result.py", line 95, in get
    interval=interval)
  File "/usr/local/lib/python2.7/dist-packages/celery/backends/amqp.py", line 144, in wait_for
    raise self.exception_to_python(meta["result"])
celery.exceptions.TaskRevokedError

Why do I get an exception? The result has not expired

If i use:

result = add.apply_async(args=[10, 10])

all ok

226107de-f739-4860-83bc-d843f17a257e
False
None
20
20
True
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-01T09:17:31+00:00Added an answer on June 1, 2026 at 9:17 am

    celeryd thinks your task has expired:

    [2012-03-21 19:50:03,012: WARNING/MainProcess] Skipping revoked task: tasks.add[4ffcff91-b12b-4bce-8d47-159314759859]
    

    When an expired task is picked up by a worker, it revokes it without executing. Check your timezone settings? I had the inverse problem: tasks weren’t expiring when they should have. This fixed it for me:

    CELERY_ENABLE_UTC = True
    CELERY_TIMEZONE = 'Etc/UTC'
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm trying to use target-counter to describe references. I found out about it from
Since I am struggling to find any official inforamtion about use() can soemone link
With reference to the following link: http://docs.python.org/faq/library.html#what-kinds-of-global-value-mutation-are-thread-safe I wanted to know if the following:
In the following link http://www.faqs.org/docs/Linux-HOWTO/NFS-HOWTO.html It said a process is not killable except by
Sorry for such a silly question but Python docs are confusing... Link 1: Queue
The docs about openssl_sign() say that the signature is returned in the passed string
I read something about this on PHP docs , but it's not clear to
in this page of tutorial : http://java.sun.com/javaee/6/docs/tutorial/doc/bnadu.html discuss about hello2 application on samples folder.
http://developers.facebook.com/docs/reference/api/post/ doesn't seem to give a clue about it. Would Install(ed) be an action?
Reference Link: http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2009/n2849.pdf I am trying to gather information about TR2 and how it

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.