python - Django ImportError from django.core.management -
i have tried make work
#!/usr/bin/env python import os import sys if __name__ == "__main__": os.environ.setdefault("django_settings_module", "leke.settings") try: django.core.management import execute_from_command_line except importerror: # above import may fail other reason. ensure # issue django missing avoid masking other # exceptions on python 2. try: import django except importerror: raise importerror( "couldn't import django. sure it's installed , " "available on pythonpath environment variable? did " "forget activate virtual environment?" ) raise execute_from_command_line(sys.argv)
please that's error have been getting manager.py . thanks
django might not able install package. i'm not sure solution did trick me.
sudo pip install django --upgrade
and if error of pakage psycopg2 install first
sudo pip install psycopg2 --upgrade
tell me if works.
also try use on pytohn3+
if still doesn't work try django-configurations¶
Comments
Post a Comment