Closed olegs closed 5 years ago
networkx.exception.NetworkXError
networkx.exception.NetworkXError: The node 17029560 is not in the digraph.
Traceback (most recent call last)
File "/Users/oleg/miniconda3/envs/pubtrends/lib/python3.7/site-packages/networkx/classes/digraph.py", line 809, in successors
return iter(self._succ[n])
During handling of the above exception, another exception occurred:
File "/Users/oleg/miniconda3/envs/pubtrends/lib/python3.7/site-packages/flask/app.py", line 2463, in __call__
return self.wsgi_app(environ, start_response)
File "/Users/oleg/miniconda3/envs/pubtrends/lib/python3.7/site-packages/flask/app.py", line 2449, in wsgi_app
response = self.handle_exception(e)
File "/Users/oleg/miniconda3/envs/pubtrends/lib/python3.7/site-packages/flask/app.py", line 1866, in handle_exception
reraise(exc_type, exc_value, tb)
File "/Users/oleg/miniconda3/envs/pubtrends/lib/python3.7/site-packages/flask/_compat.py", line 39, in reraise
raise value
File "/Users/oleg/miniconda3/envs/pubtrends/lib/python3.7/site-packages/flask/app.py", line 2446, in wsgi_app
response = self.full_dispatch_request()
File "/Users/oleg/miniconda3/envs/pubtrends/lib/python3.7/site-packages/flask/app.py", line 1951, in full_dispatch_request
rv = self.handle_user_exception(e)
File "/Users/oleg/miniconda3/envs/pubtrends/lib/python3.7/site-packages/flask/app.py", line 1820, in handle_user_exception
reraise(exc_type, exc_value, tb)
File "/Users/oleg/miniconda3/envs/pubtrends/lib/python3.7/site-packages/flask/_compat.py", line 39, in reraise
raise value
File "/Users/oleg/miniconda3/envs/pubtrends/lib/python3.7/site-packages/flask/app.py", line 1949, in full_dispatch_request
rv = self.dispatch_request()
File "/Users/oleg/miniconda3/envs/pubtrends/lib/python3.7/site-packages/flask/app.py", line 1935, in dispatch_request
return self.view_functions[rule.endpoint](**req.view_args)
File "/Users/oleg/work/pubtrends/models/app/app.py", line 141, in paper
return render_template('paper.html', **prepare_paper_data(data, source, pid),
File "/Users/oleg/work/pubtrends/models/keypaper/paper.py", line 72, in prepare_paper_data
top_references = get_top_papers(analyzer.G.successors(pid), analyzer.df, key='pagerank')
File "/Users/oleg/miniconda3/envs/pubtrends/lib/python3.7/site-packages/networkx/classes/digraph.py", line 811, in successors
raise NetworkXError("The node %s is not in the digraph." % (n,))
networkx.exception.NetworkXError: The node 17029560 is not in the digraph.
The debugger caught an exception in your WSGI application. You can now look at the traceback which led to the error.
To switch between the interactive traceback and the plaintext one, you can click on the "Traceback" headline. From the text traceback you can also create a paste of it. For code execution mouse-over the frame you want to debug and click on the console icon on the right side.
You can execute arbitrary Python code in the stack frames and there are some extra helpers available for introspection:
dump() shows all variables in the frame
dump(obj) dumps all that's known about the object
Tests on ’About Paper’ data preparation are missing.
Steps to reproduce:
version 10.10.2019 search antibiotic resistance prediction genome Click on paper from topic 4, topic 3, topic 2, topic 1. Eventually you'll get 500. http://ec2-54-171-39-244.eu-west-1.compute.amazonaws.com/paper?source=Pubmed&id=26135867&jobid=2eefcd64-73d1-4cb3-8524-bba7af5d665a