fix(import): add missing requirement

This commit is contained in:
Romain J 2021-01-28 10:39:54 +01:00
parent 287e4c1743
commit 0687ee3f06
3 changed files with 16 additions and 4 deletions

View file

@ -23,7 +23,7 @@ install_requires =
humanize>=2.6.0 humanize>=2.6.0
ipinfo>=4.1.0 ipinfo>=4.1.0
ipwhois>=1.2.0 ipwhois>=1.2.0
jishaku>=1.19.1.200 jishaku @ git+https://github.com/Gorialis/jishaku
psutil>=5.7.2 psutil>=5.7.2
pydig>=0.3.0 pydig>=0.3.0
requests>=2.25.1 requests>=2.25.1

View file

@ -73,12 +73,16 @@ class Logs(commands.Cog, name="Logs"):
traces_sample_rate=1.0, traces_sample_rate=1.0,
environment=self.bot.instance_name, environment=self.bot.instance_name,
debug=False, debug=False,
attach_stacktrace=True,
) )
def cog_unload(self): def cog_unload(self):
self.bot.on_error = self.old_on_error self.bot.on_error = self.old_on_error
async def on_error(self, event): async def on_error(self, event, *args, **kwargs):
self.bot.console.log("Error!")
self.bot.console.log(args)
self.bot.console.log(kwargs)
raise event raise event
# ========================================================================= # =========================================================================

View file

@ -127,9 +127,17 @@ class ContextPlus(commands.Context):
return self.bot.session return self.bot.session
def __repr__(self): def __repr__(self):
items = ("%s = %r" % (k, v) for k, v in self.__dict__.items()) items = (
"message=%s" % self.message,
"channel=%s" % self.channel,
"guild=%s" % self.guild,
"author=%s" % self.author,
"prefix=%s" % self.prefix,
"args=%s" % self.args,
"kwargs=%s" % self.kwargs,
)
return "<%s: {%s}>" % (self.__class__.__name__, ", ".join(items)) return "<%s %s>" % (self.__class__.__name__, ", ".join(items))
class CommandPLus(commands.Command): class CommandPLus(commands.Command):