Simple Kivy app fails to buildoze - android

I wrote a simple kivy app that replicates buttons
import kivy
from kivy.app import App
from kivy.uix.button import Button
from kivy.uix.boxlayout import BoxLayout
class ButtonApp(App):
def add_button(self, none):
button = Button(text='Press Me too!')
button.bind(on_press=self.add_button)
self.b.add_widget(button)
def build(self):
self.b = BoxLayout()
button = Button(text="Press me!")
button.bind(on_press=self.add_button)
self.b.add_widget(button)
return self.b
if __name__ == "__main__":
ButtonApp().run()
but when I run buildozer android debug, I get the following error
# Android SDK found at /Users/mmalkin/.buildozer/android/platform/android-sdk-21
# Android NDK found at /Users/mmalkin/.buildozer/android/platform/android-ndk-r9c
# Command failed: /Users/mmalkin/.buildozer/android/platform/android-sdk-21/tools/android list sdk -u -e
#
# Buildozer failed to execute the last command
# If the error is not obvious, please raise the log_level to 2
# and retry the latest command.
# In case of a bug report, please add a full log with log_level = 2
I've tried changing the directory to Macintosh HD, updating Java, and many other solutions suggested on this site. What am I doing wrong?

You have probably not installed build-tools. Check this on-going bug report - https://github.com/kivy/buildozer/issues/146
Summary of solution, run the Android SDK Manager and install that way.

Related

Kivy garden mapview deploying error with Buildozer

