[erlang-questions] R21 logger mangles map messages
Fri Aug 10 11:07:08 CEST 2018
Den tor. 9. aug. 2018 kl. 16:42 skrev Mark Geib <mark.geib.44@REDACTED>:
> Yes that removed the extra commas. Of course now the log messages are
> So to get a single line message for maps, without the commas, is the only
> approach to format the message with something like
> io_lib:print(MyBigMap,1,8192,-1) and then log the string?
Yes, or you could specify field with 0 with ~p to indicate infinite line
logger:notice("my map: ~0p",[MyMap])
(Using the value 0 here is new from OTP-21, see the description of control
sequence 'p' in the ref.man for io:format.)
I do, however, see this a bug in logger. It needs to be a bit more
sophisticated when ensuring single line - I'm looking into it.
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the erlang-questions