-
Notifications
You must be signed in to change notification settings - Fork 116
Add create pull request and auto-merge PR to release workflow #479
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
Merged
gsheni
merged 76 commits into
main
from
478-copulas-release-workflow-errors-with-failed-to-push-some-refs-to-httpsgithubcomsdv-devcopulas
Jun 20, 2025
Merged
Changes from all commits
Commits
Show all changes
76 commits
Select commit
Hold shift + click to select a range
3c176c8
Update release.yml
gsheni 5c1df72
Update release.yml
gsheni 17ea360
Update release.yml
gsheni fc82621
Update .gitignore
gsheni 3290a67
Update release.yml
gsheni a8c9024
Update __init__.py
gsheni a12b2f6
Update release.yml
gsheni 14326f8
Update release.yml
gsheni 5844bf0
Update release.yml
gsheni a388543
Update release.yml
gsheni 2b3b194
Update release.yml
gsheni 2c157ed
Update release.yml
gsheni c554077
Update release.yml
gsheni 47edeaa
Update release.yml
gsheni 361ec38
Update __init__.py
gsheni 9ba49d4
Update release.yml
gsheni 1d0d521
Update release.yml
gsheni 041ea99
Update __init__.py
gsheni e7f3e82
Update release.yml
gsheni b12f613
Update __init__.py
gsheni 3bbf439
Update pyproject.toml
gsheni db846f1
Update __init__.py
gsheni 3e5e3cc
Automated Bump Version Candidate (#481)
sdv-team b8287b1
Update release.yml
gsheni ba4dc1e
Update release.yml
gsheni 72d7168
Update __init__.py
gsheni dd6f141
Update pyproject.toml
gsheni 64ff1c8
Update pyproject.toml
gsheni 94ebbbb
Update pyproject.toml
gsheni 5a47d2f
Update release.yml
gsheni db17054
Update release.yml
gsheni 5501f31
Update release.yml
gsheni dc44de4
Update release.yml
gsheni b6bc140
Update release.yml
gsheni 33e08d6
Update __init__.py
gsheni e2349eb
Update pyproject.toml
gsheni 163d135
Update pyproject.toml
gsheni 08759b8
Update pyproject.toml
gsheni 5a2c36a
Update pyproject.toml
gsheni cc14f43
Update __init__.py
gsheni 1baeab5
Update release.yml
gsheni 738060b
Update release.yml
gsheni e6055d1
Update pyproject.toml
gsheni e20772c
Update __init__.py
gsheni 24b5ea6
Update release.yml
gsheni a896676
Update __init__.py
gsheni a4ccf79
Update pyproject.toml
gsheni cc0b5d1
Update release.yml
gsheni bc85fa4
Update __init__.py
gsheni 5157fbb
Update pyproject.toml
gsheni bd92ae2
Update release.yml
gsheni 6c35701
Update release.yml
gsheni 6fcbef6
Update release.yml
gsheni 29dab7f
Update __init__.py
gsheni 0e40591
Update pyproject.toml
gsheni 115ea74
Update release.yml
gsheni 4b530b7
Update pyproject.toml
gsheni 4edc7c5
Update __init__.py
gsheni 2985d52
Update __init__.py
gsheni 34596a0
Update __init__.py
gsheni d2a9333
Update pyproject.toml
gsheni 50465b3
Update pyproject.toml
gsheni d0870f2
Update __init__.py
gsheni 8b68d8d
Update RELEASE.md
gsheni 313d5d7
Update Makefile
gsheni dfaeea8
update release.md
gsheni c7c6d12
cleanup
gsheni 5eb0245
cleanup 2
gsheni bda6684
better header
gsheni 9ac98b0
better text
gsheni 8c373eb
better text
gsheni 55fc673
better text
gsheni b227a70
remove tox
gsheni 024dce7
remove tox 2
gsheni 08d1ece
final cleanup
gsheni 6e38d15
Update RELEASE.md
gsheni File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,7 +3,10 @@ name: Release | |
on: | ||
release: | ||
types: [published] | ||
|
||
branches: | ||
- main | ||
- stable | ||
|
||
workflow_dispatch: | ||
inputs: | ||
candidate: | ||
|
@@ -12,13 +15,15 @@ on: | |
type: boolean | ||
default: true | ||
test_pypi: | ||
description: 'Test PyPi.' | ||
description: 'Test PyPI.' | ||
type: boolean | ||
default: false | ||
|
||
jobs: | ||
release: | ||
runs-on: ubuntu-latest | ||
permissions: | ||
id-token: write | ||
steps: | ||
- uses: actions/checkout@v4 | ||
with: | ||
|
@@ -41,13 +46,38 @@ jobs: | |
- name: Publish a Python distribution to PyPI | ||
uses: pypa/gh-action-pypi-publish@release/v1 | ||
with: | ||
password: ${{ inputs.test_pypi && secrets.TEST_PYPI_API_TOKEN || secrets.PYPI_API_TOKEN }} | ||
repository-url: ${{ inputs.test_pypi && 'https://test.pypi.org/legacy/' || 'https://upload.pypi.org/legacy/' }} | ||
|
||
- name: Bump version to next candidate | ||
if: ${{ inputs.candidate && !inputs.test_pypi }} | ||
run: | | ||
git config user.name "github-actions[bot]" | ||
git config user.email "41898282+github-actions[bot]@users.noreply.github.com" | ||
make bumpversion-candidate | ||
make git-push | ||
bump-my-version bump candidate --no-tag --no-commit | ||
|
||
- name: Create pull request | ||
if: ${{ inputs.candidate && !inputs.test_pypi }} | ||
id: cpr | ||
uses: peter-evans/create-pull-request@v4 | ||
with: | ||
token: ${{ secrets.GH_ACCESS_TOKEN }} | ||
commit-message: bumpversion-candidate | ||
committer: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> | ||
author: ${{ github.actor }} <${{ github.actor_id }}+${{ github.actor }}@users.noreply.github.com> | ||
signoff: false | ||
delete-branch: true | ||
title: Automated Bump Version Candidate | ||
body: "This is an auto-generated PR that bumps the version to the next candidate." | ||
branch: bumpversion-candidate-update | ||
branch-suffix: short-commit-hash | ||
add-paths: | | ||
copulas/__init__.py | ||
pyproject.toml | ||
draft: false | ||
base: 'main' | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Assuming the base branch (target branch) should be |
||
|
||
- name: Enable Pull Request Automerge | ||
if: ${{ steps.cpr.outputs.pull-request-operation == 'created' }} | ||
run: gh pr merge "${{ steps.cpr.outputs.pull-request-number }}" --squash --admin | ||
env: | ||
GH_TOKEN: ${{ secrets.GH_ACCESS_TOKEN }} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,6 @@ | ||
.github/.tmp/ | ||
tests/readme_test/ | ||
|
||
# Byte-compiled / optimized / DLL files | ||
__pycache__/ | ||
*.py[cod] | ||
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,7 +2,7 @@ | |
|
||
__author__ = 'DataCebo, Inc.' | ||
__email__ = '[email protected]' | ||
__version__ = '0.12.4.dev0' | ||
__version__ = '0.12.4.dev3' | ||
|
||
import sys | ||
import warnings | ||
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
password
can be removed because Copulas has been added as a trusted publisher for Test PyPI.Note: For real PyPI, this is still a WIP.