From 6909900181512dc4256f03f07d62a62c303f24e3 Mon Sep 17 00:00:00 2001 From: SeaswimmerTheFsh <102361830+SeaswimmerTheFsh@users.noreply.github.com> Date: Sat, 1 Jul 2023 10:03:51 -0400 Subject: [PATCH] cleaning up & pylint fixes --- .github/workflows/pylint.yml | 2 +- cogs/info.py | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/pylint.yml b/.github/workflows/pylint.yml index 1b00cd0..266743a 100644 --- a/.github/workflows/pylint.yml +++ b/.github/workflows/pylint.yml @@ -19,7 +19,7 @@ jobs: python -m pip install --upgrade pip pip install pylint pip install -U git+https://github.com/revoltchat/revolt.py - pip install python-dotenv mysql-connector-python pytimeparse2 + pip install python-dotenv mysql-connector-python pytimeparse2 colorthief - name: Analysing the code with pylint run: | pylint $(git ls-files '*.py') diff --git a/cogs/info.py b/cogs/info.py index b0bc2ab..3661497 100644 --- a/cogs/info.py +++ b/cogs/info.py @@ -10,8 +10,8 @@ class Info(commands.Cog): self.client = client @staticmethod - def rgb_to_hex(r, g, b): - return '#{:02x}{:02x}{:02x}'.format(r, g, b) + def rgb_to_hex(r, g, b): # pylint: disable=invalid-name + return '#{:02x}{:02x}{:02x}'.format(r, g, b) # pylint: disable=consider-using-f-string async def upload_to_revolt(self, ctx: commands.Context, asset: revolt.Asset, color: bool = False): """Uploads an asset to Revolt and returns the asset ID.""" @@ -34,7 +34,7 @@ class Info(commands.Cog): pass @commands.command() - async def channelinfo(self, ctx: commands.Context, channel: commands.ChannelConverter, permissions: commands.BoolConverter = False): + async def channelinfo(self, ctx: commands.Context, channel: commands.ChannelConverter): """Displays information about a channel.""" if str(channel.channel_type) != "ChannelType.text_channel" and str(channel.channel_type) != "ChannelType.voice_channel": raise self.CustomError