apenasrr / clonechat

Clone all posts from the history of a Telegram Channel/Group to another Channel/Group.
MIT License
335 stars 85 forks source link

[QUESTION] Calling get_message a lot in a short period give me flood wait? #3

Closed upolar closed 1 year ago

upolar commented 1 year ago

Can we move the wait_a_moment function before func_sender(message, destination_chat)? If so It'll improve clone speed with my menu to select filetypes.

Something like that:

if func_sender in files_type_excluded:
    list_posted += [message.id]
    update_cache(CACHE_FILE, list_posted)
    continue
wait_a_moment(message_id)
func_sender(message, destination_chat)

I'm asking that because I'm wondering if Telegram will give FloodWait if I make a lot of get_message requests in a short period.

upolar commented 1 year ago

No, I cant do it. It'll result in flood.