-
Notifications
You must be signed in to change notification settings - Fork 5
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Final Done Task Repeating #10
Comments
I added a I guess it's terminated before it's completed the run. |
Hello @graingerkid, I will try to reproduce your case. But a possible explanation is that the last entry is repeated because it was not completely processed (it didn't get a corresponding Your initial code does not have a |
Yea this was my full code (sorry)...
I'd put
but you suggest within the |
Try the following: def worker():
while True:
try:
item = q.get()
print item
time.sleep(1) # emulate an intensive work here
except:
pass
finally:
q.task_done() Then, remove your last By repeating the execution, you would not see the item 99 repeating in the second run. If so, we may have a BUG in the code. |
It seems to work sometimes and then not others. Any ideas how we could narrow down the issue? |
FYI i've got the following set...
|
@graingerkid, I think you already narrowed down the problem. I'm just without time to work on this issue, but I will certainly do a test case for it. |
With the following example, if I run it and then comment out the
put
loop and then run it again, I get 99 printed.The text was updated successfully, but these errors were encountered: