Skip to content

Handle bridge timeouts and improve Telegram error reporting - #19

Merged
boly38 merged 2 commits into
mainfrom
dev/issue-18-telegram-timeout-reporting
Oct 18, 2026
Merged

boly38 merged 2 commits into
mainfrom
dev/issue-18-telegram-timeout-reporting

Conversation

@boly38

@boly38 boly38 commented Oct 18, 2026

Copy link
Copy Markdown
Owner

Closes #18

Summary

  • Acknowledge authorized Telegram requests immediately, then edit the acknowledgement with progress,
    the final response, or a safe error reference.
  • Submit OpenCode prompts asynchronously and correlate responses and progress events with the request.
  • Distinguish OpenCode timeouts from other failures and log the client, phase, duration, timeout, and
    safe error details without logging prompts, credentials, session IDs, or raw response bodies.
  • Set the OpenCode request deadline to 300 seconds; keep Telegram HTTP at 70 seconds and long polling
    at 50 seconds.
  • Use OpenCode-compatible message IDs and expose only generic progress states, not raw reasoning.

Validation

  • make test — 45 tests passed
  • python3 -m py_compile bot/telegram/bridge.py bot/telegram/http_api.py bot/telegram/opencode_api.py bot/telegram/bridge_config.py
  • make config
  • git diff --check
  • A manual Telegram ping was tested locally; the user reported that acknowledgement and response
    handling worked better after the message ID fix.

@boly38 boly38 added opencode bug Something isn't working labels Oct 18, 2026
@boly38 boly38 self-assigned this Oct 18, 2026
@boly38
boly38 merged commit d0e2538 into main Oct 18, 2026
1 check passed
@boly38
boly38 deleted the dev/issue-18-telegram-timeout-reporting branch October 18, 2026 18:57
@boly38 boly38 added this to the v1.0.0 milestone Oct 19, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working opencode

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Handle bridge timeouts and improve Telegram error reporting

1 participant