diff --git a/osbuild/util/jsoncomm.py b/osbuild/util/jsoncomm.py index 06fb5bdf..22d6b6d8 100644 --- a/osbuild/util/jsoncomm.py +++ b/osbuild/util/jsoncomm.py @@ -321,7 +321,7 @@ class Socket(contextlib.AbstractContextManager): return (payload, fdset, msg[3]) - def send(self, payload: object, *, destination: Optional[str] = None, fds: Optional[list] = None): + def send(self, payload: object, *, fds: Optional[list] = None): """Send Message Send a new message via this socket. This operation is synchronous. The @@ -352,5 +352,5 @@ class Socket(contextlib.AbstractContextManager): if fds: cmsg.append((socket.SOL_SOCKET, socket.SCM_RIGHTS, array.array("i", fds))) - n = self._socket.sendmsg([serialized], cmsg, 0, destination) + n = self._socket.sendmsg([serialized], cmsg, 0) assert n == len(serialized) diff --git a/test/mod/test_util_jsoncomm.py b/test/mod/test_util_jsoncomm.py index acb6d30b..99f4d5a2 100644 --- a/test/mod/test_util_jsoncomm.py +++ b/test/mod/test_util_jsoncomm.py @@ -84,7 +84,7 @@ class TestUtilJsonComm(unittest.TestCase): assert msg[0] == data assert len(msg[1]) == 0 - self.server.send(data, destination=msg[2]) + self.server.send(data) msg = self.client.recv() assert msg[0] == data assert len(msg[1]) == 0 @@ -154,7 +154,7 @@ class TestUtilJsonComm(unittest.TestCase): def echo(socket): msg = socket.recv() - socket.send(msg[0], destination=msg[2]) + socket.send(msg[0]) loop.stop() self.client.send({})