diff options
author | 2021-05-16 20:15:32 +0200 | |
---|---|---|
committer | 2021-05-16 20:17:39 +0200 | |
commit | 395a79e92252013dc32270969a3338e1d191b962 (patch) | |
tree | 712f5bb6e23e79e3761d8c46275275ed87cad534 /net-libs/nodejs | |
parent | net-libs/nodejs: remove unused patch (diff) | |
download | gentoo-395a79e92252013dc32270969a3338e1d191b962.tar.gz gentoo-395a79e92252013dc32270969a3338e1d191b962.tar.bz2 gentoo-395a79e92252013dc32270969a3338e1d191b962.zip |
net-libs/nodejs: more collections.abc fixes in jinja
Suggested-by: Jens Brandt <gentoo@brandt-george.de>
Closes: https://github.com/gentoo/gentoo/pull/20816
Signed-off-by: Marek Szuba <marecki@gentoo.org>
Diffstat (limited to 'net-libs/nodejs')
-rw-r--r-- | net-libs/nodejs/files/nodejs-12.22.1-jinja_collections_abc.patch | 84 |
1 files changed, 84 insertions, 0 deletions
diff --git a/net-libs/nodejs/files/nodejs-12.22.1-jinja_collections_abc.patch b/net-libs/nodejs/files/nodejs-12.22.1-jinja_collections_abc.patch index 45be8cb07f8d..5f0df09b6e2e 100644 --- a/net-libs/nodejs/files/nodejs-12.22.1-jinja_collections_abc.patch +++ b/net-libs/nodejs/files/nodejs-12.22.1-jinja_collections_abc.patch @@ -9,3 +9,87 @@ from jinja2.runtime import Undefined from jinja2._compat import text_type, string_types, integer_types import decimal +--- a/deps/v8/third_party/jinja2/runtime.py ++++ b/deps/v8/third_party/jinja2/runtime.py +@@ -315,7 +315,7 @@ class Context(with_metaclass(ContextMeta)): + + # register the context as mapping if possible + try: +- from collections import Mapping ++ from collections.abc import Mapping + Mapping.register(Context) + except ImportError: + pass +--- a/deps/v8/third_party/jinja2/sandbox.py ++++ b/deps/v8/third_party/jinja2/sandbox.py +@@ -14,7 +14,7 @@ + """ + import types + import operator +-from collections import Mapping ++from collections.abc import Mapping + from jinja2.environment import Environment + from jinja2.exceptions import SecurityError + from jinja2._compat import string_types, PY2 +@@ -79,7 +79,7 @@ except ImportError: + pass + + #: register Python 2.6 abstract base classes +-from collections import MutableSet, MutableMapping, MutableSequence ++from collections.abc import MutableSet, MutableMapping, MutableSequence + _mutable_set_types += (MutableSet,) + _mutable_mapping_types += (MutableMapping,) + _mutable_sequence_types += (MutableSequence,) +--- a/deps/v8/third_party/jinja2/utils.py ++++ b/deps/v8/third_party/jinja2/utils.py +@@ -482,7 +482,7 @@ class LRUCache(object): + + # register the LRU cache as mutable mapping if possible + try: +- from collections import MutableMapping ++ from collections.abc import MutableMapping + MutableMapping.register(LRUCache) + except ImportError: + pass +--- a/tools/inspector_protocol/jinja2/runtime.py ++++ b/tools/inspector_protocol/jinja2/runtime.py +@@ -315,7 +315,7 @@ class Context(with_metaclass(ContextMeta)): + + # register the context as mapping if possible + try: +- from collections import Mapping ++ from collections.abc import Mapping + Mapping.register(Context) + except ImportError: + pass +--- a/tools/inspector_protocol/jinja2/sandbox.py ++++ b/tools/inspector_protocol/jinja2/sandbox.py +@@ -14,7 +14,7 @@ + """ + import types + import operator +-from collections import Mapping ++from collections.abc import Mapping + from jinja2.environment import Environment + from jinja2.exceptions import SecurityError + from jinja2._compat import string_types, PY2 +@@ -79,7 +79,7 @@ except ImportError: + pass + + #: register Python 2.6 abstract base classes +-from collections import MutableSet, MutableMapping, MutableSequence ++from collections.abc import MutableSet, MutableMapping, MutableSequence + _mutable_set_types += (MutableSet,) + _mutable_mapping_types += (MutableMapping,) + _mutable_sequence_types += (MutableSequence,) +--- a/tools/inspector_protocol/jinja2/tests.py ++++ b/tools/inspector_protocol/jinja2/tests.py +@@ -10,7 +10,7 @@ + """ + import operator + import re +-from collections import Mapping ++from collections.abc import Mapping + from jinja2.runtime import Undefined + from jinja2._compat import text_type, string_types, integer_types + import decimal |