@poncho-ai/messaging 0.7.8 → 0.7.10

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.
@@ -1,5 +1,5 @@
1
1
 
2
- > @poncho-ai/messaging@0.7.8 build /home/runner/work/poncho-ai/poncho-ai/packages/messaging
2
+ > @poncho-ai/messaging@0.7.10 build /home/runner/work/poncho-ai/poncho-ai/packages/messaging
3
3
  > tsup src/index.ts --format esm --dts
4
4
 
5
5
  CLI Building entry: src/index.ts
@@ -7,8 +7,8 @@
7
7
  CLI tsup v8.5.1
8
8
  CLI Target: es2022
9
9
  ESM Build start
10
- ESM dist/index.js 51.91 KB
11
- ESM ⚡️ Build success in 49ms
10
+ ESM dist/index.js 52.02 KB
11
+ ESM ⚡️ Build success in 128ms
12
12
  DTS Build start
13
- DTS ⚡️ Build success in 5402ms
13
+ DTS ⚡️ Build success in 4935ms
14
14
  DTS dist/index.d.ts 11.66 KB
package/CHANGELOG.md CHANGED
@@ -1,5 +1,17 @@
1
1
  # @poncho-ai/messaging
2
2
 
3
+ ## 0.7.10
4
+
5
+ ### Patch Changes
6
+
7
+ - [#73](https://github.com/cesr/poncho-ai/pull/73) [`f72f202`](https://github.com/cesr/poncho-ai/commit/f72f202d839dbbb8240336ec76eb6340aba20f06) Thanks [@cesr](https://github.com/cesr)! - Fix Telegram approval message ordering: send accumulated assistant text before approval buttons so the conversation reads naturally. Skip empty bridge replies when text was already sent at checkpoint.
8
+
9
+ ## 0.7.9
10
+
11
+ ### Patch Changes
12
+
13
+ - [#71](https://github.com/cesr/poncho-ai/pull/71) [`3e5bf7e`](https://github.com/cesr/poncho-ai/commit/3e5bf7e527e394c5f823beac90712756e57cd491) Thanks [@cesr](https://github.com/cesr)! - Fix Telegram tool approval handler never persisting the approval decision, preventing the resume-from-checkpoint flow from triggering. Make answerCallbackQuery best-effort so transient fetch failures don't block approval processing.
14
+
3
15
  ## 0.7.8
4
16
 
5
17
  ### Patch Changes
package/dist/index.js CHANGED
@@ -99,11 +99,11 @@ ${message.text}`;
99
99
  }
100
100
  break;
101
101
  }
102
- if (this.adapter.autoReply) {
102
+ if (this.adapter.autoReply && (accumulatedResponse.trim() || accumulatedFiles.length > 0)) {
103
103
  await this.adapter.sendReply(message.threadRef, accumulatedResponse, {
104
104
  files: accumulatedFiles.length > 0 ? accumulatedFiles : void 0
105
105
  });
106
- } else if (!this.adapter.hasSentInCurrentRequest) {
106
+ } else if (!this.adapter.autoReply && !this.adapter.hasSentInCurrentRequest) {
107
107
  console.warn("[agent-bridge] tool mode completed without send_email being called; no reply sent");
108
108
  }
109
109
  } catch (error) {
@@ -1526,6 +1526,7 @@ ${inputSummary}` : "(no input)"
1526
1526
  const chatId = query.message?.chat.id ? String(query.message.chat.id) : void 0;
1527
1527
  await answerCallbackQuery(this.botToken, query.id, {
1528
1528
  text: approved ? "Approved" : "Denied"
1529
+ }).catch(() => {
1529
1530
  });
1530
1531
  if (this.approvalDecisionHandler && chatId) {
1531
1532
  await this.approvalDecisionHandler(approvalId, approved, chatId);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@poncho-ai/messaging",
3
- "version": "0.7.8",
3
+ "version": "0.7.10",
4
4
  "description": "Messaging platform adapters for Poncho agents (Slack, Telegram, etc.)",
5
5
  "repository": {
6
6
  "type": "git",
@@ -502,7 +502,7 @@ export class TelegramAdapter implements MessagingAdapter {
502
502
 
503
503
  await answerCallbackQuery(this.botToken, query.id, {
504
504
  text: approved ? "Approved" : "Denied",
505
- });
505
+ }).catch(() => {});
506
506
 
507
507
  if (this.approvalDecisionHandler && chatId) {
508
508
  await this.approvalDecisionHandler(approvalId, approved, chatId);
package/src/bridge.ts CHANGED
@@ -138,11 +138,11 @@ export class AgentBridge {
138
138
  break;
139
139
  }
140
140
 
141
- if (this.adapter.autoReply) {
141
+ if (this.adapter.autoReply && (accumulatedResponse.trim() || accumulatedFiles.length > 0)) {
142
142
  await this.adapter.sendReply(message.threadRef, accumulatedResponse, {
143
143
  files: accumulatedFiles.length > 0 ? accumulatedFiles : undefined,
144
144
  });
145
- } else if (!this.adapter.hasSentInCurrentRequest) {
145
+ } else if (!this.adapter.autoReply && !this.adapter.hasSentInCurrentRequest) {
146
146
  console.warn("[agent-bridge] tool mode completed without send_email being called; no reply sent");
147
147
  }
148
148
  } catch (error) {