Fix upgrading database settings.
Review Request #3684 — Created Dec. 19, 2012 and submitted
Fix upgrading database settings. We had two problems with the upgrade of database settings. The first was that we never properly migrated postgresql backends to have the full module path, which meant that we had a new-style DATABASES, but an old-style engine value. The second is that, starting in Django 1.4, the old-style engine names are deprecated, and the settings file was cached prior to the settings upgrade. So in both the above case and a move from an old version with DATABASE_ENGINE, we ended up with the old values still in settings, and that broke the upgrading. We're now upgrading the postgresql setting, and we're also reloading the settings so that we can use them during DB upgrade.
Created a site that had an ENGINE of 'postgres_psycopg2'. Upgraded it and verified that the proper engine path was set. Also tested the above case and the case of an old DATABASE_ENGINE setting. Prior to this, both failed with an error since the old settings were used. After, both cases worked fine.
Description | From | Last Updated |
---|---|---|
I know we don't do it often, but can we put the binary operators at the beginning of the line? … |
david |