<div>Now, the variable output works fine. But, I hit another bug:<br></div><div><br></div><div>(log5:start-sender 'mylog <br> (log5:stream-sender :location *error-output*<br> :category-spec '(log5:info)<br>
:output-spec '(log5:message)))</div><div><br></div><div>When I try to define a sender like the above, I get:</div><div><br>There is no output-specification named NIL. Use defoutput to define output specifications before using them in a sender.<br>
[Condition of type LOG5::OUTPUT-NOT-FOUND-ERROR]<br><br>Restarts:<br> 0: [RETRY] Retry SLIME REPL evaluation request.<br> 1: [*ABORT] Return to SLIME's top level.<br> 2: [TERMINATE-THREAD] Terminate this thread (#<THREAD "repl-thread" RUNNING {1003569571}>)<br>
<br>Backtrace:<br> 0: (LOG5::BUILD-HANDLE-MESSAGE-FN #<LOG5:STREAM-SENDER MYLOG {1003B542E1}>)<br> 1: ((SB-PCL::FAST-METHOD INITIALIZE-INSTANCE :AFTER (LOG5:BASIC-SENDER)) #(3 NIL) #<unused argument> #<LOG5:STREAM-SENDER MYLOG {1003B542E1}>)[:EXTERNAL]<br>
2: ((SB-PCL::EMF INITIALIZE-INSTANCE) #<unused argument> #<unused argument> #<LOG5:STREAM-SENDER MYLOG {1003B542E1}> 5864078772937 12)<br> 3: ((SB-PCL::FAST-METHOD MAKE-INSTANCE (CLASS)) #<unavailable argument> #<unavailable argument> #<STANDARD-CLASS LOG5:STREAM-SENDER>)[:EXTERNAL]<br>
4: (LOG5::START-SENDER-FN MYLOG NIL NIL LOG5:STREAM-SENDER)[:EXTERNAL]<br> 5: (SB-INT:SIMPLE-EVAL-IN-LEXENV (LOG5:START-SENDER 'MYLOG (LOG5:STREAM-SENDER :LOCATION *ERROR-OUTPUT* :CATEGORY-SPEC '(LOG5:INFO+) :OUTPUT-SPEC ...)) #<NULL-LEXENV>)<br>
--more--<br><br>I will try to see what the problem is, but with my limited lisp skills, I might not get too far :)<br>Thanks for a great piece of code, and your sustained efforts!!<br><br></div><br><div class="gmail_quote">
On Wed, Dec 8, 2010 at 10:15 PM, Gary King <span dir="ltr"><<a href="mailto:gwking@metabang.com" target="_blank">gwking@metabang.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;"><div style="word-wrap: break-word;">Hi Venkatesan,<div><br></div><div>I just updated github, etc. with the latest changes. Please let me know how they work for you and/or if you have any other comments or suggestions.</div>
<div><br></div><div>thanks,</div><div><div><div><br><div><div>On Dec 7, 2010, at 12:52 PM, Venkatesan S wrote:</div><br><blockquote type="cite"><div>Thanks Gary. You rock :)<br></div><div><br></div><br><div class="gmail_quote">
On Wed, Dec 8, 2010 at 12:40 AM, Gary King <span dir="ltr"><<a href="mailto:gwking@metabang.com" target="_blank">gwking@metabang.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;"><div style="word-wrap: break-word;">Hi Venkatesan,<div><br></div><div>Thanks for your question. You've stumbled on a bug that I've corrected locally but mistakenly failed to update on github.</div>
<div><br></div><div>I'll remedy this later today.</div><div><br></div><div>My apologies for my oversite.</div><div><br></div><div>regards,</div><div><br></div><div><br></div><div><br><div><div><div><div>On Dec 7, 2010, at 8:29 AM, Venkatesan S wrote:</div>
<br></div></div><blockquote type="cite"><div><div><div>Hi,<br clear="all"></div><div><br></div><div>I am a new user of log5 (and lisp in general). When I tried playing around, I found that log5 has a problem printing variables. For eg, </div>
<div>>(setf a 15)</div><div>
>(log-for (info) "a is ~a~%" a)</div><div><br></div><div>[after setting up a sender and importing all symbols from log5]</div><div><br></div><div>It prints:</div><div>3500123556 (INFO) a is A<br></div><div><br>
</div><div>I expected to see: a is 5</div><div><br></div><div>Is there anything I am missing? I tried grokking the source, and tried putting a , before value in the log-for macro like in:<br><br>(defmacro log-for (category-spec message &rest args)<br>
(if (%log-p category-spec)<br> `(let ((category (load-time-value <br> (update-category-spec nil ',category-spec)<br> t)))<br> (handle-message<br> (category-id category)<br> ,message<br>
,@args))<br> <span style="color: rgb(153, 153, 255);"> </span><i style="color: rgb(255, 0, 0);">`(<b>,</b>values))</i><span style="color: rgb(255, 0, 0);">)</span><br><br></div><div>But this did not help. Can anyone please let me know how to achieve what I want? If it is useful, I am using sbcl 64 bit on Centos 5.5 and the latest clog5 (v0.3.1)<br>
<br>Thanks,<br>Venkatesan<br></div><div><br></div><div><br></div><br>-- <br>
Audentis fortuna juvat<br></div></div>
_______________________________________________<br>log5-devel mailing list<br><a href="mailto:log5-devel@common-lisp.net" target="_blank">log5-devel@common-lisp.net</a><br><a href="http://common-lisp.net/cgi-bin/mailman/listinfo/log5-devel" target="_blank">http://common-lisp.net/cgi-bin/mailman/listinfo/log5-devel</a><br>
</blockquote></div><font color="#888888"><br><div>
<span style="border-collapse: separate; color: rgb(0, 0, 0); font-family: Helvetica; font-size: medium; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px;"><span style="border-collapse: separate; color: rgb(0, 0, 0); font-family: Helvetica; font-size: medium; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px;"><div style="word-wrap: break-word;">
<span style="border-collapse: separate; color: rgb(0, 0, 0); font-family: Helvetica; font-size: medium; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px;"><div style="word-wrap: break-word;">
<div>--</div><div>Gary Warren King, <a href="http://metabang.com/" target="_blank">metabang.com</a> <br>Cell: (413) 559 8738<br>Fax: (206) 338-4052<br>gwkkwg on Skype * garethsan on AIM * gwking on twitter<br></div></div>
</span></div></span></span>
</div>
<br></font></div></div></blockquote></div><br><br clear="all"><br>-- <br>Audentis fortuna juvat<br>
</blockquote></div><br><div>
<span style="border-collapse: separate; color: rgb(0, 0, 0); font-family: Helvetica; font-size: medium; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px;"><span style="border-collapse: separate; color: rgb(0, 0, 0); font-family: Helvetica; font-size: medium; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px;"><div style="word-wrap: break-word;">
<span style="border-collapse: separate; color: rgb(0, 0, 0); font-family: Helvetica; font-size: medium; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px;"><div style="word-wrap: break-word;">
<div>--</div><div>Gary Warren King, <a href="http://metabang.com/" target="_blank">metabang.com</a> <br>Cell: (413) 559 8738<br>Fax: (206) 338-4052<br>gwkkwg on Skype * garethsan on AIM * gwking on twitter<br></div></div>
</span></div></span></span>
</div>
<br></div></div></div></div></blockquote></div><br><br clear="all"><br>-- <br>Audentis fortuna juvat<br>