I am using kivy.garden.mapview for my application. Everything works properly, but problems arise when I try to deploy the application to Android with Buildozer. I set "garden_requirements = mapview" in the .spec file, and I always get the same error message: "Command failed: garden install --app mapview". The command fails even when I execute it on its own. The command "buildozer android debug deploy run logcat" produces the following output:
albi#albi-VirtualBox:~/CUCINA$ buildozer android debug deploy run logcat
# Check configuration tokens
# Ensure build layout
# Check configuration tokens
# Preparing build
# Check requirements for android
# Run 'dpkg --version'
# Cwd None
Debian 'dpkg' package management program version 1.19.7 (amd64).
This is free software; see the GNU General Public License version 2 or
later for copying conditions. There is NO warranty.
# Search for Git (git)
# -> found at /usr/bin/git
# Search for Cython (cython)
# -> found at /home/albi/.local/bin/cython
# Search for Java compiler (javac)
# -> found at /usr/lib/jvm/java-8-openjdk-amd64/bin/javac
# Search for Java keytool (keytool)
# -> found at /usr/lib/jvm/java-8-openjdk-amd64/jre/bin/keytool
# Install platform
# Run 'git config --get remote.origin.url'
# Cwd /home/albi/CUCINA/.buildozer/android/platform/python-for-android
https://github.com/kivy/python-for-android.git
# Run 'git branch -vv'
# Cwd /home/albi/CUCINA/.buildozer/android/platform/python-for-android
* master 1b3b0e3f [origin/master] Merge pull request #2225 from kivy/release-2020.06.02
# Run '/usr/bin/python3 -m pip install -q --user \'appdirs\' \'colorama>=0.3.3\' \'jinja2\' \'six\' \'enum34; python_version<"3.4"\' \'sh>=1.10; sys_platform!="nt"\' \'pep517<0.7.0"\' \'toml\''
# Cwd None
# Apache ANT found at /home/albi/.buildozer/android/platform/apache-ant-1.9.4
# Android SDK found at /home/albi/.buildozer/android/platform/android-sdk
# Recommended android's NDK version by p4a is: 19c
# Android NDK found at /home/albi/.buildozer/android/platform/android-ndk-r19c
# Check application requirements
# Check garden requirements
# Remove directory and subdirectory /home/albi/CUCINA/.buildozer/libs
# Run 'bash -c "source venv/bin/activate && env"'
# Cwd /home/albi/CUCINA/.buildozer
SHELL=/bin/bash
SESSION_MANAGER=local/albi-VirtualBox:#/tmp/.ICE-unix/1718,unix/albi-VirtualBox:/tmp/.ICE-unix/1718
QT_ACCESSIBILITY=1
COLORTERM=truecolor
XDG_CONFIG_DIRS=/etc/xdg/xdg-ubuntu:/etc/xdg
XDG_MENU_PREFIX=gnome-
GNOME_DESKTOP_SESSION_ID=this-is-deprecated
GTK_IM_MODULE=ibus
QT4_IM_MODULE=ibus
LC_ADDRESS=it_IT.UTF-8
GNOME_SHELL_SESSION_MODE=ubuntu
LC_NAME=it_IT.UTF-8
SSH_AUTH_SOCK=/run/user/1000/keyring/ssh
XMODIFIERS=#im=ibus
DESKTOP_SESSION=ubuntu
LC_MONETARY=it_IT.UTF-8
SSH_AGENT_PID=1649
ANDROIDAPI=27
GTK_MODULES=gail:atk-bridge
PWD=/home/albi/CUCINA/.buildozer
PACKAGES_PATH=/home/albi/.buildozer/android/packages
XDG_SESSION_DESKTOP=ubuntu
LOGNAME=albi
XDG_SESSION_TYPE=x11
GPG_AGENT_INFO=/run/user/1000/gnupg/S.gpg-agent:0:1
ANDROIDNDK=/home/albi/.buildozer/android/platform/android-ndk-r19c
XAUTHORITY=/run/user/1000/gdm/Xauthority
GJS_DEBUG_TOPICS=JS ERROR;JS LOG
WINDOWPATH=2
HOME=/home/albi
USERNAME=albi
IM_CONFIG_PHASE=1
LC_PAPER=it_IT.UTF-8
LANG=en_US.UTF-8
LS_COLORS=rs=0:di=01;34:ln=01;36:mh=00:pi=40;33:so=01;35:do=01;35:bd=40;33;01:cd=40;33;01:or=40;31;01:mi=00:su=37;41:sg=30;43:ca=30;41:tw=30;42:ow=34;42:st=37;44:ex=01;32:*.tar=01;31:*.tgz=01;31:*.arc=01;31:*.arj=01;31:*.taz=01;31:*.lha=01;31:*.lz4=01;31:*.lzh=01;31:*.lzma=01;31:*.tlz=01;31:*.txz=01;31:*.tzo=01;31:*.t7z=01;31:*.zip=01;31:*.z=01;31:*.dz=01;31:*.gz=01;31:*.lrz=01;31:*.lz=01;31:*.lzo=01;31:*.xz=01;31:*.zst=01;31:*.tzst=01;31:*.bz2=01;31:*.bz=01;31:*.tbz=01;31:*.tbz2=01;31:*.tz=01;31:*.deb=01;31:*.rpm=01;31:*.jar=01;31:*.war=01;31:*.ear=01;31:*.sar=01;31:*.rar=01;31:*.alz=01;31:*.ace=01;31:*.zoo=01;31:*.cpio=01;31:*.7z=01;31:*.rz=01;31:*.cab=01;31:*.wim=01;31:*.swm=01;31:*.dwm=01;31:*.esd=01;31:*.jpg=01;35:*.jpeg=01;35:*.mjpg=01;35:*.mjpeg=01;35:*.gif=01;35:*.bmp=01;35:*.pbm=01;35:*.pgm=01;35:*.ppm=01;35:*.tga=01;35:*.xbm=01;35:*.xpm=01;35:*.tif=01;35:*.tiff=01;35:*.png=01;35:*.svg=01;35:*.svgz=01;35:*.mng=01;35:*.pcx=01;35:*.mov=01;35:*.mpg=01;35:*.mpeg=01;35:*.m2v=01;35:*.mkv=01;35:*.webm=01;35:*.ogm=01;35:*.mp4=01;35:*.m4v=01;35:*.mp4v=01;35:*.vob=01;35:*.qt=01;35:*.nuv=01;35:*.wmv=01;35:*.asf=01;35:*.rm=01;35:*.rmvb=01;35:*.flc=01;35:*.avi=01;35:*.fli=01;35:*.flv=01;35:*.gl=01;35:*.dl=01;35:*.xcf=01;35:*.xwd=01;35:*.yuv=01;35:*.cgm=01;35:*.emf=01;35:*.ogv=01;35:*.ogx=01;35:*.aac=00;36:*.au=00;36:*.flac=00;36:*.m4a=00;36:*.mid=00;36:*.midi=00;36:*.mka=00;36:*.mp3=00;36:*.mpc=00;36:*.ogg=00;36:*.ra=00;36:*.wav=00;36:*.oga=00;36:*.opus=00;36:*.spx=00;36:*.xspf=00;36:
XDG_CURRENT_DESKTOP=ubuntu:GNOME
VIRTUAL_ENV=/home/albi/CUCINA/.buildozer/venv
VTE_VERSION=6001
GNOME_TERMINAL_SCREEN=/org/gnome/Terminal/screen/66ea9009_ef14_420d_ae9a_ff4590d07de8
INVOCATION_ID=5f9f2518374145c29f2f6ad18acfb7f8
MANAGERPID=1473
CLUTTER_IM_MODULE=ibus
GJS_DEBUG_OUTPUT=stderr
LESSCLOSE=/usr/bin/lesspipe %s %s
XDG_SESSION_CLASS=user
LC_IDENTIFICATION=it_IT.UTF-8
TERM=xterm-256color
LESSOPEN=| /usr/bin/lesspipe %s
USER=albi
ANDROIDMINAPI=21
GNOME_TERMINAL_SERVICE=:1.140
DISPLAY=:0
SHLVL=1
LC_TELEPHONE=it_IT.UTF-8
QT_IM_MODULE=ibus
LC_MEASUREMENT=it_IT.UTF-8
XDG_RUNTIME_DIR=/run/user/1000
PS1=(venv)
LC_TIME=it_IT.UTF-8
ANDROIDSDK=/home/albi/.buildozer/android/platform/android-sdk
JOURNAL_STREAM=9:32116
XDG_DATA_DIRS=/usr/share/ubuntu:/usr/local/share/:/usr/share/:/var/lib/snapd/desktop
PATH=/home/albi/CUCINA/.buildozer/venv/bin:/home/albi/.buildozer/android/platform/apache-ant-1.9.4/bin:/home/albi/.local/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin
GDMSESSION=ubuntu
DBUS_SESSION_BUS_ADDRESS=unix:path=/run/user/1000/bus
LC_NUMERIC=it_IT.UTF-8
OLDPWD=/home/albi
_=/usr/bin/env
# Run 'pip install Kivy-Garden==0.1.1'
# Cwd None
Requirement already satisfied: Kivy-Garden==0.1.1 in ./.buildozer/venv/lib/python3.8/site-packages (0.1.1)
Requirement already satisfied: requests in ./.buildozer/venv/lib/python3.8/site-packages (from Kivy-Garden==0.1.1) (2.23.0)
Requirement already satisfied: certifi>=2017.4.17 in ./.buildozer/venv/lib/python3.8/site-packages (from requests->Kivy-Garden==0.1.1) (2020.4.5.2)
Requirement already satisfied: idna<3,>=2.5 in ./.buildozer/venv/lib/python3.8/site-packages (from requests->Kivy-Garden==0.1.1) (2.9)
Requirement already satisfied: urllib3!=1.25.0,!=1.25.1,<1.26,>=1.21.1 in ./.buildozer/venv/lib/python3.8/site-packages (from requests->Kivy-Garden==0.1.1) (1.25.9)
Requirement already satisfied: chardet<4,>=3.0.2 in ./.buildozer/venv/lib/python3.8/site-packages (from requests->Kivy-Garden==0.1.1) (3.0.4)
# Create directory /home/albi/CUCINA/.buildozer/libs
# Install garden package mapview in buildozer_dir
# Run 'garden install --app mapview'
# Cwd /home/albi/CUCINA/.buildozer
Downloading http://github.com/kivy-garden/garden.mapview/archive/master.zip ...
Traceback (most recent call last):
File "/home/albi/CUCINA/.buildozer/venv/bin/garden", line 189, in <module>
GardenTool().main(sys.argv[1:])
File "/home/albi/CUCINA/.buildozer/venv/bin/garden", line 71, in main
options.func()
File "/home/albi/CUCINA/.buildozer/venv/bin/garden", line 109, in cmd_install
fd = self.download(opts.package)
File "/home/albi/CUCINA/.buildozer/venv/bin/garden", line 170, in download
data += buf
TypeError: can only concatenate str (not "bytes") to str
# Command failed: garden install --app mapview
# ENVIRONMENT:
# PATH = '/home/albi/CUCINA/.buildozer/venv/bin:/home/albi/.buildozer/android/platform/apache-ant-1.9.4/bin:/home/albi/.local/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin'
# PACKAGES_PATH = '/home/albi/.buildozer/android/packages'
# ANDROIDSDK = '/home/albi/.buildozer/android/platform/android-sdk'
# ANDROIDNDK = '/home/albi/.buildozer/android/platform/android-ndk-r19c'
# ANDROIDAPI = '27'
# ANDROIDMINAPI = '21'
# VIRTUAL_ENV = '/home/albi/CUCINA/.buildozer/venv'
# CC = '/bin/false'
# CXX = '/bin/false'
#
# Buildozer failed to execute the last command
# The error might be hidden in the log above this error
# Please read the full log, and search for it before
# raising an issue with buildozer itself.
# In case of a bug report, please add a full log with log_level = 2
albi#albi-VirtualBox:~/CUCINA$
I have tried everything I found on Stack Overflow, but nothing worked. Any suggestion?
The problematic error stems from this piece of information here:
Kivy-Garden==0.1.1
I had the same issue, buildozer, for some weird reason installs Kivy-Garden version 0.1.1 which produces that error when you try to install ANY garden flower. Kivy version 1.11.1 now uses Kivy-Garden>=0.1.4 which works without issues.
If you install Kivy-Garden==0.1.1 and try to install a package, it crushes with that error. However, If you upgrade to Kivy-Garden==0.1.4. The problem is that buildozer will install Kivy-Garden==0.1.1 no matter what you do. So I tried a lot of things from downgrading buildozer to manually activating the environment that buildozer creates and upgrading garden there but when you run the buildozer command again. Buildozer will simply overwrite your upgraded garden AND install the non-working 0.1.1.
Finally I just gave up and did the one thing I COULD do at this moment. Simply fix buildozer myself:
Activate your environment(assuming you have one)
Go to where buildozer is installed. In my case this is: /home/samuel/repo/mobile/venv/finager/lib/python3.7/site-packages/buildozer-1.2.0.dev0-py3.7.egg/buildozer/__init__.py. You can find that out by checking the paths in your logs.
Now go to Line 533 and change where it says pip install Kivy-Garden==0.1.1 to pip install Kivy-Garden==0.1.4
That's it, your problem should go away now.
I hope they fix this soon as this is a pretty simple thing to do. Kivy itself requires Kivy-Garden>=0.1.4 which makes me wonder why buildozer would want 0.1.1 when it clearly doesn't work

