T
T
typical_boii2020-06-14 00:35:28
Python
typical_boii, 2020-06-14 00:35:28

Need to write a script that will watch for a second script that periodically crashes?

There is a script that is installed on a dedik with Ubuntu 20.04 and plows 24/7 (no), it crashes, the error is not fixed, the crash does not depend on me, and the script is not mine. We need a couple of lines that will restart the program in case of a stop.

Answer the question

In order to leave comments, you need to log in

1 answer(s)
S
Sergey Karbivnichy, 2020-06-14
@typical_boii

It's most likely a crutch. You need to catch the error and wrap that part of the script in a try...except construct. The script is most likely a parser (probably).

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question