Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

1.8.7: pytest warnings #433

Open
kloczek opened this issue Dec 24, 2021 · 2 comments
Open

1.8.7: pytest warnings #433

kloczek opened this issue Dec 24, 2021 · 2 comments

Comments

@kloczek
Copy link

kloczek commented Dec 24, 2021

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
  • install .whl file in </install/prefix>
  • run pytest with PYTHONPATH pointing to sitearch and sitelib inside </install/prefix>

Here is pytest output:

+ PYTHONPATH=/home/tkloczko/rpmbuild/BUILDROOT/python-webob-1.8.7-4.fc35.x86_64/usr/lib64/python3.8/site-packages:/home/tkloczko/rpmbuild/BUILDROOT/python-webob-1.8.7-4.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.11.0, pluggy-1.0.0
rootdir: /home/tkloczko/rpmbuild/BUILD/webob-1.8.7, configfile: setup.cfg, testpaths: src/webob, tests
collected 2389 items

tests/test_acceptparse.py .......................................................................................................................................... [  5%]
.................................................................................................................................................................... [ 12%]
.................................................................................................................................................................... [ 19%]
.................................................................................................................................................................... [ 26%]
.................................................................................................................................................................... [ 33%]
.................................................................................................................................................................... [ 40%]
.................................................................................................................................................................... [ 46%]
....................................................................................................................................                                 [ 52%]
tests/test_byterange.py ...............                                                                                                                              [ 53%]
tests/test_cachecontrol.py ...............................                                                                                                           [ 54%]
tests/test_client.py .............                                                                                                                                   [ 54%]
tests/test_client_functional.py ....                                                                                                                                 [ 55%]
tests/test_compat.py ...........                                                                                                                                     [ 55%]
tests/test_cookies.py .............................................s.s.s................................................                                             [ 59%]
tests/test_cookies_bw.py .                                                                                                                                           [ 59%]
tests/test_datetime_utils.py ......                                                                                                                                  [ 59%]
tests/test_dec.py .........................                                                                                                                          [ 61%]
tests/test_descriptors.py ...............................................................................................................................            [ 66%]
tests/test_etag.py ..........................                                                                                                                        [ 67%]
tests/test_etag_nose.py .......                                                                                                                                      [ 67%]
tests/test_exc.py ........................................                                                                                                           [ 69%]
tests/test_headers.py .................                                                                                                                              [ 70%]
tests/test_in_wsgiref.py ..                                                                                                                                          [ 70%]
tests/test_misc.py ...s.........s.                                                                                                                                   [ 70%]
tests/test_multidict.py ........................................................................................................................                     [ 75%]
tests/test_request.py .............................................................................................................................................. [ 81%]
.......................................................................................................................s.s.s..............................s......... [ 88%]
...............................................................................                                                                                      [ 91%]
tests/test_response.py ..........................................................x.................................................................................. [ 97%]
..................                                                                                                                                                   [ 98%]
tests/test_static.py ....................                                                                                                                            [ 99%]
tests/test_transcode.py ......                                                                                                                                       [ 99%]
tests/test_util.py .......                                                                                                                                           [100%]

============================================================================= warnings summary =============================================================================
tests/test_request.py::TestRequest_functional::test_request_put
  /home/tkloczko/rpmbuild/BUILDROOT/python-webob-1.8.7-4.fc35.x86_64/usr/lib/python3.8/site-packages/webob/acceptparse.py:1262: DeprecationWarning: The behavior of .__contains__ for the Accept classes is currently being maintained for backward compatibility, but it will change in the future to better conform to the RFC.
    warnings.warn(

tests/test_request.py::TestRequest_functional::test_request_put
  /home/tkloczko/rpmbuild/BUILDROOT/python-webob-1.8.7-4.fc35.x86_64/usr/lib/python3.8/site-packages/webob/acceptparse.py:645: DeprecationWarning: The behavior of AcceptValidHeader.__contains__ is currently being maintained for backward compatibility, but it will change in the future to better conform to the RFC.
    warnings.warn(

tests/test_response.py::test_set_cookie_expires_is_datetime_and_max_age_is_None
tests/test_response.py::test_set_cookie_expires_is_timedelta_and_max_age_is_None
tests/test_response.py::test_set_cookie_expires_is_datetime_tz_and_max_age_is_None
  /home/tkloczko/rpmbuild/BUILDROOT/python-webob-1.8.7-4.fc35.x86_64/usr/lib/python3.8/site-packages/webob/response.py:1037: DeprecationWarning: Argument "expires" will be removed in a future version of WebOb, please use "max_age".
    warn_deprecation('Argument "expires" will be removed in a future '

-- Docs: https://docs.pytest.org/en/stable/warnings.html
========================================================================= short test summary info ==========================================================================
SKIPPED [1] tests/test_cookies.py:375: condition: sys.version_info >= (3, 0)
SKIPPED [1] tests/test_cookies.py:387: condition: sys.version_info >= (3, 0)
SKIPPED [1] tests/test_cookies.py:401: condition: sys.version_info >= (3, 0)
SKIPPED [2] tests/test_misc.py:35: condition: sys.version_info >= (3, 0)
SKIPPED [1] tests/test_request.py:2179: condition: sys.version_info >= (3, 0)
SKIPPED [1] tests/test_request.py:2193: condition: sys.version_info >= (3, 0)
SKIPPED [1] tests/test_request.py:2207: condition: sys.version_info >= (3, 0)
SKIPPED [1] tests/test_request.py:2491: condition: sys.version_info >= (3, 0)
XFAIL tests/test_response.py::test_response_file_body_tell
  Python 3.6 and up requires that rbo is seekable.
========================================================= 2379 passed, 9 skipped, 1 xfailed, 5 warnings in 10.64s ==========================================================
@digitalresistor
Copy link
Member

Those warnings are from inside webob itself... I am not sure what this issue is opened for? When the code that those tests depend on goes away after the deprecation period, those warnings will disappear too.

@kloczek
Copy link
Author

kloczek commented Dec 25, 2021

Sorry. I'm just packaging python modules and if I see warnings I'm only trying to make sure that this is something which is know to the maintainer.
If it is not an issue just fee free to close this ticket :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants