Error message:
Code:
References:
Kivy Tutorial #1 - How to Create Mobile Apps With Python
Update: I should mention that there was a problem with PyCharm recognizing Kivy, which I solved by following these instructions. I was able to follow them exactly, except I wasn't able to install the 0.25.2 version of cython without getting an error, so in the end I had to install the default one, which had a higher number. I don't know if that matters.
Quote:C:\Users\[USERNAME]\PycharmProjects\practice\venv\installkivy\Scripts\python.exe C:/Users/[USERNAME]/PycharmProjects/kivia/venv/installkivy/never_name_a_file_kivy.py
[INFO ] [Logger ] Record log in C:\Users\[USERNAME]\.kivy\logs\kivy_19-03-29_41.txt
[INFO ] [Kivy ] v1.10.1
[INFO ] [Python ] v3.7.3 (v3.7.3:ef4ec6ed12, Mar 25 2019, 22:22:05) [MSC v.1916 64 bit (AMD64)]
[INFO ] [Factory ] 194 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.
sdl2 - ImportError: DLL load failed: The specified module could not be found.
File "C:\Users\[USERNAME]\PycharmProjects\practice\venv\installkivy\lib\site-packages\kivy\core\__init__.py", line 59, in core_select_lib
fromlist=[modulename], level=0)
File "C:\Users\[USERNAME]\PycharmProjects\practice\venv\installkivy\lib\site-packages\kivy\core\text\text_sdl2.py", line 12, in <module>
from kivy.core.text._text_sdl2 import (_SurfaceContainer, _get_extents,
pil - ModuleNotFoundError: No module named 'PIL'
File "C:\Users\[USERNAME]\PycharmProjects\practice\venv\installkivy\lib\site-packages\kivy\core\__init__.py", line 59, in core_select_lib
fromlist=[modulename], level=0)
File "C:\Users\[USERNAME]\PycharmProjects\practice\venv\installkivy\lib\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.
Code:
import kivy from kivy.app import App from kivy.uix.label import Label class MyApp(App): def build(self): return Label(text="Hello, World.") if __name__ == "__main__": MyApp().run()What am I doing wrong?
References:
Kivy Tutorial #1 - How to Create Mobile Apps With Python
Update: I should mention that there was a problem with PyCharm recognizing Kivy, which I solved by following these instructions. I was able to follow them exactly, except I wasn't able to install the 0.25.2 version of cython without getting an error, so in the end I had to install the default one, which had a higher number. I don't know if that matters.