@testdriverai/runner 7.9.1 → 7.9.3-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.
@@ -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(`[Ably runner] ${text}`);
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(`[Ably runner] ${text}`, 'error');
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
- this._process.stdout.removeListener('data', onData);
215
+ proc.stdout.removeListener('data', onData);
212
216
  };
213
217
 
214
- this._process.stdout.on('data', onData);
215
- this._process.stdin.write(fullCommand);
218
+ proc.stdout.on('data', onData);
219
+ proc.stdin.write(fullCommand);
216
220
  });
217
221
  } catch (err) {
218
222
  return {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@testdriverai/runner",
3
- "version": "7.9.1",
3
+ "version": "7.9.3-test",
4
4
  "description": "TestDriver Runner - Ably-based remote automation agent with Node.js automation",
5
5
  "main": "index.js",
6
6
  "bin": {