summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRoss Burton <ross.burton@arm.com>2025-06-08 23:54:33 +0200
committerSteve Sakoman <steve@sakoman.com>2025-06-13 09:01:26 -0700
commit66a51c233ed7d39cc45d6d04d894900025d2ed8f (patch)
tree895d7689ad8b2346ad88aff2ff4a3633a9b4e051
parente5824127e46e927c7b24f576dbf6e603e85bc9c7 (diff)
downloadpoky-66a51c233ed7d39cc45d6d04d894900025d2ed8f.tar.gz
python3: remove obsolete deletion of non-deterministic .pyc files
These .pyc files were non-deterministic because they used frozensets[1], but this has been fixed in 3.11 onwards. [1] https://github.com/python/cpython/issues/81777 [2] https://github.com/python/cpython/commit/51999c960e7fc45feebd629421dec6524a5fc803 (From OE-Core rev: c8c391ed3e0598a3bea7bc0981126d870315063d) (From OE-Core rev: 75758dc92003892edc32cccb3c830926b5c4942a) Signed-off-by: Ross Burton <ross.burton@arm.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Peter Marko <peter.marko@siemens.com> Signed-off-by: Steve Sakoman <steve@sakoman.com>
-rw-r--r--meta/recipes-devtools/python/python3_3.13.2.bb14
1 files changed, 0 insertions, 14 deletions
diff --git a/meta/recipes-devtools/python/python3_3.13.2.bb b/meta/recipes-devtools/python/python3_3.13.2.bb
index 7c36fd92ed..0f0505c66c 100644
--- a/meta/recipes-devtools/python/python3_3.13.2.bb
+++ b/meta/recipes-devtools/python/python3_3.13.2.bb
@@ -235,20 +235,6 @@ do_install:append() {
235 $sysconfigfile 235 $sysconfigfile
236 cp $sysconfigfile ${D}${libdir}/python-sysconfigdata/_sysconfigdata.py 236 cp $sysconfigfile ${D}${libdir}/python-sysconfigdata/_sysconfigdata.py
237 237
238
239 # Unfortunately the following pyc files are non-deterministc due to 'frozenset'
240 # being written without strict ordering, even with PYTHONHASHSEED = 0
241 # Upstream is discussing ways to solve the issue properly, until then let's
242 # just not install the problematic files.
243 # More info: http://benno.id.au/blog/2013/01/15/python-determinism
244 rm -f ${D}${libdir}/python${PYTHON_MAJMIN}/test/__pycache__/test_range.cpython*
245 rm -f ${D}${libdir}/python${PYTHON_MAJMIN}/test/__pycache__/test_xml_etree.cpython*
246
247 # Similar to the above, we're getting reproducibility issues with
248 # /usr/lib/python3.10/__pycache__/traceback.cpython-310.pyc
249 # so remove it too
250 rm -f ${D}${libdir}/python${PYTHON_MAJMIN}/__pycache__/traceback.cpython*
251
252 # Remove the opt-1.pyc and opt-2.pyc files. They effectively waste space on embedded 238 # Remove the opt-1.pyc and opt-2.pyc files. They effectively waste space on embedded
253 # style targets as they're only used when python is called with the -O or -OO options 239 # style targets as they're only used when python is called with the -O or -OO options
254 # which is rare. 240 # which is rare.