meta
meta copied to clipboard
ranker.score(idx, query) runs indefinitely
I am running the search function from my Flask app. The step ranker.score(idx, query) runs indefinitely. Could you please check and help me with any pointers? Thank you.
Dataset used: data.dat attached.
Code:
Issue: The application returns results for a single search currently. During the second search, the below steps are completed:
- Index creation
- Ranker selection
- User input parsing The step ranker.score() runs indefinitely during the second search. Workaround: The Flask application requires a restart for checking different queries.
same here, please fix this
I am seeing this on Python 3.7 as well. According to other students in my class, this functionality works correctly on Python 3.5 (which I will try soon). (Unfortunately, since this is a homework assignment, I cannot provide any more details.)
@mikepigott Did you end up finding a solution? Downgrading to Python 3.5 didn't work for me, unfortunately.
As an update: running my Flask app with the "threaded" flag set to False solved the issue.
I.e., changing: app.run()
into app.run(threaded=False)
solved my issues.