voltone / x509

Elixir package for working with X.509 certificates, Certificate Signing Requests (CSRs), Certificate Revocation Lists (CRLs) and RSA/ECC key pairs
BSD 3-Clause "New" or "Revised" License
120 stars 28 forks source link

compiler(warnings): Fix compiler warning emitted from elixir 1.11.0 #38

Closed tomciopp closed 4 years ago

tomciopp commented 4 years ago

@voltone A bunch of new compiler warnings are emitted when using elixir 1.11.0. I've included one below as an example.

warning: IEx.started?/0 defined in application :iex is used by the current application but the current application does not directly depend on :iex. To fix this, you must do one of:

  1. If :iex is part of Erlang/Elixir, you must include it under :extra_applications inside "def application" in your mix.exs

  2. If :iex is a dependency, make sure it is listed under "def deps" in your mix.exs

  3. In case you don't want to add a requirement to :iex, you may optionally skip this warning by adding [xref: [exclude: IEx] to your "def project" in mix.exs

  lib/mix/tasks/x509.test_server.ex:104: Mix.Tasks.X509.TestServer.iex_running?/0
voltone commented 4 years ago

Thanks for the PR @tomciopp !

I would like to keep :iex and :syntax_tools out of the list of extra applications, since they really should not be bundled into a release just because x509 is. The former is only called after calling Code.ensure_loaded?(IEx) to detect when IEx is active, and the latter is a compile-time only dependency.

So I would propose to remove those and add the xref: [exclude: [IEx, :epp_dodger]] project option.

tomciopp commented 4 years ago

@voltone updated

voltone commented 4 years ago

Great, thanks!