JupyterLab Desktop needs to be versioned with the same major, minor and patch versions as the JupyterLab it bundles. For example, if JupyterLab Desktop is based on JupyterLab 3.1.12, a valid JupyterLab Desktop version is 3.1.12-1 to 3.1.12-n. Last number after - is used as the build number. This version matching is enforced before JupyterLab Desktop installer binaries are published.
JupyterLab version, that JupyterLab Desktop bundles, is determined by @jupyterlab/metapackage dependency version in the yarn.lock.
If the JupyterLab version is not changing with the new JupyterLab Desktop release then only increment the build number after - (for example 3.1.12-2 to 3.1.12-3). However, if JupyterLab version is changing with the new JupyterLab Desktop release then reset the build number after - to 1 (for example 3.1.12-3 to 3.1.13-1).
Run the check_version_match script before committing version changes to ensure version integrity:
yarn check_version_matchUpdating to a new JupyterLab release is automated by the Check for new JupyterLab releases workflow. It runs daily (and can be dispatched manually from the Actions tab), and when a new JupyterLab release is found it:
- Bumps the application version to
<new-jlab-version>-1using tbump - Updates the conda lock files (
yarn update_conda_lock) - Updates the macOS binary sign lists for
osx-64andosx-arm64 - Opens a PR titled
Update to JupyterLab v<new-jlab-version>
When reviewing the PR:
- Review the lock file changes carefully.
- Update
ipywidgetspython package version inenv_installer/jlab_server.yamlif there is a compatible newer version available. This is not automated.
If the workflow fails or a manual update is needed, the same steps can be run locally (requires pip install tbump):
tbump --only-patch <new-jlab-version>-1
yarn update_conda_lock
yarn create_env_installer:osx-64 && yarn update_binary_sign_list --platform osx-64
yarn create_env_installer:osx-arm64 && yarn update_binary_sign_list --platform osx-arm64Releases are driven by manually dispatched GitHub Actions workflows. They must be run from the main repo (they authenticate as a GitHub App configured in the release environment), on the master branch. The release version is always read from package.json.
-
If the version in
package.jsonhas already been released, bump the version first. A new JupyterLab version is normally bumped by the sync workflow PR described above; to re-release the same JupyterLab version, increment the build number locally with tbump and merge that change (for example, bump from3.1.12-2to3.1.12-3):tbump --only-patch 3.1.12-3
If the version in
package.jsonhas not been released yet, there is nothing to bump. -
Dispatch the
Create Pre-releaseworkflow. It creates a GitHub release of typepre-releasewith tagv<version>(for examplev3.1.12-3), unless a release with that tag already exists. Edit the release description to add the release notes; they can be refined at any time before publishing. The release needs to stay aspre-releasefor GitHub Actions to be able to attach installers to it. -
Dispatch the
Create Release PRworkflow. It verifies that the pre-release exists, then creates arelease-v<version>branch with a placeholder commit and opens aRelease v<version>PR. -
The
Publishworkflow runs on the PR (and on any push tomaster). When it finds a draft or pre-release with a tag matching the version inpackage.json, it builds signed installers for each platform (Linux, macOS, Windows) and uploads them as assets to that release. New runs overwrite the existing installer assets. Release builds also publish the snap installer to thelatest/candidatechannel in the Snap Store. -
Make sure that application is building, installing and running properly by following the distribution build instructions locally, or by testing the installers attached to the pre-release.
-
Once all the changes are complete, installers are uploaded and the release notes are ready, merge the release PR and publish the release.
-
After publishing, dispatch the
Publish to WinGetworkflow with the release tag (for examplev3.1.12-3) as the version input to submit the Windows installer to the WinGet package registry.The submission PR to microsoft/winget-pkgs is opened from the fork owned by the dedicated
jupyterlab-winget-botmachine account. The account name and its classic PAT (public_reposcope) are configured in thewingetenvironment as theWINGET_USERvariable andWINGET_TOKENsecret. The token expires and needs to be regenerated on the bot account every 9 months, then updated in the environment. -
Promote the snap from
latest/candidatetolatest/stable. This is a manual step: CI only publishes to the candidate channel. Open the Releases page of the snap listing in the Snapcraft UI and promote the candidate revision to stable.