sokol wrote:
...
I see what you did there. You are keeping the queue empty
so you get notified for free, while I introduced a new
threading Condition to detect insertions.
All that is missing in your version is to put back all
pending tasks when somebody sends the stop (None) request.
Shouldn't sched module do something similar?
Probably so, I was just scratching an itch that I had.
My target was to make the decisions as clear as possible.
What I started from is "you only need to do work when
the next thing comes up or another entry is added."
That was the core I was going after, and I just had the None
in there so my tests could stop gracefully (in fact I printed
the leftover queue when I was testing).
--Scott David Daniels
[EMAIL PROTECTED]
--
http://mail.python.org/mailman/listinfo/python-list