Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

WIP: release v4.6.0 #6796

Draft
wants to merge 1 commit into
base: master
Choose a base branch
from
Draft

WIP: release v4.6.0 #6796

wants to merge 1 commit into from

Conversation

jameslamb
Copy link
Collaborator

Release checklist:

Copied from #6538 with a few changes.

deadline

February 14, 2024 (ref: #6791)

before merge

Items to be addressed before merging:

after merge

code to update tags (click me)
NEW_VERSION="4.6.0"
git checkout master
git pull upstream master
git fetch upstream --tags
git tag -d stable
git push upstream :refs/tags/stable
git tag stable
git tag "v${NEW_VERSION}"
git push upstream stable "v${NEW_VERSION}"

after the release is created by Azure DevOps job

  • Add release notes from release-drafter to the automatically-created GitHub release, convert it from Draft to published.
  • Manually attach arm64 macOS wheel to the release
  • Upload release to CRAN
  • Upload release to test PyPI
  • Upload release to PyPI.
code to publish to PyPI (summary)
mkdir /tmp/lgb-release
cd /tmp/lgb-release

NEW_VERSION="4.6.0"

# NOTE: requires a GitHub personal access token with "repo" scope
gh release download \
    --repo microsoft/LightGBM \
    --dir ./artifacts \
    --pattern 'lightgbm*-py3-*.whl' \
    --pattern "lightgbm-${NEW_VERSION}.tar.gz" \
    "v${NEW_VERSION}"

# NOTE: manually downloaded arm64 wheels from CI

# config docs: https://packaging.python.org/en/latest/specifications/pypirc/
twine upload \
    -r testpypi \
    ./artifacts/*

(gh is the GitHub CLI, see https://cli.github.com/manual/gh_release_download)

Then confirmed that installing the latest wheel works.

pip install -i https://test.pypi.org/simple/ "lightgbm==${NEW_VERSION}"
python ./examples/python-guide/logistic_regression.py

Then pushed them to real PyPI.

twine upload \
    ./artifacts/*
code to open that dev version PR (click me)
RELEASE_PR_NUMBER="6439"
RELEASE_VERSION=$(cat ./VERSION.txt)
DEV_VERSION="${RELEASE_VERSION}.99"

git checkout -b ci/dev-version

echo "${DEV_VERSION}" > ./VERSION.txt
sed \
    -i .bak \
    "s|${RELEASE_VERSION}|${DEV_VERSION}|g" \
    .appveyor.yml

sed \
    -i .bak \
    "s|version = \"${RELEASE_VERSION}\"|version = \"${DEV_VERSION}\"|g" \
    ./python-package/pyproject.toml

sed \
    -i .bak \
    's|mode\: release|mode\: unreleased|g' \
    ./R-package/pkgdown/_pkgdown.yml

docker run \
    --rm \
    -v $(pwd):/opt/LightGBM \
    -w /opt/LightGBM \
    ubuntu:22.04 \
    ./R-package/recreate-configure.sh

git add \
    ./.appveyor.yml \
    ./R-package/configure \
    ./R-package/pkgdown/_pkgdown.yml \
    ./VERSION.txt \
    ./python-package/pyproject.toml

commit_msg="bump development version to ${DEV_VERSION}"
git commit -m "${commit_msg}"
git push upstream ci/dev-version

gh pr create \
    --repo microsoft/LightGBM \
    --base 'master' \
    --label 'maintenance' \
    --title "${commit_msg}" \
    --body "now that v${RELEASE_VERSION} has been released: #${RELEASE_PR_NUMBER}"

Notes for Reviewers

I believe this should be v4.6.0 instead of v4.5.1 because of some small breaking changes:

See https://github.com/microsoft/LightGBM/releases.

@jameslamb jameslamb changed the title release v4.6.0 WIP: release v4.6.0 Jan 23, 2025
@jameslamb
Copy link
Collaborator Author

/gha run r-configure

@jameslamb
Copy link
Collaborator Author

I think it's time to start another release!

We need to at least release the R package by February 14th, to stay on CRAN (#6791). But even without that, it's been about 6 months since v4.5.0 and a lot of good changes have piled up.

I've listed the PRs / issues that I think we should try to get into the release. Please comment if there are others you want to try to get in.

@guolinke @shiyu1994 @StrikerRUS @jmoralez @borchero @btrotta

@jameslamb
Copy link
Collaborator Author

jameslamb commented Jan 23, 2025

/gha run r-configure

This failed with the following:

{
  "message": "The 'Microsoft Open Source' enterprise forbids access via a personal access tokens (classic) if the token's lifetime is greater than 365 days. Please adjust your token's lifetime at the following URL: https://github.com/settings/tokens/503169623",
  "documentation_url": "https://docs.github.com/rest/repos/repos#create-a-repository-dispatch-event",
  "status": "403"
}

(build link)

@shiyu1994 can you please fix that in the repo settings? I can update R-package/configure manually and push it, but we'll need to get comment-triggered workflows working again to run the valgrind checks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant