Skip to content

Commit b55cc1e

Browse files
authored
chore!: drop Python 3.8 support (#187)
drop Python 3.8 support Signed-off-by: gruebel <[email protected]>
1 parent 9db9ad6 commit b55cc1e

File tree

16 files changed

+39
-52
lines changed

16 files changed

+39
-52
lines changed

.github/workflows/build.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ jobs:
2525
runs-on: ubuntu-latest
2626
strategy:
2727
matrix:
28-
python-version: ["3.8", "3.9", "3.10", "3.11", "3.12", "3.13"]
28+
python-version: ["3.9", "3.10", "3.11", "3.12", "3.13"]
2929
package:
3030
- "hooks/openfeature-hooks-opentelemetry"
3131
- "providers/openfeature-provider-flagd"
@@ -50,15 +50,15 @@ jobs:
5050
working-directory: ${{ matrix.package }}
5151

5252
- name: Type checking
53-
if: matrix.python-version == '3.11'
53+
if: matrix.python-version == '3.13'
5454
working-directory: ${{ matrix.package }}
5555
run: hatch run mypy:run
5656

5757
- name: Test with pytest
5858
run: hatch test -c
5959
working-directory: ${{ matrix.package }}
6060

61-
- if: matrix.python-version == '3.11'
61+
- if: matrix.python-version == '3.13'
6262
name: Upload coverage to Codecov
6363
uses: codecov/codecov-action@13ce06bfc6bbe3ecf90edbbf1bc32fe5978ca1d3 # v5.3.1
6464
with:
@@ -75,7 +75,7 @@ jobs:
7575
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4
7676
- uses: actions/setup-python@42375524e23c412d93fb67b49958b491fce71c38 # v5
7777
with:
78-
python-version: "3.11"
78+
python-version: "3.13"
7979
cache: "pip"
8080

8181
- name: Run pre-commit

.pre-commit-config.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
default_stages: [commit]
1+
default_stages: [pre-commit]
22
repos:
33
- repo: https://github.com/astral-sh/ruff-pre-commit
44
rev: v0.9.6

CONTRIBUTING.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,11 +4,11 @@
44

55
### System Requirements
66

7-
Python 3.8 and above are required.
7+
Python 3.9 and above are required.
88

99
### Target version(s)
1010

11-
Python 3.8 and above are supported by the SDK.
11+
Python 3.9 and above are supported by the SDK.
1212

1313
### Installation and Dependencies
1414

hooks/openfeature-hooks-opentelemetry/pyproject.toml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ dependencies = [
2020
"openfeature-sdk>=0.6.0",
2121
"opentelemetry-api",
2222
]
23-
requires-python = ">=3.8"
23+
requires-python = ">=3.9"
2424

2525
[project.urls]
2626
Homepage = "https://github.com/open-feature/python-sdk-contrib"
@@ -70,7 +70,7 @@ packages = ["src/openfeature"]
7070
mypy_path = "src"
7171
files = "src"
7272

73-
python_version = "3.8" # should be identical to the minimum supported version
73+
python_version = "3.9" # should be identical to the minimum supported version
7474
namespace_packages = true
7575
explicit_package_bases = true
7676
local_partial_types = true

providers/openfeature-provider-flagd/pyproject.toml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ dependencies = [
2626
"pyyaml>=6.0.1",
2727
"cachebox"
2828
]
29-
requires-python = ">=3.8"
29+
requires-python = ">=3.9"
3030

3131
[project.urls]
3232
Homepage = "https://github.com/open-feature/python-sdk-contrib"
@@ -113,7 +113,7 @@ omit = [
113113
mypy_path = "src"
114114
files = "src"
115115

116-
python_version = "3.8" # should be identical to the minimum supported version
116+
python_version = "3.9" # should be identical to the minimum supported version
117117
namespace_packages = true
118118
explicit_package_bases = true
119119
local_partial_types = true

providers/openfeature-provider-flagd/src/openfeature/contrib/provider/flagd/resolvers/process/flags.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -75,12 +75,12 @@ def from_dict(cls, key: str, data: dict) -> "Flag":
7575
return flag
7676

7777
@property
78-
def default(self) -> typing.Tuple[str, typing.Any]:
78+
def default(self) -> tuple[str, typing.Any]:
7979
return self.get_variant(self.default_variant)
8080

8181
def get_variant(
8282
self, variant_key: typing.Union[str, bool]
83-
) -> typing.Tuple[str, typing.Any]:
83+
) -> tuple[str, typing.Any]:
8484
if isinstance(variant_key, bool):
8585
variant_key = str(variant_key).lower()
8686

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,5 @@
1-
# as soon as we support all the features, we can actually remove this limitation to not run on Python 3.8
2-
# Python 3.8 does not fully support tagging, hence that it will run all cases
3-
import sys
4-
51
from pytest_bdd import scenarios
62

73
from tests.e2e.paths import TEST_HARNESS_PATH
84

9-
if sys.version_info >= (3, 9):
10-
scenarios(f"{TEST_HARNESS_PATH}/gherkin")
5+
scenarios(f"{TEST_HARNESS_PATH}/gherkin")
Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,5 @@
1-
import sys
2-
31
from pytest_bdd import scenarios
42

53
from tests.e2e.paths import TEST_HARNESS_PATH
64

7-
# as soon as we support all the features, we can actually remove this limitation to not run on Python 3.8
8-
# Python 3.8 does not fully support tagging, hence that it will run all cases
9-
if sys.version_info >= (3, 9):
10-
scenarios(f"{TEST_HARNESS_PATH}/gherkin")
5+
scenarios(f"{TEST_HARNESS_PATH}/gherkin")

providers/openfeature-provider-flagd/tests/e2e/step/flag_step.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,3 @@
1-
import typing
2-
31
import requests
42
from asserts import assert_equal
53
from pytest_bdd import given, parsers, then, when
@@ -20,7 +18,7 @@
2018
)
2119
def setup_key_and_default(
2220
key: str, default: JsonPrimitive, type_info: str
23-
) -> typing.Tuple[str, JsonPrimitive, str]:
21+
) -> tuple[str, JsonPrimitive, str]:
2422
return key, default, type_info
2523

2624

providers/openfeature-provider-flagd/tests/e2e/step/provider_steps.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
import logging
22
import os
33
import time
4-
import typing
54
from enum import Enum
65
from pathlib import Path
76

@@ -43,7 +42,7 @@ def setup_provider_old(
4342

4443
def get_default_options_for_provider(
4544
provider_type: str, resolver_type: ResolverType, container
46-
) -> typing.Tuple[dict, bool]:
45+
) -> tuple[dict, bool]:
4746
launchpad = "default"
4847
t = TestProviderType(provider_type)
4948
options: dict = {

0 commit comments

Comments
 (0)