@testdriverai/runner 7.9.1-test → 7.9.2-test
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.
- package/lib/ably-service.js +2 -2
- package/lib/automation.js +7 -3
- package/package.json +1 -1
package/lib/ably-service.js
CHANGED
|
@@ -185,12 +185,12 @@ class AblyService extends EventEmitter {
|
|
|
185
185
|
const text = typeof msg === 'string' ? msg : String(msg);
|
|
186
186
|
const isError = /error/i.test(text) || /\[Level 1\]/i.test(text);
|
|
187
187
|
if (isError) {
|
|
188
|
-
console.error(
|
|
188
|
+
console.error('[Ably runner] Ably SDK error', { sandboxId: self._sandboxId, raw: text });
|
|
189
189
|
Sentry.withScope((scope) => {
|
|
190
190
|
scope.setTag('ably.client', 'runner');
|
|
191
191
|
scope.setTag('sandbox.id', self._sandboxId);
|
|
192
192
|
scope.setContext('ably_log', { raw: text });
|
|
193
|
-
Sentry.captureMessage(
|
|
193
|
+
Sentry.captureMessage('Ably SDK error (runner)', 'error');
|
|
194
194
|
});
|
|
195
195
|
}
|
|
196
196
|
Sentry.addBreadcrumb({
|
package/lib/automation.js
CHANGED
|
@@ -150,6 +150,10 @@ class ShellSession {
|
|
|
150
150
|
// Clear stderr buffer
|
|
151
151
|
this._stderrLines = [];
|
|
152
152
|
|
|
153
|
+
// Capture the process reference now — the exit handler may set
|
|
154
|
+
// this._process to null before the Promise resolves/times out.
|
|
155
|
+
const proc = this._process;
|
|
156
|
+
|
|
153
157
|
return await new Promise((resolve, reject) => {
|
|
154
158
|
const timeoutMs = timeout * 1000;
|
|
155
159
|
const timer = setTimeout(() => {
|
|
@@ -208,11 +212,11 @@ class ShellSession {
|
|
|
208
212
|
|
|
209
213
|
const cleanup = () => {
|
|
210
214
|
clearTimeout(timer);
|
|
211
|
-
|
|
215
|
+
proc.stdout.removeListener('data', onData);
|
|
212
216
|
};
|
|
213
217
|
|
|
214
|
-
|
|
215
|
-
|
|
218
|
+
proc.stdout.on('data', onData);
|
|
219
|
+
proc.stdin.write(fullCommand);
|
|
216
220
|
});
|
|
217
221
|
} catch (err) {
|
|
218
222
|
return {
|