kivy: Kivy 1.9.1, ImportError while importing kivy.app.App
Installed fresh Python2.7.10, Kivy1.9.1 (following instructions from kivy.org website) on Windows7 64bit. I’m getting an ImportError when I run this code:
from kivy.app import App
from kivy.uix.button import Button
class ButtonApp(App):
def build(self):
return Button(text='TEST')
ButtonApp().run()
Console output:
E:\Python27\python.exe E:/workspace/TEST/test_kivy_1.9.1/main.py
[INFO ] [Logger ] Record log in C:\Users\Skerleton\.kivy\logs\kivy_16-01-04_38.txt
[INFO ] [Kivy ] v1.9.1
[INFO ] [Python ] v2.7.10 (default, May 23 2015, 09:40:32) [MSC v.1500 32 bit (Intel)]
[INFO ] [Factory ] 179 symbols loaded
[DEBUG ] [Cache ] register <kv.lang> with limit=None, timeout=None
Traceback (most recent call last):
File "E:/workspace/TEST/test_kivy_1.9.1/main.py", line 1, in <module>
from kivy.app import App
File "E:\Python27\lib\site-packages\kivy\app.py", line 327, in <module>
from kivy.uix.widget import Widget
File "E:\Python27\lib\site-packages\kivy\uix\widget.py", line 219, in <module>
from kivy.graphics import (
File "E:\Python27\lib\site-packages\kivy\graphics\__init__.py", line 89, in <module>
from kivy.graphics.instructions import Callback, Canvas, CanvasBase, \
ImportError: DLL load failed: The specified module could not be found.
Process finished with exit code 1
Kivy installed without issues, except for Gstreamer. This error is reported by another developer on kivy google group
About this issue
- Original URL
- State: closed
- Created 8 years ago
- Comments: 26 (17 by maintainers)
The gstreamer problem has been fixed. I also updated all the dependencies so I’d suggest you download them again with
python -m pip install --upgrade docutils pygments pypiwin32 kivy.deps.sdl2 kivy.deps.glew kivy.deps.gstreamer --extra-index-url https://kivy.org/downloads/packages/simple/
as this may fix your problem. Let us know.Install the dependencies (skip gstreamer (~120MB) if not needed, see Kivy’s dependencies):
python -m pip install docutils pygments pypiwin32 kivy.deps.sdl2 kivy.deps.glew; python -m pip install kivy.deps.gstreamer
I reinstalled Python and Kivy with
kivy.deps.sdl2==0.1.12
,kivy.deps.gstreamer==0.1.6
. It works!