This is an automated email from the ASF dual-hosted git repository.
potiuk pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/airflow.git
The following commit(s) were added to refs/heads/main by this push:
new a3e5a971ed Fix preparing rc candidates for providers (#36465)
a3e5a971ed is described below
commit a3e5a971edf9e4e86c86d595daa04dccd277aabe
Author: Jarek Potiuk <[email protected]>
AuthorDate: Thu Dec 28 10:53:57 2023 +0100
Fix preparing rc candidates for providers (#36465)
The last auto-upgrade RC implementd in #36441 had a bug - it was bumping
rc even for providers that have been already released. This change fixes
it - it skips packages that already have "final" tag present in the
repo. It also explicitely calls "Apply template update" as optional
step - only needed in case we modify templates and want to update
automatically generated documentation with it.
---
dev/README_RELEASE_PROVIDER_PACKAGES.md | 7 ++++---
.../src/airflow_breeze/prepare_providers/provider_packages.py | 4 ++++
2 files changed, 8 insertions(+), 3 deletions(-)
diff --git a/dev/README_RELEASE_PROVIDER_PACKAGES.md
b/dev/README_RELEASE_PROVIDER_PACKAGES.md
index 199480c43b..ba0657f507 100644
--- a/dev/README_RELEASE_PROVIDER_PACKAGES.md
+++ b/dev/README_RELEASE_PROVIDER_PACKAGES.md
@@ -29,7 +29,7 @@
- [Prepare Regular Provider packages
(RC)](#prepare-regular-provider-packages-rc)
- [Increasing version number](#increasing-version-number)
- [Generate release notes](#generate-release-notes)
- - [Apply template updates](#apply-template-updates)
+ - [(Optional) Apply template updates](#optional-apply-template-updates)
- [Open PR with suggested version
releases](#open-pr-with-suggested-version-releases)
- [Build provider packages for SVN apache
upload](#build-provider-packages-for-svn-apache-upload)
- [Build and sign the source and convenience
packages](#build-and-sign-the-source-and-convenience-packages)
@@ -262,9 +262,10 @@ breeze release-management prepare-provider-documentation
--include-removed-provi
--base-branch provider-cncf-kubernetes/v4-4 cncf.kubernetes
```
-## Apply template updates
+## (Optional) Apply template updates
-(This step can also be executed independently when needed)
+This step should only be executed if we want to change template files for the
providers - i.e. change
+security information, commit/index/README content that is automatically
generated.
Regenerate the documentation templates by running the command with
`--reapply-templates` flag to the command above. This refreshes the content of:
diff --git
a/dev/breeze/src/airflow_breeze/prepare_providers/provider_packages.py
b/dev/breeze/src/airflow_breeze/prepare_providers/provider_packages.py
index e8d99e6ed6..a158334f7d 100644
--- a/dev/breeze/src/airflow_breeze/prepare_providers/provider_packages.py
+++ b/dev/breeze/src/airflow_breeze/prepare_providers/provider_packages.py
@@ -172,6 +172,10 @@ def should_skip_the_package(provider_id: str,
version_suffix: str) -> tuple[bool
return False, version_suffix
# version_suffix starts with "rc"
current_version = int(version_suffix[2:])
+ release_tag = get_latest_provider_tag(provider_id, "")
+ if tag_exists_for_provider(provider_id, release_tag):
+ get_console().print(f"[warning]The tag {release_tag} exists. Provider
is released. Skipping it.[/]")
+ return True, ""
while True:
current_tag = get_latest_provider_tag(provider_id,
f"rc{current_version}")
if tag_exists_for_provider(provider_id, current_tag):