Re: Signals and Threads in Python 3.5 or so

2016-10-24 Thread Dan Stromberg
On Mon, Oct 10, 2016 at 12:05 AM, dieter wrote: > Dan Stromberg writes: >> I have a program http://stromberg.dnsalias.org/~dstromberg/looper/ >> that I use and maintain. >> >> It's like GNU parallel or similar - yet another "run n processes, m at >> a time" implementation. Interestingly, I've on

Re: Signals and Threads in Python 3.5 or so

2016-10-10 Thread dieter
Dan Stromberg writes: > I have a program http://stromberg.dnsalias.org/~dstromberg/looper/ > that I use and maintain. > > It's like GNU parallel or similar - yet another "run n processes, m at > a time" implementation. Interestingly, I've only used/tested it on > Linux, but it's under a Microsoft

Re: Signals and Threads in Python 3.5 or so

2016-10-09 Thread Marko Rauhamaa
Dan Stromberg : > That bug is: if you control-C the top-level process, all the > subprocesses are left running. Sorry, don't have a solution for your particular Python situation. > I've been thinking about making it catch SIGINT, SIGTERM and SIGHUP, > and having it SIGKILL its active subprocesses

Re: Signals and Threads in Python 3.5 or so

2016-10-09 Thread Paul Rubin
Dan Stromberg writes: > That bug is: if you control-C the top-level process, all the > subprocesses are left running. Are you setting the daemon flag? -- https://mail.python.org/mailman/listinfo/python-list

Re: Signals and Threads in Python 3.5 or so

2016-10-09 Thread Chris Angelico
On Mon, Oct 10, 2016 at 10:52 AM, Dan Stromberg wrote: > That bug is: if you control-C the top-level process, all the > subprocesses are left running. > > I've been thinking about making it catch SIGINT, SIGTERM and SIGHUP, > and having it SIGKILL its active subprocesses upon receiving one of > th

Signals and Threads in Python 3.5 or so

2016-10-09 Thread Dan Stromberg
I have a program http://stromberg.dnsalias.org/~dstromberg/looper/ that I use and maintain. It's like GNU parallel or similar - yet another "run n processes, m at a time" implementation. Interestingly, I've only used/tested it on Linux, but it's under a Microsoft copyright because Microsoft acqui

Re: I want to know how to implement concurrent threads in Python

2013-05-28 Thread Ulrich Eckhardt
Am 26.05.2013 21:10, schrieb Daniel Gagliardi: I want to know how to implement concurrent threads in Python Have you tried searching the web or maybe looked on docs.python.org? Seriously, show at least some effort before asking here. Uli -- http://mail.python.org/mailman/listinfo/python

Re: I want to know how to implement concurrent threads in Python

2013-05-27 Thread Fábio Santos
On 28 May 2013 05:06, "Daniel Gagliardi" wrote: > > fuck! fuck! i'm gonna be fired if i didnt get this shit! i told my boss id do it. fuck! im gonna pipe some crakc. fuck... So do it. You've already been told how to. It's true that python does not do real concurrent execution, but if most of you

Re: I want to know how to implement concurrent threads in Python

2013-05-27 Thread Daniel Gagliardi
fuck! fuck! i'm gonna be fired if i didnt get this shit! i told my boss id do it. fuck! im gonna pipe some crakc. fuck... 2013/5/26 Mark Lawrence > On 26/05/2013 20:10, Daniel Gagliardi wrote: > >> I want to know how to implement concurrent threads in Python >> >&g

Re: I want to know how to implement concurrent threads in Python

2013-05-26 Thread Mark Lawrence
On 26/05/2013 20:10, Daniel Gagliardi wrote: I want to know how to implement concurrent threads in Python google, bing, duckduckgo, yahoo... -- If you're using GoogleCrap™ please read this http://wiki.python.org/moin/GoogleGroupsPython. Mark Lawrence -- http://mail.python.org/ma

Re: I want to know how to implement concurrent threads in Python

2013-05-26 Thread Mark Lawrence
On 26/05/2013 22:27, Andrew Berg wrote: On 2013.05.26 16:21, Daniel Gagliardi wrote: shutup bitch! i do know python cannot concurrent threads. want a workaround You're a charming fellow. I'm sure everyone will flock to help you. So "How to win friends and influence people" had two authors.

Re: I want to know how to implement concurrent threads in Python

2013-05-26 Thread Andrew Berg
On 2013.05.26 16:21, Daniel Gagliardi wrote: > shutup bitch! i do know python cannot concurrent threads. want a workaround You're a charming fellow. I'm sure everyone will flock to help you. -- http://mail.python.org/mailman/listinfo/python-list

Re: I want to know how to implement concurrent threads in Python

2013-05-26 Thread Andrew Berg
On 2013.05.26 14:10, Daniel Gagliardi wrote: > I want to know how to implement concurrent threads in Python With the threading module in the standard library. http://docs.python.org/3.3/library/threading.html There are plenty of tutorials on this out there; we'll be happy to help if you&

I want to know how to implement concurrent threads in Python

2013-05-26 Thread Daniel Gagliardi
I want to know how to implement concurrent threads in Python -- http://mail.python.org/mailman/listinfo/python-list

Re: Threads in Python

2011-09-01 Thread Grant Edwards
On 2011-09-01, Stephen Hansen wrote: > On 9/1/11 2:45 PM, George Kovoor wrote: >> Why doesn't python threads show an associated PID? On spawning >> python threads using the threading module I can only see the main >> thread's pid on using top or ps unix command, no subprocesses are >> displayed.

Re: Threads in Python

2011-09-01 Thread Cameron Simpson
On 01Sep2011 15:27, Stephen Hansen wrote: | On 9/1/11 2:45 PM, George Kovoor wrote: | > Why doesn't python threads show an associated PID? On spawning python | > threads using the threading module I can only see the main thread's pid on | > using top or ps unix command, no subprocesses are displ

Re: Threads in Python

2011-09-01 Thread Stephen Hansen
On 9/1/11 2:45 PM, George Kovoor wrote: > Hi, > Why doesn't python threads show an associated PID? On spawning python > threads using the threading module I can only see the main thread's pid on > using top or ps unix command, no subprocesses are displayed. In otherwords > top or ps in not aware

Re: About threads in python

2011-04-25 Thread Hans Georg Schaathun
On Fri, 22 Apr 2011 12:19:56 -0700 (PDT), sturlamolden wrote: : To optimise computational code, notice that Python itself : gives you a 200x performance penalty. That is much more : important than not using all 4 cores on a quadcore processor. : In this case, start by identifying bottlenecks

Re: About threads in python

2011-04-22 Thread sturlamolden
On Apr 21, 3:19 pm, dutche wrote: > My question is about the efficiency of threads in python, does anybody > has something to share? Never mind all the FUD about the GIL. Most of it is ill-informed and plain wrong. The GIL prevents you from doing one thing, which is parallel compute-boun

Re: About threads in python

2011-04-21 Thread Dan Stromberg
On Thu, Apr 21, 2011 at 6:19 AM, dutche wrote: > Hi folks, how are ya? > > Here's the thing...I had to make a program with threads and after > finished, I found some posts and articles in Google about Python and > threads, raising the question about if it really implements thread > programming or

Re: About threads in python

2011-04-21 Thread Stefan Behnel
C api"? Do you mean that it uses binary modules, as opposed to Python modules? My question is about the efficiency of threads in python, does anybody has something to share? From your (rather unspecific) description, I gather that you are doing mostly I/O operations. Threading i

About threads in python

2011-04-21 Thread dutche
some objects. I have now in my program something about 8 threads and each of them runs different code based on some directives, these codes relies sometimes in C api, using classes like zipfile and tarfile, and others relies only in python code. My question is about the efficiency of threads in p

Re: Using threads in python is safe ?

2008-03-19 Thread Gabriel Genellina
En Wed, 19 Mar 2008 04:43:34 -0300, Deepak Rokade <[EMAIL PROTECTED]> escribió: > Thanks all for removing confusion about GIL, > one more question; > If jobs to be processed by threds is I/O bound would multithreading help > python to improve speed of application ? > Since I read that " multithr

Re: Using threads in python is safe ?

2008-03-19 Thread Simon Brunning
On Wed, Mar 19, 2008 at 7:43 AM, Deepak Rokade <[EMAIL PROTECTED]> wrote: > If jobs to be processed by threds is I/O bound would multithreading help > python to improve speed of application ? Probably, yes. -- Cheers, Simon B. [EMAIL PROTECTED] http://www.brunningonline.net/simon/blog/ -- http:

Re: Using threads in python is safe ?

2008-03-19 Thread Deepak Rokade
ant to use therads in my application. Going through the docs , I > read > > > about GIL. > > > Now I am confused whether using threads in python is safe or not. > > > > > One thing I know that if I am accessing global variables in two or > more > > &

Re: Using threads in python is safe ?

2008-03-16 Thread Benjamin
On Mar 16, 3:40 pm, "Gabriel Genellina" <[EMAIL PROTECTED]> wrote: > En Sat, 15 Mar 2008 11:57:44 -0200, Deepak Rokade <[EMAIL PROTECTED]> > escribi�: > > > I want to use therads in my application. Going through the docs , I read > > about GIL. > >

