forked from 7max/log4cl
-
Notifications
You must be signed in to change notification settings - Fork 10
Open
Description
I rememeber, some time ago it was possible to hit C-c C-g on a function body to change it's log level. But now when cursor is in the:
(in-package :scrapycl/downloader)
(defun blah ()
(log:info "Some info")
(log:error "Some error"))I see only root, package and file options:
Current levels: (set/inherited)
[R] Root logger - INFO [P] Package SCRAPYCL/DOWNLOADER - INFO
[F] File downloader.lisp - INFO
Choose logger: [rpf] ([q]:quit [h]:help)?
I have the following log config:
ROOT, INFO
|
+-(1)-#<CONSOLE-APPENDER {1003D18D33}>
| with #<PATTERN-LAYOUT {1004C310E3}>
| :conversion-pattern
| "%&%<%I%;<;;>;-5p [%D{%H:%M:%S}] %g{}{}{:downcase}%:; ;F (%C{}{ }{:downcase})%2.2N - %:_%m%>%n"
| :immediate-flush T
| :flush-interval 1
| :message-count 2
|
+-(2)-#<TRICKY-CONSOLE-APPENDER {1003D18D43}>
with #<PATTERN-LAYOUT {1004C310E3}>
:conversion-pattern
"%&%<%I%;<;;>;-5p [%D{%H:%M:%S}] %g{}{}{:downcase}%:; ;F (%C{}{ }{:downcase})%2.2N - %:_%m%>%n"
:immediate-flush T
:flush-interval 1
:stream-owner NIL
:stream
#<SB-SYS:FD-STREAM for "socket 127.0.0.1:35205, peer: 127.0.0.1:53440" {1000B90183}>
But if I do create a logger manually, by doing in the REPL:
(log:config (log:category '(scrapycl/downloader blah)) :warn)Then menu opened on the BLAH function has DEFUN option:
Current levels: (set/inherited)
[R] Root logger - INFO [P] Package SCRAPYCL/DOWNLOADER - WARN
[F] File downloader.lisp - WARN [D] Defun blah - WARN
Choose logger: [rpfd] ([q]:quit [h]:help)?
And it works even if I do (log:config :sane2 :clear)
How can I change log level for DEFUN without going to the REPL?
Metadata
Metadata
Assignees
Labels
No labels