Skip to content
This repository has been archived by the owner on Feb 25, 2022. It is now read-only.

upgrade to typesystem 0.3.0 #683

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion apistar/schemas/jsonschema.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import typesystem

definitions = typesystem.SchemaDefinitions()
definitions = typesystem.Definitions()

JSON_SCHEMA = (
typesystem.Object(
Expand Down
4 changes: 2 additions & 2 deletions apistar/schemas/openapi.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
properties={"$ref": typesystem.String(pattern="^#/components/responses/")}
)

definitions = typesystem.SchemaDefinitions()
definitions = typesystem.Definitions()

OPEN_API = typesystem.Object(
title="OpenAPI",
Expand Down Expand Up @@ -367,7 +367,7 @@ def load(self, data):
)

def get_schema_definitions(self, data):
definitions = typesystem.SchemaDefinitions()
definitions = typesystem.Definitions()
schemas = lookup(data, ["components", "schemas"], {})
for key, value in schemas.items():
ref = f"#/components/schemas/{key}"
Expand Down
4 changes: 2 additions & 2 deletions apistar/schemas/swagger.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
properties={"$ref": typesystem.String(pattern="^#/responses/")}
)

definitions = typesystem.SchemaDefinitions()
definitions = typesystem.Definitions()

SWAGGER = typesystem.Object(
title="Swagger",
Expand Down Expand Up @@ -357,7 +357,7 @@ def load(self, data):
)

def get_schema_definitions(self, data):
definitions = typesystem.SchemaDefinitions()
definitions = typesystem.Definitions()
schemas = lookup(data, ["components", "schemas"], {})
for key, value in schemas.items():
ref = f"#/components/schemas/{key}"
Expand Down
2 changes: 1 addition & 1 deletion requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ click
jinja2
requests
pyyaml
typesystem>=0.2.0
typesystem>=0.3.0,<0.4.0

# Testing requirements
black
Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ def get_long_description(long_description_file):
author_email="[email protected]",
packages=get_packages("apistar"),
package_data=get_package_data("apistar"),
install_requires=["click", "jinja2", "requests", "pyyaml", "typesystem"],
install_requires=["click", "jinja2", "requests", "pyyaml", "typesystem>=0.3.0,<0.4.0"],
python_requires=">=3.6",
classifiers=[
"Development Status :: 3 - Alpha",
Expand Down