* guile-lib logging formatters
@ 2024-04-29 9:40 Christopher Baines
0 siblings, 0 replies; only message in thread
From: Christopher Baines @ 2024-04-29 9:40 UTC (permalink / raw)
To: guile-devel
[-- Attachment #1: Type: text/plain, Size: 963 bytes --]
Hey!
I ran in to some problems with the <log-handler> formatter recently, it
seems it's being called with more than 3 arguments since the update to
guile-lib 0.2.8.
Can you advise on how to approach this?
I presume this isn't some internal interface I'm using accidentally? The
documentation states:
#:formatter
This optional parameter must be a function that takes three
arguments: the log level, the time (as from current-time), and the
log string itself. The function must return a string representing
the formatted log.
So far I've been making this change as it's the neatest way I've come up
with of making the formatters both forward and backwards compatible:
https://git.savannah.gnu.org/cgit/guix/nar-herder.git/commit/?id=6be6f63c9f03b7bc928f7927a38da91f95f57ea2
It's not very neat though. I did try something like:
(lambda* (lvl time str #:allow-other-keys) ...)
But that doesn't seem to be valid Guile.
Thanks,
Chris
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 987 bytes --]
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2024-04-29 9:40 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-04-29 9:40 guile-lib logging formatters Christopher Baines
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).