@pasko70/pibo 1.7.12 → 1.8.1

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.
@@ -252,7 +252,7 @@ export class PiboRalphService {
252
252
  },
253
253
  });
254
254
  this.store.attachRunSession(job.id, run.id, session.id);
255
- const finalAnswer = await this.emitMessageAndWait(session.id, buildRalphPrompt(job), { isCancelled: () => this.cancelledRuns.has(run.id) });
255
+ const finalAnswer = await this.emitMessageAndWait(session.id, buildRalphPrompt(job));
256
256
  return { piboSessionId: session.id, finalAnswer };
257
257
  }
258
258
  resolveTarget(job) { if (job.target.kind === 'room') {
@@ -263,7 +263,7 @@ export class PiboRalphService {
263
263
  throw new Error('Target room is archived');
264
264
  return { roomId: room.id, workspace: room.workspace ?? getDefaultPiboWorkspace() };
265
265
  } const room = this.roomService.ensureDefaultRoom({ name: 'Shared Chat' }); return { roomId: room.id, workspace: room.workspace ?? getDefaultPiboWorkspace() }; }
266
- async emitMessageAndWait(piboSessionId, text, options = {}) {
266
+ async emitMessageAndWait(piboSessionId, text) {
267
267
  const eventId = `ralph_msg_${randomUUID()}`;
268
268
  return await new Promise((resolve, reject) => {
269
269
  let settled = false;
@@ -308,9 +308,7 @@ export class PiboRalphService {
308
308
  finish(lastSessionError ? new Error(lastSessionError) : undefined);
309
309
  if (event.type === 'session_error') {
310
310
  lastSessionError = event.error;
311
- const providerAttempt = event.errorDetails?.origin === 'provider' && Boolean(event.errorDetails.api || event.errorDetails.provider || event.errorDetails.model);
312
- if (!providerAttempt || options.isCancelled?.())
313
- finish(new Error(event.error));
311
+ finish(new Error(event.error));
314
312
  }
315
313
  });
316
314
  this.options.context.emit({ type: 'message', piboSessionId, id: eventId, source: 'service', text }).catch((error) => finish(error instanceof Error ? error : new Error(String(error))));
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pasko70/pibo",
3
- "version": "1.7.12",
3
+ "version": "1.8.1",
4
4
  "type": "module",
5
5
  "imports": {
6
6
  "vscode": "./src/apps/chat-vscode/extension/src/vscode-shim.js"