I have a simple django app. It works fine in the browser. But when I attempt to start an interactive console by typing:
> python manage.py console
I get an error: ImportError: No module named shopify
shopify is an api library that I installed via this command:
pip install --user shopifyAPI
in my models and views, import the shopify package with, simply:
import shopify
And everything works fine. But I can't even start an interactive console. Do I somehow need to let django know about my external library in order to use the interactive console? If so, how do I do that, or where do I learn more about it? I'm a newbie, and I'm kind of lost.
Here's the full error message I get when I try to start a console:
22:35 ~/tsb $ python manage.py shell
Traceback (most recent call last): File "manage.py", line 22, in <module> execute_from_command_line(sys.argv) File "/usr/local/lib/python2.7/dist-packages/django/core/management/init.py", line 367, in execute_from_command_line utility.execute() File "/usr/local/lib/python2.7/dist-packages/django/core/management/init.py", line 341, in execute django.setup() File "/usr/local/lib/python2.7/dist-packages/django/init.py", line 27, in setup apps.populate(settings.INSTALLED_APPS) File "/usr/local/lib/python2.7/dist-packages/django/apps/registry.py", line 108, in populate app_config.import_models(all_models) File "/usr/local/lib/python2.7/dist-packages/django/apps/config.py", line 199, in import_mod els self.models_module = import_module(models_module_name) File "/usr/lib/python2.7/importlib/init.py", line 37, in import_module import(name) File "/home/cthventures/tsb/barcode/models.py", line 3, in <module> import shopify ImportError: No module named shopify