def _not_reentrant(func):
def wrap(self, *args, **kws):<EOL><INDENT>if self._callback_lock and self._callback_lock.in_callback:<EOL><INDENT>m = "<STR_LIT>" % func<EOL>raise RuntimeError(m)<EOL><DEDENT>return func(self, *args, **kws)<EOL><DEDENT>return wrap<EOL>
Decorator that prevents callbacks from calling into methods that are
        not reentrant