Show syntax errors when editing in python script editor

This commit is contained in:
baldurk
2026-08-13 17:46:41 +01:00
parent a70ee3a2eb
commit 23ca2cf053
3 changed files with 111 additions and 1 deletions
@@ -37,6 +37,12 @@ typedef struct _object PyObject;
typedef struct _frame PyFrameObject;
typedef struct _ts PyThreadState;
struct PyParseError
{
int lineno = -1, offset = -1;
rdcstr errStr;
};
class PythonContext : public QObject
{
private:
@@ -77,6 +83,8 @@ public:
static bool WaitForDebugger();
static void LaunchDebugger(QWidget *window, PersistantConfig &config, QString context_location);
PyParseError CheckPyParse(const QByteArray &script, const rdcstr &scriptNameForErrors);
bool CheckInterfaces(rdcstr &log);
QString versionString();