diff options
| author | Jarek Kobus <jaroslaw.kobus@qt.io> | 2024-01-22 12:49:58 +0100 |
|---|---|---|
| committer | Jarek Kobus <jaroslaw.kobus@qt.io> | 2024-01-22 20:27:38 +0000 |
| commit | f6be85b1d2762951dffa77d5b7f03199eb795f35 (patch) | |
| tree | fb35ee2ece278cf512fde686cc29fabbfdb28b47 /src/plugins/python/pythonutils.cpp | |
| parent | 886ac041e58ee77242b9d5fee0d5749239eb2228 (diff) | |
Process: Refactor timeout handling
Rename ProcessResult::Hang into Canceled.
Change the behavior of the Process:
Whenever the terminate() or kill() is called, including
indirect calls through stop() or runBlocking()'s timeout,
mark the process result as Canceled.
In this way the Process running by a call to start()
may also finish with Canceled state. Before it was only
happening for processes started via runBlocking().
Adapt the runBlockingStdOut_data() test accordingly.
Get rid of ProcessInterface::m_canceledByUser field.
Use ProcessResult::Canceled state instead.
Fix existing 3 usages of m_canceledByUser field.
Use standarized exitMessage() method for them.
Add automatic measurement of process execution.
Introduce processDuration() getter.
Use it for reporting exitMessage() instead of timeoutS().
Change-Id: I1a68559ce844caef863a97a6b0577b0238011f70
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
Diffstat (limited to 'src/plugins/python/pythonutils.cpp')
0 files changed, 0 insertions, 0 deletions
