diff --git a/backport-use-Constant-value.patch b/backport-use-Constant-value.patch new file mode 100644 index 0000000000000000000000000000000000000000..3e8725b8e4d67b52287c220c92bf81d53a97415e --- /dev/null +++ b/backport-use-Constant-value.patch @@ -0,0 +1,25 @@ +From 724eab2bcdf020a9dd3893b372730dd19c82f036 Mon Sep 17 00:00:00 2001 +From: fwx937284 +Date: Wed, 8 Jul 2020 15:24:47 +0800 +Subject: [PATCH] Use Constant.value, not Constant.n + +--- + mako/_ast_util.py | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/mako/_ast_util.py b/mako/_ast_util.py +index d770451..3120659 100644 +--- a/mako/_ast_util.py ++++ b/mako/_ast_util.py +@@ -681,7 +681,7 @@ class SourceGenerator(NodeVisitor): + self.write(repr(node.n)) + # newly needed in Python 3.8 + def visit_Constant(self, node): +- self.write(repr(node.n)) ++ self.write(repr(node.value)) + + def visit_Tuple(self, node): + self.write('(') +-- +2.23.0 + diff --git a/python-mako.spec b/python-mako.spec index e1528efad350d94144fadd33b2527ae65551c013..aeb529e6eeb9e657bd41b9c67249455e71be4be2 100644 --- a/python-mako.spec +++ b/python-mako.spec @@ -1,6 +1,6 @@ Name: python-mako Version: 1.0.6 -Release: 13 +Release: 14 Summary: Mako template library for Python License: (MIT and Python) and (BSD or GPLv2) Group: Development/Languages @@ -9,6 +9,7 @@ Source0: https://bitbucket.org/zzzeek/mako/get/rel_%(echo %{version} | sed "s/\. BuildArch: noarch Patch6000: backport-optimize-make-test.patch +Patch6001: backport-use-Constant-value.patch BuildRequires: python2-devel python2-pytest python2-setuptools BuildRequires: python2-markupsafe python2-nose python2-mock @@ -84,6 +85,12 @@ rm -rf doc/build %doc doc %changelog +* Wed Jul 8 2020 xinghe - 1.0.6-14 +- Type:bugfix +- ID:NA +- SUG:NA +- DESC:Use Constant.value + * Wed Jun 24 2020 wenzhanli - 1.0.6-13 - Type:bugfix - ID:NA