Running our python linter with a recent python and the latest release of setuptools v68.1.2:
$ python3 --version
Python 3.11.5
$ ./test/lint/lint-python.py:12: DeprecationWarning: pkg_resources is deprecated as an API.
See https://setuptools.pypa.io/en/latest/pkg_resources.html
import pkg_resources
Using pkg_resources was deprecated earlier in v67.5.0: "Although pkg_resources has been discouraged for use, some projects still consider pkg_resources viable for usage. This change makes it clear that pkg_resources should not be used, emitting a DeprecationWarning when imported."
The importlib.metadata library requires Python 3.8, which is currently our minimum-supported Python version.
For more details about importlib.metadata and the two methods imported and used here, see: