I encountered a weird problem recently. I was trying to put together a demo for one of my hex packages, and in my demo package I referenced it like this:
{:my_package, dir: "../my_package"}
I just assumed that the right key I wanted was dir. Of course it was actually supposed to be path.
The problem is this appeared like it worked at first glance. It did actually copy that folder into my deps folder. But nothing worked quite right. I would change something in the other directory and it wouldn't reflect in the other project.
I've been told online that apparently dir is an unknown key, and mix is just falling back to some kind of fallback behavior. I think it'd probably be a good idea if an entry with no known key threw some kind of an error.
Hopefully this is the right place for this issue and not the Elixir repo, but I wasn't sure.
Hello there,
I encountered a weird problem recently. I was trying to put together a demo for one of my hex packages, and in my demo package I referenced it like this:
I just assumed that the right key I wanted was
dir
. Of course it was actually supposed to bepath
.The problem is this appeared like it worked at first glance. It did actually copy that folder into my deps folder. But nothing worked quite right. I would change something in the other directory and it wouldn't reflect in the other project.
I've been told online that apparently
dir
is an unknown key, and mix is just falling back to some kind of fallback behavior. I think it'd probably be a good idea if an entry with no known key threw some kind of an error.Hopefully this is the right place for this issue and not the Elixir repo, but I wasn't sure.
Also there's some context about this here: https://x.com/wojtekmach/status/1789360660263870680