Skip to content

Commit

Permalink
Merge pull request #213 from pypa/release/24.1
Browse files Browse the repository at this point in the history
Update to 24.1
  • Loading branch information
pradyunsg authored Jun 20, 2024
2 parents 8faefc9 + 5ea70b9 commit 4c73b3f
Show file tree
Hide file tree
Showing 7 changed files with 61,440 additions and 32,885 deletions.
33,036 changes: 33,036 additions & 0 deletions public/3.7/get-pip.py

Large diffs are not rendered by default.

61,269 changes: 28,387 additions & 32,882 deletions public/get-pip.py

Large diffs are not rendered by default.

Binary file modified public/pip.pyz
Binary file not shown.
Binary file added public/zipapp/pip-24.1.pyz
Binary file not shown.
Binary file added public/zipapp/pip-24.1b1.pyz
Binary file not shown.
Binary file added public/zipapp/pip-24.1b2.pyz
Binary file not shown.
20 changes: 17 additions & 3 deletions scripts/generate.py
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,11 @@
"setuptools": "",
"wheel": "",
},
"3.7": {
"pip": "<24.1",
"setuptools": "",
"wheel": "",
},
}

# This is the oldest version of pip we will distribute as a zipapp.
Expand Down Expand Up @@ -292,7 +297,12 @@ def zipapp_location(pip_version: Version) -> Path:
return zipapp_dir / f"pip-{pip_version}.pyz"


def generate_zipapp(pip_version: Version, *, console: Console, pip_versions: Dict[Version, Tuple[str, str]]) -> None:
def generate_zipapp(
pip_version: Version,
*,
console: Console,
pip_versions: Dict[Version, Tuple[str, str]],
) -> None:
wheel_url, wheel_hash = pip_versions[pip_version]
console.log(f" Downloading [green]{Path(wheel_url).name}")
original_wheel = download_wheel(wheel_url, wheel_hash)
Expand Down Expand Up @@ -326,7 +336,9 @@ def generate_zipapp(pip_version: Version, *, console: Console, pip_versions: Dic
major, minor = map(int, m.groups())
console.log(f" Zipapp requires Python {py_req}")
else:
console.log(f" Python requirement {py_req} too complex - check skipped")
console.log(
f" Python requirement {py_req} too complex - check skipped"
)

# Write the main script
# Use a ZipInfo object to ensure reproducibility - otherwise the current time
Expand All @@ -341,7 +353,9 @@ def generate_zipapp(pip_version: Version, *, console: Console, pip_versions: Dic
# and we want a reproducible value, i.e., always use the same
# newline format.
template = Path("templates") / "zipapp_main.py"
zipapp_main = template.read_text(encoding="utf-8").format(major=major, minor=minor)
zipapp_main = template.read_text(encoding="utf-8").format(
major=major, minor=minor
)
dest.writestr(main_info, zipapp_main)


Expand Down

0 comments on commit 4c73b3f

Please sign in to comment.