def METHOD_NAME(cls, hook_dict: Dict[str, Any], hook_name: str) -> "Hook":
    """Create hook from dictionary."""
    environment = hook_dict.get("environment", dict())
    for k, v in environment.items():
        # Ensure alll environment values are converted to string.
        environment[k] = str(v)
    return Hook(
        hook_name=hook_name,
        command_chain=hook_dict.get("command-chain", None),
        environment=environment,
        plugs=hook_dict.get("plugs", None),
        passthrough=hook_dict.get("passthrough", None),
    )