Opened 4 years ago

Closed 3 years ago

#18053 closed Bug (duplicate)

empty DATABASES blows up in 1.4

Reported by: anonymous Owned by: nobody
Component: Database layer (models, ORM) Version: 1.4
Severity: Normal Keywords:
Cc: Triage Stage: Accepted
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no


In Django 1.3 if we didn't have any databases we had to set DATABASES to {}, but now in 1.4 things blow up with that setting. It would be better if it behaved the same as we can't easily migrate our systems to 1.4. The errors are triggered when a support class or shortcut is used or imported and imports django.db.*.

Change History (3)

comment:1 Changed 4 years ago by carljm

  • Component changed from Uncategorized to Database layer (models, ORM)
  • Needs documentation unset
  • Needs tests unset
  • Patch needs improvement unset
  • Triage Stage changed from Unreviewed to Accepted

comment:2 Changed 4 years ago by ptone

Ideally it would be nice to see if this can be fixed by examining the places where db/init is being invoked by import and factor those parts that actually need the db, vs those that don't. IOW see what it would take to allow a truly blank databases setting at the global conf level. The simpler fix would be to special check for a blank databases in db/init and set the dummy backend as in global settings.

comment:3 Changed 3 years ago by claudep

  • Resolution set to duplicate
  • Status changed from new to closed

See #18575.

Note: See TracTickets for help on using tickets.
Back to Top