F
Fortepianissimo
Here is the situation: I have multiple processes of same Python script
fired, but I want *only one* of them to continue and all the others to
quit immediately.
I can use a lock file, and the first process will get the necessary
lock. But if I do open(lockfile) all the other subsequent processes
will just wait there - instead I want them to quit immediately.
Can someone give a simple outline of how to achieve this? Thanks a
lot.
fired, but I want *only one* of them to continue and all the others to
quit immediately.
I can use a lock file, and the first process will get the necessary
lock. But if I do open(lockfile) all the other subsequent processes
will just wait there - instead I want them to quit immediately.
Can someone give a simple outline of how to achieve this? Thanks a
lot.