Release runs create no Git tags since 3.34.3

Đang mở
#4,167 0 bình luận 0 reaction 0 người được giao Xem trên GitHub

Maintainer thường phản hồi trong vòng 2 ngày

@anth-volk đang làm issue này rồi.

Từ ngày 3/11/2026.

  • #4168 của @anth-volk — đang mở

Đánh giá

Độ khó
3/5
Thời gian dự kiến
Nửa ngày
Mức phù hợp với người mới
45/100
Loại issue
Lỗi
Độ rõ ràng
Đặc tả rõ ràng
Mức độ hoạt động
Sôi nổi
Công nghệ
bash, git, github-actions, python, yaml
Lĩnh vực
ci-cd, cloud

Hướng nghiên cứu

Start with .github/publish-git-tag.sh and the "Publish Git Tag" job in push.yml, then read pyproject.toml for the [project] version. The .github/scripts ci-scripts guard shows how the new script and its tests in tests/unit must be set up. Done when the script reads the version from pyproject.toml, creates and pushes only the tag for this commit, and a rerun on the same commit passes.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Mô tả

Problem

The "Publish Git Tag" job in push.yml runs .github/publish-git-tag.sh on each release commit:

git tag `python setup.py --version`
git push --tags || true  # update the repository version

It hasn't created a tag since 3.34.3 (release e81ed3db, 2026-02-24), but the job passes on every release. On release run 41723443801 it logged:

python: can't open file '/home/runner/work/policyengine-api/policyengine-api/setup.py': [Errno 2] No such file or directory
Everything up-to-date
  • setup.py was removed on 2026-03-06 (#3319); the version is in [project] in pyproject.toml.
  • With no version, the script runs a bare git tag, which lists tags and exits 0. git push --tags then has nothing to push, and || true would hide a failure anyway. The script has no set -e, so it exits 0.
  • Tagging stopped before setup.py was removed. Commit 1e182346 (2026-02-24) moved the step to Python 3.12, which setup-python ships without setuptools, and setup.py began with from setuptools import setup. The job installs nothing before the step. (Inferred: the February job logs are no longer available.)

The script is outside .github/scripts, so the ci-scripts guard doesn't run shellcheck on it or require a test for it.

Proposal

  • Move the script to .github/scripts/publish_git_tag.sh, so the ci-scripts guard covers it, with tests in tests/unit.
  • Read the version from [project] in pyproject.toml, and fail if it's missing or isn't a release version.
  • Create a tag on the release commit named after the version, as the existing tags are (3.34.3), and push only that tag.
  • If the tag already exists on the remote and names this commit, succeed without changes, so a rerun of a release passes. If it names a different commit, fail.
  • Run with set -euo pipefail, without || true.

The releases from 3.35.0 to the current version have no tags. Whether to create those afterwards is a separate decision.

Ngôn ngữ chính
Python
Star
18
Fork
33
Merge trung bình
2 ngày 21 giờ
Pull request đã merge (30 ngày)
88

Chuẩn bị môi trường

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của PolicyEngine/policyengine-api

Tất cả issue của PolicyEngine/policyengine-api

Issue tương tự

Thêm issue về Python

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.