Skip to content

ci: Publish the CLI to PyPI as flagsmith-cli - #99

Open
khvn26 wants to merge 5 commits into
mainfrom
ci/pypi-publish
Open

ci: Publish the CLI to PyPI as flagsmith-cli#99
khvn26 wants to merge 5 commits into
mainfrom
ci/pypi-publish

Conversation

@khvn26

@khvn26 khvn26 commented Aug 20, 2026

Copy link
Copy Markdown
Member

Ships the release binaries as PyPI wheels, so uv tool install flagsmith-cli puts flagsmith on PATH.

The wheels carry no Python code. Each one holds the GoReleaser binary in flagsmith_cli-<version>.data/scripts/flagsmith, which every installer (uv, pip, pipx) copies straight into the environment's bin directory.

This will enable:

  • uv tool install flagsmith-cli
  • uvx --from flagsmith-cli flagsmith
  • pip install flagsmith-cli

I've added a trusted publisher on PyPI for flagsmith-cli:

image

Wheels ship the GoReleaser binary in .data/scripts, so uv/pip/pipx put
flagsmith on PATH with no Python shim. Published from a separate job via
PyPI trusted publishing, keeping third-party code out of the attesting job.
@coderabbitai

coderabbitai Bot commented Aug 20, 2026

Copy link
Copy Markdown

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: ASSERTIVE

Plan: Pro Plus

Run ID: 92ebf36f-5051-4803-bfcf-e96c99a632f8

📥 Commits

Reviewing files that changed from the base of the PR and between d526052 and 3b57f74.

📒 Files selected for processing (3)
  • .github/workflows/release.yml
  • README.md
  • packaging/pypi/build_wheels.py
💤 Files with no reviewable changes (1)
  • README.md

Included review availability: Your plan provides up to 1 included review per hour; 0 remain after this review.


📝 Walkthrough

Walkthrough

The change adds a Python wheel builder for GoReleaser binaries. It converts release tags to PEP 440 versions, maps supported targets to platform tags, embeds executables, and creates deterministic wheel metadata. Pull-request CI validates snapshot wheels. Release CI uploads wheels and publishes them to PyPI with trusted publishing. The README documents installation with uv and execution with uvx. The repository ignores Python bytecode cache directories.

Estimated code review effort: 3 (Moderate) | ~30 minutes

Merge Risk: 🔵 Low · up to 3b57f

The release packaging may advertise macOS compatibility beyond what the built binary supports, which could cause installation or execution failures for some users; mergeable with explicit owner follow-up to align the Darwin wheel tags with supported macOS versions.


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1


ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: ASSERTIVE

Plan: Pro Plus

Run ID: 152e9871-568f-4159-9e60-00f47cee5952

📥 Commits

Reviewing files that changed from the base of the PR and between c0a5cec and d526052.

📒 Files selected for processing (5)
  • .github/workflows/pull-request.yml
  • .github/workflows/release.yml
  • .gitignore
  • README.md
  • packaging/pypi/build_wheels.py

Included review availability: Your plan provides up to 1 included review per hour; 0 remain after this review.

Comment thread packaging/pypi/build_wheels.py Outdated
khvn26 added 3 commits August 20, 2026 11:13
Go 1.26, which go.mod pins and the release job builds with, requires
macOS 12. A macOS wheel tag is a minimum, so 10.13/11 tags let pip
install onto systems the binary cannot run on.
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.

2 participants