Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #82613

Re: Is there a way to schedule my script?

Path csiph.com!v102.xanadu-bbs.net!xanadu-bbs.net!nntp.club.cc.cmu.edu!micro-heart-of-gold.mit.edu!bloom-beacon.mit.edu!bloom-beacon.mit.edu!panix!gordon
From John Gordon <gordon@panix.com>
Newsgroups comp.lang.python
Subject Re: Is there a way to schedule my script?
Date Wed, 17 Dec 2014 20:23:33 +0000 (UTC)
Organization PANIX Public Access Internet and UNIX, NYC
Lines 18
Message-ID <m6soo5$mc3$1@reader1.panix.com> (permalink)
References <mailman.17010.1418843457.18130.python-list@python.org> <m6sm9d$5es$1@reader1.panix.com> <mailman.17012.1418845926.18130.python-list@python.org>
NNTP-Posting-Host panix3.panix.com
X-Trace reader1.panix.com 1418847813 22915 166.84.1.3 (17 Dec 2014 20:23:33 GMT)
X-Complaints-To abuse@panix.com
NNTP-Posting-Date Wed, 17 Dec 2014 20:23:33 +0000 (UTC)
User-Agent nn/6.7.3
Xref csiph.com comp.lang.python:82613

Show key headers only | View raw


In <mailman.17012.1418845926.18130.python-list@python.org> Juan Christian <juan0christian@gmail.com> writes:

> The standard system "kill" command would probably work for this purpose,
> assuming you have access to your main program's process ID.

> There isn't any 'prettier' way? Such as a built-in or third-party module
> for something common like that?

If you're on Unix, 'kill' and 'cron' are already built-in.

If you want to solve your problem entirely within Python, look at the
"scheduler" module.  (Although even this isn't a complete solution, as you
still have to make sure the program is running in the first place...)

-- 
John Gordon         Imagine what it must be like for a real medical doctor to
gordon@panix.com    watch 'House', or a real serial killer to watch 'Dexter'.

Back to comp.lang.python | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread


Thread

Is there a way to schedule my script? Juan Christian <juan0christian@gmail.com> - 2014-12-17 19:10 +0000
  Re: Is there a way to schedule my script? John Gordon <gordon@panix.com> - 2014-12-17 19:41 +0000
    Re: Is there a way to schedule my script? Juan Christian <juan0christian@gmail.com> - 2014-12-17 19:51 +0000
      Re: Is there a way to schedule my script? John Gordon <gordon@panix.com> - 2014-12-17 20:23 +0000
        Re: Is there a way to schedule my script? Juan Christian <juan0christian@gmail.com> - 2014-12-17 20:42 +0000
        Re: Is there a way to schedule my script? Chris Angelico <rosuav@gmail.com> - 2014-12-18 08:34 +1100
        Re: Is there a way to schedule my script? Juan Christian <juan0christian@gmail.com> - 2014-12-17 21:47 +0000
        Re: Is there a way to schedule my script? Michael Torrie <torriem@gmail.com> - 2014-12-18 09:45 -0700
  Re: Is there a way to schedule my script? Steven D'Aprano <steve+comp.lang.python@pearwood.info> - 2014-12-18 10:39 +1100
    Re: Is there a way to schedule my script? Juan Christian <juan0christian@gmail.com> - 2014-12-18 01:04 +0000
    Re: Is there a way to schedule my script? Juan Christian <juan0christian@gmail.com> - 2014-12-18 12:37 +0000
    Re: Is there a way to schedule my script? Ian Kelly <ian.g.kelly@gmail.com> - 2014-12-18 09:23 -0700
    Re: Is there a way to schedule my script? Juan Christian <juan0christian@gmail.com> - 2014-12-18 22:13 +0000
    Re: Is there a way to schedule my script? Chris Angelico <rosuav@gmail.com> - 2014-12-19 12:32 +1100
    Re: Is there a way to schedule my script? Juan Christian <juan0christian@gmail.com> - 2014-12-19 01:55 +0000
    Re: Is there a way to schedule my script? Terry Reedy <tjreedy@udel.edu> - 2014-12-19 00:58 -0500
  Re: Is there a way to schedule my script? Josh English <Joshua.R.English@gmail.com> - 2014-12-18 09:13 -0800
    Re: Is there a way to schedule my script? Juan Christian <juan0christian@gmail.com> - 2014-12-18 18:29 +0000

csiph-web