Skip to content

Commit

Permalink
Ignore PersistentTimestamp errors
Browse files Browse the repository at this point in the history
Signed-off-by: wulan17 <wulan17@nusantararom.org>
  • Loading branch information
KurimuzonAkuma authored and wulan17 committed Sep 7, 2024
1 parent ee8f11e commit 4e2d553
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions pyrogram/client.py
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@
from pyrogram.errors import (
SessionPasswordNeeded,
VolumeLocNotFound, ChannelPrivate,
BadRequest, ChannelInvalid
BadRequest, ChannelInvalid, PersistentTimestampInvalid, PersistentTimestampOutdated
)
from pyrogram.handlers.handler import Handler
from pyrogram.methods import Methods
Expand Down Expand Up @@ -666,7 +666,7 @@ async def handle_updates(self, updates):
force=False
)
)
except ChannelPrivate:
except (ChannelPrivate, PersistentTimestampOutdated, PersistentTimestampInvalid):
pass
else:
if not isinstance(diff, raw.types.updates.ChannelDifferenceEmpty):
Expand Down Expand Up @@ -742,7 +742,7 @@ async def recover_gaps(self) -> Tuple[int, int]:
qts=0
)
)
except (ChannelPrivate, ChannelInvalid):
except (ChannelPrivate, ChannelInvalid, PersistentTimestampOutdated, PersistentTimestampInvalid):
break

if isinstance(diff, raw.types.updates.DifferenceEmpty):
Expand Down

0 comments on commit 4e2d553

Please sign in to comment.