Programming Search⌘K

Elixir lints

The lint rules of Elixir, with what each one finds. This page has 116 cards.

Elixir allows us to use _ as a name for variables that are not meant to be used. Credo.Check.Consistency.UnusedVariableNames

But it’s a common practice to give these variables meaningful names anyway (_user instead of _), but some people prefer to name them all anonymously (_). Its Credo id is EX1008, and it is in the consistency category. The default configuration does not enable it. Its base priority is high.

Code
Credo.Check.Consistency.UnusedVariableNames

Source: github.com, hexdocs.pm. JSON record. This entry is a card. Help write this page.

Module attributes are evaluated at compile time and not at run time. Credo.Check.Warning.ApplicationConfigInModuleAttribute

As a result, certain configuration read calls made in your module attributes may work as expected during local development, but may break once in a deployed context. Its Credo id is EX5001, and it is in the warning category. The default configuration enables it. Its base priority is high.

Code
Credo.Check.Warning.ApplicationConfigInModuleAttribute

Source: github.com, hexdocs.pm. JSON record. This entry is a card. Help write this page.

OS child processes inherit the environment of their parent process. Credo.Check.Warning.LeakyEnvironment

This includes sensitive configuration parameters, such as credentials. To minimize the risk of such values leaking, clear or overwrite them when spawning executables. Its Credo id is EX5008, and it is in the warning category. The default configuration does not enable it. Its base priority is high.

Code
Credo.Check.Warning.LeakyEnvironment

Source: github.com, hexdocs.pm. JSON record. This entry is a card. Help write this page.