Our aging code base is still using distutils e.g. https://layers.openembedded.org/layerindex/updates/35783/ /opt/layerindex/layerindex/update_layer.py:22: DeprecationWarning: The distutils package is deprecated and slated for removal in Python 3.12. Use setuptools or check PEP 632 for potential alternatives from distutils.version import LooseVersion ERROR: ERROR: Traceback (most recent call last): File "/opt/layerindex/layerindex/update_layer.py", line 384, in main (tinfoil, tempdir) = recipeparse.init_parser(settings, branch, bitbakepath, nocheckout=options.nocheckout, logger=logger) File "/opt/layerindex/layerindex/recipeparse.py", line 91, in init_parser tinfoil = utils.setup_tinfoil(bitbakepath, enable_tracking, loglevel=logger.getEffectiveLevel()) File "/opt/layerindex/layerindex/utils.py", line 200, in setup_tinfoil import bb.tinfoil File "/opt/workdir/git___git_openembedded_org_bitbake/lib/bb/__init__.py", line 119, in <module> from bb import fetch2 as fetch File "/opt/workdir/git___git_openembedded_org_bitbake/lib/bb/fetch2/__init__.py", line 26, in <module> import bb.persist_data, bb.utils File "/opt/workdir/git___git_openembedded_org_bitbake/lib/bb/persist_data.py", line 22, in <module> from collections import Mapping ImportError: cannot import name 'Mapping' from 'collections' (/usr/lib/python3.10/collections/__init__.py)
LooseVersion is one of the items that does not have a setuptools replacement, but we have bb.utils.vercmp_string_op if it can be used. e.g. https://git.yoctoproject.org/poky/commit/?id=f0627490711f29f0e308a0afc4fc4f8e54f58dec
The actual breaking code (because of update to ubuntu:jammy and Python 3.10.y) is ImportError: cannot import name 'Mapping' from 'collections' (/usr/lib/python3.10/collections/__init__.py)
Above was for gatesgarth... probably need someone to just turn off those older branch updates.
Fixed in: https://lore.kernel.org/yocto/125fe439624b307582389aad8c8a6b920bb6b2c8.1671208436.git.tim.orling@konsulko.com/T/#u Commit: https://git.yoctoproject.org/layerindex-web/commit/?id=0cc6d8eb1f511d7008f71498e0c6e1d85d1256fe