cd ~/
mkdir myenv-python312 && cd myenv-python312
pyenv local 3.12.3
python -m venv venvjuno312
source venvjuno312/bin/activategit clone https://github.com/Juniper/ansible-junos-stdlib.git -b jnpr-ansible-merger
cd ansible-junos-stdlibansible-galaxy collection install \
git+https://github.com/Juniper/ansible-junos-stdlib.git#/ansible_collections/juniper/device,jnpr-ansible-merger
ansible-galaxy collection install ansible.netcommon \
-p ./ansible_collections
ansible-galaxy collection install ansible.utils \
-p ./ansible_collectionsrm -rf ~/.ansible/test/venv/
rm -rf tests/output/.tmp/ansible-test sanity --python 3.12 --venv --requirementsHere are the logs of a successful run for ansible-test sanity.
This resolves the common ModuleNotFoundError: ansible.netcommon and allows ansible-test sanity to pass cleanly on a fresh venv with Python 3.12.