1#ifndef SCRIPT_WORKER_HPP
2#define SCRIPT_WORKER_HPP
34 const QString &convertedScriptPath,
35 const QString &evalScriptPath,
36 bool parallelizedEvaluation,
71 void convertAndExecuteNotebook();
76 void executeConvertedScript();
81 void evaluateScriptInParallel();
91 void checkAndEmitFinished();
98 QString formatMessage(
const QString &msg,
bool fromEval =
false);
100 QString notebookPath;
101 QString convertedScriptPath;
102 QString evalScriptPath;
103 bool parallelizedEvaluationRequired;
106 bool mainScriptFinished;
107 bool evalScriptFinished;
109 QList<ProcessRunner*> processRunners;
113 QString evaluationOutput;
A class for converting Jupyter notebooks to Python scripts and processing task pools.
Definition notebook_converter.hpp:23
Manages the execution of an external process with a timeout.
Definition process_runner.hpp:15
Manages the execution of scripts for tasks.
Definition script_worker.hpp:21
ScriptWorker(const QString ¬ebookPath, const QString &convertedScriptPath, const QString &evalScriptPath, bool parallelizedEvaluation, int timeoutSeconds)
Constructs a ScriptWorker object.
Definition script_worker.cpp:25
void startExecution()
Starts the execution of the scripts.
Definition script_worker.cpp:39
void failed(const QString &error)
Signal emitted when the script execution fails.
void forceStop()
Forces the stop of all running scripts.
Definition script_worker.cpp:206
void finished()
Signal emitted when the script execution finishes.
void executePythonScript(const QString &scriptPath, const QString &name)
Executes a given Python script.
Definition script_worker.cpp:172