mirror of
https://github.com/Cog-Creators/Red-DiscordBot.git
synced 2025-11-20 09:56:05 -05:00
Update deprecation warnings (#3608)
* Make deprecation notice specify minor release based on soonest date * Stop specifying a specific release in shared libs deprecation notice * Add actual deprecation warning for `APIToken` (OMG, this is so cool) * Add dates (2020-08-05 for all) * address review * improve consistency * Add __dir__ and show APIToken in docs (or maybe I want to annoy Flame) * fix module name when importing non-existent name from parent package * Fix stack level used by depr warn in `redbot.core.commands`
This commit is contained in:
@@ -29,7 +29,7 @@ _ = Translator("Downloader", __file__)
|
||||
|
||||
DEPRECATION_NOTICE = _(
|
||||
"\n**WARNING:** The following repos are using shared libraries"
|
||||
" which are marked for removal in Red 3.4: {repo_list}.\n"
|
||||
" which are marked for removal in the future: {repo_list}.\n"
|
||||
" You should inform maintainers of these repos about this message."
|
||||
)
|
||||
|
||||
@@ -245,7 +245,6 @@ class Downloader(commands.Cog):
|
||||
installed[module._json_repo_name].pop(module.name)
|
||||
|
||||
async def _shared_lib_load_check(self, cog_name: str) -> Optional[Repo]:
|
||||
# remove in Red 3.4
|
||||
is_installed, cog = await self.is_installed(cog_name)
|
||||
# it's not gonna be None when `is_installed` is True
|
||||
# if we'll use typing_extensions in future, `Literal` can solve this
|
||||
|
||||
Reference in New Issue
Block a user