[my_bot] Waiting for 20 seconds before continuing (required by "messages.GetHistory")
Traceback (most recent call last):
File "/Users/developer/TelegramArchive/bot.py", line 950, in
app.run(main())
File "/usr/local/lib/python3.11/site-packages/pyrogram/methods/utilities/run.py", line 77, in run
run(coroutine)
File "/usr/local/Cellar/[email protected]/3.11.3/Frameworks/Python.framework/Versions/3.11/lib/python3.11/asyncio/base_events.py", line 653, in run_until_complete
return future.result()
^^^^^^^^^^^^^^^
File "/Users/developer/TelegramArchive/bot.py", line 274, in main
text = get_text_data(message, 'caption')
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/developer/TelegramArchive/bot.py", line 615, in get_text_data
txt['text'] = message.caption[e.offset:e.length]
~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/pyrogram/types/messages_and_media/message.py", line 56, in getitem
return parser_utils.remove_surrogates(parser_utils.add_surrogates(self)[item])
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/pyrogram/parser/utils.py", line 37, in remove_surrogates
return text.encode("utf-16", "surrogatepass").decode("utf-16")
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
UnicodeDecodeError: 'utf-16-le' codec can't decode bytes in position 2-3: unexpected end of data