Opened 14 years ago

Closed 14 years ago

Last modified 13 years ago

#13428 closed (fixed)

Multi-db router documentation example doesn't work as written.

Reported by: Cliff Dyer Owned by: Cliff Dyer
Component: Documentation Version: dev
Severity: Keywords: multidb model documentation
Cc: Triage Stage: Accepted
Has patch: yes Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no

Description

The MasterSlaveRouter.allow_relation example method documented in /docs/topics/db/multi-db.txt doesn't work as written. It checks if a model instance is in a list of strings representing the names of the various databases. It should check obj._state.db on each of those objects rather than checking obj directly.

Attachments (1)

allow_relation_example.diff (578 bytes ) - added by Cliff Dyer 14 years ago.
Patch to fix code example in multi-db documentation.

Download all attachments as: .zip

Change History (4)

by Cliff Dyer, 14 years ago

Attachment: allow_relation_example.diff added

Patch to fix code example in multi-db documentation.

comment:1 by Russell Keith-Magee, 14 years ago

Triage Stage: UnreviewedAccepted

comment:2 by Russell Keith-Magee, 14 years ago

Resolution: fixed
Status: newclosed

(In [13133]) Fixed #13428 -- Corrected the allow_relation behavior of and example router. Thanks to jcd for the report and patch.

comment:3 by Jacob, 13 years ago

milestone: 1.2

Milestone 1.2 deleted

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