summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHongxu Jia <hongxu.jia@windriver.com>2025-09-26 16:19:13 +0800
committerKhem Raj <raj.khem@gmail.com>2025-10-03 11:21:05 -0700
commit544667e65aef62654236adb5bf3d1ee3b175421c (patch)
tree9631d23df0f65840fbc7dc9df52c6d8e82a4d9fe
parentc8a1d7b83c3cbebeff73a837eae0045700608cb7 (diff)
downloadmeta-openembedded-544667e65aef62654236adb5bf3d1ee3b175421c.tar.gz
python3-pandas: fix reproducibility issue
The type of new_value is either `npy_timedelta' or `int64_t' In build/pandas/_libs/tslibs/timedeltas.cpython-313-x86_64-linux-gnu.so.p/pandas/_libs/tslibs/timedeltas.pyx.c .. npy_timedelta __pyx_v_new_value; ... In build/pandas/_libs/tslibs/timedeltas.cpython-313-x86_64-linux-gnu.so.p/pandas/_libs/tslibs/timedeltas.pyx.c ... __pyx_t_5numpy_int64_t __pyx_v_new_value; ... Explicitly define it as int64_t to assure the generated source is reproducibility between builds Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com> Signed-off-by: Khem Raj <raj.khem@gmail.com>
-rw-r--r--meta-python/recipes-devtools/python/python3-pandas/0001-fix-reproducibility-issue.patch43
-rw-r--r--meta-python/recipes-devtools/python/python3-pandas_2.2.3.bb1
2 files changed, 44 insertions, 0 deletions
diff --git a/meta-python/recipes-devtools/python/python3-pandas/0001-fix-reproducibility-issue.patch b/meta-python/recipes-devtools/python/python3-pandas/0001-fix-reproducibility-issue.patch
new file mode 100644
index 0000000000..deadacafa9
--- /dev/null
+++ b/meta-python/recipes-devtools/python/python3-pandas/0001-fix-reproducibility-issue.patch
@@ -0,0 +1,43 @@
1From 80274cd3a0746ddc5421643dd40d47bdf3c6a68c Mon Sep 17 00:00:00 2001
2From: Hongxu Jia <hongxu.jia@windriver.com>
3Date: Fri, 26 Sep 2025 15:47:53 +0800
4Subject: [PATCH] fix reproducibility issue
5
6The type of new_value is either `npy_timedelta' or `int64_t'
7In build/pandas/_libs/tslibs/timedeltas.cpython-313-x86_64-linux-gnu.so.p/pandas/_libs/tslibs/timedeltas.pyx.c
8..
9npy_timedelta __pyx_v_new_value;
10...
11
12In build/pandas/_libs/tslibs/timedeltas.cpython-313-x86_64-linux-gnu.so.p/pandas/_libs/tslibs/timedeltas.pyx.c
13...
14__pyx_t_5numpy_int64_t __pyx_v_new_value;
15...
16
17Explicitly define it as int64_t to assure the generated source is
18reproducibility between builds
19
20Upstream-Status: Submitted [https://github.com/pandas-dev/pandas/pull/62459]
21
22Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
23---
24 pandas/_libs/tslibs/timedeltas.pyx | 3 +++
25 1 file changed, 3 insertions(+)
26
27diff --git a/pandas/_libs/tslibs/timedeltas.pyx b/pandas/_libs/tslibs/timedeltas.pyx
28index f6c69cf..34ac9e7 100644
29--- a/pandas/_libs/tslibs/timedeltas.pyx
30+++ b/pandas/_libs/tslibs/timedeltas.pyx
31@@ -1820,6 +1820,9 @@ class Timedelta(_Timedelta):
32
33 disallow_ambiguous_unit(unit)
34
35+ cdef:
36+ int64_t new_value;
37+
38 # GH 30543 if pd.Timedelta already passed, return it
39 # check that only value is passed
40 if isinstance(value, _Timedelta):
41--
422.34.1
43
diff --git a/meta-python/recipes-devtools/python/python3-pandas_2.2.3.bb b/meta-python/recipes-devtools/python/python3-pandas_2.2.3.bb
index f1df026c5c..60cc01800f 100644
--- a/meta-python/recipes-devtools/python/python3-pandas_2.2.3.bb
+++ b/meta-python/recipes-devtools/python/python3-pandas_2.2.3.bb
@@ -8,6 +8,7 @@ LIC_FILES_CHKSUM = "file://LICENSE;md5=cb819092901ddb13a7d0a4f5e05f098a"
8 8
9SRC_URI += " \ 9SRC_URI += " \
10 file://0001-pyproject.toml-don-t-pin-dependency-versions.patch \ 10 file://0001-pyproject.toml-don-t-pin-dependency-versions.patch \
11 file://0001-fix-reproducibility-issue.patch \
11 " 12 "
12 13
13SRC_URI:append:class-target = " file://0001-BLD-add-option-to-specify-numpy-header-location.patch " 14SRC_URI:append:class-target = " file://0001-BLD-add-option-to-specify-numpy-header-location.patch "