mirror of
https://github.com/Cog-Creators/Red-DiscordBot.git
synced 2025-11-22 02:37:57 -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:
@@ -778,13 +778,13 @@ class Core(commands.Cog, CoreLogic):
|
||||
if len(repos_with_shared_libs) == 1:
|
||||
formed = _(
|
||||
"**WARNING**: The following repo is using shared libs"
|
||||
" which are marked for removal in Red 3.4: {repo}.\n"
|
||||
" which are marked for removal in the future: {repo}.\n"
|
||||
"You should inform maintainer of the repo about this message."
|
||||
).format(repo=inline(repos_with_shared_libs.pop()))
|
||||
else:
|
||||
formed = _(
|
||||
"**WARNING**: The following repos are using shared libs"
|
||||
" which are marked for removal in Red 3.4: {repos}.\n"
|
||||
" which are marked for removal in the future: {repos}.\n"
|
||||
"You should inform maintainers of these repos about this message."
|
||||
).format(repos=humanize_list([inline(repo) for repo in repos_with_shared_libs]))
|
||||
output.append(formed)
|
||||
@@ -896,13 +896,13 @@ class Core(commands.Cog, CoreLogic):
|
||||
if len(repos_with_shared_libs) == 1:
|
||||
formed = _(
|
||||
"**WARNING**: The following repo is using shared libs"
|
||||
" which are marked for removal in Red 3.4: {repo}.\n"
|
||||
" which are marked for removal in the future: {repo}.\n"
|
||||
"You should inform maintainers of these repos about this message."
|
||||
).format(repo=inline(repos_with_shared_libs.pop()))
|
||||
else:
|
||||
formed = _(
|
||||
"**WARNING**: The following repos are using shared libs"
|
||||
" which are marked for removal in Red 3.4: {repos}.\n"
|
||||
" which are marked for removal in the future: {repos}.\n"
|
||||
"You should inform maintainers of these repos about this message."
|
||||
).format(repos=humanize_list([inline(repo) for repo in repos_with_shared_libs]))
|
||||
output.append(formed)
|
||||
|
||||
Reference in New Issue
Block a user