发布 Flower

本文件描述了当前的发布流程。今后可能会有变化,也可能不会有变化。

在发布期间

The version number of a release is stated in ./framework/pyproject.toml. To release a new version of Flower, the following things need to happen (in that order):

  1. Run python3 ./framework/dev/update_changelog.py <YOUR_GH_TOKEN> to add all new changes to the changelog. You can make manual edits to the changelog afterward to improve its formatting or wording. This script will also replace the ## Unreleased header with the new version number and current date, and add a thank-you message for contributors. Open a pull request with these changes.

  2. Once the pull request is merged, tag the release commit with the version number: git tag v<NEW_VERSION> (notice the v added before the version number), then git push --tags. This will create a draft release on GitHub containing the correct artifacts and the relevant part of the changelog.

  3. 检查 GitHub 上的发布稿,如果一切正常,就发布它。

发布后

创建包含以下更改的拉取请求:

  1. Increase the minor version in pyproject.toml by one and update all files which contain the current version number (if necessary) by running ./framework/dev/update_version.py.

  2. Add a new ## Unreleased section at the top of ./framework/docs/source/ref-changelog.md to prepare for future changes.

在同一天合并拉取请求(即在新版本发布到 PyPI 之前)。

发布预发布版本

释放前命名

PyPI 支持预发布版本(alpha、beta、release candidate)。预发布版本必须使用以下命名模式之一:

  • 阿尔法 MAJOR.MINOR.PATCHaN

  • 贝塔: MAJOR.MINOR.PATCHbN

  • 版本代号 (RC): MAJOR.MINOR.PATCHrcN

例子包括:

  • 1.0.0a0

  • 1.0.0b0

  • 1.0.0rc0

  • 1.0.0rc1

这符合 PEP-440 和 Python 包装管理局 (PyPA) 的建议:

请注意,PyPA 所定义的方法与 SemVer 2.0.0 规范不兼容,详情请查阅《语义版本规范》<https://semver.org/spec/v2.0.0.html#spec-item-11>`_(特别是关于优先级的第 11 项)。

发布前分类

下一个预发布版应该叫阿尔法版、贝塔版还是候选发布版?

  • RC:功能完整,无已知问题(除了下一个稳定版中被列为 "不会修复 "的问题)--如果没有问题出现,这将成为下一个稳定版

  • 贝塔版:功能完整,允许存在已知问题

  • 阿尔法版:功能不完整,允许存在已知问题