mercadolibre / python-sdk

MercadoLibre's Python SDK
131 stars 111 forks source link

Can't import meli when running the included file 'teste.py' #33

Open Cajet0 opened 5 years ago

Cajet0 commented 5 years ago

Traceback (most recent call last): File "teste.py", line 3, in from meli import Meli ImportError: No module named meli

MarkRobles commented 5 years ago

I got the same...

dpw1 commented 4 years ago

Same here. Any help would be appreciated.

ignaciobartol commented 4 years ago

Maybe it's outdated but seems to be that you don't have the packages already installed. You should install the packages in your enviroment before running the code. You can search on google how to install packages in python because it depends if you're working on a distribution such as anaconda or miniconda, or if you're working in python from the basis. Anyway, I'll post two possible solutions for someone who could need it:

  1. open a terminal and run pip install git+https://github.com/mercadolibre/python-sdk.git (you may need to run pip with root permission, then run: sudo pip install git+https://github.com/mercadolibre/python-sdk.git) via setuptools:
  2. python setup.py install --user (or sudo python setup.py install to install the package for all users) via conda:
  3. run: conda install pip (which will install the git pip manager in conda) then run: pip install git+https://github.com/mercadolibre/python-sdk.git

And that's all, try to re-run your code and it should work.

PD: I work with macOS and Linux, I don't know if it's the same on Windows.