-
Notifications
You must be signed in to change notification settings - Fork 3.4k
Warning about configured app in umbrella application #10482
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
Dependencies in the root are not available in child applications, therefore the warning is correct. You need to explicitly list the dependencies in all projects that need them. If you find this too verbose, you can create a file in your umbrella root called defmodule SharedProject do
def deps, do: [...]
end And then in each mix.exs you can require this file and use the shared helpers. Another option is to create a project in the umbrelled called dev_helpers, which has these dependencies, and other conveniences you woudl like to share. |
I understand that these applications listed in the root mixfile can't be used in the child applications, but that's not the case here. The only reference to this dependency is in our root config for ex_unit:
|
Can you please provide a minimal application that reproduces the error then? Thank you. |
I created a very small application here: https://github.com/TBK145/config_warning. The warning appears when running |
Thanks @TBK145! The warnings are correct:
|
Thanks, I guess I don't fully understand how junit_formatter is called by the child application, as I was under the impression that it was only used by ex_unit. |
Your umbrella apps and all child apps load the same config file. The issue is that you are configuring an application that does not exist. |
Environment
Current behavior
We have a umbrella project with several dependencies in the root mix.exs file that are only used for development and CI, for example 'junit_formatter'. We configure this application in our root config file as well. When running mix test (or mix run with MIX_ENV=test) we get this warning:
When I move the dependency from the root mix.exs to one of the umbrella applications, the warning disappears.
Expected behavior
Not seeing a warning, because the application is added as depency in the root mixfile.
The text was updated successfully, but these errors were encountered: