(Mix) Could not compile dependency :chatterbox

  • (Mix) Could not compile dependency :chatterbox, “/home/user/.mix/rebar3 bare compile --paths “/home/user/Documents/signalbroker/signal_server/_build/dev/lib/*/ebin”” command failed. You can recompile this dependency with “mix deps.compile chatterbox”, update it with “mix deps.update chatterbox” or clean it with “mix deps.clean chatterbox”

I have tried all the three suggestions, still get the same error.
I use ubuntu 18, 64 bit

Probably because they have warnings_as_errors in their rebar default profile… Please checkout the repository in the exact version you want to use in your project, try to build and then file a bug report in their GitHub repository, asking to move the warnings_as_errors setting as well, as it breaks projects that depend on it.

1 Like

How do I know which exact version I need in my project?

mix deps | grep chatterbox IIRC.

It looks like you have a git dependency, not constraint by any branch/tag/commit, so you get whatever HEAD was on the first deps.get, it should be fine to simply try with HEAD from the repo and create the issue based on that.

PS: they are using gen_fsm which is a not trivial to fix issue, depending on which versions of OTP they want to support.

Easiest for now should be to fork/vendor a version that has the warnings_as_errors removed from the config.

1 Like

Thanks, removing the warnings_as_errors fixed the problem.

1 Like

Have you made them aware of the problems they are causing by that setting?


I’m fine with removing it from the default profile. Please send a PR to chatterbox and I’ll merge it.

Also note that in the latest gen_fsm has been replaced by gen_statem.

(I just realized you are using a fork of chatterbox… Maybe tony612 would be willing to upgrade his fork to the latest upstream also).

1 Like

No, how do I do that?

I don’t know why I got that, I did not change any default configuration.

What is your Elixir version? Recent Elixir versions are meant to automatically remove warnings_as_errors from dependencies, even rebar ones.

Open an issue on the GitHub repository.

But rebar won’t, so I still think it should be removed from library projects default profile.

Mix tells rebar exactly which config and profile to use and we make sure to not pass warnings_as_errors, so IIRC it should work as well.

I mean in erlang projects. Completely unrelated to elixir.

1 Like

It is 1.7.2

I assume you are using the Elixir grpc package? That uses a fork of chatterbox.

I think it still needs an outstanding PR to work with upstream. I have an open PR I’m working on getting into chatterbox that allows it to work with my grpc server/client package (grpcbox), so hopefully we can all consolidate back to the upstream repo in the near future.

Yes the project supports grpc…