Skip to content

Fix Telegram approval requests failing silently - #34

Merged
chiibitsu merged 1 commit into
mainfrom
fix/telegram-approval-delivery
Oct 8, 2026
Merged

chiibitsu merged 1 commit into
mainfrom
fix/telegram-approval-delivery

Conversation

@chiibitsu

Copy link
Copy Markdown
Contributor

Problem

"Work with Chii" bookings sometimes send no Telegram approval message, so there is no way to approve.

Cause (likely; not reproduced against live Telegram)

  • Message uses parse_mode: 'Markdown'. An unmatched _ or * makes Telegram reject the whole message.
  • Custom answers were listed under internal field ids (field_1781601947588, …), each with a _. With the trailing _Tap below…_, an odd count of _ is unbalanced.
  • The Telegram response was never checked, so the booker saw success and nothing was logged.

Changes

  • Escape booker-supplied text in Markdown mode.
  • Show field labels instead of ids.
  • Check Telegram's response, log the error body, retry once as plain text.
  • If both attempts fail, email the admin the approve/reject links.

Test

  • tsc --noEmit passes. Escape helper output checked.
  • Not tested against live Telegram. After deploy: book "Work with Chii" answering only the first question.

Review gate

Draft. Not to merge before two consecutive clean review passes (CLAUDE.md).

🤖 Generated with Claude Code

https://claude.ai/code/session_01AuaNvwMuUqzzipwjxhRdSe


Generated by Claude Code

Markdown parse mode rejected messages whenever booker text or field ids
(e.g. field_1781601947588) left an unmatched underscore, and the response
was never checked. Escape user text, show field labels, retry as plain
text, log Telegram's error, and email the admin if delivery still fails.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01AuaNvwMuUqzzipwjxhRdSe
@vercel

vercel Bot commented Oct 8, 2026

Copy link
Copy Markdown
Contributor

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
website Ready Ready Preview Oct 8, 2026 4:45pm UTC

@chiibitsu
chiibitsu marked this pull request as ready for review October 8, 2026 16:47
@chiibitsu
chiibitsu merged commit a936652 into main Oct 8, 2026
3 of 5 checks passed
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 8, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-10-08T16:48:17.895047Z 40410a3 Draft marked ready
🔒 Security Review ✅ Completed 2026-10-08T16:49:28.819603Z 40410a3 Draft marked ready
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

This branch was successfully deployed

2 active deployments
Preview – lm-booking-site — 40410a30 Deployed Oct 8, 2026 by vercel[bot]
Preview – website — 40410a30 Deployed Oct 8, 2026 by vercel[bot]
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