MCPcopy
hub / github.com/redis/redis-py / deregister_connect_callback

Method deregister_connect_callback

redis/connection.py:981–990  ·  view source on GitHub ↗

De-register a previously registered callback. It will no-longer receive notifications on connection events. Calling this is not required when the listener goes away, since the callbacks are kept as weak methods.

(self, callback)

Source from the content-addressed store, hash-verified

979 self._connect_callbacks.append(wm)
980
981 def deregister_connect_callback(self, callback):
982 """
983 De-register a previously registered callback. It will no-longer receive
984 notifications on connection events. Calling this is not required when the
985 listener goes away, since the callbacks are kept as weak methods.
986 """
987 try:
988 self._connect_callbacks.remove(weakref.WeakMethod(callback))
989 except ValueError:
990 pass
991
992 def set_parser(self, parser_class):
993 """

Callers 2

resetMethod · 0.45

Calls 1

removeMethod · 0.80

Tested by

no test coverage detected