diff --git a/.travis.yml b/.travis.yml index 94a05d5..477118c 100644 --- a/.travis.yml +++ b/.travis.yml @@ -7,16 +7,18 @@ matrix: include: # Separate job for linting - os: linux - python: "3.7" + python: "3.8" env: TOXENV=lint # Separate testing for different marshmallow versions in different jobs to ease debugging - os: linux - python: "3.7" - env: TOXENV=py37-marshmallow2 + python: "3.8" + env: TOXENV=py38-marshmallow2 - os: linux - python: "3.7" - env: TOXENV=py37-marshmallow3 + python: "3.8" + env: TOXENV=py38-marshmallow3 # These will test for both versions of marshmallow thanks to tox-travis package + - os: linux + python: "3.7" - os: linux python: "3.6" - os: linux diff --git a/CHANGES b/CHANGES index 7e769d2..4bb3965 100644 --- a/CHANGES +++ b/CHANGES @@ -1,3 +1,9 @@ +0.9.0 (2020-01-18) + +0.8.0 (2019-10-08) + +0.7.0 (2019-08-11) + 0.6.0 (2019-06-16) - lots of various fixes - fix compatibility with brutusin/json-form diff --git a/Makefile b/Makefile index c3d37ca..154f873 100644 --- a/Makefile +++ b/Makefile @@ -1,6 +1,6 @@ PROJECT = marshmallow_jsonschema -PYTHON_VERSION ?= 3.7 +PYTHON_VERSION ?= 3.8 VIRTUAL_ENV ?= .venv PYTHON ?= $(VIRTUAL_ENV)/bin/python diff --git a/pyproject.toml b/pyproject.toml index 9749950..4f04370 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,2 +1,2 @@ [tool.black] -target-version = ['py27', 'py35', 'py36', 'py37'] +target-version = ['py27', 'py35', 'py36', 'py37', 'py38'] diff --git a/requirements-tox.txt b/requirements-tox.txt index 561349e..5473c6c 100644 --- a/requirements-tox.txt +++ b/requirements-tox.txt @@ -1 +1 @@ -tox>=3.13 +tox>=3.14.3 diff --git a/setup.py b/setup.py index f3eb749..f529067 100644 --- a/setup.py +++ b/setup.py @@ -33,7 +33,7 @@ def read(fname): setup( name="marshmallow-jsonschema", - version="0.8.0", + version="0.9.0", description="JSON Schema Draft v4 (http://json-schema.org/)" " formatting with marshmallow", long_description=long_description, @@ -61,6 +61,7 @@ def read(fname): "Programming Language :: Python :: 3.5", "Programming Language :: Python :: 3.6", "Programming Language :: Python :: 3.7", + "Programming Language :: Python :: 3.8", ], test_suite="tests", ) diff --git a/tests/__init__.py b/tests/__init__.py index 8dcc82e..6d75bd9 100644 --- a/tests/__init__.py +++ b/tests/__init__.py @@ -1,5 +1,6 @@ from jsonschema import Draft7Validator from marshmallow import Schema, fields, validate +from marshmallow_jsonschema.compat import MARSHMALLOW_3 from marshmallow_jsonschema import JSONSchema from marshmallow_jsonschema.compat import dot_data_backwards_compatible @@ -26,7 +27,6 @@ class UserSchema(Schema): ) created_iso = fields.DateTime(format="iso", attribute="created", dump_only=True) updated = fields.DateTime() - updated_local = fields.LocalDateTime(attribute="updated", dump_only=True) species = fields.String(attribute="SPECIES") id = fields.String(default="no-id") homepage = fields.Url() @@ -54,6 +54,10 @@ class UserSchema(Schema): const = fields.String(validate=validate.Length(equal=50)) +if MARSHMALLOW_3: + UserSchema.updated_naive = fields.NaiveDateTime(attribute="updated", dump_only=True) + + def _validate_schema(schema): """ raises jsonschema.exceptions.SchemaError diff --git a/tox.ini b/tox.ini index d7fcd6e..10729d4 100644 --- a/tox.ini +++ b/tox.ini @@ -1,11 +1,11 @@ [tox] -envlist=lint,py{35,36,37,py3}-marshmallow{2,3}, py{27, py}-marshmallow2 +envlist=lint,py{27,35,36,37,38,py3}-marshmallow{2,3}, py{27, py}-marshmallow2 [testenv] deps= -r requirements-test.txt marshmallow2: marshmallow<3.0 - py{35,36,37,py3}-marshmallow3: marshmallow==3.0.0rc8 + py{35,36,37,38,py3}-marshmallow3: marshmallow==3.3.0 whitelist_externals=make commands=make test_coverage