Skip to content

Commit d8e27df

Browse files
Drop Python 3.8 support (#545)
* Drop Python 3.8 support * Remove workaround for Python 3.8 See d974f25
1 parent 10f8ae6 commit d8e27df

File tree

5 files changed

+5
-13
lines changed

5 files changed

+5
-13
lines changed

.github/workflows/test.yml

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -16,12 +16,9 @@ jobs:
1616
strategy:
1717
matrix:
1818
os: [Ubuntu]
19-
python-version: ["3.8", "3.9", "3.10", "3.11", "3.12"]
19+
python-version: ["3.9", "3.10", "3.11", "3.12"]
2020
sphinx-version:
2121
["sphinx==6.0", "sphinx==6.2", "sphinx==7.0", "'sphinx>=7.2,<7.3'"]
22-
exclude:
23-
- python-version: "3.8"
24-
sphinx-version: "'sphinx>=7.2,<7.3'"
2522
steps:
2623
- uses: actions/checkout@v4
2724

README.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ docstrings formatted according to the NumPy documentation format.
1818
The extension also adds the code description directives
1919
``np:function``, ``np-c:function``, etc.
2020

21-
numpydoc requires Python 3.8+ and sphinx 5+.
21+
numpydoc requires Python 3.9+ and sphinx 6+.
2222

2323
For usage information, please refer to the `documentation
2424
<https://numpydoc.readthedocs.io/>`_.

doc/install.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ Getting started
55
Installation
66
============
77

8-
This extension requires Python 3.8+, sphinx 5+ and is available from:
8+
This extension requires Python 3.9+, sphinx 6+ and is available from:
99

1010
* `numpydoc on PyPI <http://pypi.python.org/pypi/numpydoc>`_
1111
* `numpydoc on GitHub <https://github.com/numpy/numpydoc/>`_

numpydoc/tests/test_validate.py

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
import pytest
2-
import sys
32
import warnings
43
from contextlib import nullcontext
54
from functools import cached_property, partial, wraps
@@ -1638,15 +1637,12 @@ def test_raises_for_invalid_attribute_name(self, invalid_name):
16381637
with pytest.raises(AttributeError, match=msg):
16391638
numpydoc.validate.Validator._load_obj(invalid_name)
16401639

1641-
# inspect.getsourcelines does not return class decorators for Python 3.8. This was
1642-
# fixed starting with 3.9: https://github.com/python/cpython/issues/60060.
16431640
@pytest.mark.parametrize(
16441641
["decorated_obj", "def_line"],
16451642
[
16461643
[
16471644
"numpydoc.tests.test_validate.DecoratorClass",
1648-
getsourcelines(DecoratorClass)[-1]
1649-
+ (2 if sys.version_info.minor > 8 else 0),
1645+
getsourcelines(DecoratorClass)[-1] + 2,
16501646
],
16511647
[
16521648
"numpydoc.tests.test_validate.DecoratorClass.test_no_decorator",

pyproject.toml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ requires = ['setuptools>=61.2']
66
name = 'numpydoc'
77
description = 'Sphinx extension to support docstrings in Numpy format'
88
readme = 'README.rst'
9-
requires-python = '>=3.8'
9+
requires-python = '>=3.9'
1010
dynamic = ['version']
1111
keywords = [
1212
'sphinx',
@@ -19,7 +19,6 @@ classifiers = [
1919
'Topic :: Documentation',
2020
'Programming Language :: Python',
2121
'Programming Language :: Python :: 3',
22-
'Programming Language :: Python :: 3.8',
2322
'Programming Language :: Python :: 3.9',
2423
'Programming Language :: Python :: 3.10',
2524
'Programming Language :: Python :: 3.11',

0 commit comments

Comments
 (0)