Changes between Initial Version and Version 1 of Ticket #12231
- Timestamp:
- Nov 16, 2009, 9:46:31 PM (15 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
Ticket #12231 – Description
initial v1 1 1 If by example your django is in an egg like 2 2 {{{ 3 3 my.site.project 4 4 }}} 5 5 If you call the django core execution manager with: 6 6 {{{ 7 7 mod = __import__('my.site.project') 8 8 django.core.management.execute_manager(mod) 9 9 }}} 10 10 Your project will not be found cause the django core is declaring the main DJANGO_SETTINGS_MODULE with: 11 11 12 12 django.core.management.__init__: 13 {{{ 13 14 ... 14 15 project_directory, settings_filename = os.path.split(p) … … 19 20 os.environ['DJANGO_SETTINGS_MODULE = '%s.%s' % (project_name, settings_name) 20 21 ... 21 22 }}} 22 23 The project_name variable represent only the first level of the project egg. It could not work with a multilevel package and we now have to use the variable 'original_settings_path' which is just optional. 23 24