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

Test failure in Python 3.11 #582

Closed
mgorny opened this issue Jul 17, 2022 · 3 comments
Closed

Test failure in Python 3.11 #582

mgorny opened this issue Jul 17, 2022 · 3 comments
Assignees
Milestone

Comments

@mgorny
Copy link

mgorny commented Jul 17, 2022

There's one test failing with Python 3.11.0b4:

$ tox -e py311
GLOB sdist-make: /tmp/wand/setup.py
py311 create: /tmp/wand/.tox/py311
py311 installdeps: pytest, pytest-xdist, pytest-cov, memory_profiler, psutil
py311 inst: /tmp/wand/.tox/.tmp/package/1/Wand-0.6.8.zip
py311 installed: attrs==21.4.0,coverage==6.4.2,execnet==1.9.0,iniconfig==1.1.1,memory-profiler==0.60.0,packaging==21.3,pluggy==1.0.0,psutil==5.9.1,py==1.11.0,pyparsing==3.0.9,pytest==7.1.2,pytest-cov==3.0.0,pytest-forked==1.4.0,pytest-xdist==2.5.0,tomli==2.0.1,Wand @ file:///tmp/wand/.tox/.tmp/package/1/Wand-0.6.8.zip
py311 run-test-pre: PYTHONHASHSEED='1352898524'
py311 run-test: commands[0] | pytest --durations=5 --boxed
========================================================= test session starts =========================================================
platform linux -- Python 3.11.0b4, pytest-7.1.2, pluggy-1.0.0
cachedir: .tox/py311/.pytest_cache
Wand Version: 0.6.8
ImageMagick Version: ImageMagick 7.1.0-20 Q16-HDRI x86_64 2022-01-22 https://imagemagick.org
rootdir: /tmp/wand
plugins: xdist-2.5.0, cov-3.0.0, forked-1.4.0
collected 573 items                                                                                                                   

tests/_resource_test.py ................................................................                                        [ 11%]
tests/color_test.py .................................s....                                                                      [ 17%]
tests/drawing_test.py ....................................ss...................................................                 [ 33%]
tests/exceptions_test.py ...                                                                                                    [ 33%]
tests/image_methods_test.py ...........................................................................F....................... [ 51%]
..................................................................................................................              [ 71%]
tests/image_properties_test.py ......x...........................................................                               [ 82%]
tests/image_test.py ..........................................sss.                                                              [ 90%]
tests/misc_test.py .....                                                                                                        [ 91%]
tests/sequence_test.py .................................................                                                        [100%]

============================================================== FAILURES ===============================================================
____________________________________________________________ test_fx_error ____________________________________________________________
fx_asset = local('/tmp/wand/tests/assets')

    def test_fx_error(fx_asset):
        with Image() as empty_wand:
            with raises(AttributeError):
>               with empty_wand.fx('8'):
E               TypeError: 'NoneType' object does not support the context manager protocol

tests/image_methods_test.py:982: TypeError
========================================================== warnings summary ===========================================================
.tox/py311/lib/python3.11/site-packages/xdist/plugin.py:205
  /tmp/wand/.tox/py311/lib/python3.11/site-packages/xdist/plugin.py:205: DeprecationWarning: The --boxed commmand line argument is deprecated. Install pytest-forked and use --forked instead. pytest-xdist 3.0.0 will remove the --boxed argument and pytest-forked dependency.
    config.issue_config_time_warning(warning, 2)

-- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html
========================================================= slowest 5 durations =========================================================
10.13s call     tests/image_methods_test.py::test_resize_and_sample_gif[resize]
9.20s call     tests/image_methods_test.py::test_resize_and_sample_gif[sample]
4.23s call     tests/image_methods_test.py::test_rotate_gif
3.23s call     tests/image_methods_test.py::test_transform_gif
2.93s call     tests/image_methods_test.py::test_crop_gif
======================================================= short test summary info =======================================================
FAILED tests/image_methods_test.py::test_fx_error
=================================== 1 failed, 565 passed, 6 skipped, 1 xfailed, 1 warning in 55.71s ===================================
ERROR: InvocationError for command /tmp/wand/.tox/py311/bin/pytest --durations=5 --boxed (exited with code 1)
_______________________________________________________________ summary _______________________________________________________________
ERROR:   py311: commands failed
@emcconville
Copy link
Owner

Thanks for reporting this.

@emcconville emcconville self-assigned this Jul 17, 2022
@emcconville emcconville added this to the Wand 0.6.9 milestone Jul 17, 2022
emcconville added a commit that referenced this issue Jul 17, 2022
@emcconville
Copy link
Owner

This issue should be resolved. Thanks!

@mgorny
Copy link
Author

mgorny commented Jul 18, 2022

Thanks. I can confirm that the tests pass for me now.

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