How To Fix Importerror: Cannot Import Name 'format_exception_only' In Python
I am using pycharm community version for python 3.6.1 as I'm beginner when i try to run simple tokenize program - import nltk from nltk.tokenize import word_tokenize word_tokeniz
Solution 1:
File "E:\test\token.py", line 2, in from nltk.tokenize import word_tokenize
There happen to be another script with the same name Python is looking for. Python got confused about the script from package and your own script because it start searching from the folder where you are. So just change your own script to another name.
Post a Comment for "How To Fix Importerror: Cannot Import Name 'format_exception_only' In Python"