Problem Making New Django project - please help

102 views
Skip to first unread message

Shashwat singh

unread,
Dec 2, 2014, 4:59:30 AM12/2/14
to django...@googlegroups.com

Traceback (most recent call last):

  File "/Library/Frameworks/Python.framework/Versions/2.7/bin/django-admin.py", line 5, in <module>

    management.execute_from_command_line()

  File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/django/core/management/__init__.py", line 385, in execute_from_command_line

    utility.execute()

  File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/django/core/management/__init__.py", line 345, in execute

    settings.INSTALLED_APPS

  File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/django/conf/__init__.py", line 46, in __getattr__

    self._setup(name)

  File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/django/conf/__init__.py", line 42, in _setup

    self._wrapped = Settings(settings_module)

  File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/django/conf/__init__.py", line 98, in __init__

    % (self.SETTINGS_MODULE, e)

ImportError: Could not import settings 'my_project.settings' (Is it on sys.path? Is there an import error in the settings file?): No module named my_project.settings



PLEASE HELP WITH THIS 

Daniel Roseman

unread,
Dec 2, 2014, 6:59:37 AM12/2/14
to django...@googlegroups.com
On Tuesday, 2 December 2014 09:59:30 UTC, Shashwat singh wrote:

<snip>

PLEASE HELP WITH THIS 


Nobody can possibly help with this. This is a random error message. What were you doing when you got it? What did you type at the command line? What code do you have already?

And, please do not shout.
--
DR.

Florian Schweikert

unread,
Dec 2, 2014, 7:18:05 AM12/2/14
to django...@googlegroups.com
On 2014-12-02 10:59, Shashwat singh wrote:
> ImportError: Could not import settings 'my_project.settings' (Is it on
> sys.path? Is there an import error in the settings file?): No module
> named my_project.settings
>
> PLEASE HELP WITH THIS

there is not enough information to see the cause of the problem

what command did you run?
what was your cwd?
what does your project dir structure look like?

-- Florian

Shashwat singh

unread,
Dec 3, 2014, 10:36:34 AM12/3/14
to django...@googlegroups.com
Django is properly installed but when i try to create a new project --- " django-admin.py startproject abc " it returns ^^ that error. 
Any help will be highly appreciated.

Shashwat singh

unread,
Dec 3, 2014, 10:44:20 AM12/3/14
to django...@googlegroups.com, kel...@ist-total.org
Django is properly installed but when i try to create a new project --- " django-admin.py startproject abc " it returns ^^ that error. 
I've tried almost everything, but nothing seems to fix that.

Collin Anderson

unread,
Dec 4, 2014, 8:48:52 AM12/4/14
to django...@googlegroups.com, kel...@ist-total.org
Hi,

That is quite odd. Do you have the DJANGO_SETTINGS_MODULE set in your shell environment? (you shouldn't).

What version of Django are you using?

Are you doing this from your home directory?

Collin

Florian Schweikert

unread,
Dec 4, 2014, 11:48:38 AM12/4/14
to django...@googlegroups.com
starting new project with name abc throws the my_project.settings not
found? Then there is something wrong with the env_variables of your shell.

-- Florian

signature.asc

jogaserbia

unread,
Dec 4, 2014, 1:11:01 PM12/4/14
to django...@googlegroups.com
Are you trying to set it up in a virtualenv?  

Shashwat singh

unread,
Dec 5, 2014, 1:52:34 AM12/5/14
to django...@googlegroups.com, kel...@ist-total.org
Django version -- 1, 7, 1

And yes doing this from my home directory.


Shashwat singh

unread,
Dec 5, 2014, 1:56:34 AM12/5/14
to django...@googlegroups.com
No , it used to work perfectly on osx mavericks, then i did some stuff with opencv and since then i'm getting that error. I've tried each n every solution available on internet but nothing seems to solve that problem :/

Collin Anderson

unread,
Dec 6, 2014, 12:29:03 PM12/6/14
to django...@googlegroups.com
Hi,

Is your DJANGO_SETTINGS_MODULE set in your environment? You may need to clear that out before running django-admin.py

Something like one of these:

unset DJANGO_SETTINGS_MODULE
DJANGO_SETTINGS_MODULE= django-admin.py startproject
env -u DJANGO_SETTINGS_MODULE django-admin.py startproject

Collin
Reply all
Reply to author
Forward
0 new messages