Remove recommandations for unmaintained flex library

Fixes #285
This commit is contained in:
Cristi Vijdea
2019-01-29 09:04:10 +02:00
parent 7c5a0b7176
commit df82fe59d7
5 changed files with 17 additions and 10 deletions
+6 -2
View File
@@ -15,8 +15,12 @@ logger = logging.getLogger(__name__)
def _validate_flex(spec):
from flex.core import parse as validate_flex
from flex.exceptions import ValidationError
try:
from flex.core import parse as validate_flex
from flex.exceptions import ValidationError
except ImportError:
return
try:
validate_flex(spec)
except ValidationError as ex:
+1 -1
View File
@@ -57,7 +57,7 @@ def get_schema_view(info=None, url=None, patterns=None, urlconf=None, public=Fal
:param patterns: same as :class:`.OpenAPISchemaGenerator`
:param urlconf: same as :class:`.OpenAPISchemaGenerator`
:param bool public: if False, includes only the endpoints that are accesible by the user viewing the schema
:param list validators: a list of validator names to apply; allowed values are ``flex``, ``ssv``
:param list validators: a list of validator names to apply; the only allowed value is ``ssv``, for now
:param type generator_class: schema generator class to use; should be a subclass of :class:`.OpenAPISchemaGenerator`
:param tuple authentication_classes: authentication classes for the schema view itself
:param tuple permission_classes: permission classes for the schema view itself