Skip to content

Commit 58fd713

Browse files
committed
make release-tag: Merge branch 'main' into stable
2 parents 8f332b0 + d37a295 commit 58fd713

28 files changed

+667
-350
lines changed

.github/workflows/dependency_checker.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,10 +8,10 @@ jobs:
88
runs-on: ubuntu-latest
99
steps:
1010
- uses: actions/checkout@v4
11-
- name: Set up Python 3.9
11+
- name: Set up latest Python
1212
uses: actions/setup-python@v5
1313
with:
14-
python-version: 3.9
14+
python-version-file: 'pyproject.toml'
1515
- name: Install dependencies
1616
run: |
1717
python -m pip install .[dev]

.github/workflows/integration.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,11 +10,11 @@ jobs:
1010
runs-on: ${{ matrix.os }}
1111
strategy:
1212
matrix:
13-
python-version: ['3.8', '3.9', '3.10', '3.11', '3.12', '3.13']
13+
python-version: ['3.9', '3.10', '3.11', '3.12', '3.13']
1414
os: [ubuntu-latest, windows-latest]
1515
include:
1616
- os: macos-latest
17-
python-version: '3.8'
17+
python-version: '3.9'
1818
- os: macos-latest
1919
python-version: '3.13'
2020
steps:

.github/workflows/lint.yml

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,15 +5,19 @@ on:
55
pull_request:
66
types: [opened, reopened]
77

8+
concurrency:
9+
group: ${{ github.workflow }}-${{ github.ref }}
10+
cancel-in-progress: true
11+
812
jobs:
913
lint:
10-
runs-on: ubuntu-20.04
14+
runs-on: ubuntu-latest
1115
steps:
1216
- uses: actions/checkout@v4
13-
- name: Set up Python 3.9
17+
- name: Set up latest Python
1418
uses: actions/setup-python@v5
1519
with:
16-
python-version: 3.9
20+
python-version-file: 'pyproject.toml'
1721
- name: Install dependencies
1822
run: |
1923
python -m pip install --upgrade pip

.github/workflows/minimum.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,11 +11,11 @@ jobs:
1111
runs-on: ${{ matrix.os }}
1212
strategy:
1313
matrix:
14-
python-version: ['3.8', '3.9', '3.10', '3.11', '3.12', '3.13']
14+
python-version: ['3.9', '3.10', '3.11', '3.12', '3.13']
1515
os: [ubuntu-latest, windows-latest]
1616
include:
1717
- os: macos-13
18-
python-version: '3.8'
18+
python-version: '3.9'
1919
- os: macos-latest
2020
python-version: '3.13'
2121
steps:

.github/workflows/prepare_release.yml

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,18 +19,22 @@ jobs:
1919
runs-on: ubuntu-latest
2020
steps:
2121
- uses: actions/checkout@v4
22-
- name: Set up Python 3.10
22+
- name: Set up latest Python
2323
uses: actions/setup-python@v5
2424
with:
25-
python-version: '3.10'
25+
python-version-file: 'pyproject.toml'
2626

2727
- name: Install dependencies
2828
run: |
2929
python -m pip install --upgrade pip
3030
python -m pip install requests==2.31.0
3131
python -m pip install bandit==1.7.7
32+
python -m pip install packaging
3233
python -m pip install .[test]
3334
35+
- name: Check for prerelease dependencies
36+
run: python scripts/check_for_prereleases.py
37+
3438
- name: Generate release notes
3539
env:
3640
GH_ACCESS_TOKEN: ${{ secrets.GH_ACCESS_TOKEN }}

.github/workflows/readme.yml

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,12 +5,16 @@ on:
55
pull_request:
66
types: [opened, reopened]
77

8+
concurrency:
9+
group: ${{ github.workflow }}-${{ github.ref }}
10+
cancel-in-progress: true
11+
812
jobs:
913
readme:
1014
runs-on: ${{ matrix.os }}
1115
strategy:
1216
matrix:
13-
python-version: ['3.8', '3.9', '3.10', '3.11', '3.12', '3.13']
17+
python-version: ['3.9', '3.10', '3.11', '3.12', '3.13']
1418
os: [ubuntu-latest, macos-latest] # skip windows bc rundoc fails
1519
steps:
1620
- uses: actions/checkout@v4

.github/workflows/release.yml

Lines changed: 81 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,81 @@
1+
name: Release
2+
on:
3+
release:
4+
types: [published]
5+
branches:
6+
- main
7+
- stable
8+
9+
workflow_dispatch:
10+
inputs:
11+
candidate:
12+
description: 'Release candidate.'
13+
required: true
14+
type: boolean
15+
default: true
16+
test_pypi:
17+
description: 'Test PyPI.'
18+
type: boolean
19+
default: false
20+
jobs:
21+
release:
22+
runs-on: ubuntu-latest
23+
permissions:
24+
id-token: write
25+
steps:
26+
- uses: actions/checkout@v4
27+
with:
28+
ref: ${{ inputs.candidate && 'main' || 'stable' }}
29+
30+
- name: Set up latest Python
31+
uses: actions/setup-python@v5
32+
with:
33+
python-version-file: 'pyproject.toml'
34+
35+
- name: Install dependencies
36+
run: |
37+
python -m pip install --upgrade pip
38+
python -m pip install .[dev]
39+
40+
- name: Create wheel
41+
run: |
42+
make dist
43+
44+
- name: Publish a Python distribution to PyPI
45+
uses: pypa/gh-action-pypi-publish@release/v1
46+
with:
47+
repository-url: ${{ inputs.test_pypi && 'https://test.pypi.org/legacy/' || 'https://upload.pypi.org/legacy/' }}
48+
49+
- name: Bump version to next candidate
50+
if: ${{ inputs.candidate && !inputs.test_pypi }}
51+
run: |
52+
git config user.name "github-actions[bot]"
53+
git config user.email "41898282+github-actions[bot]@users.noreply.github.com"
54+
bump-my-version bump candidate --no-tag --no-commit
55+
56+
- name: Create pull request
57+
if: ${{ inputs.candidate && !inputs.test_pypi }}
58+
id: cpr
59+
uses: peter-evans/create-pull-request@v4
60+
with:
61+
token: ${{ secrets.GH_ACCESS_TOKEN }}
62+
commit-message: bumpversion-candidate
63+
committer: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
64+
author: ${{ github.actor }} <${{ github.actor_id }}+${{ github.actor }}@users.noreply.github.com>
65+
signoff: false
66+
delete-branch: true
67+
title: Automated Bump Version Candidate
68+
body: "This is an auto-generated PR that bumps the version to the next candidate."
69+
branch: bumpversion-candidate-update
70+
branch-suffix: short-commit-hash
71+
add-paths: |
72+
ctgan/__init__.py
73+
pyproject.toml
74+
draft: false
75+
base: main
76+
77+
- name: Enable Pull Request Automerge
78+
if: ${{ steps.cpr.outputs.pull-request-operation == 'created' }}
79+
run: gh pr merge "${{ steps.cpr.outputs.pull-request-number }}" --squash --admin
80+
env:
81+
GH_TOKEN: ${{ secrets.GH_ACCESS_TOKEN }}

.github/workflows/unit.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,11 +10,11 @@ jobs:
1010
runs-on: ${{ matrix.os }}
1111
strategy:
1212
matrix:
13-
python-version: ['3.8', '3.9', '3.10', '3.11', '3.12', '3.13']
13+
python-version: ['3.9', '3.10', '3.11', '3.12', '3.13']
1414
os: [ubuntu-latest, windows-latest]
1515
include:
1616
- os: macos-latest
17-
python-version: '3.8'
17+
python-version: '3.9'
1818
- os: macos-latest
1919
python-version: '3.13'
2020
steps:

.gitignore

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,6 @@
1+
.github/.tmp/
2+
tests/readme_test/
3+
14
# Byte-compiled / optimized / DLL files
25
__pycache__/
36
*.py[cod]
@@ -104,5 +107,8 @@ ENV/
104107
# mypy
105108
.mypy_cache/
106109

110+
# other
111+
.DS_Store
112+
107113
# Vim
108-
.*.swp
114+
.*.swp

0 commit comments

Comments
 (0)