diff --git a/README.md b/README.md index 0483afd..3fe0406 100644 --- a/README.md +++ b/README.md @@ -3,7 +3,7 @@ Telegram Bot that allows you to play the popular card game UNO via inline querie To run the bot yourself, you will need: - Python (tested with 3.4) -- The [python-telegram-bot](https://github.com/python-telegram-bot/python-telegram-bot) module (currently using ``dispatcher-rework`` beta branch) +- The [python-telegram-bot](https://github.com/python-telegram-bot/python-telegram-bot) module version 4.0.1 Get a bot token from [@BotFather](http://telegram.me/BotFather), place it in `credentials.py` and run the bot with `python3 bot.py` diff --git a/bot.py b/bot.py index bcbc228..3382df8 100644 --- a/bot.py +++ b/bot.py @@ -8,7 +8,7 @@ from telegram import InlineQueryResultArticle, ParseMode, Message, Chat, \ InlineQueryResultCachedSticker as Sticker, InlineKeyboardMarkup, \ InlineKeyboardButton from telegram.ext import Updater, InlineQueryHandler, \ - ChosenInlineResultHandler, CommandHandler, MessageHandler, filters, \ + ChosenInlineResultHandler, CommandHandler, MessageHandler, Filters, \ CallbackQueryHandler from telegram.ext.dispatcher import run_async from telegram.utils.botan import Botan @@ -640,7 +640,7 @@ dp.addHandler(CommandHandler('close', close_game)) dp.addHandler(CommandHandler('skip', skip_player)) dp.addHandler(CommandHandler('help', help)) dp.addHandler(CommandHandler('news', news)) -dp.addHandler(MessageHandler([filters.STATUS_UPDATE], status_update)) +dp.addHandler(MessageHandler([Filters.status_update], status_update)) dp.addErrorHandler(error) start_bot(u)