]> git.ipfire.org Git - thirdparty/openembedded/openembedded-core.git/commit
python3-setuptools-scm: respect GIT_CEILING_DIRECTORIES
authorEtienne Cordonnier <ecordonnier@snap.com>
Thu, 13 Feb 2025 16:32:10 +0000 (17:32 +0100)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Mon, 17 Feb 2025 22:04:00 +0000 (22:04 +0000)
commit4ebe72477484cf68165b6f736ce10373e97d0e6d
treef804eb22332e19dbaa5806778bc75c9a99081f1a
parent4bea64347407dfb1eb46dacffd05af3bd200b419
python3-setuptools-scm: respect GIT_CEILING_DIRECTORIES

Fixes https://bugzilla.yoctoproject.org/show_bug.cgi?id=15740

python3-setuptools-scm was ignoring GIT_CEILING_DIRECTORIES which is set by poky,
and it was thus finding a wrong value of "toplevel" in ./src/setuptools_scm/_file_finders/git.py
The code is supposed to generate the list of files contained in python3-setuptools-scm, but it was
instead running "git archive" on whatever git repository was above the build directory, because the
tarball containing the sources of python3-setuptools-scm does not contain a .git directory.

This is barely noticeable when building as a subdirectory of poky which is only 48MB, but this was
causing serious slowdowns of python3-setuptools-scm:do_compile when building
inside a big git repository with files tracked using git-lfs (50 minutes in my use-case).

Reported upstream as https://github.com/pypa/setuptools-scm/issues/1103

Signed-off-by: Etienne Cordonnier <ecordonnier@snap.com>
Signed-off-by: Ross Burton <ross.burton@arm.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
meta/recipes-devtools/python/python3-setuptools-scm/0001-respect-GIT_CEILING_DIRECTORIES.patch [new file with mode: 0644]
meta/recipes-devtools/python/python3-setuptools-scm_8.1.0.bb