def METHOD_NAME(var: str):
    """Find an executable from an environment variable.
    Args:
        var (str): environment variable name
    Returns:
        (str or None, list): executable string (or None if not found) and
            arguments parsed from the env var
    """
    # try to get the environment variable
    exe = os.environ.get(var)
    if not exe:
        return None, []
    # split env var into executable and args if needed
    args = shlex.split(str(exe))
    if not args:
        return None, []
    exe = spack.util.executable.which_string(args[0])
    args = [exe] + args[1:]
    return exe, args