I happened on this thread again after overhearing a couple of different teams mention that they were looking at alternatives to Ansible due to these difficulties. As a Python open source maintainer, I deeply share the desire to get rid of old versions but this feels suboptimal to me.
One of the thoughts I had is that where this has come up in my experience has almost exclusively been the python-dnf dependency where Ansible was otherwise functional using the Python 3.11 installed from Red Hat’s repository for RHEL8. This made me wonder what percentage of problems would be resolved if Red Hat’s Python packaging team could make the dnf bindings available in the newer versions as well, and what the best path for Red Hat customers might be to request that.