meshmonitor icon indicating copy to clipboard operation
meshmonitor copied to clipboard

[BUG] 4.14.1 - "reply to" is not translated well over Bridge

Open kokoshell opened this issue 3 months ago • 1 comments

Meshtastic message + tapbacks "reply to"

Image

Meshcore messages got from the Bridge = independent msgs Image

kokoshell avatar Aug 13 '26 19:08 kokoshell

Thanks for the report! Classifying this as a Bug Report.

What's happening

The screenshots show it exactly: on the Meshtastic side a message and its tapback/reply render as threaded (linked to the original), but once relayed across the MT↔MC bridge automation (src/components/automations/templates/bridge.ts, from the earlier #4577 bridge feature), the MeshCore side shows it as a brand-new, unrelated message.

Root cause — two independent gaps

  1. The bridge's relay text never looked at reply/tapback data at all. The MT→MC relay action built its text as {{ trigger.protocolShort }}@{{ trigger.fromName }}: {{ trigger.text }} — flat text, regardless of whether the source message was a tapback (an emoji reaction) or a threaded reply. Meshtastic tapbacks/replies are delivered to the automation engine with their replyId/emoji fields intact (triggerContext.ts), but the bridge template simply discarded that context.
  2. Even if it hadn't, MeshCore has nowhere to put it. MeshCore's sendMessage() API (meshcoreManager.ts) has no reply-id/thread parameter — the wire protocol has no threading concept for the bridge to populate. So a fully linked "reply" on the MeshCore side isn't achievable today without upstream MeshCore protocol support.

Fix

Since real thread-linking isn't possible, I've added the best available signal: a new {{ trigger.replyContext }} token (derived from the existing replyId/emoji fields) that renders "↩️ reacted: " for a tapback or "↩️ reply: " for a threaded reply, and is blank for an ordinary message. The bridge's MT→MC relay text now includes it, so instead of MC@Alice: 👍 (looking like a fresh message), the MeshCore side now sees MC@Alice: ↩️ reacted: 👍 — clearly marked as a reaction rather than new chat. Same treatment for threaded replies.

This doesn't restore true click-to-jump threading (MeshCore's protocol has no field for that), but it does fix the specific complaint here — reactions/replies no longer look like independent, unrelated messages.

PR: #4699 (full test suite + lint clean). I'll keep an eye on CI for it.

-- Authored by Roger 🤓


Generated by Claude Code

Yeraze avatar Aug 13 '26 20:08 Yeraze