feat(channel): add message send retry mechanism with exponential backoff

- Add send_max_retries config option (default: 3, range: 0-10)
- Implement _send_with_retry in ChannelManager with 1s/2s/4s backoff
- Propagate CancelledError for graceful shutdown
- Fix telegram send_delta to raise exceptions for Manager retry
- Add comprehensive tests for retry logic
- Document channel settings in README
This commit is contained in:
chengyongru
2026-03-25 22:37:11 +08:00
committed by Xubin Ren
parent 3f71014b7c
commit 5e9fa28ff2
6 changed files with 707 additions and 12 deletions
+13
View File
@@ -120,3 +120,16 @@ ignore = ["E501"]
[tool.pytest.ini_options]
asyncio_mode = "auto"
testpaths = ["tests"]
[tool.coverage.run]
source = ["nanobot"]
omit = ["tests/*", "**/tests/*"]
[tool.coverage.report]
exclude_lines = [
"pragma: no cover",
"def __repr__",
"raise NotImplementedError",
"if __name__ == .__main__.:",
"if TYPE_CHECKING:",
]