Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

stacklevel 2 warnings #226

Merged
merged 1 commit into from
Sep 30, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion src/cachetools/cache.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,7 @@
from . import Cache

warnings.warn(
"cachetools.cache is deprecated, please use cachetools.Cache", DeprecationWarning
"cachetools.cache is deprecated, please use cachetools.Cache",
DeprecationWarning,
stacklevel=2,
)
4 changes: 3 additions & 1 deletion src/cachetools/fifo.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,7 @@
from . import FIFOCache

warnings.warn(
"cachetools.fifo is deprecated, please use cachetools.FIFOCache", DeprecationWarning
"cachetools.fifo is deprecated, please use cachetools.FIFOCache",
DeprecationWarning,
stacklevel=2,
)
4 changes: 3 additions & 1 deletion src/cachetools/lfu.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,7 @@
from . import LFUCache

warnings.warn(
"cachetools.lfu is deprecated, please use cachetools.LFUCache", DeprecationWarning
"cachetools.lfu is deprecated, please use cachetools.LFUCache",
DeprecationWarning,
stacklevel=2,
)
4 changes: 3 additions & 1 deletion src/cachetools/lru.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,7 @@
from . import LRUCache

warnings.warn(
"cachetools.lru is deprecated, please use cachetools.LRUCache", DeprecationWarning
"cachetools.lru is deprecated, please use cachetools.LRUCache",
DeprecationWarning,
stacklevel=2,
)
4 changes: 3 additions & 1 deletion src/cachetools/mru.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,7 @@
from . import MRUCache

warnings.warn(
"cachetools.mru is deprecated, please use cachetools.MRUCache", DeprecationWarning
"cachetools.mru is deprecated, please use cachetools.MRUCache",
DeprecationWarning,
stacklevel=2,
)
4 changes: 3 additions & 1 deletion src/cachetools/rr.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,7 @@
from . import RRCache

warnings.warn(
"cachetools.rr is deprecated, please use cachetools.RRCache", DeprecationWarning
"cachetools.rr is deprecated, please use cachetools.RRCache",
DeprecationWarning,
stacklevel=2,
)
4 changes: 3 additions & 1 deletion src/cachetools/ttl.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,7 @@
from . import TTLCache

warnings.warn(
"cachetools.ttl is deprecated, please use cachetools.TTLCache", DeprecationWarning
"cachetools.ttl is deprecated, please use cachetools.TTLCache",
DeprecationWarning,
stacklevel=2,
)