fix(telegram): reset webhook cleanup latch after polling 409 conflicts (#39205, thanks @amittell)

Co-authored-by: amittell <mittell@me.com>
This commit is contained in:
Peter Steinberger
2026-03-07 22:08:41 +00:00
parent c934dd51c0
commit 42bf4998d3
3 changed files with 42 additions and 0 deletions

View File

@@ -373,6 +373,9 @@ export async function monitorTelegramProvider(opts: MonitorTelegramOpts = {}) {
throw err;
}
const isConflict = isGetUpdatesConflict(err);
if (isConflict) {
webhookCleared = false;
}
const isRecoverable = isRecoverableTelegramNetworkError(err, { context: "polling" });
if (!isConflict && !isRecoverable) {
throw err;