N
N
nnikolyaa2020-07-17 11:55:09
Python
nnikolyaa, 2020-07-17 11:55:09

Running an external program?

An error occurs when running an external file.
The file is on the host. Because of this, I can't specify the full path because it doesn't exist.
Searched the forums for an answer, but none worked.
autorestart.py:

import time
import os
while True:
  os.system('/user/nnikolyaa/files/home/nnikolyaa/example.py')
  time.sleep(3600)

Answer the question

In order to leave comments, you need to log in

1 answer(s)
D
Dmitry, 2020-07-17
@nnikolyaa

example.py is executable? If not, why should it be executed?
> Because of this, I can not specify the full path, since it does not exist
, this is some kind of nonsense

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question