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

Hypnotix fail to start (libmpv problem) #254

Open
matthgyver opened this issue Nov 15, 2022 · 10 comments
Open

Hypnotix fail to start (libmpv problem) #254

matthgyver opened this issue Nov 15, 2022 · 10 comments

Comments

@matthgyver
Copy link

Hi,

Since last update on Arch linux, Hypnotix fail to start with this error:

Traceback (most recent call last):
File "/usr/lib/hypnotix/hypnotix.py", line 25, in <module>
    import mpv
File "/usr/lib/hypnotix/mpv.py", line 531, in <module>
    _handle_func('mpv_detach_destroy',          [],                                         None, errcheck=None)
File "/usr/lib/hypnotix/mpv.py", line 478, in _handle_func
    func = getattr(backend, name)
File "/usr/lib/python3.10/ctypes/__init__.py", line 387, in __getattr__
    func = self.__getitem__(name)
File "/usr/lib/python3.10/ctypes/__init__.py", line 392, in __getitem__
    func = self._FuncPtr((name_or_ordinal, self))
AttributeError: /usr/lib/libmpv.so.2: undefined symbol: mpv_detach_destroy

MPV infos:

mpv --version
mpv 0.35.0 Copyright © 2000-2022 mpv/MPlayer/mplayer2 projects
    built on UNKNOWN
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

Have you an idea about this problem please ?

Thanks

@Axel-Erfurt
Copy link

Axel-Erfurt commented Nov 16, 2022

What's the output of

ldconfig -p | grep libmpv

mpv_detach_destroy is deprecated, you can try

replace mpv_detach_destroy with mpv_destroy in /usr/lib/hypnotix/mpv.py

@matthgyver
Copy link
Author

Hi,

ldconfig -p | grep libmpv
libmpv.so.2 (libc6,x86-64) => /usr/lib/libmpv.so.2
libmpv.so (libc6,x86-64) => /usr/lib/libmpv.so

It's work with your suggestion.
Thanks

@Axel-Erfurt
Copy link

Mint has no libmpv.so.2

libmpv.so.1 (libc6,x86-64) => /lib/x86_64-linux-gnu/libmpv.so.1

@adocampo
Copy link

replace mpv_detach_destroy with mpv_destroy in /usr/lib/hypnotix/mpv.py

Yes, hypnotix stopped working a pair of days ago on arch. Your suggestion did the trick.

Thank you very much

@Mennaruuk
Copy link

What's the output of

ldconfig -p | grep libmpv

mpv_detach_destroy is deprecated, you can try

replace mpv_detach_destroy with mpv_destroy in /usr/lib/hypnotix/mpv.py

Does anyone know how to fix this Hypnotix issue for Ubuntu 22.10? I tried replacing mpv_detach_destroy with mpv_destroy in /usr/lib/hypnotix/mpv.py, however, that failed to resolve the problem.

@bobby285271
Copy link

replace mpv_detach_destroy with mpv_destroy in /usr/lib/hypnotix/mpv.py

I can confirm this also fixes the issue on NixOS and jaseg/python-mpv@2b3249a did the same thing. A quick look at https://github.com/mpv-player/mpv/blob/v0.34.1/libmpv/client.h#L502 and https://github.com/mpv-player/mpv/blob/v0.34.1/player/client.c#L557 what mpv_detach_destroy in mpv 0.34.1 does is simply calling mpv_destroy, so I guess it should be okay for mint to fix this now?

Does anyone know how to fix this Hypnotix issue for Ubuntu 22.10?

https://packages.ubuntu.com/search?keywords=libmpv&searchon=names says ubuntu 22.10 does not have libmpv2 yet, I guess what you encountered is not related to this issue?

@joaoeudes7
Copy link

Thanks @Mennaruuk! Works here!

@TheGarageRocks
Copy link

What's the output of

ldconfig -p | grep libmpv

mpv_detach_destroy is deprecated, you can try

replace mpv_detach_destroy with mpv_destroy in /usr/lib/hypnotix/mpv.py

This fixed it for me on Debian Sid !
Thanks !!!

@levimaen
Copy link

help required: Hypnotix stop working after installing Linux mint 21.11
this are the results in the terminal
niso@niso-HP-ProDesk-600-G2-SFF:$ GDK_BACKEND=x11 hypnotix
niso@niso-HP-ProDesk-600-G2-SFF:
$ Loading providers...
XTREAM Niso Loading Channels

(hypnotix.py:9325): Gdk-ERROR **: 00:56:53.917: The program 'hypnotix.py' received an X Window System error.
This probably reflects a bug in the program.
The error was 'BadRequest (invalid request code or no such operation)'.
(Details: serial 1610 error_code 1 request_code 0 (core protocol) minor_code 0)
(Note to programmers: normally, X errors are reported asynchronously;
that is, you will receive the error a while after causing it.
To debug your program, run it with the GDK_SYNCHRONIZE environment
variable to change this behavior. You can then get a meaningful
backtrace from your debugger if you break on the gdk_x_error() function.)

@Sadi58
Copy link

Sadi58 commented Mar 17, 2024

I installed Hypnotix today on Debian Trixie using the file hypnotix_4.3_all.deb from Mint repositories, and also the file "python3-imdbpy_2021.04.18-3_all.deb" from the old Debian repositories (I wonder why it doesn't exist in the current Debian repositories?)
However, after fixing the "mpv_detach_destroy" issue as above, I now get this terminal output:

System version of yt-dlp selected.
Traceback (most recent call last):
  File "/usr/lib/hypnotix/hypnotix.py", line 27, in <module>
    import mpv
  File "/usr/lib/hypnotix/mpv.py", line 53, in <module>
    backend = CDLL(sofile)
              ^^^^^^^^^^^^
  File "/usr/lib/python3.11/ctypes/__init__.py", line 376, in __init__
    self._handle = _dlopen(self._name, mode)
                   ^^^^^^^^^^^^^^^^^^^^^^^^^
OSError: /lib/x86_64-linux-gnu/libmpv.so.2: undefined symbol: av_packet_side_data_get, version LIBAVCODEC_60

I hope someone can suggest a fix for this also as easy as the one above. ;-)

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

9 participants