pytoolz / toolz

A functional standard library for Python.
http://toolz.readthedocs.org/
Other
4.71k stars 263 forks source link

0.11.1: pytest `DeprecationWarning` warning #520

Closed kloczek closed 3 years ago

kloczek commented 3 years ago

Yeah looks like pytest shows some warnings:

+ PYTHONPATH=/home/tkloczko/rpmbuild/BUILDROOT/python-toolz-0.11.1-6.fc35.x86_64/usr/lib64/python3.8/site-packages:/home/tkloczko/rpmbuild/BUILDROOT/python-toolz-0.11.1-6.fc35.x86_64/usr/lib/python3.8/site-packages
+ /usr/bin/pytest -ra
=========================================================================== test session starts ============================================================================
platform linux -- Python 3.8.11, pytest-6.2.4, py-1.10.0, pluggy-0.13.1
benchmark: 3.4.1 (defaults: timer=time.perf_counter disable_gc=False min_rounds=5 min_time=0.000005 max_time=1.0 calibration_precision=10 warmup=False warmup_iterations=100000)
Using --randomly-seed=2247035504
rootdir: /home/tkloczko/rpmbuild/BUILD/toolz-0.11.1
plugins: forked-1.3.0, shutil-1.7.0, virtualenv-1.7.0, expect-1.1.0, flake8-1.0.7, timeout-1.4.2, betamax-0.8.1, freezegun-0.4.2, aspectlib-1.5.2, toolbox-0.5, rerunfailures-9.1.1, requests-mock-1.9.3, cov-2.12.1, pyfakefs-4.5.0, flaky-3.7.0, benchmark-3.4.1, xdist-2.3.0, pylama-7.7.1, datadir-1.3.1, regressions-2.2.0, cases-3.6.3, xprocess-0.18.1, black-0.3.12, checkdocs-2.7.1, anyio-3.3.0, Faker-8.11.0, asyncio-0.15.1, trio-0.7.0, httpbin-1.0.0, subtests-0.5.0, isort-2.0.0, hypothesis-6.14.6, mock-3.6.1, profiling-1.7.0, randomly-3.8.0
collected 205 items

bench/test_memoize_kwargs.py .                                                                                                                                       [  0%]
bench/test_get_list.py .                                                                                                                                             [  0%]
bench/test_first_iter.py ..                                                                                                                                          [  1%]
bench/test_curry_baseline.py .                                                                                                                                       [  2%]
bench/test_wordcount.py .                                                                                                                                            [  2%]
toolz/tests/test_tlz.py .                                                                                                                                            [  3%]
toolz/tests/test_curried_doctests.py .                                                                                                                               [  3%]
toolz/sandbox/tests/test_core.py ....                                                                                                                                [  5%]
bench/test_pluck.py .                                                                                                                                                [  6%]
toolz/tests/test_dicttoolz.py ...............................................                                                                                        [ 29%]
toolz/tests/test_itertoolz.py ..................................................                                                                                     [ 53%]
bench/test_join.py ...                                                                                                                                               [ 55%]
bench/test_sliding_window.py .                                                                                                                                       [ 55%]
toolz/tests/test_utils.py .                                                                                                                                          [ 56%]
toolz/tests/test_functoolz.py ......................................                                                                                                 [ 75%]
toolz/tests/test_serialization.py .........                                                                                                                          [ 79%]
bench/test_get.py .                                                                                                                                                  [ 79%]
toolz/tests/test_inspect_args.py .................                                                                                                                   [ 88%]
toolz/sandbox/tests/test_parallel.py .                                                                                                                               [ 88%]
bench/test_first.py ..                                                                                                                                               [ 89%]
toolz/tests/test_recipes.py ..                                                                                                                                       [ 90%]
toolz/tests/test_curried.py ..........                                                                                                                               [ 95%]
bench/test_groupby.py .                                                                                                                                              [ 96%]
bench/test_memoize.py .                                                                                                                                              [ 96%]
toolz/tests/test_signatures.py ...                                                                                                                                   [ 98%]
bench/test_frequencies.py ..                                                                                                                                         [ 99%]
. .                                                                                                                                                                  [ 99%]
bench/test_curry.py .                                                                                                                                                [100%]

