IddoB
Posts: 56
Joined: Wed Aug 23, 2017 4:39 pm

Problems when installing package

Thu Sep 28, 2017 10:29 am

Hi there,

I am working on a project that includes a LCD. I am using Thonny to write my code and I tried to install the package smbus cffi.
Each time I try I get the same error:

Command "python setup.py egg_info" failed with error code 1 in /tmp/pip-build-3e0xsufc/smbus-cffi/
https://gyazo.com/b274d4fd6763039ce1d6ecc1e3be0e17

When I run the commands (Of the LCD in the Python Shell) they all work fine and the LCD works... Im not sure whats going on in the Thonny IDE, if you have better IDE Id be happy to hear.

Thank you,
Iddo

IddoB
Posts: 56
Joined: Wed Aug 23, 2017 4:39 pm

Re: Problems when installing package

Sun Oct 01, 2017 11:58 am

Anyone can help?

User avatar
DougieLawson
Posts: 39300
Joined: Sun Jun 16, 2013 11:19 pm
Location: A small cave in deepest darkest Basingstoke, UK
Contact: Website Twitter

Re: Problems when installing package

Sun Oct 01, 2017 12:01 pm

Open an LXTerminal window and try sudo pip install python2-package-name or sudo pip3 install python3-package-name.

There's nothing wrong with Thonny, it's a massive step up from idle and idle3.
Note: Any requirement to use a crystal ball or mind reading will result in me ignoring your question.

Criticising any questions is banned on this forum.

Any DMs sent on Twitter will be answered next month.
All non-medical doctors are on my foes list.

IddoB
Posts: 56
Joined: Wed Aug 23, 2017 4:39 pm

Re: Problems when installing package

Mon Oct 02, 2017 5:26 am

Thank you for your input. The package is installed on the RPi already, and works in the terminal. It seems like Thonny has his own package folder.
I tried to install the package through the Thonny, but the shell isnt responding at all:
https://gyazo.com/9429179ac6966806cd49f7d6dad67b10

IddoB
Posts: 56
Joined: Wed Aug 23, 2017 4:39 pm

Re: Problems when installing package

Mon Oct 02, 2017 5:30 am

EDIT: I got it to work by putting the library folder in of the python file.

Return to “Python”