diff -r 435286b8fe10 -r c6aff16e5aed server/hook.py --- a/server/hook.py Wed Sep 23 09:35:28 2009 +0200 +++ b/server/hook.py Wed Sep 23 09:35:36 2009 +0200 @@ -137,14 +137,16 @@ @classproperty def __regid__(cls): - warn('[3.6] %s: please specify an id for your hook' % cls) + warn('[3.6] %s.%s: please specify an id for your hook' + % (cls.__module__, cls.__name__), DeprecationWarning) return str(id(cls)) @classmethod def __registered__(cls, vreg): super(Hook, cls).__registered__(vreg) if getattr(cls, 'accepts', None): - warn('[3.6] %s: accepts is deprecated, define proper __select__' % cls) + warn('[3.6] %s.%s: accepts is deprecated, define proper __select__' + % (cls.__module__, cls.__name__), DeprecationWarning) rtypes = [] for ertype in cls.accepts: if ertype.islower(): @@ -165,8 +167,9 @@ def __call__(self): if hasattr(self, 'call'): - warn('[3.6] %s: call is deprecated, implements __call__' % self.__class__, - DeprecationWarning) + cls = self.__class__ + warn('[3.6] %s.%s: call is deprecated, implements __call__' + % (cls.__module__, cls.__name__), DeprecationWarning) if self.event.endswith('_relation'): self.call(self._cw, self.eidfrom, self.rtype, self.eidto) elif 'delete' in self.event: