From 595d89698a9b832d51d61a475b64011b969ff264 Mon Sep 17 00:00:00 2001 From: ines Date: Thu, 16 Mar 2017 10:01:14 +0100 Subject: [PATCH] Add basestring --- spacy/deprecated.py | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/spacy/deprecated.py b/spacy/deprecated.py index 7394c5bf3..72327c584 100644 --- a/spacy/deprecated.py +++ b/spacy/deprecated.py @@ -4,6 +4,12 @@ from . import util from .download import download +try: + basestring +except NameError: + basestring = str + + def read_lang_data(package): tokenization = package.load_json(('tokenizer', 'specials.json')) with package.open(('tokenizer', 'prefix.txt'), default=None) as file_: