()
| 24 | |
| 25 | |
| 26 | def main() -> None: |
| 27 | out_path = find_repo_root() / "pex/venv/virtualenv_16.7.12_py" |
| 28 | with httpx.stream( |
| 29 | "GET", |
| 30 | f"https://raw.githubusercontent.com/pypa/virtualenv/" |
| 31 | f"{VIRTUALENV_16_7_12_RELEASE_SHA}/virtualenv.py", |
| 32 | ) as response, named_temporary_file( |
| 33 | dir=out_path.parent, prefix=f"{out_path.name}.", suffix=".downloading" |
| 34 | ) as out_fp: |
| 35 | for chunk in response.iter_bytes(): |
| 36 | out_fp.write(chunk) |
| 37 | os.rename(out_fp.name, out_path) |
| 38 | |
| 39 | |
| 40 | if __name__ == "__main__": |
no test coverage detected