jaseg / python-mpv

Python interface to the awesome mpv media player
https://git.jaseg.de/python-mpv.git
Other
531 stars 67 forks source link

Testsuite failures with mpv 0.35 #239

Closed baldurmen closed 1 year ago

baldurmen commented 1 year ago

Hello!

Debian is transitioning to mpv 0.35 and I get what I think are testsuite failures (they are not registered as such?) on test_read and test_write, although I'm not exactly sure, as I am not really familiar with the mpv codebase :)

Note that these tests are running with Python 3.11, but I get the same thing with 3.10.

I: pybuild base:240: python3.11 setup.py test 
/usr/lib/python3/dist-packages/setuptools/dist.py:771: UserWarning: Usage of dash-separated 'description-file' will not be supported in future versions. Please use the underscore name 'description_file' instead
  warnings.warn(
running test
WARNING: Testing via this command is deprecated and will be removed in a future version. Users looking for a generic test entry point independent of test runner are encouraged to use tox.
running egg_info
creating python_mpv.egg-info
writing python_mpv.egg-info/PKG-INFO
writing dependency_links to python_mpv.egg-info/dependency_links.txt
writing requirements to python_mpv.egg-info/requires.txt
writing top-level names to python_mpv.egg-info/top_level.txt
writing manifest file 'python_mpv.egg-info/SOURCES.txt'
reading manifest file 'python_mpv.egg-info/SOURCES.txt'
adding license file 'LICENSE.GPL'
adding license file 'LICENSE.LGPL'
writing manifest file 'python_mpv.egg-info/SOURCES.txt'
running build_ext
test_async_command (tests.test_mpv.CommandTests.test_async_command) ... ok
test_loadfile_with_subtitles (tests.test_mpv.CommandTests.test_loadfile_with_subtitles) ... ok
test_sub_add (tests.test_mpv.CommandTests.test_sub_add) ... ok
test_register_decorator_fun (tests.test_mpv.KeyBindingTest.test_register_decorator_fun) ... ok
test_register_decorator_fun_chaining (tests.test_mpv.KeyBindingTest.test_register_decorator_fun_chaining) ... ok
test_register_direct_bound_method (tests.test_mpv.KeyBindingTest.test_register_direct_bound_method) ... ok
test_register_direct_cmd (tests.test_mpv.KeyBindingTest.test_register_direct_cmd) ... ok
test_register_direct_fun (tests.test_mpv.KeyBindingTest.test_register_direct_fun) ... ok
test_register_simple_decorator_fun_chaining (tests.test_mpv.KeyBindingTest.test_register_simple_decorator_fun_chaining) ... ok
test_wait_for_event_error_forwarding (tests.test_mpv.KeyBindingTest.test_wait_for_event_error_forwarding) ... ok
test_wait_for_property_error_forwarding (tests.test_mpv.KeyBindingTest.test_wait_for_property_error_forwarding) ... ok
test_observe_property (tests.test_mpv.ObservePropertyTest.test_observe_property) ... ok
test_property_observer_decorator (tests.test_mpv.ObservePropertyTest.test_property_observer_decorator) ... ok
test_instance_method_property_observer (tests.test_mpv.RegressionTests.test_instance_method_property_observer)
Ensure that bound method objects can be used as property observers. ... ok
test_unobserve_property_runtime_error (tests.test_mpv.RegressionTests.test_unobserve_property_runtime_error)
Ensure a `RuntimeError` is not thrown within ... ok
test_create_destroy (tests.test_mpv.TestLifecycle.test_create_destroy) ... ok
test_event_callback (tests.test_mpv.TestLifecycle.test_event_callback) ... ok
test_flags (tests.test_mpv.TestLifecycle.test_flags) ... ok
test_log_handler (tests.test_mpv.TestLifecycle.test_log_handler) ... ok
test_options (tests.test_mpv.TestLifecycle.test_options) ... ok
test_wait_for_event (tests.test_mpv.TestLifecycle.test_wait_for_event) ... ok
test_wait_for_event_shutdown (tests.test_mpv.TestLifecycle.test_wait_for_event_shutdown) ... ok
test_wait_for_prooperty_event_overflow (tests.test_mpv.TestLifecycle.test_wait_for_prooperty_event_overflow) ... skipped 'Fails'
test_wait_for_property_negative (tests.test_mpv.TestLifecycle.test_wait_for_property_negative) ... skipped 'Fails'
test_wait_for_property_positive (tests.test_mpv.TestLifecycle.test_wait_for_property_positive) ... skipped 'Fails'
test_wait_for_property_shutdown (tests.test_mpv.TestLifecycle.test_wait_for_property_shutdown) ... skipped 'Fails'
test_wait_for_shutdown (tests.test_mpv.TestLifecycle.test_wait_for_shutdown) ... ok
test_array_property_bounce (tests.test_mpv.TestProperties.test_array_property_bounce) ... ok
test_multivalued_option (tests.test_mpv.TestProperties.test_multivalued_option) ... ok
test_option_read (tests.test_mpv.TestProperties.test_option_read) ... ok
test_osd_property_bounce (tests.test_mpv.TestProperties.test_osd_property_bounce) ... ok
test_property_bounce (tests.test_mpv.TestProperties.test_property_bounce) ... ok
test_property_decoding_invalid_utf8 (tests.test_mpv.TestProperties.test_property_decoding_invalid_utf8) ... ok
test_property_decoding_multi (tests.test_mpv.TestProperties.test_property_decoding_multi) ... ok
test_property_decoding_valid_utf8 (tests.test_mpv.TestProperties.test_property_decoding_valid_utf8) ... ok
test_raw_property_bounce (tests.test_mpv.TestProperties.test_raw_property_bounce) ... ok
test_read (tests.test_mpv.TestProperties.test_read) ... [W][02359.711281] pw.conf      | [          conf.c:  939 try_load_conf()] can't load config client.conf: No such file or directory
[E][02359.711288] pw.conf      | [          conf.c:  963 pw_conf_load_conf_for_context()] can't load default config client.conf: No such file or directory
ok
test_write (tests.test_mpv.TestProperties.test_write) ... [W][02360.176119] pw.conf      | [          conf.c:  939 try_load_conf()] can't load config client.conf: No such file or directory
[E][02360.176127] pw.conf      | [          conf.c:  963 pw_conf_load_conf_for_context()] can't load default config client.conf: No such file or directory
ok
test_custom_stream (tests.test_mpv.TestStreams.test_custom_stream) ... ok
test_python_stream (tests.test_mpv.TestStreams.test_python_stream) ... ok

----------------------------------------------------------------------
Ran 40 tests in 26.728s
jaseg commented 1 year ago

Thank you for the bug report. I was unable to reproduce this on arch on current main. These are the versions I'm running:

bigdata~/p/python-mpv (venv) <3 python --version
Python 3.10.9
bigdata~/p/python-mpv (venv) <3 mpv --version
mpv 0.35.1 Copyright © 2000-2023 mpv/MPlayer/mplayer2 projects
 built on Mon Feb 20 07:38:49 2023
FFmpeg library versions:
   libavutil       57.28.100
   libavcodec      59.37.100
   libavformat     59.27.100
   libswscale      6.7.100
   libavfilter     8.44.100
   libswresample   4.7.100
FFmpeg version: n5.1.2

The errors you got in TestProperties look weird. They don't get registered as testsuite failures because libmpv does not actually forward them as error codes to the API, instead it just prints them to the log, and then seems to ignore them. I think this might be a bug or flakiness on libmpv's side. Please re-open this if you get the same error again, and I will try to reproduce this in a debian VM.