def test(self):
self._load_auth()
history = FileHistory('.history')
project_id = self._get_current_project_id()
bot = self._load_bot()
while True:
try:
line = prompt('BotHub> ', history=history)
if not line:
continue
event = make_event(line)
context = {}
bot.handle_message(event, context)
except (EOFError, KeyboardInterrupt):
break
except Exception:
traceback.print_exc()
评论列表
文章目录