Adding __repr__ to childs object breaks accesss to parent.childs attribute

Issue #616 resolved
Former user created an issue

If we define repr in child object class, then appending it to parent goes silently, but accessing all childs from parent is broken. Test-case is attached

---rossMoHaX

Comments (1)

  1. jek

    All {{{repr}}} methods in Python must return a string type. Here's the minimal test from the attached:

    class ChildWithReprObj(object):
        def __repr__(self):
            print 'Crash the sqlalchemy now! =)'
    print repr(ChildWithReprObj())
    

    Change the {{{print}}} to {{{return}}} and you're fine.

  2. Log in to comment