net-mgmt/py-napalm-logs: Update to 0.11.0
0.9.0 fails on Python 3.12+: napalm_logs.base imports imp (removed
in 3.12) to load the Python device profiles, and it calls yaml.load()
without a Loader, which PyYAML 6 rejects, so no YAML profile loads.
0.11.0 fixes the YAML loading.
Also add some patches to fix the following issues:
- Replace the imp calls with importlib.
- napalm_logs/__init__.py imports pkg_resources to look up its version; pkg_resources is deprecated and only available with setuptools, which is not a run dependency. Use importlib.metadata.
- The authenticator process and the ClientAuth helper call ssl.wrap_socket(), removed in Python 3.12, so the auth process crashes on the first connection and clients cannot authenticate. Use SSLContext with the same behaviour.
While here:
- Switch to USE_PYTHON=pep517 to make the port future-proof.
- Fix portlint warnings and document the patches.
- Add LICENSE_FILE and switch to USE_PYTHON=pytest to simplify the Makefile.
PR: 300164
MFH: 2026Q4
Co-Authored-By: Kai Knoblich <kai@FreeBSD.org>
(cherry picked from commit 661a4d62fa69fe29b4f223b6f0824868fb966b4a)