Closed kanishkablack closed 5 years ago
I am also seeing this.
It seems adding a missing dependency fixes this. In my case, I had lager being included via config (and extra_application), but putting in the deps worked. Note that I had to set the distillery version to 1.5.5 to get a helpful error message about it. One I added the the dep, going back to distillery 2.0 worked just fine.
@ogreface Just FYI, but you can't put third-party dependencies in extra_applications
, it is intended for "extra" standard library applications from Elixir or Erlang, e.g. logger
or crypto
. You can of course add third-party deps to that list, but it doesn't actually do anything, and can cause issues when tools don't expect it. In this case though, it seems like you didn't have the lager
dependency in your deps list at all, which is why the error is a bit obtuse.
I'll add a TODO to make sure Distillery identifies this edge case. Thanks!
I fixed it removing a missing app
, in the application
function in mix.exs
.
I forgot I experimented with Scrape
. and I had extra_applications: [:scrape, :logger, :runtime_tools]
just removes :scrape
and it works. Hope help newcomers like me.
Its good to know this place is only for standard libraries from the ecosystem.
thanks.
@bitwalker Great to know, thanks for the feedback!
The problem still exists when you're using debian/ubuntu.
In my case, I've forgotten to install erlang-xmerl
package and this kind of error appeared. To fix this you have to apt install erlang-xmerl
. There was a few other missing packages: erlang-xmerl erlang-appmon erlang-os-mon.
The problem is that you simply don't know what package you're missing.
I found one more case:
When you have an umbrella app in your deps, you'll get same error.
The solution is to just add runtime: false
, but I've spent about an hour to figure it out.
Attempt to fix this issue: https://github.com/bitwalker/distillery/pull/614
Thanks for update
In general there is no way for us to tell you which package to install or something of that nature, we can only identify when an app is extraneous (i.e. it is in the list, but not on the code path).
Steps to reproduce
mix release
Verbose Logs
==> Release failed: function nil.name/0 is undefined
Description of issue
2.0
Erlang 20/ Elixir 1.7.3