-
-
Notifications
You must be signed in to change notification settings - Fork 32
Description
Since I also have the error that is described in #77 I searched further through the logs and figured that there must be wrong in parsing my local env with asdf.
I could find that my process is dying:
10:29:21.220 [error] Process #PID<0.173.0> terminating
** (MatchError) no match of right hand side value: [""]
(xp_expert 0.1.0-3f5914a) lib/expert/port.ex:75: anonymous fn/1 in XPExpert.Port.reset_env/2
(elixir 1.17.3) lib/enum.ex:1703: Enum."-map/2-lists^map/1-1-"/2
(elixir 1.17.3) lib/enum.ex:1703: Enum."-map/2-lists^map/1-1-"/2
(xp_expert 0.1.0-3f5914a) lib/expert/port.ex:74: XPExpert.Port.reset_env/2
(xp_expert 0.1.0-3f5914a) lib/expert/port.ex:55: XPExpert.Port.version_manager_path_and_env/2
(xp_expert 0.1.0-3f5914a) lib/expert/port.ex:38: XPExpert.Port.elixir_executable/1
(xp_expert 0.1.0-3f5914a) lib/expert/engine_node.ex:174: XPExpert.EngineNode.glob_paths/1
(xp_expert 0.1.0-3f5914a) lib/expert/engine_node.ex:120: XPExpert.EngineNode.start/1
While checking manually with iex what the code does it turns out that https://github.com/elixir-lang/expert/blob/main/apps/expert/lib/expert/port.ex#L77 under some condition will have an empty ""
which then fails on matching with the [key, value]
.
I was able to find that after getting the env from the system that I have on some point 2 \n
which then after splitting by that newline will lead to that empty string and subsequent in failing.
Unfortunately I wasnt able to find out where those 2 \n
come from since my regular linux env seems to be ok and does not show anything that could explain this.
Maybe someone got an idea or further insight?
best