gangsta icon indicating copy to clipboard operation
gangsta copied to clipboard

Bot is not replying

Open ghost opened this issue 4 years ago • 5 comments

Hello bro, I watched the tutorial and write the ditto code, even copied yours, but the bot is able to read the messages but not able to reply. Kindly help

ghost avatar Jun 07 '20 11:06 ghost

Please be more precise with your question. What did you do? What part of the code did you change?

Klimmbimmel avatar Jul 17 '20 19:07 Klimmbimmel

I watched the video and used the code exactly, I didn't change anything. When I ran the server.py code I got an error ... Traceback (most recent call last): File "server.py", line 15, in updates = updates["result"] TypeError: 'NoneType' object is not subscriptable i delete my file tree from the file part

helenmar avatar Sep 17 '20 06:09 helenmar

I watched the video and used the code exactly, I didn't change anything. When I ran the server.py code I got an error ... Traceback (most recent call last): File "server.py", line 15, in updates = updates["result"] TypeError: 'NoneType' object is not subscriptable i delete my file tree from the file part

I'm getting this same error anyone knows why?

tuyyui avatar Nov 20 '20 17:11 tuyyui

It wasn't the authorization token it was an error within my PyCharm setting. Please make sure you have a cfg extension installed so your PyCharm IDE will read the file.

tuyyui avatar Dec 01 '20 00:12 tuyyui

Following the error, this could also be related to a broken telegram response. Updates will look very empty in case of server errors. It can be empty, updates["ok"] can be False. (I have never seen ok or result not being in updates, although i check for those errors.)

Also, one user deleted their reply, but it was correct also. The line 24 in server.py

from_ = item["message"]["from"]["id"]

can break also, as ["message"]["from"] is optional. (It might be empty in redirected messages)

Klimmbimmel avatar Jan 11 '21 13:01 Klimmbimmel