@midscene/visualizer 1.0.4-beta-20251223112206.0 → 1.0.4-beta-20251223124656.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -71,18 +71,6 @@ function _object_spread_props(target, source) {
|
|
|
71
71
|
});
|
|
72
72
|
return target;
|
|
73
73
|
}
|
|
74
|
-
function formatError(error) {
|
|
75
|
-
var _error_dump;
|
|
76
|
-
if (!error) return '';
|
|
77
|
-
if ('string' == typeof error) return error;
|
|
78
|
-
if (null == error ? void 0 : null == (_error_dump = error.dump) ? void 0 : _error_dump.error) return error.dump.error;
|
|
79
|
-
if (error.message) return String(error.message);
|
|
80
|
-
try {
|
|
81
|
-
return JSON.stringify(error);
|
|
82
|
-
} catch (e) {
|
|
83
|
-
return String(error);
|
|
84
|
-
}
|
|
85
|
-
}
|
|
86
74
|
function buildProgressContent(task) {
|
|
87
75
|
const action = typeStr(task);
|
|
88
76
|
const description = paramStr(task);
|
|
@@ -154,7 +142,7 @@ function usePlaygroundExecution(playgroundSDK, storage, actionSpace, loading, se
|
|
|
154
142
|
content: buildProgressContent(task),
|
|
155
143
|
timestamp: new Date((null == (_task_timing = task.timing) ? void 0 : _task_timing.start) || Date.now()),
|
|
156
144
|
result: task.error ? {
|
|
157
|
-
error:
|
|
145
|
+
error: String(task.error),
|
|
158
146
|
result: null
|
|
159
147
|
} : void 0
|
|
160
148
|
};
|
|
@@ -180,11 +168,11 @@ function usePlaygroundExecution(playgroundSDK, storage, actionSpace, loading, se
|
|
|
180
168
|
const resultObj = result.result;
|
|
181
169
|
if (resultObj.dump) result.dump = resultObj.dump;
|
|
182
170
|
if (resultObj.reportHTML) result.reportHTML = resultObj.reportHTML;
|
|
183
|
-
if (resultObj.error) result.error =
|
|
171
|
+
if (resultObj.error) result.error = resultObj.error;
|
|
184
172
|
if (void 0 !== resultObj.result) result.result = resultObj.result;
|
|
185
173
|
}
|
|
186
174
|
} catch (e) {
|
|
187
|
-
result.error =
|
|
175
|
+
result.error = (null == e ? void 0 : e.message) || String(e);
|
|
188
176
|
console.error('Playground execution error:', e);
|
|
189
177
|
if ('object' == typeof e && null !== e) {
|
|
190
178
|
if (e.dump) result.dump = e.dump;
|
|
@@ -99,18 +99,6 @@ function _object_spread_props(target, source) {
|
|
|
99
99
|
});
|
|
100
100
|
return target;
|
|
101
101
|
}
|
|
102
|
-
function formatError(error) {
|
|
103
|
-
var _error_dump;
|
|
104
|
-
if (!error) return '';
|
|
105
|
-
if ('string' == typeof error) return error;
|
|
106
|
-
if (null == error ? void 0 : null == (_error_dump = error.dump) ? void 0 : _error_dump.error) return error.dump.error;
|
|
107
|
-
if (error.message) return String(error.message);
|
|
108
|
-
try {
|
|
109
|
-
return JSON.stringify(error);
|
|
110
|
-
} catch (e) {
|
|
111
|
-
return String(error);
|
|
112
|
-
}
|
|
113
|
-
}
|
|
114
102
|
function buildProgressContent(task) {
|
|
115
103
|
const action = (0, agent_namespaceObject.typeStr)(task);
|
|
116
104
|
const description = (0, agent_namespaceObject.paramStr)(task);
|
|
@@ -182,7 +170,7 @@ function usePlaygroundExecution(playgroundSDK, storage, actionSpace, loading, se
|
|
|
182
170
|
content: buildProgressContent(task),
|
|
183
171
|
timestamp: new Date((null == (_task_timing = task.timing) ? void 0 : _task_timing.start) || Date.now()),
|
|
184
172
|
result: task.error ? {
|
|
185
|
-
error:
|
|
173
|
+
error: String(task.error),
|
|
186
174
|
result: null
|
|
187
175
|
} : void 0
|
|
188
176
|
};
|
|
@@ -208,11 +196,11 @@ function usePlaygroundExecution(playgroundSDK, storage, actionSpace, loading, se
|
|
|
208
196
|
const resultObj = result.result;
|
|
209
197
|
if (resultObj.dump) result.dump = resultObj.dump;
|
|
210
198
|
if (resultObj.reportHTML) result.reportHTML = resultObj.reportHTML;
|
|
211
|
-
if (resultObj.error) result.error =
|
|
199
|
+
if (resultObj.error) result.error = resultObj.error;
|
|
212
200
|
if (void 0 !== resultObj.result) result.result = resultObj.result;
|
|
213
201
|
}
|
|
214
202
|
} catch (e) {
|
|
215
|
-
result.error =
|
|
203
|
+
result.error = (null == e ? void 0 : e.message) || String(e);
|
|
216
204
|
console.error('Playground execution error:', e);
|
|
217
205
|
if ('object' == typeof e && null !== e) {
|
|
218
206
|
if (e.dump) result.dump = e.dump;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@midscene/visualizer",
|
|
3
|
-
"version": "1.0.4-beta-
|
|
3
|
+
"version": "1.0.4-beta-20251223124656.0",
|
|
4
4
|
"repository": "https://github.com/web-infra-dev/midscene",
|
|
5
5
|
"homepage": "https://midscenejs.com/",
|
|
6
6
|
"types": "./dist/types/index.d.ts",
|
|
@@ -60,10 +60,10 @@
|
|
|
60
60
|
"antd": "^5.21.6",
|
|
61
61
|
"buffer": "6.0.3",
|
|
62
62
|
"dayjs": "^1.11.11",
|
|
63
|
-
"@midscene/core": "1.0.4-beta-
|
|
64
|
-
"@midscene/playground": "1.0.4-beta-
|
|
65
|
-
"@midscene/shared": "1.0.4-beta-
|
|
66
|
-
"@midscene/web": "1.0.4-beta-
|
|
63
|
+
"@midscene/core": "1.0.4-beta-20251223124656.0",
|
|
64
|
+
"@midscene/playground": "1.0.4-beta-20251223124656.0",
|
|
65
|
+
"@midscene/shared": "1.0.4-beta-20251223124656.0",
|
|
66
|
+
"@midscene/web": "1.0.4-beta-20251223124656.0"
|
|
67
67
|
},
|
|
68
68
|
"license": "MIT",
|
|
69
69
|
"scripts": {
|