mirror of
https://github.com/Cog-Creators/Red-DiscordBot.git
synced 2025-11-20 18:06:08 -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:
@@ -184,8 +184,8 @@ def bounded_gather_iter(
|
||||
"""
|
||||
if loop is not None:
|
||||
warnings.warn(
|
||||
"Explicitly passing the loop will not work in Red 3.4+ and is currently ignored."
|
||||
"Call this from the related event loop.",
|
||||
"`loop` kwarg is deprecated since Red 3.3.1. It is currently being ignored"
|
||||
" and will be removed in the first minor release after 2020-08-05.",
|
||||
DeprecationWarning,
|
||||
stacklevel=2,
|
||||
)
|
||||
@@ -242,8 +242,8 @@ def bounded_gather(
|
||||
"""
|
||||
if loop is not None:
|
||||
warnings.warn(
|
||||
"Explicitly passing the loop will not work in Red 3.4+ and is currently ignored."
|
||||
"Call this from the related event loop.",
|
||||
"`loop` kwarg is deprecated since Red 3.3.1. It is currently being ignored"
|
||||
" and will be removed in the first minor release after 2020-08-05.",
|
||||
DeprecationWarning,
|
||||
stacklevel=2,
|
||||
)
|
||||
|
||||
@@ -214,7 +214,8 @@ def start_adding_reactions(
|
||||
loop = asyncio.get_running_loop()
|
||||
else:
|
||||
warnings.warn(
|
||||
"Explicitly passing the loop will not work in Red 3.4+",
|
||||
"`loop` kwarg is deprecated since Red 3.3.1. It is currently being ignored"
|
||||
" and will be removed in the first minor release after 2020-08-05.",
|
||||
DeprecationWarning,
|
||||
stacklevel=2,
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user