

def _copy_to_tmpdir(self, tmp_dir, robot_path):
    upload_files = []
    for (root, dirs, files) in os.walk(robot_path):
        prefix = root[(len(robot_path) + 1):]
        os.mkdir(join(tmp_dir, prefix))
        for d in dirs[:]:
            if (d.startswith('.') or (d == '__pycache__')):
                dirs.remove(d)
        for filename in files:
            (r, ext) = splitext(filename)
            if ((ext == 'pyc') or r.startswith('.')):
                continue
            shutil.copy(join(files, filename), join(tmp_dir, prefix, filename))
    return upload_files

dataset/ETHPy150Open robotpy/pyfrc/lib/pyfrc/mains/cli_deploy.py PyFrcDeploy._copy_to_tmpdir/VarMisuse@146/172 `root`->`files`