docstr: Handle recv events
code: def _handle_recv(self):
      """Handle recv events"""
      if not self._shadow_sock.get(EVENTS) & POLLIN:
          # event triggered, but state may have been changed between trigger and callback
          return
      f = None
      while self._recv_futures:
          f, kind, kwargs, _, timer = self._recv_futures.popleft()
          # skip any cancelled futures
          if f.done():
              f = None
          else:
              break
  
      if not self._recv_futures:
          self._drop_io_state(POLLIN)
  
      if f is None:
          return
  
      timer.cancel()
  
      if kind == "poll":
          # on poll event, just signal ready, nothing else.
          f.set_result(None)
          return
      elif kind == "recv_multipart":
          recv = self._shadow_sock.recv_multipart
      elif kind == "recv":
          recv = self._shadow_sock.recv
      else:
          raise ValueError("Unhandled recv event type: %r" % kind)
  
      kwargs["flags"] |= _zmq.DONTWAIT
      try:
          result = recv(**kwargs)
      except Exception as e:
          f.set_exception(e)
      else:
          f.set_result(result)
  
imports: import warnings
  from asyncio import Future
  from collections import deque
  from itertools import chain
  from typing import Any, Awaitable, Callable, Dict, List, NamedTuple, Optional, Tuple, Type, TypeVar, Union, cast, overload
  import zmq
  from zmq import EVENTS, POLLIN, POLLOUT
  from zmq._typing import Literal
label_desc: Use image node_id 22 for calling the _AsyncSocket obj's underlying member method code with example usage: obj._handle_recv() without return types