def setup():
'''GAE DISPATCHER SETUP'''
global dispatcher
# Note that update_queue is setted to None and
# 0 workers are allowed on Google app Engine (If not-->Problems with multithreading)
dispatcher = Dispatcher(bot=bot, update_queue=None, workers=0)
# ---Register handlers here---
dispatcher.add_handler(CommandHandler("start", start))
dispatcher.add_handler(CommandHandler("help", help))
dispatcher.add_handler(MessageHandler([Filters.text], echo))
dispatcher.add_error_handler(error)
return dispatcher
message_handler.py 文件源码
python
阅读 18
收藏 0
点赞 0
评论 0
评论列表
文章目录