Good citizen stuff for pylint
This commit is contained in:
parent
13e64461be
commit
1a123bc25d
|
@ -36,7 +36,7 @@ class BotList(commands.Cog, name='Bot List'):
|
|||
self.bot, self.dbl_token)
|
||||
|
||||
# Start update loop
|
||||
self.update_stats.start()
|
||||
self.update_stats.start() # pylint: disable=no-member
|
||||
|
||||
async def _update_logic(self):
|
||||
"""Handles all statistic updating for various different bot lists."""
|
||||
|
@ -168,7 +168,7 @@ class BotList(commands.Cog, name='Bot List'):
|
|||
await self._update_logic()
|
||||
|
||||
def cog_unload(self):
|
||||
self.update_stats.cancel()
|
||||
self.update_stats.cancel() # pylint: disable=no-member
|
||||
|
||||
|
||||
def setup(bot):
|
||||
|
|
|
@ -343,7 +343,7 @@ Guild count: {len(self.bot.guilds)}
|
|||
"You wish to use me in!_"
|
||||
)
|
||||
|
||||
await guild.owner.send(guild_msg)
|
||||
await owner.send(guild_msg)
|
||||
return # Ends here if there are no good channels to send to
|
||||
|
||||
# Owner Disclosure
|
||||
|
@ -362,7 +362,7 @@ Guild count: {len(self.bot.guilds)}
|
|||
)
|
||||
|
||||
# Send owner disclosure
|
||||
await guild.owner.send(owner_msg)
|
||||
await owner.send(owner_msg)
|
||||
|
||||
|
||||
def setup(bot):
|
||||
|
|
|
@ -5,9 +5,11 @@
|
|||
|
||||
'''HelpCmd File'''
|
||||
|
||||
import itertools
|
||||
|
||||
import discord
|
||||
from discord.ext import commands
|
||||
import itertools
|
||||
|
||||
|
||||
class TaciHelpCommand(commands.MinimalHelpCommand):
|
||||
def __init__(self, **options):
|
||||
|
@ -105,7 +107,8 @@ class TaciHelpCommand(commands.MinimalHelpCommand):
|
|||
if heading == '\U0001F4E6 Core':
|
||||
# `command1`, `command2`, `command3`
|
||||
# On Same Line
|
||||
self.paginator.add_line(", ".join(f"`{c.name}`" for c in commands))
|
||||
self.paginator.add_line(
|
||||
", ".join(f"`{c.name}`" for c in commands))
|
||||
else:
|
||||
# `command` - description
|
||||
# On new lines
|
||||
|
@ -130,8 +133,8 @@ class TaciHelpCommand(commands.MinimalHelpCommand):
|
|||
self.paginator.add_line(note, empty=True)
|
||||
|
||||
# Gets the category for each command in the bot
|
||||
no_category = f"\u200b{self.no_category}"
|
||||
def get_category(command, *, no_category=no_category):
|
||||
def get_category(command, *,
|
||||
no_category = f"\u200b{self.no_category}"):
|
||||
cog = command.cog
|
||||
if cog is not None:
|
||||
return f"{cog.emoji} {cog.qualified_name}" if cog.emoji else cog.qualified_name
|
||||
|
@ -144,7 +147,8 @@ class TaciHelpCommand(commands.MinimalHelpCommand):
|
|||
|
||||
# Splits Bot List and Core commands out of the others
|
||||
for category, commands in to_iterate:
|
||||
commands = sorted(commands, key=lambda c: c.name) if self.sort_commands else list(commands)
|
||||
commands = sorted(
|
||||
commands, key=lambda c: c.name) if self.sort_commands else list(commands)
|
||||
if category in ['\U0001F4E6 Core', '\U0001F5F3 Bot List']:
|
||||
main_cmds.extend(commands)
|
||||
else:
|
||||
|
@ -248,6 +252,7 @@ class TaciHelpCommand(commands.MinimalHelpCommand):
|
|||
self.paginator.close_page() # TODO What does this do?
|
||||
await self.send_pages()
|
||||
|
||||
|
||||
def setup(bot):
|
||||
"""Lets helpcmd be added and reloaded as an extension."""
|
||||
pass
|
|
@ -135,8 +135,7 @@ class SpecialtySearch(commands.Cog, name="Specialty"):
|
|||
|
||||
await ctx.send(f"**{title}** - <{url}>", embed=embed)
|
||||
|
||||
except Exception as e:
|
||||
|
||||
except:
|
||||
aired = f"{anime['attributes']['startDate']}{thing}"
|
||||
template = f"""
|
||||
url: {url}
|
||||
|
|
|
@ -5,10 +5,10 @@
|
|||
|
||||
'''Online File'''
|
||||
|
||||
import asyncio
|
||||
import traceback
|
||||
from typing import Optional
|
||||
|
||||
import asyncio
|
||||
import discord
|
||||
from discord.ext.commands import Context
|
||||
|
||||
|
|
Loading…
Reference in New Issue