[cleanup] pylint detected error (among a ton of false positives due to the dynamic nature of cubicweb's code...) stable
authorSylvain Thénault <sylvain.thenault@logilab.fr>
Tue, 11 Jan 2011 17:08:52 +0100
branchstable
changeset 6807 7330d1fa02dd
parent 6806 8291f5e0c9f6
child 6808 d9e2478e7818
[cleanup] pylint detected error (among a ton of false positives due to the dynamic nature of cubicweb's code...)
entity.py
sobjects/notification.py
web/_exceptions.py
--- a/entity.py	Tue Nov 09 17:19:39 2010 +0100
+++ b/entity.py	Tue Jan 11 17:08:52 2011 +0100
@@ -697,7 +697,7 @@
         if not self.has_eid():
             if entities:
                 return []
-            return self.empty_rset()
+            return self._cw.empty_rset()
         rql = self.cw_related_rql(rtype, role)
         rset = self._cw.execute(rql, {'x': self.eid})
         self.cw_set_relation_cache(rtype, role, rset)
--- a/sobjects/notification.py	Tue Nov 09 17:19:39 2010 +0100
+++ b/sobjects/notification.py	Tue Jan 11 17:08:52 2011 +0100
@@ -27,7 +27,7 @@
 
 from cubicweb.selectors import yes
 from cubicweb.view import Component
-from cubicweb.mail import NotificationView, SkipEmail
+from cubicweb.mail import NotificationView as BaseNotificationView, SkipEmail
 from cubicweb.server.hook import SendMailOp
 
 
@@ -59,7 +59,7 @@
 
 # abstract or deactivated notification views and mixin ########################
 
-class NotificationView(NotificationView):
+class NotificationView(BaseNotificationView):
     """overriden to delay actual sending of mails to a commit operation by
     default
     """
--- a/web/_exceptions.py	Tue Nov 09 17:19:39 2010 +0100
+++ b/web/_exceptions.py	Tue Jan 11 17:08:52 2011 +0100
@@ -62,7 +62,7 @@
     """raised when a json remote call fails
     """
     def __init__(self, reason=''):
-        super(RequestError, self).__init__()
+        super(RemoteCallFailed, self).__init__()
         self.reason = reason
 
     def dumps(self):