From df230bcd8e431eddccfb22068237b2ba04fc96cf Mon Sep 17 00:00:00 2001 From: Zac Herd Date: Sun, 24 Apr 2016 21:15:40 +0100 Subject: [PATCH] Updated to use new OAuth2 method for connecting. Requires latest discord.py and permission from server owner, v0.13.0 --- bot.py | 14 +++----------- 1 file changed, 3 insertions(+), 11 deletions(-) diff --git a/bot.py b/bot.py index 184e8e6..72ac2c1 100644 --- a/bot.py +++ b/bot.py @@ -18,7 +18,7 @@ import logging import markov # file in this directory called "secret.py" should contain these variables -from secret import email,pwd +from secret import token # CONFIGURATION @@ -27,7 +27,7 @@ from secret import email,pwd name = "Maki" # bot version -version = "v0.12.2" +version = "v0.13.0" # text shown by .help command helptext = """I am a bot written in Python by MrDetonia @@ -349,15 +349,7 @@ def on_message(message): # Run the client -while run: - try: - print('INFO: starting client') - client.run(email, pwd) - except: - print('ERROR: caught some exception') - continue - else: - break +client.run(token) # finish execution exit(0)