Exploring Graphs with Elixir: Missing module attribute? (57)

Exploring Graphs with Elixir by @tonyhammond

When defining the GraphCommons.Graph module, I noticed a missing module definition for @storage_dir
To align with the expected output when testing new/3 (p.61), I defined it as “…”
From what I think, this will later be defined from “system-defined inputs for project location and Mix environment”.

For now I have added the following to both graph.ex and query.ex

 @storage_dir GraphCommons.storage_dir()

It’s a hack but works for now.

Yeah, that’s what I ended up doing too after finishing a later section and confirming with the official project code.

Perhaps temporarily define @storage_dir in graph.ex and query.ex as “…”,
then redefine it later:
p.68 – Ch 2 > Building a Graph Store > Creating a Storage area
in GraphCommons.ex, where we define 4 directory output functions.

whatever works best