def _get_message(self, q):
        try:
            m = q.popleft()
            assert self._incoming > 0
            self._incoming -= 1
            return m
        except IndexError:
            return None
dataset/ETHPy150Open osrg/ryu/ryu/lib/rpc.py/EndPoint._get_message/original