Skip to content

Add CI workflows for releasing Python and JavaScript packages#19

Merged
colonelpanic8 merged 1 commit intorlrml:masterfrom
jtmarks6:ci/add-release-workflows
Mar 4, 2026
Merged

Add CI workflows for releasing Python and JavaScript packages#19
colonelpanic8 merged 1 commit intorlrml:masterfrom
jtmarks6:ci/add-release-workflows

Conversation

@jtmarks6
Copy link
Copy Markdown
Contributor

@jtmarks6 jtmarks6 commented Mar 4, 2026

Summary

This PR adds automated release workflows for publishing to PyPI and npm when a version tag is pushed.

What's included

  • .github/workflows/release-python.yml - Builds manylinux wheels for:

    • Linux x86_64 (manylinux) - compatible with AWS Lambda, Docker, etc.
    • Linux aarch64 (ARM)
    • Windows x86_64
    • macOS
    • Source distribution
  • .github/workflows/release-js.yml - Builds WASM and publishes to npm

  • RELEASING.md - Documentation for the release process

Why this is needed

Currently only source distributions are published to PyPI. This means users on Linux (AWS Lambda, Docker, CI systems) must have Rust installed to compile subtr-actor-py. Pre-built manylinux wheels eliminate this requirement and make installation much faster.

Setup required (one-time)

Before the workflows will work, you'll need to configure secrets:

  1. PyPI (choose one):

    • Trusted Publishing (recommended): Go to PyPI → Account Settings → Publishing → Add pending publisher with repo rlrml/subtr-actor, workflow release-python.yml, environment pypi
    • API Token: Add PYPI_TOKEN as a GitHub secret
  2. npm: Add NPM_TOKEN as a GitHub secret

How to release (after setup)

# 1. Bump versions
just bump 0.1.11   # or manually edit Cargo.toml, python/pyproject.toml, js/package.json

# 2. Commit and tag
git commit -am "Release v0.1.11"
git tag v0.1.11
git push origin master --tags

The workflows trigger automatically on v* tags.


🤖 Generated with Claude Code

This PR adds automated release workflows for PyPI and npm publishing.

## What's included

- `.github/workflows/release-python.yml` - Builds manylinux wheels for Linux,
  Windows, and macOS, then publishes to PyPI
- `.github/workflows/release-js.yml` - Builds WASM and publishes to npm
- `RELEASING.md` - Documentation for the release process

## Why this is needed

Currently only source distributions are published to PyPI, which means users
on Linux (including AWS Lambda, Docker containers, etc.) must have Rust
installed to use subtr-actor-py. Pre-built wheels eliminate this requirement.

## Setup required

Before the workflows will work, the repo owner needs to configure:

1. **PyPI**: Set up trusted publishing or add `PYPI_TOKEN` secret
2. **npm**: Add `NPM_TOKEN` secret

See RELEASING.md for detailed setup instructions.

## How to release

After setup, releasing is simple:
1. Bump versions in Cargo.toml, python/pyproject.toml, js/package.json
2. Commit, tag with `v*`, and push

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@colonelpanic8 colonelpanic8 merged commit d0df817 into rlrml:master Mar 4, 2026
1 check passed
@colonelpanic8
Copy link
Copy Markdown
Contributor

but wont this not work in ci because we havent set up the tokens in the github context?

@jtmarks6
Copy link
Copy Markdown
Contributor Author

jtmarks6 commented Mar 4, 2026

Yeah I haven't worked with github ci before, I usually use circleCI. I assumed there was a way to input tokens as secrets

@colonelpanic8
Copy link
Copy Markdown
Contributor

there is, but i would need to generate them right, since i own the packages?

@jtmarks6
Copy link
Copy Markdown
Contributor Author

jtmarks6 commented Mar 5, 2026

Yes I think you would need to since you own it. Once it get setup it should publish to all the envs automatically and not need to be touched again

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