[sqlalchemy] Re: some failures on polymorphic-mapper with non-lazy relations
Employee points to Dept and Dept points to Director; Director inherits Employee. no other references. thats not the test case im talking about, you gave me just A and B with B point to A (which is A pointing to A). that right, i found another case giving the same error, and thought it is somewhat linked. just look at the queries these things generate, expecting eager in all cases from those relations is starting to push the envelope a bit further than I can handle myself (as well as what a DB can usually handle). is there any link between a relation being post_update and being lazy? no. that's all okay, i don't expect anything. i just want the thing to run. and i don't realy care about the lazy/eagerness that much. Can we invent some practical rule about what cannot (or should not) be lazy? a) self-reference and inheritance between pointing and pointed, in any direction b) anything else ?? i see rev.2257 Otherwise, it is a trial-and-error: - make some relation eager - try querying all classes around - make another relation eager ... until one hits some error - or succeeds --~--~-~--~~~---~--~~ 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 -~--~~~~--~~--~--~---
[sqlalchemy] Re: some failures on polymorphic-mapper with non-lazy relations
Can we invent some practical rule about what cannot (or should not) be lazy? sorry, what cannot (or should not) be _eager_ a) self-reference and inheritance between pointing and pointed, in any direction b) anything else ?? --~--~-~--~~~---~--~~ 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 -~--~~~~--~~--~--~---
[sqlalchemy] Re: some failures on polymorphic-mapper with non-lazy relations
self-referential eager loads are never going to be supported. the bug here is that the eager loader isnt checking hard enough to see that its in fact self-referential. On Jan 25, 6:12 pm, [EMAIL PROTECTED] wrote: i have added a switch for lazy on/off to that 115-case full combination test for A-B inheritance and relations. For lazy=True all is ok. For lazy=False, i am setting lazy=False only for those relations which refer to klas not a subklas to the main one. The result is 8 cases fail, all of same pattern, and with same error (keyerror on discriminator being None): $ python sa_ref_A_B_A_all.py no_lazy -- fail: 8 of total 115 ; 6 % poly= 1, inh=tableinh, Alink= B, Blink= A, BAlink=None ::: KeyError: ssingle A poly= 1, inh=tableinh, Alink= B, Blink= A, BAlink= B ::: KeyError: ssingle A poly= 1, inh=tableinh, Alink= B, Blink= A1, BAlink=None ::: KeyError: ssingle A poly= 1, inh=tableinh, Alink= B, Blink= A1, BAlink= B ::: KeyError: ssingle A poly= 1, inh=tableinh, Alink= B1, Blink= A, BAlink=None ::: KeyError: ssingle A poly= 1, inh=tableinh, Alink= B1, Blink= A, BAlink= B1 ::: KeyError: ssingle A poly= 1, inh=tableinh, Alink= B1, Blink= A1, BAlink=None ::: KeyError: ssingle A poly= 1, inh=tableinh, Alink= B1, Blink= A1, BAlink= B1 ::: KeyError: ssingle A i've picked 1st testcase. All can be generated via $ python sa_ref_A_B_A_all.py no_lazy generate_many ciao svil sa_gentestbase.py 2KDownload sa_B_inh_A_A_ref_AB.py 4KDownload sa_generator.py 10KDownload _test_AB_poly_1__inh_tableinh__Alink_B__Blink_A__BAlink_None.py 2KDownload --~--~-~--~~~---~--~~ 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 -~--~~~~--~~--~--~---