diff --git a/nltk/decorators.py b/nltk/decorators.py index 7687224a23..d64fe0e1ec 100644 --- a/nltk/decorators.py +++ b/nltk/decorators.py @@ -20,7 +20,7 @@ # Hack to keep NLTK's "tokenize" module from colliding with the "tokenize" in # the Python standard library. OLD_SYS_PATH = sys.path[:] -sys.path = [p for p in sys.path if p and "nltk" not in p] +sys.path = [p for p in sys.path if p and "nltk" not in str(p)] import inspect sys.path = OLD_SYS_PATH