Closed syxanash closed 2 years ago
this is the error when I update the library to the latest version instead:
Traceback (most recent call last):
8: from test.rb:5:in `<main>'
7: from /home/pi/.rvm/gems/ruby-2.5.0/gems/telegram-bot-ruby-0.19.2/lib/telegram/bot/client.rb:10:in `run'
6: from /home/pi/.rvm/gems/ruby-2.5.0/gems/telegram-bot-ruby-0.19.2/lib/telegram/bot/client.rb:20:in `run'
5: from test.rb:6:in `block in <main>'
4: from /home/pi/.rvm/gems/ruby-2.5.0/gems/telegram-bot-ruby-0.19.2/lib/telegram/bot/client.rb:27:in `listen'
3: from /home/pi/.rvm/gems/ruby-2.5.0/gems/telegram-bot-ruby-0.19.2/lib/telegram/bot/client.rb:35:in `fetch_updates'
2: from /home/pi/.rvm/gems/ruby-2.5.0/gems/telegram-bot-ruby-0.19.2/lib/telegram/bot/client.rb:35:in `each'
1: from /home/pi/.rvm/gems/ruby-2.5.0/gems/telegram-bot-ruby-0.19.2/lib/telegram/bot/client.rb:36:in `block in fetch_updates'
test.rb:7:in `block (2 levels) in <main>': undefined method `text' for #<Telegram::Bot::Types::ChatMemberUpdated:0x0285b3e8> (NoMethodError)
Hey @syxanash,
You need to check message type first, see https://github.com/atipugin/telegram-bot-ruby/issues/226#issuecomment-797296565
just noticed, will close as a duplicate issue then, thank you for your help!
Hey I'm trying to add my bot to a group (even with bot group enabled in botfather) but I get this issue:
I remember it used to work in the past but for some reasons it's not anymore, I'm using the code example you mentioned in the README.md: