From 571519f8b8293e599359be38d65fb7bb345477d5 Mon Sep 17 00:00:00 2001 From: Jordi Llonch Date: Tue, 15 Mar 2016 16:03:38 +1100 Subject: [PATCH] keep response as str to avoid double encoding --- pycorenlp/corenlp.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pycorenlp/corenlp.py b/pycorenlp/corenlp.py index 986c094..989c046 100644 --- a/pycorenlp/corenlp.py +++ b/pycorenlp/corenlp.py @@ -23,7 +23,7 @@ def annotate(self, text, properties=None): self.server_url, params={ 'properties': str(properties) }, data=text) - output = r.text + output = r.content if ('outputFormat' in properties and properties['outputFormat'] == 'json'): try: