mirror of
https://github.com/Cog-Creators/Red-DiscordBot.git
synced 2025-11-06 03:08:55 -05:00
Merge pull request #6099 from Jackenmen/bump_black
Reformat with Black 2023 formatting changes
This commit is contained in:
commit
4edf975996
40
.git-blame-ignore-revs
Normal file
40
.git-blame-ignore-revs
Normal file
@ -0,0 +1,40 @@
|
||||
# Since version 2.23 (released in August 2019), git-blame has a feature
|
||||
# to ignore or bypass certain commits.
|
||||
#
|
||||
# This file contains a list of commits that are not likely what you
|
||||
# are looking for in a blame, such as mass reformatting or renaming.
|
||||
# You can set this file as a default ignore file for blame by running
|
||||
# the following command.
|
||||
#
|
||||
# $ git config blame.ignoreRevsFile .git-blame-ignore-revs
|
||||
|
||||
# [V3] Update code standards (black code format pass) (#1650)
|
||||
b88b5a2601f56bda985729352d24842f087a8ade
|
||||
|
||||
# Black tests and setup.py (#1657)
|
||||
e01cdbb0912387749d9459e1d934f9ed393a9b51
|
||||
|
||||
# Black formatting for generate_strings.py and docs/conf.py (#1658)
|
||||
1ecaf6f8d5f2af731bec3eb6ad3a9721ab7a2812
|
||||
|
||||
# [V3 Travis] Update travis to not skip pipfile lock... (#1678)
|
||||
# additional black formatting pass to conform to black 18.5b
|
||||
d3f406a34a5cae6ea63664e76e8e74be43f9949f
|
||||
|
||||
# [V3] Update black version and reformat (#1745)
|
||||
14cc701b25cea385fd0d537cdb6475d341c017c5
|
||||
|
||||
# [V3] Clean up some ugly auto-formatted strings (#1753)
|
||||
622382f42588ac1d8a52bd3e39bf171c89ff0224
|
||||
|
||||
# [CI] Improve automated checks (#2702)
|
||||
16443c8cc0c24cbc5b3dc7de858edb71b9ca6cd3
|
||||
|
||||
# Bump black to 20.8b1 (and reformat) (#4371)
|
||||
85afe19455f91af21a0f603705eeb5d9599b45cc
|
||||
|
||||
# Reformat with Black 22.1.0 (#5633)
|
||||
c69e8d31fdadbe10230ec0ea2ef35402e5c4cf43
|
||||
|
||||
# Reformat with Black 2023 formatting changes
|
||||
226d8d734de43e1d5ea96a528a8e480641604db1
|
||||
@ -43,7 +43,7 @@ red-discordbot = "redbot.pytest"
|
||||
|
||||
[tool.black]
|
||||
line-length = 99
|
||||
required-version = '22'
|
||||
required-version = '23'
|
||||
target-version = ['py38']
|
||||
include = '\.py$'
|
||||
force-exclude = '''
|
||||
|
||||
@ -1009,7 +1009,6 @@ class Repo(RepoJSONMixin):
|
||||
|
||||
|
||||
class RepoManager:
|
||||
|
||||
GITHUB_OR_GITLAB_RE = re.compile(r"https?://git(?:hub)|(?:lab)\.com/")
|
||||
TREE_URL_RE = re.compile(r"(?P<tree>/tree)/(?P<branch>\S+)$")
|
||||
|
||||
|
||||
@ -299,7 +299,6 @@ class Economy(commands.Cog):
|
||||
cur_time = calendar.timegm(ctx.message.created_at.utctimetuple())
|
||||
credits_name = await bank.get_currency_name(ctx.guild)
|
||||
if await bank.is_global(): # Role payouts will not be used
|
||||
|
||||
# Gets the latest time the user used the command successfully and adds the global payday time
|
||||
next_payday = (
|
||||
await self.config.user(author).next_payday() + await self.config.PAYDAY_TIME()
|
||||
|
||||
@ -54,7 +54,6 @@ def get_video_ids_from_feed(feed):
|
||||
|
||||
|
||||
class Stream:
|
||||
|
||||
token_name: ClassVar[Optional[str]] = None
|
||||
platform_name: ClassVar[Optional[str]] = None
|
||||
|
||||
@ -106,7 +105,6 @@ class Stream:
|
||||
|
||||
|
||||
class YoutubeStream(Stream):
|
||||
|
||||
token_name = "youtube"
|
||||
platform_name = "YouTube"
|
||||
|
||||
@ -306,7 +304,6 @@ class YoutubeStream(Stream):
|
||||
|
||||
|
||||
class TwitchStream(Stream):
|
||||
|
||||
token_name = "twitch"
|
||||
platform_name = "Twitch"
|
||||
|
||||
@ -464,7 +461,6 @@ class TwitchStream(Stream):
|
||||
|
||||
|
||||
class PicartoStream(Stream):
|
||||
|
||||
token_name = None # This streaming services don't currently require an API key
|
||||
platform_name = "Picarto"
|
||||
|
||||
|
||||
@ -312,7 +312,7 @@ class TriviaSession:
|
||||
top_score = self.scores.most_common(1)[0][1]
|
||||
winners = []
|
||||
num_humans = 0
|
||||
for (player, score) in self.scores.items():
|
||||
for player, score in self.scores.items():
|
||||
if not player.bot:
|
||||
if score == top_score:
|
||||
winners.append(player)
|
||||
|
||||
@ -36,7 +36,6 @@ def encode_identifier_data(
|
||||
|
||||
|
||||
class PostgresDriver(BaseDriver):
|
||||
|
||||
_pool: Optional["asyncpg.pool.Pool"] = None
|
||||
|
||||
@classmethod
|
||||
|
||||
@ -430,7 +430,6 @@ class RedHelpFormatter(HelpFormatterABC):
|
||||
await self.make_and_send_embeds(ctx, emb, help_settings=help_settings)
|
||||
|
||||
else: # Code blocks:
|
||||
|
||||
subtext = None
|
||||
subtext_header = None
|
||||
if subcommands:
|
||||
|
||||
@ -58,6 +58,7 @@ log = logging.getLogger("red.core.utils")
|
||||
_T = TypeVar("_T")
|
||||
_S = TypeVar("_S")
|
||||
|
||||
|
||||
# Benchmarked to be the fastest method.
|
||||
def deduplicate_iterables(*iterables):
|
||||
"""
|
||||
|
||||
@ -1,8 +1,8 @@
|
||||
black==22.12.0
|
||||
black==23.3.0
|
||||
# via -r extra-style.in
|
||||
mypy-extensions==0.4.3
|
||||
mypy-extensions==1.0.0
|
||||
# via black
|
||||
pathspec==0.10.3
|
||||
pathspec==0.11.1
|
||||
# via black
|
||||
tomli==2.0.1
|
||||
# via black
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user