Pyinstaller Kivy:[严重] [Window] 无法找到任何有价值的 Window 提供商
Pyinstaller Kivy: [CRITICAL] [Window ] Unable to find any valuable Window provider
我正在尝试将我的 kivy 代码转换为 exe,但我遇到了这个错误
[CRITICAL] [Window ] Unable to find any valuable Window provider. Please enable debug logging (e.g. add -d if running from the command line, or change the log level in the config) and re-run your app to identify potential causes
sdl2 - Exception: SDL2: Unable to load image
File "kivy\core\__init__.py", line 71, in core_select_lib
File "kivy\core\window\window_sdl2.py", line 165, in __init__
File "kivy\core\window\__init__.py", line 1071, in __init__
File "kivy\core\window\window_sdl2.py", line 362, in create_window
File "kivy\core\window\__init__.py", line 1450, in create_window
File "kivy\graphics\instructions.pyx", line 797, in kivy.graphics.instructions.RenderContext.__init__
File "kivy\core\image\__init__.py", line 561, in __init__
File "kivy\core\image\__init__.py", line 754, in _set_filename
File "kivy\core\image\__init__.py", line 460, in load
File "kivy\core\image\__init__.py", line 223, in __init__
File "kivy\core\image\img_sdl2.py", line 47, in load
[CRITICAL] [App ] Unable to get a Window, abort.
我有一个 python 文件、一个 .kv 文件、一些图像和一个需要编译的 zip 文件。
但我一直收到这个错误。我也使用了 auto-py-to-exe。
我在堆栈上也看到了关于此问题的其他问题。但是这些答案对我没有任何帮助。
我遇到了同样的问题并在 kivy's pyinstaller guide
的帮助下修复了它
但是现在当我 运行 编译的 exe 时我收到这个错误。
Traceback (most recent call last):
File "kivy\lang\parser.py", line 553, in execute_directives
File "<frozen importlib._bootstrap>", line 1109, in __import__
File "<frozen importlib._bootstrap>", line 1030, in _gcd_import
File "<frozen importlib._bootstrap>", line 1007, in _find_and_load
File "<frozen importlib._bootstrap>", line 972, in _find_and_load_unlocked
File "<frozen importlib._bootstrap>", line 228, in _call_with_frames_removed
File "<frozen importlib._bootstrap>", line 1030, in _gcd_import
File "<frozen importlib._bootstrap>", line 1007, in _find_and_load
File "<frozen importlib._bootstrap>", line 984, in _find_and_load_unlocked
ModuleNotFoundError: No module named 'kivymd.toast'
我正在尝试将我的 kivy 代码转换为 exe,但我遇到了这个错误
[CRITICAL] [Window ] Unable to find any valuable Window provider. Please enable debug logging (e.g. add -d if running from the command line, or change the log level in the config) and re-run your app to identify potential causes
sdl2 - Exception: SDL2: Unable to load image
File "kivy\core\__init__.py", line 71, in core_select_lib
File "kivy\core\window\window_sdl2.py", line 165, in __init__
File "kivy\core\window\__init__.py", line 1071, in __init__
File "kivy\core\window\window_sdl2.py", line 362, in create_window
File "kivy\core\window\__init__.py", line 1450, in create_window
File "kivy\graphics\instructions.pyx", line 797, in kivy.graphics.instructions.RenderContext.__init__
File "kivy\core\image\__init__.py", line 561, in __init__
File "kivy\core\image\__init__.py", line 754, in _set_filename
File "kivy\core\image\__init__.py", line 460, in load
File "kivy\core\image\__init__.py", line 223, in __init__
File "kivy\core\image\img_sdl2.py", line 47, in load
[CRITICAL] [App ] Unable to get a Window, abort.
我有一个 python 文件、一个 .kv 文件、一些图像和一个需要编译的 zip 文件。 但我一直收到这个错误。我也使用了 auto-py-to-exe。
我在堆栈上也看到了关于此问题的其他问题。但是这些答案对我没有任何帮助。
我遇到了同样的问题并在 kivy's pyinstaller guide
的帮助下修复了它但是现在当我 运行 编译的 exe 时我收到这个错误。
Traceback (most recent call last):
File "kivy\lang\parser.py", line 553, in execute_directives
File "<frozen importlib._bootstrap>", line 1109, in __import__
File "<frozen importlib._bootstrap>", line 1030, in _gcd_import
File "<frozen importlib._bootstrap>", line 1007, in _find_and_load
File "<frozen importlib._bootstrap>", line 972, in _find_and_load_unlocked
File "<frozen importlib._bootstrap>", line 228, in _call_with_frames_removed
File "<frozen importlib._bootstrap>", line 1030, in _gcd_import
File "<frozen importlib._bootstrap>", line 1007, in _find_and_load
File "<frozen importlib._bootstrap>", line 984, in _find_and_load_unlocked
ModuleNotFoundError: No module named 'kivymd.toast'