From c907422156f1ad4762a17fd6852f8961ce38fc92 Mon Sep 17 00:00:00 2001 From: Stefano Pigozzi Date: Thu, 11 Apr 2019 19:29:33 +0200 Subject: [PATCH] Here is the problem. --- royalgames.py | 2 +- royalnet/database/alchemy.py | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/royalgames.py b/royalgames.py index 40fbc112..0d9856cb 100644 --- a/royalgames.py +++ b/royalgames.py @@ -15,7 +15,7 @@ commands = [PingCommand, ShipCommand, SmecdsCommand, ColorCommand, CiaoruoziComm master = RoyalnetServer("localhost", 1234, "sas") tg_bot = TelegramBot(os.environ["TG_AK"], "localhost:1234", "sas", commands, os.environ["DB_PATH"], Royal, Telegram, "tg_id", error_command=ErrorHandlerCommand) -ds_bot = DiscordBot(os.environ["DS_AK"], "localhost:1234", "sas", commands, os.environ["DB_PATH"], Royal, Discord, "discord_ig", error_command=ErrorHandlerCommand) +ds_bot = DiscordBot(os.environ["DS_AK"], "localhost:1234", "sas", commands, os.environ["DB_PATH"], Royal, Discord, "discord_id", error_command=ErrorHandlerCommand) loop.create_task(master.run()) loop.create_task(tg_bot.run()) print("Commands enabled:") diff --git a/royalnet/database/alchemy.py b/royalnet/database/alchemy.py index 43417dfd..c9cdcbe9 100644 --- a/royalnet/database/alchemy.py +++ b/royalnet/database/alchemy.py @@ -25,6 +25,7 @@ class Alchemy: self.__getattribute__(name) except AttributeError: # Actually the intended result + # TODO: here is the problem! self.__setattr__(name, type(name, (self.Base,), cdj(table))) else: raise NameError(f"{name} is a reserved name and can't be used as a table name")