Author: adrian
Date: 2007-01-24 18:52:05 -0600 (Wed, 24 Jan 2007)
New Revision: 4424
Modified:
django/trunk/django/core/management.py
Log:
Fixed #3299 -- Added 'site' to the list of INVALID_PROJECT_NAMES and improved
the error message. Thanks for the patch, ubernostrum
Modified: django/trunk/django/core/management.py
===================================================================
--- django/trunk/django/core/management.py 2007-01-25 00:47:44 UTC (rev
4423)
+++ django/trunk/django/core/management.py 2007-01-25 00:52:05 UTC (rev
4424)
@@ -25,7 +25,7 @@
# which has been installed.
PROJECT_TEMPLATE_DIR = os.path.join(django.__path__[0], 'conf', '%s_template')
-INVALID_PROJECT_NAMES = ('django', 'test')
+INVALID_PROJECT_NAMES = ('django', 'site', 'test')
# Set up the terminal color scheme.
class dummy: pass
@@ -708,7 +708,7 @@
"Creates a Django project for the given project_name in the given
directory."
from random import choice
if project_name in INVALID_PROJECT_NAMES:
- sys.stderr.write(style.ERROR("Error: %r isn't a valid project name.
Please try another.\n" % project_name))
+ sys.stderr.write(style.ERROR("Error: '%r' conflicts with the name of
an existing Python module and cannot be used as a project name. Please try
another name.\n" % project_name))
sys.exit(1)
_start_helper('project', project_name, directory)
# Create a random SECRET_KEY hash, and put it in the main settings.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Django updates" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/django-updates?hl=en
-~----------~----~----~----~------~----~------~--~---