diff --git a/src/openapi_server/apis/reading_api.py b/src/openapi_server/apis/reading_api.py index 3dd0850..0b055b3 100644 --- a/src/openapi_server/apis/reading_api.py +++ b/src/openapi_server/apis/reading_api.py @@ -109,7 +109,7 @@ async def list_unpublished_get_get( if "application/xml" in content_type: return Response(status_code=200, content=xml, media_type="application/xml") - root = lxml.etree.fromstring(xml) + root = lxml.etree.fromstring(xml) # noqa: S320 namespaces = { "search": "http://marklogic.com/appservices/search", "uk": "https://caselaw.nationalarchives.gov.uk/akn", diff --git a/src/openapi_server/apis/utils.py b/src/openapi_server/apis/utils.py index aeb0bf6..f4f7116 100644 --- a/src/openapi_server/apis/utils.py +++ b/src/openapi_server/apis/utils.py @@ -20,7 +20,7 @@ def error_response(e): """provide a uniform error Response""" logging.warning(e) if isinstance(e, MarklogicValidationFailedError): - root = lxml.etree.fromstring(e.response.content) + root = lxml.etree.fromstring(e.response.content) # noqa: S320 error_message = root.xpath( "//mlerror:message/text()", namespaces={"mlerror": "http://marklogic.com/xdmp/error"},