Buildozer Error: Could not create service of type FileHasher using GradleUserHomeScopeServices.createCachingFileHasher()

In order to create the .apk file that will be able to be run on an android phone, I decided to use the kivy virtual machine to run buildozer on Linux. I was able to setup the buildozer.spec and the main.py, but when I ran buildozer android debug deploy run, it gave me this error message
Error Message
This is the buildozer.spec file
Buildozer.spec
And this is the main.py
import kivy
from kivy.app import App
import cv2
from kivy.uil.label import Label
class SimpleKivy(object):
def build(self):
return Label(text="Hello World!")
if __name__ == "__main__":
SimpleKivy().run()

Build apk using buildozer and kivy Error with gradlew (new project)

I have been able to build an .apk file by kivy and python2.7 using buildozer, and the app works fine on phone-device. After a while, i started a new project in a new folder (together with new main.py), but when i do buildozer android debug, the Error attached keeps coming out, something with gradlew. In my previous builds, this never happens.
In this new main.py, i previously use numpy module, but this module cause Error also in the build-up. So i removed it and rewrite the code. Now another Error occurs (the Error because gradlew).
I have tried added android in the requirements. Does not work. (although i prefer to use the default buildozer.spec).
I appreciate some inputs on this.
*Also, i found some official resources, either from Github or the buildozer site are a bit inconsistent. Is there a detail resource such that i may install buildozer correctly, also the guide for the buildozer.specs?
I even not fully remember why the previous app works well..because i also bumped into several problems before the 1st App works fine.
** When i debug the new main.py in the old folder, the build process succeed.**
** (I also use the same package.name and package.domain as the 1st App) **
Thanks in advance.
STDERR:
[INFO]: STDOUT:
Unzipping /home/kivy/.gradle/wrapper/dists/gradle-3.3-all/2n0i7hqatcbtk57vvql575dbap/gradle-3.3-all.zip to /home/kivy/.gradle/wrapper/dists/gradle-3.3-all/2n0i7hqatcbtk57vvql575dbap
Exception in thread "main" java.util.zip.ZipException: error in opening zip file
at java.util.zip.ZipFile.open(Native Method)
at java.util.zip.ZipFile.<init>(ZipFile.java:225)
at java.util.zip.ZipFile.<init>(ZipFile.java:155)
at java.util.zip.ZipFile.<init>(ZipFile.java:169)
at org.gradle.wrapper.Install.unzip(Install.java:157)
at org.gradle.wrapper.Install.access$400(Install.java:26)
at org.gradle.wrapper.Install$1.call(Install.java:67)
at org.gradle.wrapper.Install$1.call(Install.java:44)
at org.gradle.wrapper.ExclusiveFileAccessManager.access(ExclusiveFileAccessManager.java:65)
at org.gradle.wrapper.Install.createDist(Install.java:44)
at org.gradle.wrapper.WrapperExecutor.execute(WrapperExecutor.java:126)
at org.gradle.wrapper.GradleWrapperMain.main(GradleWrapperMain.java:56)
[INFO]: STDERR:
[INFO]: COMMAND:
cd /home/kivy/Desktop/blablaapp/.buildozer/android/platform/build/dists/myapp && ./gradlew assembleDebug
[WARNING]: ERROR: ./gradlew failed!
# Command failed: /usr/bin/python -m pythonforandroid.toolchain apk --debug --bootstrap=sdl2 --dist_name myapp --name 'My Application' --version 0.1 --package org.test.myapp --android_api 19 --minsdk 9 --private /home/kivy/Desktop/sudoku_newbie/.buildozer/android/app --orientation portrait --window --copy-libs --arch armeabi-v7a --color=always --storage-dir=/home/kivy/Desktop/sudoku_newbie/.buildozer/android/platform/build
#
# Buildozer failed to execute the last command
# The error might be hidden in the log above this error
# Please read the full log, and search for it before
# raising an issue with buildozer itself.
# In case of a bug report, please add a full log with log_level = 2
This error mostly occurs when you've interrupted the system when Gradle was downloading.
You can simply fix this by manually downloading gradle from https://services.gradle.org/distributions/gradle-4.4-all.zip
Then replace the gradle-4.4-all.zip.part in /your/home/path/.gradle/wrapper/dists/gradle-4.4-all/4th6d42q1kgladv9hkn2iehgi5 with the new dowloaded file
I had the same problem to solve mine I downloaded an earlier version of buildozer and it worked

Buildozer Numpy RuntimeError: Broken toolchain: cannot link a simple C program

Writing my first Android app in Python and using Buildozer to package it. Because I will need to use numpy later on in the project, I tried packaging the following test code:
import numpy
import kivy
kivy.require('1.0.6')
from kivy.app import App
from kivy.uix.button import Button
class TestApp(App):
def build(self):
return Button(text='Hello World')
TestApp().run()
However, I got the following error:
Traceback (most recent call last):
File "setup.py", line 251, in <module>
setup_package()
File "setup.py", line 243, in setup_package
setup(**metadata)
File "/home/kivy/Desktop/cam/.buildozer/android/platform/build/build/other_builds/numpy/armeabi-v7a/numpy/numpy/distutils/core.py", line 169, in setup
return old_setup(**new_attr)
File "/home/kivy/Desktop/cam/.buildozer/android/platform/build/build/python-installs/myapp/lib/python2.7/distutils/core.py", line 152, in setup
dist.run_commands()
File "/home/kivy/Desktop/cam/.buildozer/android/platform/build/build/python-installs/myapp/lib/python2.7/distutils/dist.py", line 953, in run_commands
self.run_command(cmd)
File "/home/kivy/Desktop/cam/.buildozer/android/platform/build/build/python-installs/myapp/lib/python2.7/distutils/dist.py", line 972, in run_command
cmd_obj.run()
File "/home/kivy/Desktop/cam/.buildozer/android/platform/build/build/other_builds/numpy/armeabi-v7a/numpy/numpy/distutils/command/build_ext.py", line 59, in run
self.run_command('build_src')
File "/home/kivy/Desktop/cam/.buildozer/android/platform/build/build/python-installs/myapp/lib/python2.7/distutils/cmd.py", line 326, in run_command
self.distribution.run_command(command)
File "/home/kivy/Desktop/cam/.buildozer/android/platform/build/build/python-installs/myapp/lib/python2.7/distutils/dist.py", line 972, in run_command
cmd_obj.run()
File "/home/kivy/Desktop/cam/.buildozer/android/platform/build/build/other_builds/numpy/armeabi-v7a/numpy/numpy/distutils/command/build_src.py", line 153, in run
self.build_sources()
File "/home/kivy/Desktop/cam/.buildozer/android/platform/build/build/other_builds/numpy/armeabi-v7a/numpy/numpy/distutils/command/build_src.py", line 164, in build_sources
self.build_library_sources(*libname_info)
File "/home/kivy/Desktop/cam/.buildozer/android/platform/build/build/other_builds/numpy/armeabi-v7a/numpy/numpy/distutils/command/build_src.py", line 299, in build_library_sources
sources = self.generate_sources(sources, (lib_name, build_info))
File "/home/kivy/Desktop/cam/.buildozer/android/platform/build/build/other_builds/numpy/armeabi-v7a/numpy/numpy/distutils/command/build_src.py", line 386, in generate_sources
source = func(extension, build_dir)
File "numpy/core/setup.py", line 686, in get_mathlib_info
raise RuntimeError("Broken toolchain: cannot link a simple C program")
RuntimeError: Broken toolchain: cannot link a simple C program
STDERR:
# Command failed: /usr/bin/python -m pythonforandroid.toolchain create --dist_name=myapp --bootstrap=sdl2 --requirements=kivy,numpy --arch armeabi-v7a --copy-libs --color=always --storage-dir=/home/kivy/Desktop/cam/.buildozer/android/platform/build
#
# Buildozer failed to execute the last command
# The error might be hidden in the log above this error
# Please read the full log, and search for it before
# raising an issue with buildozer itself.
# In case of a bug report, please add a full log with log_level = 2
Also, here is my buildozer.spec file:
title = My Application
package.name = myapp
package.domain = org.test
source.dir = .
source.include_exts = py,png,jpg,kv,atlas
version = 1.0
requirements = kivy,numpy
orientation = portrait
osx.kivy_version = 1.9.1
fullscreen = 0
android.api = 19
android.sdk = 20
android.ndk = 9c
android.arch = armeabi-v7a
log_level = 2
warn_on_root = 1
Note that when I removed "import numpy" from the python code and removed "numpy" from the requirements list in the buildozer.spec file, my code was packaged perfectly. I am running this on VM Virtual Box which had Buildozer pre-installed.
Also it is not just Numpy giving me this issue- OpenCV is giving me the exact same errors. Will make separate post for that if needed.
This issue is reported in Python for Android (p4a) project here, didn't knew it's actual for stable p4a. Nevertheless, by link you can find PR that fixes issue. I didn't test it, but different people say it works.
You can try to build numpy with this fix, here's what you'll need:
Make sure you clean all left from current building process with command:
buildozer distclean
Clone p4a branch with fix using command:
git clone -b p4a_numpy_fix https://github.com/mahomahomaho/python-for-android fix-numpy
Change your buildozer.spec to use this cloned version of p4a (use your actual path):
p4a.source_dir = /home/ubuntu/p4a_numpy_fix
And run building apk again. If everything will work fine, you'll be able to build apk. If not you'll face another errors, no guarantees here :(

How to run a kivy script in the kivy VM?

So I am looking into using Kivy for Android development. Defeating the jedi etc.
But I have hit a roadblock! I installed the Kivy VM image in VirtualBox, but when I try to run the test script:
# /usr/bin/kivy
__version__ = 1.0
from kivy.app import App
from kivy.uix.button import Button
class Hello(App):
def build(self):
btn = Button(text='Hello World')
return btn
Hello().run()
Using:
python main.py
I get:
Traceback (most recent call last):
File "main.py", line 3, in <module>
from kivy.app import App
ImportError: No module named kivy.app
do you have a file named kivy.py in the same folder as main.py?
try
#!/usr/bin/kivy
import kivy
print kivy.__file__
I tried just plain installing kivy as they say to on their website, and it worked.
sudo add-apt-repository ppa:kivy-team/kivy
apt-get install python-kivy

Categories

Resources