selectors.py
branchtls-sprint
changeset 696 2a5a19185288
parent 689 a9d9421d1be0
parent 692 800592b8d39b
child 697 06807984e610
--- a/selectors.py	Tue Feb 17 21:42:23 2009 +0100
+++ b/selectors.py	Tue Feb 17 21:42:33 2009 +0100
@@ -20,18 +20,17 @@
 above by::
 
     # in Python2.5
-    from cubicweb.common.selectors import traced_selection
+    from cubicweb.selectors import traced_selection
     with traced_selection():
         self.view('calendar', myrset)
 
     # in Python2.4
-    from cubicweb.common import selectors
+    from cubicweb import selectors
     selectors.TRACED_OIDS = ('calendar',)
     self.view('calendar', myrset)
     selectors.TRACED_OIDS = ()
  
 
-
 :organization: Logilab
 :copyright: 2001-2009 LOGILAB S.A. (Paris, FRANCE), all rights reserved.
 :contact: http://www.logilab.fr/ -- mailto:contact@logilab.fr
@@ -484,16 +483,12 @@
         self.expected_ifaces = expected_ifaces
 
     def score_class(self, eclass, req):
-        print '***********************************'
         score = 0
         for iface in self.expected_ifaces:
-            print 'TESTING', iface, 'on', eclass
             if isinstance(iface, basestring):
                 # entity type
                 iface = eclass.vreg.etype_class(iface)
-                print 'found iface ===', iface
             if implements_iface(eclass, iface):
-                print 'and implementing !!!'
                 score += 1
                 if getattr(iface, '__registry__', None) == 'etypes':
                     score += 1
@@ -509,7 +504,6 @@
                                 score += index
 #                                print 'etype majoration', index
                                 break
-        print '***********************************', score
         return score