Closed dzflack closed 7 years ago
@dzflack Does this happen for other articles as well? (ie. 'football', 'kangaroo', 'spider man')
Also, what version of Python are you using?
Yup for all articles.
* Running on http://127.0.0.1:5000/ (Press CTRL+C to quit)
* Restarting with stat
* Debugger is active!
* Debugger pin code: 640-888-131
127.0.0.1 - - [19/Feb/2017 11:19:44] "GET /quiz/football/ HTTP/1.1" 500 -
127.0.0.1 - - [19/Feb/2017 11:20:48] "GET /quiz/kangaroo/ HTTP/1.1" 500 -
127.0.0.1 - - [19/Feb/2017 11:20:59] "GET /quiz/spider%20man/ HTTP/1.1" 500 -
Tried on both Python 2.7.13 and Python 3.6.0
@dzflack In server.py
, I have a try/except wrapping everything, but clearly it's having the adverse effect of hiding the root of the problem. If you remove lines 14,27,28 (try:
and except: resp = Response("ERROR", status=500, mimetype='application/json')
), the error should spit out on the command line.
Very curious to see what it will be.
@dzflack
kercker 0 minutes ago [-]
I got this problem too.
I solved it by downloading 'averaged_perceptron_tagger' from nltk.
>>>import nltk
>>>nltk.download('averaged_perceptron_tagger')
Hope that works!
I think the problem is because this app depends on the package 'averaged_perceptron_tagger' from nltk. I solved this problem by downloading it from nltk.
import nltk nltk.download('averaged_perceptron_tagger')
Yup thats it thanks 👍
Going to add this to the README right now, I forgot I had done this. Sorry for any confusion!