Django

Code

Ticket #4299 (reopened)

Opened 2 years ago

Last modified 1 year ago

remove code duplication in postgresql and postgresql_psycopg2 backends

Reported by: Gary Wilson <gary.wilson@gmail.com> Assigned to: nobody
Milestone: Component: Database layer (models, ORM)
Version: SVN Keywords:
Cc: Triage Stage: Accepted
Has patch: 0 Needs documentation: 0
Needs tests: 0 Patch needs improvement: 0

Description

Their base.py and introspection.py modules are almost identical and cause bugs to have to be fixed in both places.

Attachments

Change History

08/20/07 04:37:51 changed by Simon G. <dev@simon.net.nz>

  • needs_better_patch changed.
  • stage changed from Unreviewed to Accepted.
  • needs_tests changed.
  • needs_docs changed.

09/13/07 23:29:27 changed by bp@barryp.org

  • status changed from new to closed.
  • resolution set to fixed.

Duplicated in #5106 and taken care of there, starting with [5949]?

09/13/07 23:37:15 changed by Barry Pederson <bp@barryp.org>

  • status changed from closed to reopened.
  • resolution deleted.

09/13/07 23:37:35 changed by Barry Pederson <bp@barryp.org>

  • status changed from reopened to closed.
  • resolution set to duplicate.

09/14/07 00:30:43 changed by gwilson

  • status changed from closed to reopened.
  • resolution deleted.

No duplication was removed from the modules listed in the ticket description though in all of that refactoring.

09/14/07 00:33:40 changed by gwilson

(In [6165]) Refs #4299 -- Removed some code duplication in the postgresql introspection modules by letting the postgresql_psycopg2 backend use identical functions from the postgresql backend.

09/14/07 00:50:55 changed by gwilson

  • status changed from reopened to closed.
  • resolution set to fixed.

The base modules don't really have that much duplication except for in the DatabaseWrapper class, and subclassing one from the other probably isn't worth it.

09/14/07 01:22:11 changed by jason

  • status changed from closed to reopened.
  • resolution deleted.

Fix imports from django.db.backends.postgresql.introspection, which imports db.backend.postgresql.base and thus psycopg in the psycopg2 backend.

09/14/07 08:49:47 changed by gwilson

[6165] backed out in [6171].


Add/Change #4299 (remove code duplication in postgresql and postgresql_psycopg2 backends)




Change Properties
Action