tigergraph / gsql-graph-algorithms

GSQL Graph Algorithms
https://docs.tigergraph.com/graph-ml/current/intro/
Apache License 2.0
192 stars 70 forks source link

Typo in the gsql of a-star algorithm #129

Open boopalanjayaraman opened 2 years ago

boopalanjayaraman commented 2 years ago

Hi All,

I was trying to install and run a-star algorithm's GSQL for the tigergraph's graph for all challenge.

But I came across a semantic error saying - "path_Tuple" not found.

Below is how the code looked like:

TYPEDEF TUPLE<FLOAT dist, VERTEX v> pathTuple;    # <shotest distance, parent node>
HeapAccum<path_Tuple>(1, dist ASC) @@find_min_v_heap;  # retain 1 shortest path
HeapAccum<path_Tuple>(1, dist ASC) @min_dist_heap;

... s.@min_dist_heap = path_Tuple(0,s);

We can see above that the tuple has been defined as pathTuple but it is being referred as path_Tuple right below (with an underscore) which leads to this error.

https://github.com/tigergraph/gsql-graph-algorithms/blob/d41cfc0096fe39fd814dbf55fdf8ed62ea95e1c9/algorithms/Path/astar_shortest_path/tg_astar.gsql