Re: [BangPypers] Query on correct use of threading

2016-11-09 Thread Rajesh Deo
art() > workers.append(t) > > - pt = threading.Thread(target=printer, args=(output_queue,)) > +pt = threading.Thread(target=printer, args=(output_queue, count)) > pt.daemon = True > pt.start() > > > Cheers, > Praveen > > On 8 N

Re: [BangPypers] Query on correct use of threading

2016-11-08 Thread Rajesh Deo
Pls try this: https://bpaste.net/show/4279bfdb091a On Tue, Nov 8, 2016 at 9:33 PM, Noufal Ibrahim KV wrote: > On Tue, Nov 08 2016, Rajesh Deo wrote: > > > Dear All, > > > > I was exploring the threading module and came up with following, after > > going t

[BangPypers] Query on correct use of threading

2016-11-08 Thread Rajesh Deo
Dear All, I was exploring the threading module and came up with following, after going through @raymondh's talk (https://www.youtube.com/watch?v=Bv25Dwe84g0) http://pastebin.com/usKE6nME While the code runs fine when ran once or twice, it either deadlocks or waits indefinitely while performing a