在我的python代码中导入mpv模块时出错

vh0rcniy  于 2023-01-06  发布在  Python
关注(0)|答案(1)|浏览(234)

我尝试使用python的mpv绑定,但是每次我尝试执行import mpv时,都会出现以下错误:

Traceback (most recent call last):
  File "e:\Programming\Web2Desk\t1.py", line 1, in <module>
    import mpv
  File "e:\Programming\Web2Desk\mpv.py", line 566, in <module>
    _handle_func('mpv_abort_async_command',     [c_ulonglong],                              None, errcheck=None)   
  File "e:\Programming\Web2Desk\mpv.py", line 502, in _handle_func
    func = getattr(backend, name)
  File "C:\Users\PC\AppData\Local\Programs\Python\Python39\lib\ctypes\__init__.py", line 387, in __getattr__
    func = self.__getitem__(name)
  File "C:\Users\PC\AppData\Local\Programs\Python\Python39\lib\ctypes\__init__.py", line 392, in __getitem__
    func = self._FuncPtr((name_or_ordinal, self))
AttributeError: function 'mpv_abort_async_command' not found

好心帮忙。

mctunoxg

mctunoxg1#

我在旧版本(0.5.2)上得到这个,所以升级到最新版本应该可以。我在1.0.1上,它工作得很好。

相关问题