summaryrefslogtreecommitdiff
path: root/test/dialect/postgresql/test_compiler.py
diff options
context:
space:
mode:
authorMike Bayer <mike_mp@zzzcomputing.com>2022-01-21 10:19:02 -0500
committerMike Bayer <mike_mp@zzzcomputing.com>2022-01-21 23:31:29 -0500
commit8a1931601d3b105ad585ef39840c8251ebdb44a2 (patch)
treeed21f98d35c2aad2222b5bf696cb100d609db08b /test/dialect/postgresql/test_compiler.py
parent7d9b811555a88dd2f1cb1520027546b87383e159 (diff)
downloadsqlalchemy-8a1931601d3b105ad585ef39840c8251ebdb44a2.tar.gz
Skip PK returned as None for RETURNING, server side default
Fixed regression where the ORM exception that is to be raised when an INSERT silently fails to actually insert a row (such as from a trigger) would not be reached, due to a runtime exception raised ahead of time due to the missing primary key value, thus raising an uninformative exception rather than the correct one. For 1.4 and above, a new ``FlushError`` is added for this case that's raised earlier than the previous "null identity" exception was for 1.3, as a situation where the number of rows actually INSERTed does not match what was expected is a more critical situation in 1.4 as it prevents batching of multiple objects from working correctly. This is separate from the case where a newly fetched primary key is fetched as NULL, which continues to raise the existing "null identity" exception. Fixes: #7594 Change-Id: Ie8e181e3472f09f389cca757c5e58e61b15c7d79
Diffstat (limited to 'test/dialect/postgresql/test_compiler.py')
0 files changed, 0 insertions, 0 deletions