Skip to content

Fix release pipeline failures#3423

Merged
pingsutw merged 2 commits intomasterfrom
fix-release-pipeline
Apr 13, 2026
Merged

Fix release pipeline failures#3423
pingsutw merged 2 commits intomasterfrom
fix-release-pipeline

Conversation

@pingsutw
Copy link
Copy Markdown
Member

Tracking Issue

N/A - operational fix for release pipeline

Why are the changes needed?

The v1.16.17 release pipeline failed due to multiple issues:

  1. Transient PyPI connection error: The flytekitplugins_dask upload hung for 4 minutes during plugin publishing, then PyPI dropped the connection (RemoteDisconnected). This killed the entire deploy job, causing all Docker image builds to be skipped.

  2. Re-runs are not idempotent: Re-running the failed workflow fails immediately because twine upload returns 400 Bad Request for already-uploaded packages.

  3. build_image.yml passes github.sha as VERSION: The manual image build workflow passed the commit SHA as the PyPI version, which is not a valid PEP 440 version string, causing uv pip install flytekit==<sha> to fail.

  4. Unstable Python version: actions/setup-python@v1 with python-version: "3.x" resolved to Python 3.14.3, which is brand new and potentially unstable for building release artifacts.

What changes were made?

pythonpublish.yml

  • Upgrade actions/setup-python from v1 to v5
  • Pin Python to 3.12 instead of 3.x
  • Add --verbose --skip-existing to twine upload so re-runs skip already-uploaded packages
  • Use safer shell parameter expansion (${GITHUB_REF#refs/tags/v}) instead of piping through sed

build_image.yml

  • Add get-version job that extracts the semver from the branch/tag name (strips v prefix)
  • All image build jobs now use the extracted version instead of github.sha as the VERSION build arg
  • Add version-based image tags alongside SHA-based tags

plugins/Makefile

  • Add --verbose --skip-existing to both twine upload commands

How was this tested?

Reviewed CI logs from the failed v1.16.17 release runs:

Check all the applicable boxes

  • My code follows the style guidelines of this project
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • My changes generate no new warnings
  • I have added tests that prove my fix is effective or that my feature works

The v1.16.17 release failed because a transient PyPI connection error
during plugin upload killed the entire deploy job, and re-runs failed
because already-uploaded packages return 400. The manual build_image
workflow also failed because it passed github.sha as the package version
instead of the actual semver.

Changes:
- Upgrade actions/setup-python from v1 to v5 and pin Python to 3.12
  (3.x resolved to unstable Python 3.14)
- Add --verbose --skip-existing to all twine upload commands so re-runs
  skip already-uploaded packages instead of failing
- Fix build_image.yml to derive VERSION from branch/tag name instead of
  github.sha, which is not a valid PyPI version
- Use safer shell parameter expansion for GITHUB_REF parsing

Signed-off-by: Kevin Su <kevin@union.ai>
Signed-off-by: Kevin Su <pingsutw@apache.org>
If triggered from a non-version ref like 'master', error out with a
clear message instead of silently using an invalid PyPI version.

Signed-off-by: Kevin Su <pingsutw@apache.org>
@pingsutw pingsutw merged commit 39d4a9f into master Apr 13, 2026
16 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant