Hi,
when i am trying to test my code i am getting the below error when running the unit test (unittests.test_shortest_path(GraphShortestPath))
this is the error i get:
Process shortest_path:
Traceback (most recent call last):
File “/opt/conda/lib/python3.11/multiprocessing/process.py”, line 314, in _bootstrap
self.run()
File “/opt/conda/lib/python3.11/multiprocessing/process.py”, line 108, in run
self._target(*self._args, **self._kwargs)
File “/home/jovyan/work/unittests.py”, line 51, in helper
out = func(*arg)
^^^^^^^^^^
File “/tmp/ipykernel_11936/512831735.py”, line 46, in shortest_path
for neighbor, weight in graph.graph[current_vertex].items():
~~~~~~~~~~~^^^^^^^^^^^^^^^^
KeyError: 654