diff options
author | David Lord <davidism@gmail.com> | 2021-05-13 18:01:18 -0700 |
---|---|---|
committer | David Lord <davidism@gmail.com> | 2021-05-13 18:01:18 -0700 |
commit | 55848d36c0a589139e5003a5ad263fce0d95aa2f (patch) | |
tree | 0c56d7689916728b6b3417e07c0b7cc712aef7fc | |
parent | a2e83d07a30e1d6f1242993e694f8fdfad1d23f2 (diff) | |
parent | fb564a84af82cc896c9b1be421a100e256254677 (diff) | |
download | jinja2-55848d36c0a589139e5003a5ad263fce0d95aa2f.tar.gz |
Merge branch '3.0.x'
-rw-r--r-- | CHANGES.rst | 2 | ||||
-rw-r--r-- | src/jinja2/ext.py | 4 |
2 files changed, 4 insertions, 2 deletions
diff --git a/CHANGES.rst b/CHANGES.rst index e9dc9b0..2f86bb3 100644 --- a/CHANGES.rst +++ b/CHANGES.rst @@ -15,6 +15,8 @@ Unreleased - Mark top-level names as exported so type checking understands imports in user projects. :issue:`1426` - Fix some types that weren't available in Python 3.6.0. :issue:`1433` +- The deprecation warning for unneeded ``autoescape`` and ``with_`` + extensions shows more relevant context. :issue:`1429` Version 3.0.0 diff --git a/src/jinja2/ext.py b/src/jinja2/ext.py index 9c5498b..3e98293 100644 --- a/src/jinja2/ext.py +++ b/src/jinja2/ext.py @@ -604,7 +604,7 @@ class WithExtension(Extension): "The 'with' extension is deprecated and will be removed in" " Jinja 3.1. This is built in now.", DeprecationWarning, - stacklevel=2, + stacklevel=3, ) @@ -615,7 +615,7 @@ class AutoEscapeExtension(Extension): "The 'autoescape' extension is deprecated and will be" " removed in Jinja 3.1. This is built in now.", DeprecationWarning, - stacklevel=2, + stacklevel=3, ) |