nodes: 0, module; 1, function_definition; 2, function_name:GetArtifactsForCollection; 3, parameters; 4, block; 5, identifier:os_name; 6, identifier:artifact_list; 7, expression_statement; 8, expression_statement; 9, expression_statement; 10, return_statement; 11, comment:"""Wrapper for the ArtifactArranger.
  
    Extend the artifact list by dependencies and sort the artifacts to resolve the
    dependencies.
  
    Args:
      os_name: String specifying the OS name.
      artifact_list: List of requested artifact names.
  
    Returns:
      A list of artifacts such that if they are collected in the given order
        their dependencies are resolved.
    """; 12, assignment; 13, assignment; 14, identifier:artifact_names; 15, identifier:artifact_arranger; 16, call; 17, identifier:artifact_names; 18, call; 19, identifier:ArtifactArranger; 20, argument_list; 21, attribute; 22, argument_list; 23, identifier:os_name; 24, identifier:artifact_list; 25, identifier:artifact_arranger; 26, identifier:GetArtifactsInProperOrder
code: def GetArtifactsForCollection(os_name, artifact_list):
    """Wrapper for the ArtifactArranger.
  
    Extend the artifact list by dependencies and sort the artifacts to resolve the
    dependencies.
  
    Args:
      os_name: String specifying the OS name.
      artifact_list: List of requested artifact names.
  
    Returns:
      A list of artifacts such that if they are collected in the given order
        their dependencies are resolved.
    """
    artifact_arranger = ArtifactArranger(os_name, artifact_list)
    artifact_names = artifact_arranger.GetArtifactsInProperOrder()
    return artifact_names