# \#logger

**URL:** https://erlangforums.com/tag/logger/490.md

[Latest](https://erlangforums.com/latest.md) · [Categories](https://erlangforums.com/categories.md) · [Tags](https://erlangforums.com/tags.md)

---

## [How to shortner Erlang module file names in the logs?](https://erlangforums.com/t/how-to-shortner-erlang-module-file-names-in-the-logs/4740)

<div class="topic-metadata">

**Author:** [@zabrane](https://erlangforums.com/u/zabrane)\
**Replies:** 1\
**Last updated:** [May 8, 2025, 10:21pm UTC](https://erlangforums.com/t/how-to-shortner-erlang-module-file-names-in-the-logs/4740 "2025-05-08T22:21:52Z")

</div>

Hi All I’m using logger for my app and always see fullpath for module names: 2025-05-08T21:36:21.371089+02:00 \[info\] \[/Users/zab/dev/kolu/src/kolu.erl.233\] a09ed09367c0=put(11111720002-DrillDoctor) 2025-05-08T21:36:21.…

---

## [Reading standard \`logger\` logs](https://erlangforums.com/t/reading-standard-logger-logs/4441)

<div class="topic-metadata">

**Author:** [@mmin](https://erlangforums.com/u/mmin)\
**Replies:** 3\
**Last updated:** [February 3, 2025, 12:16pm UTC](https://erlangforums.com/t/reading-standard-logger-logs/4441 "2025-02-03T12:16:55Z")

</div>

How to read logs produced from logger, i.e. by logger\_std\_h or logger\_disk\_log\_h ? Ideally, what I want is some interface like the one in wrar\_logger\_reader, but it seems that it’s only working for disk\_log, not logger: …

---

## [Including file name, function arity etc. in logger's output](https://erlangforums.com/t/including-file-name-function-arity-etc-in-loggers-output/3500)

<div class="topic-metadata">

**Author:** [@elbrujohalcon](https://erlangforums.com/u/elbrujohalcon)\
**Replies:** 4\
**Last updated:** [April 17, 2024, 11:54am UTC](https://erlangforums.com/t/including-file-name-function-arity-etc-in-loggers-output/3500 "2024-04-17T11:54:03Z")

</div>

Hi folks :wave: I’m working on a project where we want to replace lager with OTP’s logger and there is one thing that’s causing us quite a few headaches. Since lager uses parse-trasnforms, it can easily include module …

---

## [Illegal\_config\_change when trying to redirect logger to standard error](https://erlangforums.com/t/illegal-config-change-when-trying-to-redirect-logger-to-standard-error/3262)

<div class="topic-metadata">

**Author:** [@mat-hek](https://erlangforums.com/u/mat-hek)\
**Replies:** 7\
**Last updated:** [February 5, 2024, 5:24pm UTC](https://erlangforums.com/t/illegal-config-change-when-trying-to-redirect-logger-to-standard-error/3262 "2024-02-05T17:24:14Z")

</div>

Hello, I’m trying to redirect logs to standard error: logger:set\_handler\_config(default, config, #{type =\> {device, standard\_error}} and I’m getting the illegal\_config\_change error. Currently, I’m removing the handler …

---

## [How can I configure debug-level logging in my unit tests?](https://erlangforums.com/t/how-can-i-configure-debug-level-logging-in-my-unit-tests/2678)

<div class="topic-metadata">

**Author:** [@rlipscombe](https://erlangforums.com/u/rlipscombe)\
**Replies:** 2\
**Last updated:** [June 12, 2023, 10:58am UTC](https://erlangforums.com/t/how-can-i-configure-debug-level-logging-in-my-unit-tests/2678 "2023-06-12T10:58:57Z")

</div>

I’ve got some ?LOG\_DEBUG statements in my code. I’d like to see it while running rebar3 eunit. How can I configure debug-level logging in my unit tests?

---

## [Something like flush function for logger?](https://erlangforums.com/t/something-like-flush-function-for-logger/2664)

<div class="topic-metadata">

**Author:** [@kuna.prime](https://erlangforums.com/u/kuna.prime)\
**Replies:** 2\
**Last updated:** [June 6, 2023, 5:33pm UTC](https://erlangforums.com/t/something-like-flush-function-for-logger/2664 "2023-06-06T17:33:30Z")

</div>

I’m building escript and using logger but i have noticed that if my script finishes too fast not all log information is printed (either in terminal or in a log files). Currently i’m working around this problem by invokin…

---

## [How to configure Logger?](https://erlangforums.com/t/how-to-configure-logger/2357)

<div class="topic-metadata">

**Author:** [@zabrane](https://erlangforums.com/u/zabrane)\
**Replies:** 1\
**Last updated:** [March 22, 2023, 11:36pm UTC](https://erlangforums.com/t/how-to-configure-logger/2357 "2023-03-22T23:36:02Z")

</div>

Hi guys, With the default logger config, I get this: $ ls -1 /var/log/dracs/ debug.log.1 debug.log.2 debug.log.3 debug.log.idx debug.log.siz error.log.1 error.log.2 error.log.idx error.log.siz What I’d like to have is…

---

## [Logger\_formatter.erl](https://erlangforums.com/t/logger-formatter-erl/2328)

<div class="topic-metadata">

**Author:** [@meox](https://erlangforums.com/u/meox)\
**Replies:** 0\
**Last updated:** [January 31, 2023, 4:00pm UTC](https://erlangforums.com/t/logger-formatter-erl/2328 "2023-01-31T16:00:27Z")

</div>

I need to customize the time field format in the logger\_std\_h handler. For instance instead of the classical 2023-01-31T15:06:26.556275+00:00 a simpler view like 15:06:26.556. Probably a simple way to do that is to ext…

---

## [Trouble getting logger metadata in error reports](https://erlangforums.com/t/trouble-getting-logger-metadata-in-error-reports/1858)

<div class="topic-metadata">

**Author:** [@ruslandoga](https://erlangforums.com/u/ruslandoga)\
**Replies:** 1\
**Last updated:** [September 23, 2022, 9:28am UTC](https://erlangforums.com/t/trouble-getting-logger-metadata-in-error-reports/1858 "2022-09-23T09:28:00Z")

</div>

Even though my question uses Elixir, I think this might be more of an Erlang question since the Elixir’s Logger.Translator is not getting any metadata in error reports. Question How to get metadata passed to error repor…

---

## [Logging Metadata with macros help](https://erlangforums.com/t/logging-metadata-with-macros-help/1679)

<div class="topic-metadata">

**Author:** [@stratacast](https://erlangforums.com/u/stratacast)\
**Replies:** 2\
**Last updated:** [August 9, 2022, 6:25pm UTC](https://erlangforums.com/t/logging-metadata-with-macros-help/1679 "2022-08-09T18:25:30Z")

</div>

Hello all! I have a project that I have been working on. I have been using function calls such as logger:info/2, logger:debug/2, etc. but have been wanting to add more metadata info. I don’t understand how to make this …
