human
Complete this python program:
def check_rosdeps(name):
assistant
#Here is the Python code you requested.

    """Validator for stack rosdeps.
    @raise ManifestException: if validation fails
    """
    def check(n, filename):
        nodes = get_nodes_by_name(n, name)
        rosdeps = [e.attributes for e in nodes]
        names = [d['name'].value for d in rosdeps]
        return [ROSDep(n) for n in names]
    return check