3.0 KiB
Releasing the plugin SDK (langbot-plugin)
The SDK shares the LangBot repository with Core and the official plugins, but it
has its own version (sdk/pyproject.toml and src/langbot_plugin/version.py),
its own CI (.github/workflows/sdk-*.yml) and its own PyPI package.
Rules
- Release by pushing a tag named
sdk/vX.Y.Z(pre-releases:sdk/vX.Y.ZrcN)..github/workflows/sdk-publish.ymlchecks that the tag matchessdk/pyproject.toml, buildssdk/and publisheslangbot-pluginto PyPI. If the version is already on PyPI it uploads nothing. - Never create a GitHub Release for the SDK. Every
release: publishedevent in this repository belongs to Core: Dockerlatest, Core PyPI, release assets, fnOS, Discord and changelog sync listen to it, and LangBot Space's update check reads this repository's release list. Core release workflows only acceptv*tags, but a SDK release in the list would still hide Core updates from deployed instances. Write SDK release notes in the PR that bumps the version. - Never use plain
vX.Y.Ztags for the SDK; those are Core releases. - Root
uv syncresolves Core's exactlangbot-plugin==Xrequirement to the editable localsdk/source. Checkouts, Docker, release ZIPs and fnOS carry that source and can use coordinated SDK changes before an SDK release. - The standalone Core PyPI package retains the exact published dependency; its wheel excludes SDK code. Publishing that package requires the matching SDK release first. Independently installed Runtimes and plugins also need their own compatible SDK installation.
Steps
-
Bump
versioninsdk/pyproject.tomlandsrc/langbot_plugin/version.py(tests/packaging/test_release_metadata.pychecks they match) and merge. -
Tag the merged commit and push the tag:
git tag sdk/v0.7.25 <commit> git push origin sdk/v0.7.25 -
Confirm the SDK / Publish to PyPI run and the new version on https://pypi.org/project/langbot-plugin/.
-
For the standalone Core PyPI package, bump
langbot-plugin==Xin the rootpyproject.toml, runuv lock, and pass the gate below before publishing. Source-based Core deployments do not need to wait for this publication.
Core release gate
scripts/check_sdk_release_pin.py runs in the standalone Core PyPI release
workflow. Docker and source distributions use the checked-out SDK directly.
The PyPI gate fails when:
- Core's pin differs from
sdk/pyproject.toml; - that version is not on PyPI;
- the tag
sdk/v<pin>is missing, orsdk/src/sdk/pyproject.tomlchanged after it (unreleased SDK code in the Core release commit).
When it fails, release the SDK first and bump the pin, or revert the unreleased SDK change on the release branch.
History
The SDK was imported as a snapshot of langbot-app/langbot-plugin-sdk v0.7.24
(sdk/SOURCE.json). Older history, issues, pull requests and the v0.x tags
remain in that archived repository. The baseline tag sdk/v0.7.24 marks the
import in this repository.