Forbid the use of the Debug module before it goes into production or fails in the CI.
config =
[ NoDebug.rule
]
Fail
if Debug.log "condition" condition then
a
else
b
if condition then
Debug.todo "Nooo!"
else
value
Success
if condition then
a
else
b
When (not) to use this rule
You should use this rule if you're developing a package meant to be published,
or an application that is put into production, and wish to know about the use of
the Debug
module before committing your changes.
You should not use this rule if you are developing an application that is not
put into production, and you do not care about having stray debug logs or
runtime exceptions caused by Debug.todo,
and you do not ship to production.
Forbid the use of the
Debugmodule before it goes into production or fails in the CI.Fail
Success
When (not) to use this rule
You should use this rule if you're developing a package meant to be published, or an application that is put into production, and wish to know about the use of the
Debugmodule before committing your changes.You should not use this rule if you are developing an application that is not put into production, and you do not care about having stray debug logs or runtime exceptions caused by
Debug.todo, and you do not ship to production.