telegram-support-bot icon indicating copy to clipboard operation
telegram-support-bot copied to clipboard

The reply is not getting the contacting user

Open Abduvakilov opened this issue 3 years ago • 9 comments

The app is deployed on heroku. If a user that needs support starts the bot the bot is messaging hand emoji and I am getting the contacted user info. I am getting forwarded messages of users from the bot. But if I reply to the forwarded message my message is being forwarded to myself and the owner of the message is not gettin my message. I have tried to restart all dynos. How can I fix the problem?

Abduvakilov avatar May 14 '21 19:05 Abduvakilov

I have the same problem...

DavianMachete avatar Jul 20 '21 22:07 DavianMachete

same

Hazerott avatar Aug 14 '21 04:08 Hazerott

Same, trace

ERROR:telegram.ext.dispatcher:No error handlers are registered, logging exception.
Traceback (most recent call last):
   File "/app/.heroku/python/lib/python3.9/site-packages/telegram/ext/dispatcher.py", line 555, in process_update
   handler.handle_update(update, self, check, context)

   File "/app/.heroku/python/lib/python3.9/site-packages/telegram/ext/handler.py", line 198, in handle_update
   return self.callback(update, context)

   File "/app/handlers.py", line 47, in forward_to_user
   user_id = update.message.reply_to_message.forward_from.id

   AttributeError: 'NoneType' object has no attribute 'id'

Akiyamka avatar Aug 28 '21 14:08 Akiyamka

lol, same

starrabb1t avatar Jun 08 '22 17:06 starrabb1t

SOLUTION: in handlers.py change line with user_id declaration to this: user_id = update.message.reply_to_message.forward_from.id

starrabb1t avatar Jun 08 '22 18:06 starrabb1t

Do yo mean line 54? https://github.com/ohld/telegram-support-bot/blob/93782bf01ed53548c8e2898f9867c2687e893b2d/handlers.py#L54

Abduvakilov avatar Jun 09 '22 04:06 Abduvakilov

oh, I see it's seems to be okay now. i have old version

starrabb1t avatar Jun 09 '22 11:06 starrabb1t

Can somebody help please? I changed line 54 to user_id = update.message.reply_to_message.forward_from.id but it didn't help

fayzrakhmanov2000 avatar Sep 18 '22 10:09 fayzrakhmanov2000

SOLUTION: in handlers.py change line with user_id declaration to this: user_id = update.message.reply_to_message.forward_from.id

Can you help please? I changed line 54 to user_id = update.message.reply_to_message.forward_from.id but it didn't help

fayzrakhmanov2000 avatar Sep 18 '22 11:09 fayzrakhmanov2000