Edits and deletions are easier to keep up with on large archives: the listener catches up on what changed while it was stopped, and SYNC_DELETIONS_EDITS can check only recent messages. No migration. Docker deployments only need the new pins. Thanks to @Scalpinho, whose measurements in #608 led to both.
Added
SYNC_DELETIONS_EDITScan check only recent messages. Telegram answers about 300 ids per 30 seconds by id, so on an archive of millions of messages one sweep took days.SYNC_DELETIONS_EDITS_DAYS=Nre-checks only messages posted in the last N days, highest message id first. The default,0, re-reads every message as before. Changes to older posts wait for a run with0. See Checking only recent messages. (#608)
Fixed
- The listener now replays edits, deletions and new messages missed while the process was stopped, from the update state Telethon already keeps in the session file. Before, a restart started from "now" and only
SYNC_DELETIONS_EDITSrecovered what changed while it was down. Replayed deletions still needLISTEN_DELETIONS=trueand go through the mass-operation limit. If Telethon is still fetching a difference when the listener connects, the replay waits up to 10 minutes for it to finish instead of being skipped. See Catching up after a disconnect. (#611, #614)
📋 Full changelog: docs/CHANGELOG.md