Skip to content

Commit 5504913

Browse files
authored
Changed supported python versions to 3.8-3.12 (#263)
1 parent 5b33c3b commit 5504913

File tree

4 files changed

+10
-35
lines changed

4 files changed

+10
-35
lines changed

.github/workflows/python-package.yml

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -12,10 +12,7 @@ jobs:
1212
fail-fast: false
1313
matrix:
1414
os: ["ubuntu-latest"]
15-
python_version: ["3.7", "3.8", "3.9", "3.10", "3.11", "pypy3.10"]
16-
include:
17-
- os: "ubuntu-20.04"
18-
python_version: "3.6"
15+
python_version: ["3.8", "3.9", "3.10", "3.11", "3.12", "pypy3.10"]
1916

2017
runs-on: ${{ matrix.os }}
2118
steps:

README.md

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -54,13 +54,8 @@ This package [is hosted on PyPI](https://pypi.org/project/marshmallow-dataclass/
5454
pip3 install marshmallow-dataclass
5555
```
5656

57-
You may optionally install the following extras:
58-
59-
- `enum` : enum support for marshmallow versions <3.18 [marshmallow-enum](https://github.com/justanr/marshmallow_enum).
60-
- `union` : for translating python [`Union` types](https://docs.python.org/3/library/typing.html#typing.Union) to union fields.
61-
6257
```shell
63-
pip3 install "marshmallow-dataclass[enum,union]"
58+
pip3 install "marshmallow-dataclass"
6459
```
6560

6661
### marshmallow 2 support

setup.py

Lines changed: 8 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -1,30 +1,23 @@
11
from setuptools import setup, find_packages
22

3-
VERSION = "8.6.1"
3+
VERSION = "9.0.0"
44

55
CLASSIFIERS = [
66
"Development Status :: 4 - Beta",
77
"Environment :: Console",
88
"Operating System :: OS Independent",
99
"License :: OSI Approved :: MIT License",
1010
"Programming Language :: Python",
11-
"Programming Language :: Python :: 3.6",
12-
"Programming Language :: Python :: 3.7",
1311
"Programming Language :: Python :: 3.8",
1412
"Programming Language :: Python :: 3.9",
1513
"Programming Language :: Python :: 3.10",
1614
"Programming Language :: Python :: 3.11",
15+
"Programming Language :: Python :: 3.12",
1716
"Topic :: Internet :: WWW/HTTP :: Dynamic Content :: CGI Tools/Libraries",
1817
]
1918

2019
EXTRAS_REQUIRE = {
21-
"enum": [
22-
"marshmallow-enum; python_version < '3.7'",
23-
"marshmallow>=3.18.0,<4.0; python_version >= '3.7'",
24-
],
25-
"union": ["typeguard>=2.4.1,<5.0.0"],
2620
"lint": ["pre-commit~=2.17"],
27-
':python_version == "3.6"': ["dataclasses", "types-dataclasses<0.6.4"],
2821
"docs": ["sphinx"],
2922
"tests": [
3023
"pytest>=5.4",
@@ -34,11 +27,7 @@
3427
],
3528
}
3629
EXTRAS_REQUIRE["dev"] = (
37-
EXTRAS_REQUIRE["enum"]
38-
+ EXTRAS_REQUIRE["union"]
39-
+ EXTRAS_REQUIRE["lint"]
40-
+ EXTRAS_REQUIRE["docs"]
41-
+ EXTRAS_REQUIRE["tests"]
30+
EXTRAS_REQUIRE["lint"] + EXTRAS_REQUIRE["docs"] + EXTRAS_REQUIRE["tests"]
4231
)
4332

4433
setup(
@@ -56,15 +45,13 @@
5645
keywords=["marshmallow", "dataclass", "serialization"],
5746
classifiers=CLASSIFIERS,
5847
license="MIT",
59-
python_requires=">=3.6",
48+
python_requires=">=3.8",
6049
install_requires=[
61-
"marshmallow>=3.13.0,<4.0",
62-
"typing-inspect>=0.8.0,<1.0",
63-
# Need `Literal`
64-
"typing-extensions>=3.7.2; python_version < '3.8'",
50+
"marshmallow>=3.18.0,",
51+
"typing-inspect~=0.9.0",
52+
"typeguard~=4.0.0",
6553
# Need `dataclass_transform(field_specifiers)`
66-
# NB: typing-extensions>=4.2.0 conflicts with python 3.6
67-
"typing-extensions>=4.2.0; python_version<'3.11' and python_version>='3.7'",
54+
"typing-extensions>=4.2.0; python_version<'3.11'",
6855
],
6956
extras_require=EXTRAS_REQUIRE,
7057
package_data={"marshmallow_dataclass": ["py.typed"]},

tests/test_union.py

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -197,10 +197,6 @@ class PEP604IntOrStr:
197197
data_in = {"value": 42}
198198
self.assertEqual(schema.dump(schema.load(data_in)), data_in)
199199

200-
@unittest.skipIf(
201-
sys.version_info < (3, 7, 4),
202-
"Requires typeguard >=4.0.0 not available for py<3.7.4",
203-
)
204200
def test_union_with_generics(self):
205201
IntList = NewType("IntList", List[int])
206202

0 commit comments

Comments
 (0)