Skip to content

Commit f36f937

Browse files
committed
Drop Python 3.7 and support 3.11 and 3.12; also update dev deps
1 parent d817013 commit f36f937

File tree

6 files changed

+22
-59
lines changed

6 files changed

+22
-59
lines changed

.github/workflows/build.yml

Lines changed: 15 additions & 39 deletions
Original file line numberDiff line numberDiff line change
@@ -14,69 +14,50 @@ jobs:
1414
tests:
1515
strategy:
1616
fail-fast: false
17-
max-parallel: 4
17+
max-parallel: 5
1818
matrix:
1919
platform: [ubuntu-latest, windows-latest]
20-
python-version: [3.7, 3.8, 3.9, '3.10']
21-
include:
22-
- python-version: 3.7
23-
tox-env: py37
24-
- python-version: 3.8
25-
tox-env: py38
26-
- python-version: 3.9
27-
tox-env: py39
28-
- python-version: '3.10'
29-
tox-env: py310
20+
python-version: [3.8, 3.9, '3.10', 3.11, 3.12]
3021

3122
env:
3223
TOXENV: ${{ matrix.tox-env }}
3324

3425
runs-on: ${{ matrix.platform }}
3526

3627
steps:
37-
- uses: actions/checkout@v2
28+
- uses: actions/checkout@v4
3829
- name: Set up Python ${{ matrix.python-version }}
39-
if: "!endsWith(matrix.python-version, '-dev')"
40-
uses: actions/setup-python@v2
41-
with:
42-
python-version: ${{ matrix.python-version }}
43-
- name: Set up development Python ${{ matrix.python-version }}
44-
if: endsWith(matrix.python-version, '-dev')
45-
uses: deadsnakes/action@v1.0.0
30+
uses: actions/setup-python@v4
4631
with:
4732
python-version: ${{ matrix.python-version }}
33+
allow-prereleases: true
4834
- name: Install dependencies
4935
run: |
5036
python -m pip install --upgrade pip build tox coverage codecov
5137
- name: Test
5238
run: |
53-
python -m tox
39+
python -m tox -e py
5440
- name: Upload Results
5541
if: success()
5642
uses: codecov/codecov-action@v1
5743
with:
5844
file: ./coverage.xml
5945
flags: unittests
60-
name: ${{ matrix.platform }}-${{ matrix.tox-env }}
46+
name: ${{ matrix.platform }}-${{ matrix.python-version }}
6147
fail_ci_if_error: false
6248

6349
lint:
64-
strategy:
65-
max-parallel: 4
66-
matrix:
67-
python-version: ['3.10']
68-
6950
env:
7051
TOXENV: lint
7152

7253
runs-on: ubuntu-latest
7354

7455
steps:
75-
- uses: actions/checkout@v2
76-
- name: Set up Python ${{ matrix.python-version }}
77-
uses: actions/setup-python@v2
56+
- uses: actions/checkout@v4
57+
- name: Set up Python
58+
uses: actions/setup-python@v4
7859
with:
79-
python-version: ${{ matrix.python-version }}
60+
python-version: 3.11
8061
- name: Install dependencies
8162
run: |
8263
python -m pip install --upgrade pip build tox
@@ -85,22 +66,17 @@ jobs:
8566
python -m tox
8667
8768
documents:
88-
strategy:
89-
max-parallel: 4
90-
matrix:
91-
python-version: ['3.10']
92-
9369
env:
9470
TOXENV: documents
9571

9672
runs-on: ubuntu-latest
9773

9874
steps:
99-
- uses: actions/checkout@v2
100-
- name: Set up Python ${{ matrix.python-version }}
101-
uses: actions/setup-python@v2
75+
- uses: actions/checkout@v4
76+
- name: Set up Python
77+
uses: actions/setup-python@v4
10278
with:
103-
python-version: ${{ matrix.python-version }}
79+
python-version: 3.11
10480
- name: Install dependencies
10581
run: |
10682
python -m pip install --upgrade pip build tox

.github/workflows/deploy.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,10 +10,10 @@ jobs:
1010
runs-on: ubuntu-latest
1111

1212
steps:
13-
- uses: actions/checkout@v2
14-
- uses: actions/setup-python@v2
13+
- uses: actions/checkout@v4
14+
- uses: actions/setup-python@v4
1515
with:
16-
python-version: '3.10'
16+
python-version: '3.11'
1717
- name: Package
1818
run: |
1919
pip install --upgrade build

hatch_build.py

Lines changed: 2 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -15,35 +15,24 @@ def get_version_dev_status(root):
1515
return module.__version_info__._get_dev_status()
1616

1717

18-
def get_requirements(root):
19-
"""Load list of dependencies."""
20-
21-
install_requires = []
22-
with open(os.path.join(root, "requirements", "project.txt")) as f:
23-
for line in f:
24-
if not line.startswith("#"):
25-
install_requires.append(line.strip())
26-
return install_requires
27-
28-
2918
class CustomMetadataHook(MetadataHookInterface):
3019
"""Our metadata hook."""
3120

3221
def update(self, metadata):
3322
"""See https://ofek.dev/hatch/latest/plugins/metadata-hook/ for more information."""
3423

35-
metadata["dependencies"] = get_requirements(self.root)
3624
metadata["classifiers"] = [
3725
f"Development Status :: {get_version_dev_status(self.root)}",
3826
"Environment :: Console",
3927
"Intended Audience :: Developers",
4028
"License :: OSI Approved :: MIT License",
4129
"Operating System :: OS Independent",
4230
"Programming Language :: Python :: 3",
43-
"Programming Language :: Python :: 3.7",
4431
"Programming Language :: Python :: 3.8",
4532
"Programming Language :: Python :: 3.9",
4633
"Programming Language :: Python :: 3.10",
34+
"Programming Language :: Python :: 3.11",
35+
"Programming Language :: Python :: 3.12",
4736
"Topic :: Internet :: WWW/HTTP :: Dynamic Content",
4837
"Topic :: Software Development :: Libraries :: Python Modules",
4938
"Topic :: Text Processing :: Filters",

materialx/__meta__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -188,5 +188,5 @@ def parse_version(ver):
188188
return Version(major, minor, micro, release, pre, post, dev)
189189

190190

191-
__version_info__ = Version(1, 1, 1, "final")
191+
__version_info__ = Version(1, 2, 0, "final")
192192
__version__ = __version_info__._get_canonical()

requirements/project.txt

Whitespace-only changes.

tox.ini

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,11 @@
11
[tox]
22
isolated_build = true
33
envlist =
4-
{py37,py38,py39,py310}, lint, documents
4+
{py38,py39,py310,py311,py312}, lint, documents
55

66
[testenv]
77
passenv = LANG
88
deps=
9-
-rrequirements/project.txt
109
-rrequirements/test.txt
1110
commands=
1211
{envbindir}/py.test --cov materialx --cov-append {toxinidir}
@@ -24,7 +23,6 @@ commands=
2423

2524
[testenv:lint]
2625
deps=
27-
-rrequirements/project.txt
2826
-rrequirements/lint.txt
2927
commands=
3028
{envbindir}/flake8 {toxinidir}

0 commit comments

Comments
 (0)