Attribute error -_-

showing error when I’m using bot.send_message(chat_id=X , text=Y)
error>>>>>
Update object has no attribute ‘send_message’

but when I’m using…
bot.message.reply(text)>>it runs perfectly…

what is going here?? why I’m unable to send response using send_message method??

hey @snehill090 ,
can you please let me know , on what version of telegram bot are your working on.

It’s 13.4 v. I thought there is just some different commands cz when I again reinstall its 11 version boom!! Working perfectly…I want to work with it’s latest version. but some commands are diff :frowning: I tried so much to get those command but haven’t found yet -_-…

okay ,yeah i can provide you that.

but can you let me know , are you working on polling or using ngrok ?

I tried both Poling and ngrok using python-tekegram-bot v 11.1.0

for webhook you can have a look here
https://ide.codingblocks.com/s/386542 .

for polling you just need to change the functions and it will work fine.

I hope I’ve cleared your doubt. I ask you to please rate your experience here
Your feedback is very important. It helps us improve our platform and hence provide you
the learning experience you deserve.

On the off chance, you still have some questions or not find the answers satisfactory, you may reopen
the doubt.

1 Like