Hi, I am a beginner and have been following the elixir introduction step-by-step up to Distributed tasks and tags — Elixir v1.17.2 where I am getting this error:
iex(bar@vicomptwo)3> task = Task.Supervisor.async({KV.RouterTasks, :"foo@vicomptwo"}, Kernel, :node, [])
** (exit) exited in: GenServer.call({KV.RouterTasks, :foo@vicomptwo}, {:start_task, [{:bar@vicomptwo, #PID<0.142.0>, #PID<0.142.0>}, :monitor], :temporary, nil}, :infinity)
** (EXIT) no process: the process is not alive or there's no process currently associated with the given name, possibly because its application isn't started
(elixir 1.16.3) lib/gen_server.ex:1114: GenServer.call/3
(elixir 1.16.3) lib/task/supervisor.ex:546: Task.Supervisor.async/6
iex:3: (file)
Which steps can I take to debug this issue?
I found some posts about this error in the forums but they seem to be quite complicated compared to what I am doing.
So far I have tried:
iex(foo@vicomptwo)2> Application.ensure_all_started(:kv)
{:ok, []}
iex(foo@vicomptwo)3> Application.start(:kv)
{:error, {:already_started, :kv}}
iex(foo@vicomptwo)4> Application.start(:logger)
{:error, {:already_started, :logger}}
I would expect Application.ensure_all_started(:kv)
to return {:ok, [:logger, :kv]}
like is shown in this section of the introduction but I do not if it is related (or what to do about it).