{"comment":{"created_at":"2011-10-26T10:14:27Z","body":"I feared you said that ;-)\r\nI prepare those files for you\r\n\r\n2011/10/26 Burak Arslan\r\n<reply@reply.github.com>:\r\n> oh my. this'll be difficult to debug. can you please provide a py file that illustrates the issue? i may need to ask sqlalchemy people about this.\r\n>\r\n> --\r\n> Reply to this email directly or view it on GitHub:\r\n> https://github.com/arskom/rpclib/issues/105#issuecomment-2528628\r\n>\r\n\r\n\r\n\r\n-- \r\nStéphan","updated_at":"2011-10-26T10:14:27Z","url":"https://api.github.com/repos/arskom/rpclib/issues/comments/2528732","id":2528732,"user":{"avatar_url":"https://secure.gravatar.com/avatar/def2f451c5eb0286165af034e3df5eba?d=https://a248.e.akamai.net/assets.github.com%2Fimages%2Fgravatars%2Fgravatar-140.png","gravatar_id":"def2f451c5eb0286165af034e3df5eba","url":"https://api.github.com/users/SunWukong","id":1150633,"login":"SunWukong"}},"action":"created","issue":{"number":105,"created_at":"2011-10-26T09:56:53Z","pull_request":{"diff_url":null,"patch_url":null,"html_url":null},"body":"Hi !\r\n\r\nI will start with the error message :\r\n\r\n  File \"C:\\Python27\\lib\\site-packages\\sqlalchemy-0.7.2-py2.7-win32.egg\\sqlalchemy\\orm\\instrumentation.py\", line 307, in _new_state_if_none\r\n    _new_state_if_none(instance)\r\n  File \"C:\\Python27\\lib\\site-packages\\sqlalchemy-0.7.2-py2.7-win32.egg\\sqlalchemy\\orm\\instrumentation.py\", line 307, in _new_state_if_none\r\n    _new_state_if_none(instance)\r\n  File \"C:\\Python27\\lib\\site-packages\\sqlalchemy-0.7.2-py2.7-win32.egg\\sqlalchemy\\orm\\instrumentation.py\", line 307, in _new_state_if_none\r\n    _new_state_if_none(instance)\r\n  File \"C:\\Python27\\lib\\site-packages\\sqlalchemy-0.7.2-py2.7-win32.egg\\sqlalchemy\\orm\\instrumentation.py\", line 307, in _new_state_if_none\r\n    _new_state_if_none(instance)\r\n  File \"C:\\Python27\\lib\\site-packages\\sqlalchemy-0.7.2-py2.7-win32.egg\\sqlalchemy\\orm\\instrumentation.py\", line 307, in _new_state_if_none\r\n    _new_state_if_none(instance)\r\n  File \"C:\\Python27\\lib\\site-packages\\sqlalchemy-0.7.2-py2.7-win32.egg\\sqlalchemy\\orm\\instrumentation.py\", line 307, in _new_state_if_none\r\n    _new_state_if_none(instance)\r\n  File \"C:\\Python27\\lib\\site-packages\\sqlalchemy-0.7.2-py2.7-win32.egg\\sqlalchemy\\orm\\instrumentation.py\", line 307, in _new_state_if_none\r\n    _new_state_if_none(instance)\r\n  File \"C:\\Python27\\lib\\site-packages\\sqlalchemy-0.7.2-py2.7-win32.egg\\sqlalchemy\\orm\\instrumentation.py\", line 307, in _new_state_if_none\r\n    _new_state_if_none(instance)\r\n  File \"C:\\Python27\\lib\\site-packages\\sqlalchemy-0.7.2-py2.7-win32.egg\\sqlalchemy\\orm\\instrumentation.py\", line 307, in _new_state_if_none\r\n    _new_state_if_none(instance)\r\n  File \"C:\\Python27\\lib\\site-packages\\sqlalchemy-0.7.2-py2.7-win32.egg\\sqlalchemy\\orm\\instrumentation.py\", line 307, in _new_state_if_none\r\n    _new_state_if_none(instance)\r\n  File \"C:\\Python27\\lib\\site-packages\\sqlalchemy-0.7.2-py2.7-win32.egg\\sqlalchemy\\orm\\instrumentation.py\", line 307, in _new_state_if_none\r\n    _new_state_if_none(instance)\r\n  File \"C:\\Python27\\lib\\site-packages\\sqlalchemy-0.7.2-py2.7-win32.egg\\sqlalchemy\\orm\\instrumentation.py\", line 307, in _new_state_if_none\r\n    _new_state_if_none(instance)\r\n  File \"C:\\Python27\\lib\\site-packages\\sqlalchemy-0.7.2-py2.7-win32.egg\\sqlalchemy\\orm\\instrumentation.py\", line 307, in _new_state_if_none\r\n    _new_state_if_none(instance)\r\n  File \"C:\\Python27\\lib\\site-packages\\sqlalchemy-0.7.2-py2.7-win32.egg\\sqlalchemy\\orm\\instrumentation.py\", line 306, in _new_state_if_none\r\n    return self._subclass_manager(instance.__class__).\\\r\n  File \"C:\\Python27\\lib\\site-packages\\sqlalchemy-0.7.2-py2.7-win32.egg\\sqlalchemy\\orm\\instrumentation.py\", line 135, in _subclass_manager\r\n    manager = manager_of_class(cls)\r\n  File \"C:\\Python27\\lib\\site-packages\\sqlalchemy-0.7.2-py2.7-win32.egg\\sqlalchemy\\orm\\instrumentation.py\", line 609, in manager_of_class\r\n    return cls.__dict__.get(ClassManager.MANAGER_ATTR, None)\r\nRuntimeError: maximum recursion depth exceeded while calling a Python object\r\n\r\nThe loop is on File \"C:\\Python27\\lib\\site-packages\\sqlalchemy-0.7.2-py2.7-win32.egg\\sqlalchemy\\orm\\instrumentation.py\", line 307\r\n\r\nThe context : \r\nPython 2.7\r\nSQLAlchemy 0.7.2 (MySQL DB)\r\nrpclib 2.4.4 or a dev repo provided by Burak (see issue #104)\r\n\r\nI've got this class that maps a MySQL table :\r\n\r\n    class Patient(TableModel, DeclarativeBase):\r\n        __namespace__ = nameSpace\r\n        __tablename__ = 'fiche_patient'\r\n        #\r\n        patient_id = Column(sqlalchemy.Integer, primary_key=True)\r\n        user_id = Column(sqlalchemy.Integer)\r\n        nom = Column(sqlalchemy.String(50))\r\n        prenom = Column(sqlalchemy.String(25))\r\n        telephone = Column(sqlalchemy.String(20))\r\n        telephone2 = Column(sqlalchemy.String(20))\r\n        adresse = Column(sqlalchemy.String(160))\r\n        code_postal = Column(sqlalchemy.String(10))\r\n        ville = Column(sqlalchemy.String(30))\r\n        nom_med = Column(sqlalchemy.String(50))\r\n        tel_med = Column(sqlalchemy.String(20))\r\n        tel_med2 = Column(sqlalchemy.String(20))\r\n        note = Column(sqlalchemy.Text)\r\n        photo = Column(sqlalchemy.LargeBinary)\r\n        maj = Column(sqlalchemy.String(1))\r\n        patient_id_tpz = Column(sqlalchemy.Integer)\r\n\r\nAnd here's the called method of the web service :\r\n\r\n    @rpc(Int(min_occurs=1, max_occurs=1),\r\n        String(min_occurs=1, max_occurs=1),\r\n        Array(Patient),\r\n        _returns=Int(min_occurs=1, max_occurs=1))\r\n    def tpz_setPatients(ctx, user_id, password, patients):\r\n        if do_verifPassword(ctx, user_id, password):\r\n            idx = 0\r\n            for patient in patients:\r\n                idx += 1\r\n                ctx.udc.session.add(patient)\r\n            return idx\r\n        else:\r\n            return -1\r\n\r\n\r\n\r\n\r\n","comments":2,"title":"Infinite loop with the sqlalchemy backend","updated_at":"2011-10-26T10:14:27Z","url":"https://api.github.com/repos/arskom/rpclib/issues/105","id":2055064,"assignee":{"avatar_url":"https://secure.gravatar.com/avatar/63756693d9b79ff633f86ff5672652e9?d=https://a248.e.akamai.net/assets.github.com%2Fimages%2Fgravatars%2Fgravatar-140.png","gravatar_id":"63756693d9b79ff633f86ff5672652e9","url":"https://api.github.com/users/plq","id":79872,"login":"plq"},"milestone":{"number":2,"created_at":"2011-09-02T09:18:02Z","due_on":null,"title":"2.x","creator":{"avatar_url":"https://secure.gravatar.com/avatar/63756693d9b79ff633f86ff5672652e9?d=https://a248.e.akamai.net/assets.github.com%2Fimages%2Fgravatars%2Fgravatar-140.png","gravatar_id":"63756693d9b79ff633f86ff5672652e9","url":"https://api.github.com/users/plq","id":79872,"login":"plq"},"url":"https://api.github.com/repos/arskom/rpclib/milestones/2","open_issues":6,"closed_issues":5,"description":"The issues that should be resolved for the stabilization of 2.x series.","state":"open"},"closed_at":null,"user":{"avatar_url":"https://secure.gravatar.com/avatar/def2f451c5eb0286165af034e3df5eba?d=https://a248.e.akamai.net/assets.github.com%2Fimages%2Fgravatars%2Fgravatar-140.png","gravatar_id":"def2f451c5eb0286165af034e3df5eba","url":"https://api.github.com/users/SunWukong","id":1150633,"login":"SunWukong"},"html_url":"https://github.com/arskom/rpclib/issues/105","labels":[{"name":"Defect","url":"https://api.github.com/repos/arskom/rpclib/labels/Defect","color":"ff0000"},{"name":"master","url":"https://api.github.com/repos/arskom/rpclib/labels/master","color":"ededed"}],"state":"open"},"legacy":{"issue_id":2055064,"comment_id":2528732}}