[Connection] inherit from RequestSessionBase
authorPierre-Yves David <pierre-yves.david@logilab.fr>
Fri, 29 Mar 2013 17:43:18 +0100
changeset 9073 9574df1cd054
parent 9072 774029a4a718
child 9074 0616f7a713c6
[Connection] inherit from RequestSessionBase This contains a lot method. We need them to move more code from Session to connection.
server/session.py
--- a/server/session.py	Wed Jun 26 13:48:18 2013 +0200
+++ b/server/session.py	Fri Mar 29 17:43:18 2013 +0100
@@ -359,7 +359,7 @@
                 timeout -= time() - start
             return tuple(self._record)
 
-class Connection(object):
+class Connection(RequestSessionBase):
     """Repository Connection
 
     Holds all connection related data
@@ -417,6 +417,8 @@
     """
 
     def __init__(self, cnxid, session, rewriter):
+        # using super(Connection, self) confuse some test hack
+        RequestSessionBase.__init__(self, session.vreg)
         #: connection unique id
         self.connectionid = cnxid
         #: reentrance handling