66 push :
77 tags :
88 # Only run this workflow for tags that start with 'v.' (release tags)
9- - ' v* '
9+ - " v* "
1010
1111jobs :
1212 test :
@@ -16,48 +16,48 @@ jobs:
1616 strategy :
1717 matrix :
1818 os : [macos-latest, ubuntu-latest]
19- python-version : ["3.9", "3. 10", "3.11", "3.12"]
19+ python-version : ["3.10", "3.11", "3.12"]
2020
2121 runs-on : ${{ matrix.os }}
2222 name : Test with Python ${{ matrix.python-version }} on ${{ matrix.os }}
2323
2424 steps :
25- - name : Checkout Code
26- uses : actions/checkout@v4
25+ - name : Checkout Code
26+ uses : actions/checkout@v4
2727
28- - name : Setup Python ${{ matrix.python-version }}
29- uses : actions/setup-python@v5
30- with :
31- python-version : ${{ matrix.python-version }}
32- cache : pip
28+ - name : Setup Python ${{ matrix.python-version }}
29+ uses : actions/setup-python@v5
30+ with :
31+ python-version : ${{ matrix.python-version }}
32+ cache : pip
3333
34- - name : Install dependencies
35- run : |
36- python -m pip install --upgrade pip
37- pip install -r requirements/requirements-test.txt
38- pip install wheel
39- # Install setuptools for Python 3.12 and above
40- if [[ "$(python -c 'import sys; print(sys.version_info >= (3, 12))')" == "True" ]]; then
41- pip install setuptools
42- fi
34+ - name : Install dependencies
35+ run : |
36+ python -m pip install --upgrade pip
37+ pip install -r requirements/requirements-test.txt
38+ pip install wheel
39+ # Install setuptools for Python 3.12 and above
40+ if [[ "$(python -c 'import sys; print(sys.version_info >= (3, 12))')" == "True" ]]; then
41+ pip install setuptools
42+ fi
4343
44- - name : Build and install aicodebot
45- run : |
46- python setup.py sdist bdist_wheel
47- pip install dist/*.whl
44+ - name : Build and install aicodebot
45+ run : |
46+ python setup.py sdist bdist_wheel
47+ pip install dist/*.whl
4848
49- - name : Test
50- run : |
51- aicodebot -V
52- # Python 3.9 testing fails because of an issue with vcrpy
53- # https://github.com/kevin1024/vcrpy/issues/688
54- if [[ "${{ matrix.python-version }}" == "3.9" ]]; then
55- echo "Skipping tests for Python 3.9, running alignment instead"
56- aicodebot configure
57- aicodebot alignment
58- else
59- pytest --record-mode=new_episodes
60- fi
49+ - name : Test
50+ run : |
51+ aicodebot -V
52+ # Python 3.9 testing fails because of an issue with vcrpy
53+ # https://github.com/kevin1024/vcrpy/issues/688
54+ if [[ "${{ matrix.python-version }}" == "3.9" ]]; then
55+ echo "Skipping tests for Python 3.9, running alignment instead"
56+ aicodebot configure
57+ aicodebot alignment
58+ else
59+ pytest --record-mode=new_episodes
60+ fi
6161
6262 pypi_release :
6363 needs : test
@@ -68,29 +68,29 @@ jobs:
6868 contents : write
6969
7070 steps :
71- - name : Checkout Code
72- uses : actions/checkout@v4
71+ - name : Checkout Code
72+ uses : actions/checkout@v4
7373
74- - name : Setup Python
75- uses : actions/setup-python@v5
76- with :
77- python-version : 3.12
78- cache : pip
74+ - name : Setup Python
75+ uses : actions/setup-python@v5
76+ with :
77+ python-version : 3.12
78+ cache : pip
7979
80- - name : Build the package
81- run : |
82- pip install wheel twine setuptools
83- python setup.py sdist bdist_wheel
80+ - name : Build the package
81+ run : |
82+ pip install wheel twine setuptools
83+ python setup.py sdist bdist_wheel
8484
85- - name : Publish to PyPi
86- env :
87- TWINE_USERNAME : ${{ secrets.PYPI_USERNAME }}
88- TWINE_PASSWORD : ${{ secrets.PYPI_PASSWORD }}
89- run : |
90- twine check dist/*
91- twine upload dist/*
85+ - name : Publish to PyPi
86+ env :
87+ TWINE_USERNAME : ${{ secrets.PYPI_USERNAME }}
88+ TWINE_PASSWORD : ${{ secrets.PYPI_PASSWORD }}
89+ run : |
90+ twine check dist/*
91+ twine upload dist/*
9292
93- - name : Create GitHub Release
94- uses : ncipollo/release-action@v1
95- with :
96- generateReleaseNotes : true
93+ - name : Create GitHub Release
94+ uses : ncipollo/release-action@v1
95+ with :
96+ generateReleaseNotes : true
0 commit comments