Skip to content

Commit

Permalink
Drop Python 3.8 support
Browse files Browse the repository at this point in the history
Python 3.8 will reach its end of life in October 2024, and
Python 3.9 will become the minimum version required by the project.

Update the GitHub workflows to run tests for Python 3.9, 3.10, 3.11
and 3.12 for future releases.

Update some pinned dependencies due to old errors that seem to
have been fixed.

Remove deprecated docker image for Perceval.

Signed-off-by: Jose Javier Merchante <jjmerchante@bitergia.com>
  • Loading branch information
jjmerchante committed Sep 18, 2024
1 parent 37f308b commit 613ee54
Show file tree
Hide file tree
Showing 10 changed files with 169 additions and 237 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ jobs:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ['3.8', '3.9', '3.10', '3.11']
python-version: ['3.9', '3.10', '3.11', '3.12']
steps:
- uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1
- name: Download distribution artifact
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ jobs:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ['3.8', '3.9', '3.10', '3.11']
python-version: ['3.9', '3.10', '3.11', '3.12']

name: Python ${{ matrix.python-version }}
steps:
Expand Down
19 changes: 0 additions & 19 deletions docker/images/Makefile

This file was deleted.

36 changes: 0 additions & 36 deletions docker/images/README.md

This file was deleted.

20 changes: 0 additions & 20 deletions docker/images/master/Dockerfile

This file was deleted.

2 changes: 1 addition & 1 deletion perceval/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -132,7 +132,7 @@ def parse_headers(msg):
hv = []

for text, charset in email.header.decode_header(value):
if type(text) == bytes:
if isinstance(text, bytes):
charset = charset if charset else 'utf-8'
try:
text = text.decode(charset, errors='surrogateescape')
Expand Down
309 changes: 154 additions & 155 deletions poetry.lock

Large diffs are not rendered by default.

6 changes: 3 additions & 3 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -44,14 +44,14 @@ classifiers = [
perceval = 'perceval.perceval:main'

[tool.poetry.dependencies]
python = "^3.8"
python = "^3.9"

python-dateutil = "^2.6.0"
requests = "^2.7.0"
beautifulsoup4 = "^4.3.2"
feedparser = "^6.0.8"
dulwich = "^0.20.0"
urllib3 = "^1.26"
urllib3 = "^2.2"
PyJWT = "^2.4.0"
cryptography = ">=41.0.3,<44.0.0"
grimoirelab-toolkit = { version = ">=0.3", allow-prereleases = true}
Expand All @@ -62,7 +62,7 @@ furo = { version = "^2023.03.27", optional = true }

[tool.poetry.dev-dependencies]
httpretty = "^1.1.4"
flake8 = "^4.0.1"
flake8 = "^7.1.1"
coverage = "^7.2.3"

[tool.poetry.extras]
Expand Down
8 changes: 8 additions & 0 deletions releases/unreleased/python-minimum-version-updated.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
---
title: Python minimum version updated
category: dependency
author: Jose Javier Merchante <jjmerchante@bitergia.com>
issue: null
notes: >
Python 3.8 will reach its end of life in October 2024.
Python 3.9 is the minimum version required by the project.
2 changes: 1 addition & 1 deletion tests/test_mediawiki.py
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ class HTTPServer():
def routes(cls, version="1.28", empty=False, response_num=200):
"""Configure in http the routes to be served"""

assert(version in TESTED_VERSIONS)
assert version in TESTED_VERSIONS

if version == "1.28":
mediawiki_siteinfo = read_file('data/mediawiki/mediawiki_siteinfo_1.28.json')
Expand Down

0 comments on commit 613ee54

Please sign in to comment.