def __init__(self, on_message):
        """Constructs (but does not start) a server.

        Args:
            on_message (function): callback that takes a single argument (any
                Python object sent by a client) and returns an object in
                response
        """
        super().__init__(
            ("localhost", 0), IPCRequestHandler, bind_and_activate=True
        )
        self.on_message = on_message
        self.__lock = threading.Lock()
        self.__in_serve_forever = False
Constructs (but does not start) a server.

        Args:
            on_message (function): callback that takes a single argument (any
                Python object sent by a client) and returns an object in
                response
        
fiftyone/service/ipc.py