From ccea418bb84de67c378b5d86908607ebc6986e7c Mon Sep 17 00:00:00 2001 From: Felipe Date: Tue, 20 Mar 2018 10:58:15 -0300 Subject: [PATCH] =?UTF-8?q?corre=C3=A7ao=20de=20bug=20unicode?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pytrustnfe/xml/__init__.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pytrustnfe/xml/__init__.py b/pytrustnfe/xml/__init__.py index 0ed0ee5..0d11eab 100644 --- a/pytrustnfe/xml/__init__.py +++ b/pytrustnfe/xml/__init__.py @@ -46,7 +46,7 @@ def render_xml(path, template_name, remove_empty, **nfe): def sanitize_response(response): - tree = etree.fromstring(response) + tree = etree.fromstring(response.encode('utf-8')) # Remove namespaces inuteis na resposta for elem in tree.getiterator(): if not hasattr(elem.tag, 'find'):