Closed kloczek closed 1 year ago
I'm sorry, but I don't reproduce this anomaly. I think it's fixed in the version v1.2.14 that I've just published.
I'm closing this issue, but you can reopen it if necessary. In this case, please describe precisely the steps to reproduce the problem.
Just tested 1.2.14 and warnings are still present.
+ PYTHONPATH=/home/tkloczko/rpmbuild/BUILDROOT/python-deprecated-1.2.14-2.fc35.x86_64/usr/lib64/python3.8/site-packages:/home/tkloczko/rpmbuild/BUILDROOT/python-deprecated-1.2.14-2.fc35.x86_64/usr/lib/python3.8/site-packages
+ /usr/bin/pytest -ra -m 'not network'
============================= test session starts ==============================
platform linux -- Python 3.8.16, pytest-7.3.1, pluggy-1.0.0
rootdir: /home/tkloczko/rpmbuild/BUILD/deprecated-1.2.14
configfile: setup.cfg
collected 171 items
tests/test.py .. [ 1%]
tests/test_deprecated.py ......................................... [ 25%]
tests/test_deprecated_class.py ....... [ 29%]
tests/test_deprecated_metaclass.py .... [ 31%]
tests/test_sphinx.py ................................................... [ 61%]
........................................... [ 86%]
tests/test_sphinx_adapter.py ............ [ 93%]
tests/test_sphinx_class.py ....... [ 97%]
tests/test_sphinx_metaclass.py .... [100%]
=============================== warnings summary ===============================
../../../../../usr/lib/python3.8/site-packages/pkg_resources/__init__.py:121
/usr/lib/python3.8/site-packages/pkg_resources/__init__.py:121: DeprecationWarning: pkg_resources is deprecated as an API
warnings.warn("pkg_resources is deprecated as an API", DeprecationWarning)
../../../../../usr/lib/python3.8/site-packages/pkg_resources/__init__.py:2870
../../../../../usr/lib/python3.8/site-packages/pkg_resources/__init__.py:2870
../../../../../usr/lib/python3.8/site-packages/pkg_resources/__init__.py:2870
../../../../../usr/lib/python3.8/site-packages/pkg_resources/__init__.py:2870
../../../../../usr/lib/python3.8/site-packages/pkg_resources/__init__.py:2870
/usr/lib/python3.8/site-packages/pkg_resources/__init__.py:2870: DeprecationWarning: Deprecated call to `pkg_resources.declare_namespace('sphinxcontrib')`.
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
declare_namespace(pkg)
tests/test_deprecated_class.py::test_simple_class_deprecation_with_args
/home/tkloczko/rpmbuild/BUILD/deprecated-1.2.14/tests/test_deprecated_class.py:148: DeprecationWarning: Call to deprecated class MyClass. (kwargs class)
MyClass(5)
tests/test_sphinx_class.py::test_isinstance_deprecated
/home/tkloczko/rpmbuild/BUILD/deprecated-1.2.14/tests/test_sphinx_class.py:134: DeprecationWarning: Call to deprecated class DeprecatedChildCls. (some reason) -- Deprecated since version Y.Z.
instance = DeprecatedChildCls()
tests/test_sphinx_class.py::test_isinstance_deprecated
/home/tkloczko/rpmbuild/BUILD/deprecated-1.2.14/deprecated/classic.py:173: DeprecationWarning: Call to deprecated class DeprecatedCls. (some reason) -- Deprecated since version X.Y.
return old_new1(cls, *args, **kwargs)
-- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html
======================= 171 passed, 9 warnings in 0.42s ========================
You need setuptools
67.x.
I'm trying to package your module as an rpm package. So I'm using the typical PEP517 based build, install and test cycle used on building packages from non-root account.
python3 -sBm build -w --no-isolation
build
with--no-isolation
I'm using during all processes only locally installed modulesHere is pytest output: