Repository navigation
Conversation
AliZakaee
marked this pull request as draft
August 6, 2026 15:31
AliZakaee
marked this pull request as ready for review
August 6, 2026 17:12
AliZakaee
marked this pull request as draft
August 6, 2026 17:13
AliZakaee
marked this pull request as draft
August 6, 2026 19:27
AliZakaee
marked this pull request as ready for review
August 7, 2026 05:05
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.
Summary
sendingclaim for approval deliveriessentorsent_editedonly after Telegram accepts the replypendingonly when the rollback succeedsWhy this is meaningful
Approval mode previously marked a reply as sent before calling Telegram. If both the TeleBot path and raw HTTP fallback failed, the customer received nothing while the database permanently reported success and rejected future retry attempts. This change keeps double-tap protection while aligning persisted state, outbound history, memory, owner feedback, and retry availability with the actual delivery result. It also avoids promising a retry when the database could not release a failed delivery claim.
Validation
.venv/bin/python -m pytest --cov=. --cov-report=term-missing --cov-report=xml:<temp>/post-coverage.xml --junitxml=<temp>/post-junit.xml— 274 passed.venv/bin/python -m pytest tests/unit/handlers/test_approvals.py tests/unit/test_database_dal.py tests/unit/test_telegram_api.py -q— 52 passed.venv/bin/python -m pytest --cov=. --cov-report=term-missing --cov-report=xml:<temp>/final-coverage.xml --junitxml=<temp>/final-junit.xml— 276 passed, 60% total coverage.venv/bin/python -m compileall -q handlers database.py tests/unit— passedgit diff --check— passedhandlers/approvals.pyandtests/unit/handlers/test_approvals.pychanged in the reconciliation commitRisk and rollback
Risk is limited to the internal approval state machine and owner feedback for failed sends. There are no schema, dependency, configuration, public API, authentication, deployment, or workflow changes. A process crash during the brief
sendingstate remains an ambiguous delivery case and is quarantined for manual review. Roll back by reverting the focused approval-delivery commits.Prepared with automated assistance by EQ for ITheEqualizer.