pombreda / formalchemy

Automatically exported from code.google.com/p/formalchemy
MIT License
0 stars 0 forks source link

Autoflush caused by relationship cascade causes IntegrityError #159

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. See discussion on formalchemy group:

https://groups.google.com/group/formalchemy/browse_thread/thread/2482c94e43ee46a
1?hl=ena65d464587135e4

What is the expected output? What do you see instead?

FieldSet does not render, raises Integrity Error.

What version of the product are you using? On what operating system?

In [8]: formalchemy.__version__
Out[8]: '1.3.5'

Please provide any additional information below.

Setting Session.autoflush to False just before fs.render() (and setting it back 
to it previous value right after) voids the problem (see also 
http://www.mail-archive.com/sqlalchemy@googlegroups.com/msg13152.html)

Thanks to Gaël Pasgrimaud for finding the solution.

Original issue reported on code.google.com by neur...@gmail.com on 11 Jan 2011 at 2:17