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

Documentation Issues: Logger Middleware #379

Open
aselder opened this issue Apr 29, 2020 · 3 comments
Open

Documentation Issues: Logger Middleware #379

aselder opened this issue Apr 29, 2020 · 3 comments

Comments

@aselder
Copy link

aselder commented Apr 29, 2020

I was running it to a situation where I set the log_level of a Logger middleware to always be :debug, but I was still seeing log output with the Logger log_level set to warn.

Looking at the code, it does something slightly different than was the documentation says.

If the request returns {:error, whatever}, the log level is always set to :error, the custom log level function is never called. The custom log level is only used when an {:ok, ...} is returned.

@aselder
Copy link
Author

aselder commented Apr 29, 2020

Also, the docs don't mention that you can pass an atom instead of a function as the log_level option

@aselder
Copy link
Author

aselder commented Apr 29, 2020

I'll see what I can do about putting together a PR.

@teamon teamon added the docs label May 18, 2020
@teamon teamon added this to the 1.4 milestone Jun 15, 2020
@teamon teamon modified the milestones: 1.4, 1.5 Nov 15, 2020
@teamon
Copy link
Member

teamon commented Sep 10, 2021

Hey @aselder, do you still want to give this a try? :)

@teamon teamon removed the help wanted label May 8, 2022
@teamon teamon removed this from the 1.5 milestone May 8, 2022
@teamon teamon added this to Roadmap May 8, 2022
@teamon teamon moved this to Todo in Roadmap May 8, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: Todo
Development

Successfully merging a pull request may close this issue.

2 participants