]> git.ipfire.org Git - thirdparty/sqlalchemy/sqlalchemy.git/commit
- Duplicate items in a list-based collection will
authorMike Bayer <mike_mp@zzzcomputing.com>
Tue, 25 Nov 2008 04:43:04 +0000 (04:43 +0000)
committerMike Bayer <mike_mp@zzzcomputing.com>
Tue, 25 Nov 2008 04:43:04 +0000 (04:43 +0000)
commit332f5ee2662835ed1ca008043d40c37d7cddc270
treea173fd7bb9f624490a9456ded43ba3b19849caf4
parente3502f7f9d9b68d718a517a3d17f5bdd2aaa86c7
- Duplicate items in a list-based collection will
be maintained when issuing INSERTs to
a "secondary" table in a many-to-many relation.
Assuming the m2m table has a unique or primary key
constraint on it, this will raise the expected
constraint violation instead of silently
dropping the duplicate entries. Note that the
old behavior remains for a one-to-many relation
since collection entries in that case
don't result in INSERT statements and SQLA doesn't
manually police collections. [ticket:1232]
CHANGES
lib/sqlalchemy/orm/attributes.py
test/orm/attributes.py
test/orm/manytomany.py