Skip to content

Commit ccdae8c

Browse files
authored
chore: remove references to Python version 3.8 (#15438)
## Description <!-- Provide an overview of the change and motivation for the change --> ## Testing <!-- Describe your testing strategy or note what tests are included --> ## Risks <!-- Note any risks associated with this change, or "None" if no risks --> ## Additional Notes <!-- Any other information that would be helpful for reviewers -->
1 parent 9ab207c commit ccdae8c

File tree

18 files changed

+17
-123
lines changed

18 files changed

+17
-123
lines changed

.github/workflows/changelog.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ jobs:
2929
- uses: actions/setup-python@a26af69be951a213d495a4c3e4e4022e16d87065 # v5.6.0
3030
name: Install Python
3131
with:
32-
python-version: '3.8'
32+
python-version: '3.13'
3333

3434
- name: Install Dependencies
3535
run: pip install reno docutils
@@ -40,7 +40,7 @@ jobs:
4040
- name: Generate changelog
4141
run: |
4242
reno report | tee CHANGELOG.rst
43-
rst2html.py CHANGELOG.rst CHANGELOG.html
43+
rst2html CHANGELOG.rst CHANGELOG.html
4444
4545
- name: Upload CHANGELOG.rst
4646
uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4.6.2

.github/workflows/generate-package-versions.yml

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -19,11 +19,6 @@ jobs:
1919
with:
2020
persist-credentials: false
2121

22-
- name: Setup Python 3.8
23-
uses: actions/setup-python@a26af69be951a213d495a4c3e4e4022e16d87065 # v5.6.0
24-
with:
25-
python-version: "3.8"
26-
2722
- name: Setup Python 3.9
2823
uses: actions/setup-python@a26af69be951a213d495a4c3e4e4022e16d87065 # v5.6.0
2924
with:

.github/workflows/generate-supported-versions.yml

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -17,11 +17,6 @@ jobs:
1717
with:
1818
persist-credentials: false
1919

20-
- name: Setup Python 3.8
21-
uses: actions/setup-python@a26af69be951a213d495a4c3e4e4022e16d87065 # v5.6.0
22-
with:
23-
python-version: "3.8"
24-
2520
- name: Setup Python 3.9
2621
uses: actions/setup-python@a26af69be951a213d495a4c3e4e4022e16d87065 # v5.6.0
2722
with:

.github/workflows/requirements-locks.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ jobs:
2525
run: git config --global --add safe.directory "$GITHUB_WORKSPACE"
2626

2727
- name: Set python interpreters
28-
run: pyenv global 3.10 3.8 3.9 3.11 3.12 3.13 3.14
28+
run: pyenv global 3.10 3.9 3.11 3.12 3.13 3.14
2929

3030
- name: Install Dependencies
3131
# Keep pip at <25.3 until https://github.com/jazzband/pip-tools/issues/2252 is resolved

ddtrace/appsec/_iast/_taint_tracking/_vendor/pybind11/pybind11/__init__.py

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,5 @@
11
from __future__ import annotations
22

3-
import sys
4-
5-
if sys.version_info < (3, 8): # noqa: UP036
6-
msg = "pybind11 does not support Python < 3.8. v2.13 was the last release supporting Python 3.7."
7-
raise ImportError(msg)
8-
93

104
from ._version import __version__, version_info
115
from .commands import get_cmake_dir, get_include, get_pkgconfig_dir

lib-injection/sources/sitecustomize.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ def parse_version(version):
4242
SCRIPT_DIR = os.path.dirname(__file__)
4343
RUNTIMES_ALLOW_LIST = {
4444
"cpython": {
45-
"min": Version(version=(3, 8), constraint=""),
45+
"min": Version(version=(3, 9), constraint=""),
4646
"max": Version(version=(3, 14), constraint=""),
4747
}
4848
}

pyproject.toml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
[build-system]
22
requires = [
33
"cython",
4-
"cmake>=3.24.2,<3.28; python_version>='3.8'",
4+
"cmake>=3.24.2,<3.28",
55
"setuptools-rust<2",
66
"patchelf>=0.17.0.0; sys_platform == 'linux'",
77
]
@@ -22,7 +22,6 @@ classifiers = [
2222
"Programming Language :: Python :: Implementation :: CPython",
2323
"Programming Language :: Python",
2424
"Programming Language :: Python :: 3 :: Only",
25-
"Programming Language :: Python :: 3.8",
2625
"Programming Language :: Python :: 3.9",
2726
"Programming Language :: Python :: 3.10",
2827
"Programming Language :: Python :: 3.11",

tests/appsec/iast/_ast/fixtures/annotated_code37.py

Lines changed: 0 additions & 34 deletions
This file was deleted.

tests/appsec/iast/_ast/test_ast_patching_type_hints.py

Lines changed: 1 addition & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,7 @@
11
# -*- encoding: utf-8 -*-
22
from ast import unparse
3-
import sys
43
from typing import Text
54

6-
import pytest
7-
85

96
def _get_patched_code(module_path: Text, module_name: Text) -> str:
107
"""
@@ -30,8 +27,7 @@ def _get_patched_code(module_path: Text, module_name: Text) -> str:
3027
return new_code
3128

3229

33-
@pytest.mark.skipif(sys.version_info == (3, 8, 0), reason="Sample code not compatible with Python 3.8")
34-
def test_no_index_aspects_py38plus():
30+
def test_no_index_aspects():
3531
"""
3632
Methods should not be replaced by the aspect since it's not the builtin method
3733
"""
@@ -43,17 +39,3 @@ def test_no_index_aspects_py38plus():
4339
# Makes sure all add operators are patched:
4440
assert "ddtrace_aspects.add_aspect" in patched_code
4541
assert "+" not in patched_code
46-
47-
48-
def test_no_index_aspects_py37():
49-
"""
50-
Methods should not be replaced by the aspect since it's not the builtin method
51-
"""
52-
patched_code = _get_patched_code("tests/appsec/iast/_ast/fixtures/annotated_code37.py", "annotated_code")
53-
54-
# Makes sure no subscripts are patched:
55-
assert "index_aspect" not in patched_code
56-
57-
# Makes sure all add operators are patched:
58-
assert "ddtrace_aspects.add_aspect" in patched_code
59-
assert "+" not in patched_code

tests/appsec/iast/taint_sinks/test_code_injection_inspect_regression.py

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@
66
f_back and other crashes.
77
"""
88

9-
import sys
109
from unittest import mock
1110

1211
import pytest
@@ -165,7 +164,6 @@ def test_function():
165164
data = _get_iast_data()
166165
assert len(data["vulnerabilities"]) == 1
167166

168-
@pytest.mark.skipif(sys.version_info < (3, 8), reason="Mock spec issues with older Python")
169167
def test_eval_no_globals_extraction_on_currentframe_none(self, iast_context_defaults):
170168
"""
171169
Verify that when currentframe returns None, we don't try to access f_back.

0 commit comments

Comments
 (0)