python-jinja2/0001-add-linetable-to-the-preserved-CodeType-attributes-1.patch
DistroBaker e4ab01d960 Merged update from upstream sources
This is an automated DistroBaker update from upstream sources.
If you do not know what this is about or would like to opt out,
contact the OSCI team.

Source: https://src.fedoraproject.org/rpms/python-jinja2.git#93898ae45c1e90f2e9c41a49126884cb5be93ffc
2021-02-06 13:14:24 +00:00

28 lines
852 B
Diff

From 9a99db929323f60553b391c80d0395821121d593 Mon Sep 17 00:00:00 2001
From: Thomas Moschny <thomas.moschny@gmx.de>
Date: Tue, 19 Jan 2021 21:01:18 +0100
Subject: [PATCH] add 'linetable' to the preserved CodeType attributes (#1334)
add 'linetable' to the preserved CodeType attributes
co_linetable replaces co_lnotab as part of PEP 626 in Python 3.10.
---
src/jinja2/debug.py | 1 +
1 file changed, 1 insertion(+)
diff --git a/src/jinja2/debug.py b/src/jinja2/debug.py
index 5d8aec3..e256617 100644
--- a/src/jinja2/debug.py
+++ b/src/jinja2/debug.py
@@ -137,6 +137,7 @@ def fake_traceback(exc_value, tb, filename, lineno):
"lnotab",
"freevars",
"cellvars",
+ "linetable", # Python 3.10
):
if isinstance(attr, tuple):
# Replace with given value.
--
2.29.2