ironic-lib uses the deprecated declare_namespace call

Bug #2070370 reported by Dmitry Tantsur
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
ironic-lib
Triaged
Medium
Unassigned

Bug Description

Warning from sushy-tools, for example:

/home/dtantsur/Projects/sushy-tools/.tox/venv/lib/python3.12/site-packages/ironic_lib/__init__.py:18: DeprecationWarning: pkg_resources is deprecated as an API. See https://setuptools.pypa.io/en/latest/pkg_resources.html
  import pkg_resources
/home/dtantsur/Projects/sushy-tools/.tox/venv/lib/python3.12/site-packages/ironic_lib/__init__.py:19: DeprecationWarning: Deprecated call to `pkg_resources.declare_namespace('ironic_lib')`.
Implementing implicit namespace packages (as specified in PEP 420) is preferred to `pkg_resources.declare_namespace`. See https://setuptools.pypa.io/en/latest/references/keywords.html#keyword-namespace-packages
  pkg_resources.declare_namespace(__name__)

I have no idea why we do this: ironic-lib is not a namespace, just a normal package. This code has been there since the inception. I suspect we can remove it.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.