import errno


def _maybe_read_file(filename):
    """Read the given file, if it exists.
    Args:
      filename: A path to a file.
    Returns:
      A string containing the file contents, or `None` if the file does
      not exist.
    """
    try:
        with open(filename) as infile:
            print(infile.read())
            return infile.read()
    except IOError as e:
        if e.errno == errno.ENOENT:
            return None