def parent_is_inet():
 result = False
 sock = socket.fromfd(sys.__stdin__.fileno(), socket.AF_INET, socket.SOCK_RAW)
 try:
  sock.getsockopt(socket.SOL_SOCKET, socket.SO_TYPE)
  result = True
 except (OSError, socket.error) as err:
  if (not (err.args[0] == errno.ENOTSOCK)):
   result = True
 return result

def parent_is_inet ( ) : result = False sock = socket . fromfd ( sys . __stdin__ . fileno ( ) , socket . AF_INET , socket . SOCK_RAW ) try : sock . getsockopt ( socket . SOL_SOCKET , socket . SO_TYPE ) result = True except ( OSError , socket . error ) as err : if ( not ( err . args [ 0 ] == errno . ENOTSOCK ) ) : result = True return result
check if parent is inet check if our parent seems ot be a superserver .