Skip to content

fix(reticulum): remap identity Chat DMs and clear link-timeout Send stuck - #967

Merged
rinchen merged 1 commit into
mainfrom
fix/reticulum-mc-mc-lxmf-dm
Sep 9, 2026
Merged

rinchen merged 1 commit into
mainfrom
fix/reticulum-mc-mc-lxmf-dm

Conversation

@rinchen

@rinchen rinchen commented Sep 9, 2026

Copy link
Copy Markdown
Member

Summary

Test plan

  • Vitest: identity→LXMF remap/refuse, open DM tab collapse, send uses LXMF hash, face-hash remaps identity
  • Vitest: reticulumLinkTimeoutBridgeDedup clear-on-new-outbound + runtime source contracts
  • Pre-commit related suite green
  • Manual: paste peer identity with known LXMF → single tab, header LXMF matches Network
  • Manual: after Direct link timeout + Propagation Off, second Send to same peer reaches Failed (not stuck Sending)
  • Reporter retest: both Announce now; Message on LXMF row; Propagation Auto; Prefer RF ≠ disable TCP

Summary by CodeRabbit

  • Bug Fixes

    • Reticulum chats now resolve identity hashes to the peer’s available LXMF destination when possible.
    • Messages sent to identity-based destinations are routed through the correct chat destination.
    • Link-timeout handling now avoids duplicate failures while allowing later delivery attempts to retry successfully.
  • Documentation

    • Expanded troubleshooting guidance for chat failures, RF-only testing, missing paths, announce timing, and comparing diagnostic exports.

…tuck

RNS identity pastes no longer open a separate non-LXMF tab or send to the
wrong dest; link-timeout bridge dedupe clears on each new outbound so later
Sends can fail instead of staying Sending forever.
@coderabbitai

coderabbitai Bot commented Sep 9, 2026

Copy link
Copy Markdown
Contributor

Review Change StackReview Change Stack

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: QUIET

Plan: Advanced

Run ID: 3a1b25e7-523c-4b9e-bf97-85eabf69569e

📥 Commits

Reviewing files that changed from the base of the PR and between ec06b75 and e240648.

📒 Files selected for processing (11)
  • docs/troubleshooting.md
  • src/renderer/lib/reticulum/resolveReticulumChatLxmfDest.test.ts
  • src/renderer/lib/reticulum/resolveReticulumChatLxmfDest.ts
  • src/renderer/lib/reticulum/reticulumChatFaceHash.test.ts
  • src/renderer/lib/reticulum/reticulumDestinationInput.test.ts
  • src/renderer/lib/reticulum/reticulumDestinationInput.ts
  • src/renderer/lib/reticulum/reticulumLinkTimeoutBridgeDedup.test.ts
  • src/renderer/lib/reticulum/reticulumLinkTimeoutBridgeDedup.ts
  • src/renderer/lib/reticulum/sendReticulumChatMessage.test.ts
  • src/renderer/runtime/useReticulumRuntime.reconnect-hardening.test.ts
  • src/renderer/runtime/useReticulumRuntime.ts

Included review availability: Your plan provides up to 2 included reviews per hour; 1 remains after this review.


📝 Walkthrough

Walkthrough

The change maps known RNS identity hashes to LXMF destinations across chat flows. It also centralizes link-timeout deduplication and permits retries after new outbound sends. Troubleshooting guidance and tests cover both behaviors.

Changes

Reticulum chat delivery

Layer / File(s) Summary
Identity hash to LXMF resolution
src/renderer/lib/reticulum/resolveReticulumChatLxmfDest.ts, src/renderer/lib/reticulum/*test.ts
Known RNS identity hashes now resolve to announced lxmf.delivery destinations. Identities without LXMF activity return missing_lxmf. Chat destination, DM face, node canonicalization, and message sending tests cover the mapping.
Link-timeout retry deduplication
src/renderer/lib/reticulum/reticulumLinkTimeoutBridgeDedup.*, src/renderer/runtime/useReticulumRuntime.*, docs/troubleshooting.md
Link-timeout handling uses normalized processed-destination helpers. New sends clear prior processed state. Troubleshooting guidance documents identity/LXMF resolution, RF testing, path checks, and message activity comparison.

Priority: ➖ Normal

Estimated code review effort: 3 (Moderate) | ~20 minutes

Merge Risk: ⚪ Minimal · up to e2406

No confirmed merge-blocking risk remains in the reviewed changes.

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 70.00% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 10 functions across 10 files. (1 skipped:… Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (4 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly summarizes the two primary changes: remapping identity-based Reticulum Chat DMs and clearing link-timeout state that can leave Sends stuck.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Full details: Docstring Coverage

Explanation

Docstring coverage is 70.00% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 10 functions across 10 files. (1 skipped: 1 unsupported.)

  • Fix all pre-merge checks with AI
✨ Finishing Touches 💡 1
📝 Generate docstrings 💡
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch fix/reticulum-mc-mc-lxmf-dm

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@rinchen
rinchen merged commit ffda414 into main Sep 9, 2026
24 checks passed
@rinchen
rinchen deleted the fix/reticulum-mc-mc-lxmf-dm branch September 9, 2026 21:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant