Skip to content

Commit 2c13670

Browse files
[PATCH] Fix outdated GitHub workflows (#30)
* Fix outdated GitHub workflows Applied recommendations from https://rhysd.github.io/actionlint/ * Updated list of tested python versions ; set minimal python version to 3.8
1 parent c56b453 commit 2c13670

File tree

7 files changed

+19
-18
lines changed

7 files changed

+19
-18
lines changed

.github/workflows/_code_checks.yml

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -15,23 +15,23 @@ jobs:
1515
strategy:
1616
fail-fast: false
1717
matrix:
18-
python-version: ["3.7", "3.8", "3.9", "3.10"]
18+
python-version: ["3.9", "3.10", "3.11", "3.12", "3.13"]
1919

2020
name: Check Python${{ matrix.python-version }}
2121

2222
steps:
2323
- name: checkout current commit
24-
uses: actions/checkout@v2
24+
uses: actions/checkout@v4
2525
if: ${{ inputs.ref == 'default' }}
2626

2727
- name: checkout main
28-
uses: actions/checkout@v2
28+
uses: actions/checkout@v4
2929
with:
3030
ref: ${{ inputs.ref }}
3131
if: ${{ inputs.ref != 'default' }}
3232

3333
- name: install python
34-
uses: actions/setup-python@v2
34+
uses: actions/setup-python@v5
3535
with:
3636
python-version: ${{ matrix.python-version }}
3737

@@ -48,9 +48,9 @@ jobs:
4848
run: make test
4949

5050
- name: codeql_init
51-
uses: github/codeql-action/init@v1
51+
uses: github/codeql-action/init@v3
5252
with:
5353
languages: 'python'
5454

5555
- name: codeql_analyze
56-
uses: github/codeql-action/analyze@v1
56+
uses: github/codeql-action/analyze@v3

.github/workflows/check_pr_code.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ jobs:
1414
n_commits: ${{ steps.count_commits.outputs.n_commits }}
1515
steps:
1616
- name: checkout current branch
17-
uses: actions/checkout@v2
17+
uses: actions/checkout@v4
1818
with:
1919
fetch-depth: 0
2020

@@ -23,7 +23,7 @@ jobs:
2323
run: |
2424
git fetch
2525
N_COMMITS=$(git rev-list origin/main.. --count)
26-
echo "::set-output name=n_commits::${N_COMMITS}"
26+
echo "n_commits=${N_COMMITS}" >> $GITHUB_OUTPUT
2727
2828
add_empty_commit_if_only_one:
2929
needs: count_commits
@@ -33,7 +33,7 @@ jobs:
3333
steps:
3434

3535
- name: checkout current branch
36-
uses: actions/checkout@v2
36+
uses: actions/checkout@v4
3737
with:
3838
repository: ${{ github.event.pull_request.head.repo.full_name }}
3939
ref: ${{ github.event.pull_request.head.ref }}

.github/workflows/release.yml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -19,10 +19,10 @@ jobs:
1919
startsWith(github.event.head_commit.message, '[PATCH]')
2020
steps:
2121

22-
- uses: actions/checkout@v2
22+
- uses: actions/checkout@v4
2323

2424
- name: Set up Python
25-
uses: actions/setup-python@v2
25+
uses: actions/setup-python@v5
2626
with:
2727
python-version: '3.8'
2828

@@ -71,7 +71,7 @@ jobs:
7171
steps:
7272

7373
- name: Checkout main
74-
uses: actions/checkout@v2
74+
uses: actions/checkout@v4
7575
with:
7676
ref: main
7777
fetch-depth: 0 # fetches entire history for all branches and tags
@@ -99,12 +99,12 @@ jobs:
9999
steps:
100100

101101
- name: Checkout main
102-
uses: actions/checkout@v2
102+
uses: actions/checkout@v4
103103
with:
104104
ref: main
105105

106106
- name: Set up Python
107-
uses: actions/setup-python@v2
107+
uses: actions/setup-python@v5
108108
with:
109109
python-version: '3.8'
110110

Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ lint:
1010

1111
test:
1212
PYTHON_VERSION=$$(python3 --version) && \
13-
if echo "$${PYTHON_VERSION}" | grep -q "3.10"; \
13+
if echo "$${PYTHON_VERSION}" | grep -E -q "3\.[0-9]{2,}"; \
1414
then python3 -m pytest tests; \
1515
else nosetests -v --with-coverage --cover-package=$(PROJECT) tests; \
1616
fi

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ a thumb up: https://gitlab.com/gitlab-org/gitlab/-/issues/352836
4040
---
4141

4242
## Requirements
43-
- Python >= __3.7__ (required by `python-gitlab` since version `3.0.0`)
43+
- Python >= __3.8__ (`python-gitlab` requires python>=3.9 since version `5.0.0`)
4444

4545
## Dependencies
4646
- [python-gitlab](https://github.com/python-gitlab/python-gitlab)

requirements.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
1-
python-gitlab==3.1.0
2-
giturlparse==0.10.0
1+
python-gitlab>=3.1.0
2+
giturlparse>=0.10.0

setup.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,7 @@
2626
maintainer='Valentin François',
2727
url='https://github.com/ValentinFrancois/python-gitlab-submodule',
2828
packages=['gitlab_submodule'],
29+
python_requires='>=3.8.0',
2930
install_requires=[
3031
'python-gitlab>=3.0.0',
3132
'giturlparse>=0.10.0'

0 commit comments

Comments
 (0)