diff mbox series

[04/11] python3-jinja2: allow building with flit_core 4

Message ID 20261129192114.12997-5-tim.orling@konsulko.com
State New
Headers show
Series python3-flit-core: upgrade to 4.2.0, fix recipes that pin flit_core <4 | expand

Commit Message

Tim Orling Nov. 29, 2026, 7:21 p.m. UTC
Relax the flit_core <4 build requirement to <5. The project already uses
the [project] table, so nothing flit_core 4 removed affects it. Upstream
declined the same change, as for the other pallets projects.

Tested by building with flit_core 3.12.0 and 4.2.0.

AI-Generated: Uses Claude Code (Claude Opus 5.5)
Signed-off-by: Tim Orling <tim.orling@konsulko.com>
---
 ...toml-allow-building-with-flit_core-4.patch | 25 +++++++++++++++++++
 .../python/python3-jinja2_3.1.6.bb            |  1 +
 2 files changed, 26 insertions(+)
 create mode 100644 meta/recipes-devtools/python/python3-jinja2/0001-pyproject.toml-allow-building-with-flit_core-4.patch
diff mbox series

Patch

diff --git a/meta/recipes-devtools/python/python3-jinja2/0001-pyproject.toml-allow-building-with-flit_core-4.patch b/meta/recipes-devtools/python/python3-jinja2/0001-pyproject.toml-allow-building-with-flit_core-4.patch
new file mode 100644
index 0000000000..1edb526ae1
--- /dev/null
+++ b/meta/recipes-devtools/python/python3-jinja2/0001-pyproject.toml-allow-building-with-flit_core-4.patch
@@ -0,0 +1,25 @@ 
+From: Tim Orling <tim.orling@konsulko.com>
+Subject: [PATCH] pyproject.toml: allow building with flit_core 4
+
+flit_core 4 only drops features this project does not use (the
+[tool.flit.metadata] table, sdists from VCS and --setup-py), so
+raise the upper bound to <5, as the flit 4.0 release notes suggest:
+https://flit.pypa.io/en/stable/history.html#version-4-0
+
+Upstream-Status: Denied [https://github.com/pallets/jinja/issues/2232]
+AI-Generated: Uses Claude Code (Claude Opus 5.5)
+Signed-off-by: Tim Orling <tim.orling@konsulko.com>
+---
+diff --git a/pyproject.toml b/pyproject.toml
+index a7cfa7f..8a29a8a 100644
+--- a/pyproject.toml
++++ b/pyproject.toml
+@@ -33,7 +33,7 @@ i18n = ["Babel>=2.7"]
+ jinja2 = "jinja2.ext:babel_extract[i18n]"
+ 
+ [build-system]
+-requires = ["flit_core<4"]
++requires = ["flit_core<5"]
+ build-backend = "flit_core.buildapi"
+ 
+ [tool.flit.module]
diff --git a/meta/recipes-devtools/python/python3-jinja2_3.1.6.bb b/meta/recipes-devtools/python/python3-jinja2_3.1.6.bb
index 0d06b962a1..3d586843a2 100644
--- a/meta/recipes-devtools/python/python3-jinja2_3.1.6.bb
+++ b/meta/recipes-devtools/python/python3-jinja2_3.1.6.bb
@@ -4,6 +4,7 @@  HOMEPAGE = "https://pypi.org/project/Jinja2/"
 LICENSE = "BSD-3-Clause"
 LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=5dc88300786f1c214c1e9827a5229462"
 
+SRC_URI += "file://0001-pyproject.toml-allow-building-with-flit_core-4.patch"
 SRC_URI[sha256sum] = "0137fb05990d35f1275a587e9aee6d56da821fc83491a0fb838183be43f66d6d"
 
 CVE_PRODUCT = "jinja2 jinja"