fix(backup): disable SLF001
Some checks failed
Actions / Build Documentation (MkDocs) (push) Successful in 45s
Actions / Lint Code (Ruff & Pylint) (push) Failing after 52s

This commit is contained in:
cswimr 2025-01-26 13:42:57 +00:00
parent dbff8d0d2a
commit 6f0fee8275
Signed by: cswimr
GPG key ID: 0EC431A8DA8F8087

View file

@ -17,6 +17,9 @@ from redbot.core.bot import Red
from redbot.core.utils.chat_formatting import bold, error, humanize_list, text_to_file
# Disable Ruff & Pylint complaining about accessing private members
# That's kind of necessary for this cog to function because the Downloader cog has a limited public API
# ruff: noqa: SLF001 # Private member access
# pylint: disable=protected-access
class Backup(commands.Cog):
"""A utility to make reinstalling repositories and cogs after migrating the bot far easier."""
@ -74,7 +77,7 @@ class Backup(commands.Cog):
if cog.repo_name == repo.name:
cog_dict = {
"name": cog.name,
# "loaded": cog.name in ctx.bot.extensions.keys(),
# "loaded": cog.name in ctx.bot.extensions.keys(), # noqa: ERA001
# this functionality was planned but never implemented due to Red limitations
# and the possibility of restoration functionality being added to Core
"pinned": cog.pinned,