]> git.ipfire.org Git - thirdparty/sqlalchemy/sqlalchemy.git/commit
Remove errant assertion from unit of work
authorMike Bayer <mike_mp@zzzcomputing.com>
Sat, 23 Jan 2021 23:02:17 +0000 (18:02 -0500)
committerMike Bayer <mike_mp@zzzcomputing.com>
Sun, 24 Jan 2021 21:38:36 +0000 (16:38 -0500)
commitd446d8df1b2456c3444a4e0ebc0cb76ef03afac5
tree8f0b7ffe733d33fa3a76d085fd4544816477cdb2
parent33b12754f9aa0aaee2bdac01faeade7ecc93f028
Remove errant assertion from unit of work

Fixed ORM unit of work regression where an errant "assert primary_key"
statement interferes with primary key generation sequences that don't
actually consider the columns in the table to use a real primary key
constraint, instead using :paramref:`_orm.mapper.primary_key` to establish
certain columns as "primary".

Also remove errant "identity" requirement which does not seem to
represent any current backend and is applied to
test/sql/test_defaults.py->AutoIncrementTest, but these tests work
on all backends.

Fixes: #5867
Change-Id: I4502ca5079d824d7b4d055194947aa1a00effde7
doc/build/changelog/unreleased_14/5867.rst [new file with mode: 0644]
lib/sqlalchemy/orm/persistence.py
test/orm/test_unitofworkv2.py
test/requirements.py
test/sql/test_defaults.py