Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add ci and release github actions for easier maintenance #120

Closed
wants to merge 1 commit into from

Conversation

mbachry
Copy link

@mbachry mbachry commented Dec 9, 2021

Linux and Mac binary wheels were handled by travis builds, but it seems that travis is currently broken. Instead of fixing it, I suggest a single github action that builds wheels for all three platforms (thus replacing both travis and appveyor). The action is triggered by pushing a git tag with v prefix (eg. v2.1.0) - this should be the only operation required to make a full release.

Some changes:

  • build.yml action that builds and uploads a release on a new git tag; regular pushes upload to test.pypi.org (matches current behavior)
  • added setuptools_scm, so you don't have to edit version.py (the version is picked automatically from the current git tag)
  • a simple ci.yml for running tests

Here's my test release: https://test.pypi.org/project/hiredis-mytest/0.0.0.dev0/#files (all currently supported platforms are there)

Note that TEST_PYPI_API_TOKEN and PYPI_API_TOKEN pypi secrets would have to be created in github repo settings for pypi uploads to work.

@jlvrhee
Copy link

jlvrhee commented Mar 25, 2022

Is there anyone who can merge this pull request, so we get an updated wheel in pypi?

Thanks in advance

Copy link

@rth rth left a comment

Choose a reason for hiding this comment

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

This looks really good. Thanks @mbachry . Now we need to find a maintainer to review/merge it.

Also Github Actions didn't trigger. Either it needs to be approved by a maintainer or I found that manually adding some starting setup in the "Actions" tab is usually sufficient to make it enabled.


- name: Set test tag
if: ${{ !startsWith(github.event.ref, 'refs/tags/v') }}
run: git tag -f v0.0.0-dev0
Copy link

Choose a reason for hiding this comment

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

We shouldn't forget to remove it before merging.


- name: Set test tag
if: ${{ !startsWith(github.event.ref, 'refs/tags/v') }}
run: git tag -f v0.0.0-dev0
Copy link

Choose a reason for hiding this comment

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

Same comment.

run: git tag -f v0.0.0-dev0

- name: Build sdist
run: pipx run build --sdist
Copy link

Choose a reason for hiding this comment

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

Let's maybe avoid pipx,

pip install build
python -m build --sdist

is the more standard way.

@ifduyue
Copy link
Collaborator

ifduyue commented Oct 12, 2022

Also Github Actions didn't trigger.

I think those .github files should go first into master branch and then github actions can be triggered.
But I can't add PyPI tokens to this repo's github action secrets.
This needs some help from someone with repo admin rights.

@rth
Copy link

rth commented Oct 12, 2022

Yes, makes sense. Looks like it's blocked by #63 for now.

@chayim chayim closed this in #136 Dec 12, 2022
chayim added a commit that referenced this pull request Dec 12, 2022
closes #120
closes #122
closes #124
closes #129
closes #130
closes #121
closes #118
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.

4 participants