def METHOD_NAME(self, message: Optional[str], *args: Any, **kwargs: Any) -> None:
    if self.ws.closed:
        return
    try:
        self.ws.send(message, **kwargs)
    except WebSocketError as e:
        log.warning(
            f'Got WebSocketError {e!s} for sending message {message} to a websocket',
        )