omry / omegaconf

Flexible Python configuration system. The last one you will ever need.
BSD 3-Clause "New" or "Revised" License
1.94k stars 105 forks source link

Tests fail because of PEP420 deprecation warnings. #1064

Closed GaetanLepage closed 1 year ago

GaetanLepage commented 1 year ago

Describe the bug The following test fails: test_pydev_resolver_plugin.py

Output:

============================= test session starts ==============================
platform linux -- Python 3.10.10, pytest-7.2.1, pluggy-1.0.0
rootdir: /build/source, configfile: pyproject.toml
collecting ... ^Mcollecting 2724 items                                                          ^Mcollecting 5470 items                                                          ^Mcollecting 6883 items / 1 error                                                ^Mcollected 8133 items / 1 error                                                 

==================================== ERRORS ====================================
_____________ ERROR collecting tests/test_pydev_resolver_plugin.py _____________
tests/test_pydev_resolver_plugin.py:23: in <module>
    from pydevd_plugins.extensions.pydevd_plugin_omegaconf import (
pydevd_plugins/__init__.py:2: in <module>
    __import__("pkg_resources").declare_namespace(__name__)
/nix/store/qg3jn6cd12kphciq49grn38hk5fzgs0v-python3.10-setuptools-67.4.0/lib/python3.10/site-packages/pkg_resources/__init__.py:2298: in declare_namespace
    warnings.warn(msg, DeprecationWarning, stacklevel=2)
E   DeprecationWarning: Deprecated call to `pkg_resources.declare_namespace('pydevd_plugins')`.
E   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
=========================== short test summary info ============================
ERROR tests/test_pydev_resolver_plugin.py - DeprecationWarning: Deprecated call to `pkg_resources.declare_namespace('py...
!!!!!!!!!!!!!!!!!!!! Interrupted: 1 error during collection !!!!!!!!!!!!!!!!!!!!
=============================== 1 error in 2.21s ===============================

To Reproduce Run the tests.

Expected behavior Tests pass.

Additional context

Jasha10 commented 1 year ago

Thanks @GaetanLepage. This is closed by #1069.