from kivy.app import App
from kivy.uix.button import Button
class MyApp(App):
def build(self):
return Button(text = "Это моя первая кнопка!")
if __name__ == "__main__":
MyApp().run()
Ошибка:
[INFO ] [Logger ] Record log in C:\Users\Maxim\.kivy\logs\kivy_20-09-09_13.txt
[INFO ] [Kivy ] v1.11.1
[INFO ] [Kivy ] Installed at "C:\Users\Maxim\AppData\Roaming\Python\Python37\site-packages\kivy\__init__.py"
[INFO ] [Python ] v3.7.8 (tags/v3.7.8:4b47a5b6ba, Jun 28 2020, 08:53:46) [MSC v.1916 64 bit (AMD64)]
[INFO ] [Python ] Interpreter at "C:\Program Files\Python37\pythonw.exe"
[INFO ] [Factory ] 184 symbols loaded
[INFO ] [Image ] Providers: img_tex, img_dds, img_gif (img_sdl2, img_pil, img_ffpyplayer ignored)
[CRITICAL] [Text ] Unable to find any valuable Text 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 - ImportError: DLL load failed: Не найден указанный модуль.
File "C:\Users\Maxim\AppData\Roaming\Python\Python37\site-packages\kivy\core\__init__.py", line 63, in core_select_lib
fromlist=[modulename], level=0)
File "C:\Users\Maxim\AppData\Roaming\Python\Python37\site-packages\kivy\core\text\text_sdl2.py", line 13, in <module>
from kivy.core.text._text_sdl2 import (_SurfaceContainer, _get_extents,
pil - ModuleNotFoundError: No module named 'PIL'
File "C:\Users\Maxim\AppData\Roaming\Python\Python37\site-packages\kivy\core\__init__.py", line 63, in core_select_lib
fromlist=[modulename], level=0)
File "C:\Users\Maxim\AppData\Roaming\Python\Python37\site-packages\kivy\core\text\text_pil.py", line 7, in <module>
from PIL import Image, ImageFont, ImageDraw
[CRITICAL] [App ] Unable to get a Text provider, abort.