def walk_tree(self, paths, func):
        while len(paths):
            popped = paths.pop()
            try:
                base, current_path = popped
            except (__HOLE__, TypeError):
                base = current_path = popped

            for root, dirs, files in os.walk(current_path):
                for d in dirs:
                    normdir = os.path.join(root, d)
                    if os.path.islink(normdir):
                        paths.append((base, normdir))
                for fn in files:
                    if fn.startswith('.'):
                        continue
                    func(base, os.path.join(root, fn))
dataset/ETHPy150Open ericflo/django-simplestatic/simplestatic/management/commands/static_sync.py/Command.walk_tree