Do better DM retry to align with stndard firmware retry (but so that we can track the acks). Closes #73.

This commit is contained in:
Jack Kingsman
2026-03-17 18:12:07 -07:00
parent d5b8f7d462
commit 020acbda02
10 changed files with 474 additions and 9 deletions
+7
View File
@@ -12,6 +12,7 @@ from unittest.mock import AsyncMock, MagicMock, patch
import pytest
from fastapi import HTTPException
import app.services.message_send as message_send_service
from app.radio import radio_manager
from app.repository import (
ChannelRepository,
@@ -39,6 +40,12 @@ def _reset_radio_state():
radio_manager._channel_key_by_slot = prev_key_by_slot
@pytest.fixture(autouse=True)
def _disable_background_dm_retries(monkeypatch):
monkeypatch.setattr(message_send_service, "DM_SEND_MAX_ATTEMPTS", 1)
yield
def _patch_require_connected(mc=None, *, detail="Radio not connected"):
if mc is None:
return patch(