NorwegianClassic
Posts: 17
Joined: Mon Oct 19, 2015 8:33 am
Location: Bergen, Norway

Bash: kivy: command not found?

Sat Jan 14, 2017 5:07 pm

Hi there!

I'm trying to install Beautiful Soup 4 to use in my kivy app for my rpi 3, but I can quite get it too work.

When I use

Code: Select all

kivy -m pip install bs4
it returns bash: kivy: command not found.
I have tried to set the PYTHONPATH.

I saw that /usr/lib/python2.7/dist-packages/kivy doesn't exist, can this be a part of the problem?

User avatar
rpdom
Posts: 17275
Joined: Sun May 06, 2012 5:17 am
Location: Chelmsford, Essex, UK

Re: Bash: kivy: command not found?

Sat Jan 14, 2017 5:16 pm

Is kivy installed?

Try

Code: Select all

sudo apt-get update
sudo apt-get -y install python-kivy

NorwegianClassic
Posts: 17
Joined: Mon Oct 19, 2015 8:33 am
Location: Bergen, Norway

Re: Bash: kivy: command not found?

Sat Jan 14, 2017 5:51 pm

Yes I have. I tried the commands you posted just to be sure, and tried $kivy -m pip install bs4, but still no luck.

I can run the demos, so kivy works. But when I run my program that uses bs4, it returns:

Code: Select all

bs4.FeatureNotFound: Couldn't find a tree builder with the features you requested: lxml. Do you need to install a parser library?

User avatar
rpdom
Posts: 17275
Joined: Sun May 06, 2012 5:17 am
Location: Chelmsford, Essex, UK

Re: Bash: kivy: command not found?

Sat Jan 14, 2017 6:01 pm

That message looks like you haven't got lxml installed (a quick google confirmed this)

Code: Select all

sudo apt-get install python-lxml

NorwegianClassic
Posts: 17
Joined: Mon Oct 19, 2015 8:33 am
Location: Bergen, Norway

Re: Bash: kivy: command not found?

Sat Jan 14, 2017 6:40 pm

Thank you, that solved it! I thought bs4 and lxml did the same thing, so I thought I didn't need it! :D

Return to “Troubleshooting”