Taosky / telegram-search-bot

A telegram group record search bot that solves the problem of direct search inability in languages such as CJK / Telegram 群聊天记录搜索Bot,解决CJK等语言无法直接搜索问题
MIT License
356 stars 47 forks source link

导入遇到新问题 #45

Closed lancer-wang closed 10 months ago

lancer-wang commented 10 months ago

Traceback (most recent call last): File "/app/json_receive.py", line 167, in main() File "/app/json_receive.py", line 110, in main filesize = int(filesize) ValueError: invalid literal for int() with base 10: '5213871{\n "name": "Coder Offtopic 中文群",\n "type": "public_supergroup",\n "id": 1154313178,\n "messages": [\n {\n "id": 2632606,\n "type": "message",\n "date": "2023-09-08T00:02:42",\n "date

Taosky commented 10 months ago

不应该啊,先传过去的是文件名和文件大小。

filesize = os.path.getsize(filepath)
    client.send(f"{filepath}{SEPARATOR}{filesize}".encode())
lancer-wang commented 10 months ago

奇怪的事发生了,我又试了下,又可以了