Skip to content

feat: /help in Telegram, and a hint for messages the bot does not handle - #38

Merged
groupsky merged 1 commit into
mainfrom
feat/telegram-help
Nov 17, 2026
Merged

groupsky merged 1 commit into
mainfrom
feat/telegram-help

Conversation

@groupsky

Copy link
Copy Markdown
Contributor

Fixes #26

What changes

  • /help from the owner, in the owner's chat, not edited, gets a fixed list: /check, /check NAME, /help, the instance names, what Apply and Skip do, and the root commands pullgate status NAME, --pause, --resume, --ask-again. The listener cannot read root's files, so it does not show the mode or the pause state; the list points to pullgate status NAME for them.
  • Any other text from the owner in that chat that is not a command gets one reply: "Not a command. Send /help for the list." The text of the message is never repeated or logged.
  • Each of the two replies is sent at most once per minute (in memory), so a stuck client or a long paste cannot fill the chat.
  • Messages from another user, in another chat, or edited, get no reply, as before.
  • README ("Commands: /help"), DESIGN.md section 9, THREAT-MODEL.md T19.
  • setMyCommands (optional in the issue) is not done.

Tests

  • TestHelp: the owner gets the list, it names each instance, it holds no token and no path, and a second /help within a minute gets nothing.
  • TestHintOncePerMinute: other text gets the hint once; a second one in the same minute gets nothing; after a minute it comes again; a stranger's message does not use up the hint.
  • TestHelpAndHintNotForOthers: /help and other text from another user, another chat, or edited get no reply.
  • TestCheckCommandsThatDoNotCount: updated, hello, please /check and /CHECK from the owner now get the hint.

Reviews

Security review: no critical, high or medium findings. Fixed: /help is limited too, and clearer --ask-again wording. Not changed: /help@BotName gets the hint, as /check@bot gets the usage text today (the listener does not know its own bot name); an owner message without text (a photo) gets the hint, at most once a minute.
Correctness review: no bug found. Added the stranger test, and the host value in T19.

🤖 Generated with Claude Code

/help from the owner, in the owner's chat, gets a fixed list: the
commands, the instance names, what Apply and Skip do, and the
pullgate status commands for the host. Any other text from the owner
gets "Not a command. Send /help for the list." Each reply is sent at
most once per minute. Others get no answer.

Fixes #26

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@groupsky
groupsky merged commit c341ec1 into main Nov 17, 2026
9 checks passed
@groupsky
groupsky deleted the feat/telegram-help branch November 17, 2026 08:18
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.

feat: /help in Telegram, and a hint to it for any message the bot does not handle

1 participant