Skip to content
This repository was archived by the owner on Nov 23, 2017. It is now read-only.

wait()/wait_for() losing items on Queue.get() #201

Closed
GoogleCodeExporter opened this issue Apr 10, 2015 · 3 comments
Closed

wait()/wait_for() losing items on Queue.get() #201

GoogleCodeExporter opened this issue Apr 10, 2015 · 3 comments

Comments

@GoogleCodeExporter
Copy link

Re: https://groups.google.com/forum/#!topic/python-tulip/31FktH8h-jk
(TL;DR: How do I use timeouts with "Queue.get()"?)

What steps will reproduce the problem?

The attached script demonstrates that loss of items in producer-consumer 
situation where there are timeouts with ".wait()".

The script will start a producer and a consumer. It will process 100 items.

What is the expected output? What do you see instead?

It is expected that the producer will put 100 items and the consumer will get 
100 items. Instead, the producer will put 100 items, but the consumer will only 
see a fraction of the items.

On my computer, the script will hang with 31 items outstanding. It is expected 
that the script should finish. If you remove line 40 where the producer is 
blocked (causing a timeout on the consumer), the script should complete.

What version of the product are you using? On what operating system?

Python 3.4.0 Ubuntu 14.04

Please provide any additional information below.

This also occurs with Trollius 1.0.

Original issue reported on code.google.com by [email protected] on 20 Aug 2014 at 3:07

Attachments:

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

1 participant