I am developing a GUI interface for a Python module (running in CLI), that when executed was the output bellow:
Progress: 50%|███████████████ | 45/45 [time, info]
Message 1
Message 2
Progress: 100%|███████████████████████████████| 45/45 [time, info]
Finished!
I intend to execute this as a subprocess
and get the output, parse the perceptual to a process bar and the "Messages" to a log.
How I do that? Is it possible with subprocess
get the output of a CLI software periodically (or each new entry) without show the terminal?
To execute it now, I am using subprocess.call('shell command', shell=True)
. So it is really a shell command (that at the end load and run a python module), but this give the output in the terminal.