I get this error when i try to execute the folowing code (Test, Section, Question, Answer are mepped tables): test = Test() section = Section() section.Test=test for i in range(60): q=Question() q.Section=section for j in range(6) a = Answer() a.Question = q
db_session.save(test) db_session.commit() <---- this command generates the error, and only if the number of Questions is above cca. 45 But if I do a first commit before the "for i", and one commit after each question has been created then no error is generated. Is this a big in SQLAlchemy? File "/usr/lib/python2.5/site-packages/SQLAlchemy-0.4.6-py2.5.egg/ sqlalchemy/orm/unitofwork.py", line 930, in execute self.execute_save_steps(trans, task) File "/usr/lib/python2.5/site-packages/SQLAlchemy-0.4.6-py2.5.egg/ sqlalchemy/orm/unitofwork.py", line 947, in execute_save_steps self.execute_per_element_childtasks(trans, task, False) File "/usr/lib/python2.5/site-packages/SQLAlchemy-0.4.6-py2.5.egg/ sqlalchemy/orm/unitofwork.py", line 970, in execute_per_element_childtasks self.execute_element_childtasks(trans, element, isdelete) File "/usr/lib/python2.5/site-packages/SQLAlchemy-0.4.6-py2.5.egg/ sqlalchemy/orm/unitofwork.py", line 974, in execute_element_childtasks self.execute(trans, [child], isdelete) File "/usr/lib/python2.5/site-packages/SQLAlchemy-0.4.6-py2.5.egg/ sqlalchemy/orm/unitofwork.py", line 930, in execute self.execute_save_steps(trans, task) File "/usr/lib/python2.5/site-packages/SQLAlchemy-0.4.6-py2.5.egg/ sqlalchemy/orm/unitofwork.py", line 945, in execute_save_steps self.save_objects(trans, task) File "/usr/lib/python2.5/site-packages/SQLAlchemy-0.4.6-py2.5.egg/ sqlalchemy/orm/unitofwork.py", line 936, in save_objects task.mapper._save_obj(task.polymorphic_tosave_objects, trans) File "/usr/lib/python2.5/site-packages/SQLAlchemy-0.4.6-py2.5.egg/ sqlalchemy/orm/mapper.py", line 1161, in _save_obj c = connection.execute(statement.values(value_params), params) File "/usr/lib/python2.5/site-packages/SQLAlchemy-0.4.6-py2.5.egg/ sqlalchemy/engine/base.py", line 844, in execute return Connection.executors[c](self, object, multiparams, params) File "/usr/lib/python2.5/site-packages/SQLAlchemy-0.4.6-py2.5.egg/ sqlalchemy/engine/base.py", line 895, in execute_clauseelement return self._execute_compiled(elem.compile(dialect=self.dialect, column_keys=keys, inline=len(params) > 1), distilled_params=params) File "/usr/lib/python2.5/site-packages/SQLAlchemy-0.4.6-py2.5.egg/ sqlalchemy/sql/expression.py", line 1132, in compile compiler.compile() File "/usr/lib/python2.5/site-packages/SQLAlchemy-0.4.6-py2.5.egg/ sqlalchemy/sql/compiler.py", line 181, in compile self.string = self.process(self.statement) File "/usr/lib/python2.5/site-packages/SQLAlchemy-0.4.6-py2.5.egg/ sqlalchemy/sql/compiler.py", line 189, in process return meth(obj, **kwargs) File "/usr/lib/python2.5/site-packages/SQLAlchemy-0.4.6-py2.5.egg/ sqlalchemy/databases/postgres.py", line 712, in visit_insert text = super(PGCompiler, self).visit_insert(insert_stmt) File "/usr/lib/python2.5/site-packages/SQLAlchemy-0.4.6-py2.5.egg/ sqlalchemy/sql/compiler.py", line 598, in visit_insert colparams = self._get_colparams(insert_stmt) File "/usr/lib/python2.5/site-packages/SQLAlchemy-0.4.6-py2.5.egg/ sqlalchemy/sql/compiler.py", line 674, in _get_colparams values.append((c, create_bind_param(c, None))) File "/usr/lib/python2.5/site-packages/SQLAlchemy-0.4.6-py2.5.egg/ sqlalchemy/sql/compiler.py", line 634, in create_bind_param return self.bindparam_string(self._truncate_bindparam(bindparam)) File "/usr/lib/python2.5/site-packages/SQLAlchemy-0.4.6-py2.5.egg/ sqlalchemy/sql/compiler.py", line 440, in bindparam_string return self.bindtemplate % {'name':name, 'position':len(self.positiontup)} RuntimeError: maximum recursion depth exceeded --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "sqlalchemy" group. To post to this group, send email to sqlalchemy@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/sqlalchemy?hl=en -~----------~----~----~----~------~----~------~--~---