Thanks! Does the example code for that module in the guide work _without_ adding the module to `:extra_applications` because I'm running it on my 'dev' computer? In the test project I used, there are NO (explicit) Mix deps, so I don't _think_ `crypto` could be being pulled in via some other dependency.
On Tuesday, September 21, 2021 at 11:39:25 AM UTC-4 José Valim wrote: > The wording here is definitely confusing. Erlang is a collection of > applications and crypto is one of them. You need to include all of Erlang > applications, outside of "kernel" and "stdlib" apps, in extra_applications. > I will clarify the guides. Thanks! > > > On Tue, Sep 21, 2021 at 5:33 PM Kenny Evitt <kenny...@gmail.com> wrote: > >> On the Erlang libraries page of the current guide, for the `crypto` >> module >> <https://elixir-lang.org/getting-started/erlang-libraries.html#the-crypto-module> >> : >> >> > The `:crypto` module is not part of the Erlang standard library, but is >> included with the Erlang distribution. This means you must list `:crypto` >> in your project’s applications list whenever you use it. To do this, edit >> your `mix.exs` file to include: >> > >> > ``` >> > def application do >> > [extra_applications: [:crypto]] >> > end >> > ``` >> >> But in a reply on a recent Elixir Forum post >> <https://elixirforum.com/t/help-with-reading-typespecs-for-erlang-crypto-module/42423/7>, >> >> someone claimed: >> >> > `:crypto` is a part of and is distributed with Erlang/OTP ... >> >> And that doesn't seem to contradict what's in the Getting Started guide. >> >> But I'm confused as to why that module should be added to the >> `:extra_applications` key. I just tried running the example code from the >> guide in a 'scratchpad' project that has NO (explicit) Mix deps, and only >> `:logger` listed in `:extra_applications` and the code worked fine in >> `iex`. Does that code work because I'm running it on my 'dev' computer? >> Would NOT adding `:crypto` to `:extra_applications` present a problem were >> I to deploy that project's code to another computer? >> >> Or is `crypto` now (somehow) part of "the Erlang standard library"? >> >> I'm just curious! But, if the guide is now incorrect about this, I'd be >> happy to submit a PR with any suitable changes. >> >> -- >> You received this message because you are subscribed to the Google Groups >> "elixir-lang-core" group. >> To unsubscribe from this group and stop receiving emails from it, send an >> email to elixir-lang-co...@googlegroups.com. >> To view this discussion on the web visit >> https://groups.google.com/d/msgid/elixir-lang-core/58f100bd-b79c-4893-8f1f-ec8aea26d81dn%40googlegroups.com >> >> <https://groups.google.com/d/msgid/elixir-lang-core/58f100bd-b79c-4893-8f1f-ec8aea26d81dn%40googlegroups.com?utm_medium=email&utm_source=footer> >> . >> > -- You received this message because you are subscribed to the Google Groups "elixir-lang-core" group. To unsubscribe from this group and stop receiving emails from it, send an email to elixir-lang-core+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/elixir-lang-core/de5e8144-d3ff-4805-a903-4d2b084ebbfan%40googlegroups.com.