Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #78923

Re: ZMQError: Resource temporarily unavailable

From dieter <dieter@handshake.de>
Subject Re: ZMQError: Resource temporarily unavailable
Date 2014-10-10 07:57 +0200
References <0ac40dbc-105b-42d4-91f8-d0937bad30cf@googlegroups.com>
Newsgroups comp.lang.python
Message-ID <mailman.14738.1412920684.18130.python-list@python.org> (permalink)

Show all headers | View raw


karthik.sharma@gmail.com writes:

> I am using zero-mq for IPC between two machines.
>
> My zmq function is given below
>
>     def recieve_messages(self):
>              string = self.sub_socket.recv(flags=zmq.NOBLOCK)
>              print('flow mod messages recieved {}'.format(string))
>
>
> When I run the program however I get the following error.
>
>       string = self.sub_socket.recv(flags=zmq.NOBLOCK)
>       File "socket.pyx", line 616, in zmq.core.socket.Socket.recv (zmq/core/socket.c:5961)
>       File "socket.pyx", line 650, in zmq.core.socket.Socket.recv (zmq/core/socket.c:5832)
>       File "socket.pyx", line 119, in zmq.core.socket._recv_copy (zmq/core/socket.c:1669)
>     ZMQError: Resource temporarily unavailable
>
>
> Can someone explain what is likely causing this error.

The most likely cause is that you try to receive data while there
is none available. Usually, with non blocking operations, you
start them only after you know they can succeed. If the operation
is impossible, you will get an exception (and "Resource temporarily
unavailable" seems a good candidate).

Back to comp.lang.python | Previous | Next — Previous in thread | Find similar | Unroll thread


Thread

ZMQError: Resource temporarily unavailable karthik.sharma@gmail.com - 2014-10-08 23:16 -0700
  Re: ZMQError: Resource temporarily unavailable dieter <dieter@handshake.de> - 2014-10-10 07:57 +0200

csiph-web