From 38a23f66a8373f1dbbe8154b5780da37cfb84cfb Mon Sep 17 00:00:00 2001 From: Jiaming Yuan Date: Fri, 17 Sep 2021 11:14:05 +0800 Subject: [PATCH] Fix typo in release script. [skip ci] (#7238) --- dev/release-pypi.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/dev/release-pypi.py b/dev/release-pypi.py index c4254e156..c12c8059f 100644 --- a/dev/release-pypi.py +++ b/dev/release-pypi.py @@ -36,10 +36,10 @@ def retrieve(url, filename=None): return urlretrieve(url, filename, reporthook=show_progress) -def lastest_hash() -> str: +def latest_hash() -> str: "Get latest commit hash." ret = subprocess.run(["git", "rev-parse", "HEAD"], capture_output=True) - assert ret.returncode == 0, "Failed to get lastest commit hash." + assert ret.returncode == 0, "Failed to get latest commit hash." commit_hash = ret.stdout.decode("utf-8").strip() return commit_hash @@ -96,7 +96,7 @@ def main(args: argparse.Namespace) -> None: git.checkout(branch) git.pull("origin", branch) git.submodule("update") - commit_hash = lastest_hash() + commit_hash = latest_hash() dir_URL = PREFIX + str(major) + "." + str(minor) + ".0" + "/" src_filename_prefix = "xgboost-" + args.release + "%2B" + commit_hash + "-py3-none-"