Ticket #303 (closed defect: invalid)

Opened 5 years ago

Last modified 5 years ago

Respect DJANGO_SETTINGS_MODULE, --settings

Reported by: anonymous Owned by: andrew
Priority: major Milestone: 0.7
Component: commands Version: 0.6.2
Keywords: Cc:

Description

I have two settings profiles: one for production (settings) and one for development (settings.dev). I am seeing two problems, which seem related but may be separate:

$ export DJANGO_SETTINGS_MODULE="settings.dev"
$ ./manage.py migrate myapp my_migration

does not use settings.dev. In my case, I'm using a separate database for development. The migration is applied to my production database instead of the development.

./manage.py migrate --settings="settings.dev" ...
Unknown command: 'migrate'

Change History

comment:1 Changed 5 years ago by andrew

  • Status changed from new to assigned
  • Milestone set to 0.7

That's odd, South uses the standard Django machinery for configuration. I'll check this.

comment:2 Changed 5 years ago by andrew

Using --settings works for me on my dev box; did you forget to include south in settings.dev's installed apps?

comment:3 Changed 5 years ago by anonymous

andrew: you were right about south missing from settings.dev.

it looks like my manage.py imports settings (instead of using DJANGO_SETTINGS_MODULE).

therefore, this is invalid as far as I can tell.

comment:4 Changed 5 years ago by andrew

  • Status changed from assigned to closed
  • Resolution set to invalid

Marking as such.

Note: See TracTickets for help on using tickets.