Skip to content

Fix definition of paths in walkthrough

In the walkthrough track building model, paths = list(p.map(find_paths_partial, starting_nodes)) creates an extra set of brackets around each sublist in paths that causes problems. I haven't figured out if this is due to some version update or what, but the fix is to just add the last line here:

    with Pool(workers) as p:
        paths = list(p.map(find_paths_partial, starting_nodes))
    paths = list(chain.from_iterable(paths)) # This line removes one layer of brackets, and fixes the bug