Skip to content
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

TECH-437 Lazy Evaluation #2

Closed
wants to merge 1 commit into from
Closed

Conversation

rraub
Copy link
Member

@rraub rraub commented Oct 14, 2020

wrap log formatting in functions so they can be lazy evaluated

Credo style guide: https://github.com/rrrene/credo/blob/master/lib/credo/check/warning/lazy_logging.ex

Should be no noticeable change, except saving some cpu cycles when the log level is set higher than debug.

so they can be lazy evalued
@esvinson
Copy link
Member

esvinson commented Oct 14, 2020

Credo disables this on elixir >= 1.7.

Patch notes from Credo v1.0.3:

Disable LazyLogging for Elixir >= 1.7

PR for Reference: rrrene/credo#638

These should already be lazy.

@rraub
Copy link
Member Author

rraub commented Oct 14, 2020

Dang! how did I miss that!? https://github.com/elixir-lang/elixir/blob/v1.7/CHANGELOG.md#other-logger-improvements
Thanks @esvinson !

@rraub rraub closed this Oct 14, 2020
@rraub rraub deleted the tech-347-wrap-in-functions branch October 14, 2020 23:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants