From 156cdcf92decdf18a87a1229ba4ef8da1e6972ab Mon Sep 17 00:00:00 2001 From: Russell Keith-Magee Date: Tue, 23 Feb 2010 12:24:41 +0000 Subject: Fixed #12912 -- Placed the psycopg1-backed ``postgresql`` database backend on the deprecation path. git-svn-id: http://code.djangoproject.com/svn/django/trunk@12510 bcc190cf-cafb-0310-a4f2-bffc1f526a37 --- django/db/backends/postgresql/base.py | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'django') diff --git a/django/db/backends/postgresql/base.py b/django/db/backends/postgresql/base.py index 5681311a65..5352e9bff6 100644 --- a/django/db/backends/postgresql/base.py +++ b/django/db/backends/postgresql/base.py @@ -102,6 +102,12 @@ class DatabaseWrapper(BaseDatabaseWrapper): def __init__(self, *args, **kwargs): super(DatabaseWrapper, self).__init__(*args, **kwargs) + import warnings + warnings.warn( + 'The ``postgres`` backend has been deprecated. Use ``postgres_psycopg2`` instead.', + PendingDeprecationWarning + ) + self.features = DatabaseFeatures() self.ops = DatabaseOperations(self) self.client = DatabaseClient(self) -- cgit v1.3