Repository navigation
fix(chat): bot_message_id is update-only; never invent one - #162
Closed
mauriciomdb wants to merge 1 commit into
Closed
mauriciomdb wants to merge 1 commit into
mauriciomdb wants to merge 1 commit into
Conversation
`chat send` help and the README now say every send posts a new message, Dailybot creates and returns its bot_message_id, and that id is kept only for `chat update` (72h). A `--payload-json` body carrying bot_message_id is refused locally with a pointer to `chat update`, and the API's new `400 unknown_bot_message_id` gets a plain explanation. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01AY6kxNxkCZG2pPJSh1Bxer
Member
|
Continued in #164 (same commits, opened from a maintainer account so the AI review gate runs). |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Why
A coding agent sent messages with its own
bot_message_idvalues (e.g.gos-test-plain-1).bot_message_idonly updates a message Dailybot already sent, so every send was a silent no-op edit:200, the id echoed back, nothing delivered. The API now refuses such ids with400 unknown_bot_message_id(api-servicesfeature__new_dailybot); this makes the CLI say the same thing up front.What
dailybot chat send --help: every send posts a new message; Dailybot creates and returnsbot_message_id; keep it only forchat update(72h); never invent one.dailybot chat update --help:BOT_MESSAGE_IDis the id a send returned, never one you choose.chat send --payload-jsonwith abot_message_idis refused locally (exit 1) with a pointer tochat update.unknown_bot_message_iderror gets a plain explanation.chat updaterow.Tests
ruff check,ruff format --check,mypy dailybot_cliclean;pytest tests/chat_commands_test.py53 passed (3 new).🤖 Generated with Claude Code
https://claude.ai/code/session_01AY6kxNxkCZG2pPJSh1Bxer