What does your “main file” look like?
Others will correct me if I’m wrong, but I think, based on @wojtekmach’s answer, it’s because your function calls are not themselves in a function, so they call functions at compile time instead of run time:
Try putting those function calls in a function:
defmodule Main do
def go do
Hello.say_hi()
GetPayloadInfo.doReq()
end
end
Then (without the Application.ensure_all_started
), run the Main.go
function in iex (in the directory containing your Mix project):
$ iex -S mix
iex> Main.go