============================================================================= warnings summary =============================================================================
../../BUILDROOT/python-toolz-0.11.1-6.fc35.x86_64/usr/lib/python3.8/site-packages/toolz/compatibility.py:2
  /home/tkloczko/rpmbuild/BUILDROOT/python-toolz-0.11.1-6.fc35.x86_64/usr/lib/python3.8/site-packages/toolz/compatibility.py:2: DeprecationWarning: The toolz.compatibility module is no longer needed in Python 3 and has been deprecated. Please import these utilities directly from the standard library. This module will be removed in a future release.
    warnings.warn("The toolz.compatibility module is no longer "

-- Docs: https://docs.pytest.org/en/stable/warnings.html
===================================================================== 204 passed, 1 warning in 15.72s ======================================================================
pytest-xprocess reminder::Be sure to terminate the started process by running 'pytest --xkill' if you have not explicitly done so in your fixture with 'xprocess.getinfo(<process_name>).terminate()'.
eriknw commented 3 years ago

Thanks @kloczek. This is now fixed by #485. Closing.

kloczek commented 3 years ago

Just tested that PR. All looks clean now :)

+ PYTHONPATH=/home/tkloczko/rpmbuild/BUILDROOT/python-toolz-0.11.1-6.1.fc35.x86_64/usr/lib64/python3.8/site-packages:/home/tkloczko/rpmbuild/BUILDROOT/python-toolz-0.11.1-6.1.fc35.x86_64/usr/lib/python3.8/site-packages
+ /usr/bin/pytest -ra
=========================================================================== test session starts ============================================================================
platform linux -- Python 3.8.12, pytest-6.2.5, py-1.10.0, pluggy-0.13.1
rootdir: /home/tkloczko/rpmbuild/BUILD/toolz-0.11.1
plugins: forked-1.3.0, shutil-1.7.0, virtualenv-1.7.0, flake8-1.0.7, xdist-2.3.0, cov-2.12.1, mock-3.6.1, localserver-0.5.0
collected 204 items

bench/test_curry.py .                                                                                                                                                [  0%]
bench/test_curry_baseline.py .                                                                                                                                       [  0%]
bench/test_first.py ..                                                                                                                                               [  1%]
bench/test_first_iter.py ..                                                                                                                                          [  2%]
bench/test_frequencies.py ..                                                                                                                                         [  3%]
bench/test_get.py .                                                                                                                                                  [  4%]
bench/test_get_list.py .                                                                                                                                             [  4%]
bench/test_groupby.py .                                                                                                                                              [  5%]
bench/test_join.py ...                                                                                                                                               [  6%]
bench/test_memoize.py .                                                                                                                                              [  7%]
bench/test_memoize_kwargs.py .                                                                                                                                       [  7%]
bench/test_pluck.py .                                                                                                                                                [  8%]
bench/test_sliding_window.py .                                                                                                                                       [  8%]
bench/test_wordcount.py .                                                                                                                                            [  9%]
toolz/sandbox/tests/test_core.py ....                                                                                                                                [ 11%]
toolz/sandbox/tests/test_parallel.py .                                                                                                                               [ 11%]
toolz/tests/test_compatibility.py .                                                                                                                                  [ 12%]
toolz/tests/test_curried.py ..........                                                                                                                               [ 17%]
toolz/tests/test_curried_doctests.py .                                                                                                                               [ 17%]
toolz/tests/test_dicttoolz.py ...............................................                                                                                        [ 40%]
toolz/tests/test_functoolz.py ......................................                                                                                                 [ 59%]
toolz/tests/test_inspect_args.py .................                                                                                                                   [ 67%]
toolz/tests/test_itertoolz.py ..................................................                                                                                     [ 92%]
toolz/tests/test_recipes.py ..                                                                                                                                       [ 93%]
toolz/tests/test_serialization.py .........                                                                                                                          [ 97%]
toolz/tests/test_signatures.py ...                                                                                                                                   [ 99%]
toolz/tests/test_tlz.py .                                                                                                                                            [ 99%]
toolz/tests/test_utils.py .                                                                                                                                          [100%]

=========================================================================== 204 passed in 30.54s ===========================================================================

Thank you :)