Hi! I'm running into a weird problem where Path.expand doesn't return the absolute path while running an elixir release. We're passing as argument this kind of path path = ../../../../examples/simple/simple_scripts/script_1
And doing
Path.expand(path) returns
examples/simple/simple_scripts/script_1 instead of
home/project/examples/simple/simple_scripts/script_1
Does anyone know why?.
#Path.expand doesn't return the absolute path on an Elixir release
8 messages · Page 1 of 1 (latest)
I think because there is bug in the docs, as it will not make your path absolute
Deep down :file.get_cwd() is called, so perhaps that is returning an error? It could if there are permission problems somewhere in the directory hierarchy.
I would suggest adding some debug code that logs the return of that, or File.cwd() which also calls :file.get_cwd().