BeiBaiNian opened a new pull request, #8:
URL: https://github.com/apache/casbin-python-django-orm-adapter/pull/8
## Why
This repository currently releases automatically via semantic-release
(`npx semantic-release` on every push to master). As an Apache (incubating)
project, every release must pass a formal Apache vote before it is published.
Automatic releases on merge are not acceptable for an Apache project:
- a merged PR would trigger an immediate PyPI publish without a vote, and
- the release manager must be able to cut a release candidate (rc) tag,
run the Apache vote on it, and only publish the final tag after approval.
This PR replaces the automatic release pipeline with a manual,
tag-triggered workflow, following the same pattern already adopted by
casbin, casbin-sqlx-adapter, casbin-jcasbin-jdbc-adapter and
casbin-mongodb-adapter.
## What changed
- Deleted `.releaserc.json` (semantic-release configuration).
- Deleted `package.json` (only contained semantic-release dependencies).
- Removed the `release` job from `.github/workflows/build.yml`
(the `npx semantic-release` step).
- Added `.github/workflows/release.yml`, triggered by pushing a tag:
- `vX.Y.Z-rcN` → creates a GitHub **pre-release** with the Apache
source package
(`apache-casbin-django-orm-adapter-<version>-incubating-src.tar.gz`
+ `.sha512`) for the Apache vote;
- `vX.Y.Z` → creates the GitHub **release** and publishes the package
to PyPI via `twine` using the existing `PYPI_TOKEN` secret.
- The workflow validates that the tag version matches `pyproject.toml`
before building the source package.
## Verification
- Both workflows parse as valid YAML (jobs: `test`/`lint`/`coveralls` in
`build.yml`, `release` in `release.yml`).
- No semantic-release or `.releaserc*` remnants left in the repository.
- No third-party GitHub Actions are used; only official `actions/*`,
`gh` CLI and native `twine` commands (safe for the ASF allowed-actions
policy).
- Tag parsing logic (`vX.Y.Z` / `vX.Y.Z-rcN`) covered with local tests.
- CI runs on this PR validate the `build` workflow; the `release`
workflow runs only when a tag is pushed.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]