Skip to content

Commit

Permalink
Upgrade dependencies, remove Python 3.6 support (#457)
Browse files Browse the repository at this point in the history
  • Loading branch information
EnricoMi authored May 26, 2023
1 parent b4424af commit fa88269
Show file tree
Hide file tree
Showing 6 changed files with 18 additions and 29 deletions.
3 changes: 1 addition & 2 deletions .github/upgrade-pip-packages.sh
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,7 @@ pip install --upgrade --force pip==22.0.0
pip install --upgrade --upgrade-strategy eager -r "$base/../python/requirements-direct.txt" -c "$base/../python/constraints.txt"

pip install pipdeptree
grep -e "^#" -e ";" "$base/../python/requirements-direct.txt" > "$base/../python/requirements.txt"
pipdeptree --packages="$(grep -v "^#" "$base/../python/requirements-direct.txt" | sed -e "s/;.*//" -e "s/=.*//g" | paste -s -d ,)" --freeze >> "$base/../python/requirements.txt"
pipdeptree --packages="$(sed -e "s/;.*//" -e "s/=.*//g" "$base/../python/requirements-direct.txt" | paste -s -d ,)" --freeze > "$base/../python/requirements.txt"

git diff "$base/../python/requirements.txt"

10 changes: 2 additions & 8 deletions .github/workflows/ci-cd.yml
Original file line number Diff line number Diff line change
Expand Up @@ -76,12 +76,6 @@ jobs:
- os: windows-latest
python-version: "3.7"

- os: macos-11
python-version: "3.6"
- os: ubuntu-20.04
python-version: "3.6"
- os: windows-2019
python-version: "3.6"

steps:
- name: Setup Ubuntu
Expand Down Expand Up @@ -272,7 +266,7 @@ jobs:

- name: Build Docker image
id: build
uses: docker/build-push-action@v3
uses: docker/build-push-action@v4
with:
load: true
push: false
Expand Down Expand Up @@ -666,7 +660,7 @@ jobs:
password: ${{ secrets.CR_PAT }}

- name: Build and push Docker image
uses: docker/build-push-action@v3
uses: docker/build-push-action@v4
with:
tags: ${{ steps.docker-meta.outputs.tags }}
labels: ${{ steps.docker-meta.outputs.labels }}
Expand Down
2 changes: 1 addition & 1 deletion composite/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -185,7 +185,7 @@ runs:
continue-on-error: true
with:
path: ${{ steps.os.outputs.pip-cache }}
key: enricomi-publish-action-${{ runner.os }}-${{ runner.arch }}-pip-${{ steps.python.outputs.version }}-f3f2c295046c91ed612b4efb6c9fb352
key: enricomi-publish-action-${{ runner.os }}-${{ runner.arch }}-pip-${{ steps.python.outputs.version }}-b8e8abb8483d74cfe629dd253143f067

- name: Install Python dependencies
run: |
Expand Down
4 changes: 2 additions & 2 deletions python/publish_test_results.py
Original file line number Diff line number Diff line change
Expand Up @@ -419,8 +419,8 @@ def get_settings(options: dict, gha: GithubAction) -> Settings:
event_name == 'pull_request' and \
event.get('pull_request', {}).get('head', {}).get('repo', {}).get('full_name') != repo

api_url = options.get('GITHUB_API_URL') or github.MainClass.DEFAULT_BASE_URL
graphql_url = options.get('GITHUB_GRAPHQL_URL') or f'{github.MainClass.DEFAULT_BASE_URL}/graphql'
api_url = options.get('GITHUB_API_URL') or github.Consts.DEFAULT_BASE_URL
graphql_url = options.get('GITHUB_GRAPHQL_URL') or f'{github.Consts.DEFAULT_BASE_URL}/graphql'
test_changes_limit = get_var('TEST_CHANGES_LIMIT', options) or '10'
check_var_condition(test_changes_limit.isnumeric(), f'TEST_CHANGES_LIMIT must be a positive integer or 0: {test_changes_limit}')

Expand Down
12 changes: 5 additions & 7 deletions python/requirements-direct.txt
Original file line number Diff line number Diff line change
@@ -1,9 +1,7 @@
# dataclasses does not exist before Python3.7, needed as dependency
dataclasses;python_version<"3.7"
humanize==3.14.0
junitparser==2.8.0
junitparser==3.1.0
lxml==4.9.1
psutil==5.9.4
PyGithub==1.56
requests==2.27.1
urllib3==1.26.13
psutil==5.9.5
PyGithub==1.58.2
requests==2.31.0
urllib3==1.26.16
16 changes: 7 additions & 9 deletions python/requirements.txt
Original file line number Diff line number Diff line change
@@ -1,19 +1,17 @@
# dataclasses does not exist before Python3.7, needed as dependency
dataclasses;python_version<"3.7"
humanize==3.14.0
junitparser==2.8.0
junitparser==3.1.0
future==0.18.3
lxml==4.9.1
psutil==5.9.4
PyGithub==1.56
psutil==5.9.5
PyGithub==1.58.2
Deprecated==1.2.13
wrapt==1.15.0
PyJWT==2.4.0
PyNaCl==1.5.0
cffi==1.15.1
pycparser==2.21
requests==2.27.1
certifi==2022.12.7
charset-normalizer==2.0.12
requests==2.31.0
certifi==2023.5.7
charset-normalizer==3.1.0
idna==3.4
urllib3==1.26.13
urllib3==1.26.16

0 comments on commit fa88269

Please sign in to comment.