Re: Using threads in python is safe ?

2008-03-16 Thread Gabriel Genellina
En Sat, 15 Mar 2008 11:57:44 -0200, Deepak Rokade <[EMAIL PROTECTED]> escribi�: > I want to use therads in my application. Going through the docs , I read > about GIL. > Now I am confused whether using threads in python is safe or not. > > One thing I know that if

Using threads in python is safe ?

2008-03-15 Thread Deepak Rokade
Hi All, I want to use therads in my application. Going through the docs , I read about GIL. Now I am confused whether using threads in python is safe or not. One thing I know that if I am accessing global variables in two or more threads I need to synchronize them using locking or such mechanism

Re: Fwd: Problem with threads in python????????

2008-02-27 Thread James Matthews
Yes On Wed, Feb 27, 2008 at 3:56 AM, <[EMAIL PROTECTED]> wrote: > On Feb 26, 7:56 pm, "Gabriel Genellina" <[EMAIL PROTECTED]> > wrote: > > En Tue, 26 Feb 2008 01:46:48 -0200, Manikandan R <[EMAIL PROTECTED]> > > > escribió: > > > > > Hai, > > > > > Is it possible to share a single varia

Re: Fwd: Problem with threads in python????????

2008-02-26 Thread castironpi
On Feb 26, 7:56 pm, "Gabriel Genellina" <[EMAIL PROTECTED]> wrote: > En Tue, 26 Feb 2008 01:46:48 -0200, Manikandan R <[EMAIL PROTECTED]>   > escribió: > > > Hai, > > >           Is it possible to share a single variable between multiple > > threads. For eg: > > > Class A: > >          thread_init(

Re: Fwd: Problem with threads in python????????

2008-02-26 Thread Gabriel Genellina
En Tue, 26 Feb 2008 01:46:48 -0200, Manikandan R <[EMAIL PROTECTED]> escribió: > Hai, > > Is it possible to share a single variable between multiple > threads. For eg: > > Class A: > thread_init() > >def run(): > fun1() > > def fun(): > assume s

Fwd: Problem with threads in python????????

2008-02-25 Thread Manikandan R
Hai, Is it possible to share a single variable between multiple threads. For eg: Class A: thread_init() def run(): fun1() def fun(): assume some arithmatic operation is going on according to the input given and each fun will *give different outp

Problem with threads in python????????

2008-02-25 Thread Manikandan R
Hai, Is it possible to share a single variable between multiple threads. For eg: Class A: thread_init() def run(): fun1() def fun(): assume some arithmatic operation is going on according to the input given and each fun will *give different outp

Re: Problem ... with threads in Python

2005-10-26 Thread Jeremy Jones
y have to finish a project which uses multiple threads in > Python, and i shouldn't use the time.sleep() function. > Is there any posibility to use multiple threads without using the > time.sleep() function ? And if so, what that way should be ? > > Best regards, > _Cosmin

Problem ... with threads in Python

2005-10-26 Thread Negoescu Constantin
Hello.       I know that Python is not fully threadsafe. Unlike Java, where threading was considered to be so important that it is a part of the syntax, in Python threads were laid down at the altar of Portability. But, i really have to finish a project  which uses multiple threads in

Re: What is situation with threads in Python

2005-04-25 Thread Jp Calderone
On Mon, 25 Apr 2005 10:46:57 -0700, "Leonard J. Reder" <[EMAIL PROTECTED]> wrote: Hello Mark, I took your three day course here at JPL and recall that you said something was wrong with the implementation of threads within Python but I cannot recall what. So what is wrong with t

Re: What is situation with threads in Python

2005-04-25 Thread Jp Calderone
annot recall what. So what is wrong with threads in Python? I'm going to guess that he meant the Global Interpreter Lock is what's wrong with Python threads. You can read about it in the docs at http://docs.python.org/api/threads.html and get some good analysis from Ian Bicking (with some e

Re: What is situation with threads in Python

2005-04-25 Thread Bill Mill
On 4/25/05, Leonard J. Reder <[EMAIL PROTECTED]> wrote: > Hello Mark, > > I took your three day course here at JPL and recall that you said > something was wrong with the implementation of threads within Python > but I cannot recall what. So what is wrong with threads in

What is situation with threads in Python

2005-04-25 Thread Leonard J. Reder
Hello Mark, I took your three day course here at JPL and recall that you said something was wrong with the implementation of threads within Python but I cannot recall what. So what is wrong with threads in Python? The other part of this question is, if there is something wrong with the threads