Skip to content

fix: catch webhook errors escaping grammy middleware pipeline#20

Merged
edloidas merged 1 commit intomasterfrom
claude/fix-bot-kicked-error-YbnzD
Apr 3, 2026
Merged

fix: catch webhook errors escaping grammy middleware pipeline#20
edloidas merged 1 commit intomasterfrom
claude/fix-bot-kicked-error-YbnzD

Conversation

@edloidas
Copy link
Copy Markdown
Owner

@edloidas edloidas commented Apr 3, 2026

The bot.catch handler already silences 403 kicked/blocked errors, but
rejected promises from handleUpdate propagated to Bun.serve, which
dumped the full BotError context object to stderr. Wrapping the call
in try-catch with await keeps the verbose output out of logs.

https://claude.ai/code/session_01T69M5EvJPB13ia34cGtgzo

The `bot.catch` handler already silences 403 kicked/blocked errors, but
rejected promises from `handleUpdate` propagated to `Bun.serve`, which
dumped the full `BotError` context object to stderr. Wrapping the call
in try-catch with `await` keeps the verbose output out of logs.

Kicked/blocked errors now log as concise one-liners with sender, chat
name, method, and description. All logging stays in `bot.catch`; the
webhook catch is a silent safety net only.

https://claude.ai/code/session_01T69M5EvJPB13ia34cGtgzo
@edloidas edloidas force-pushed the claude/fix-bot-kicked-error-YbnzD branch from f709651 to 020fca2 Compare April 3, 2026 23:50
@edloidas edloidas merged commit 89f7520 into master Apr 3, 2026
1 check passed
@edloidas edloidas deleted the claude/fix-bot-kicked-error-YbnzD branch April 3, 2026 23:51
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.

2 participants