Re: [eng] Re: Question about Januk's print template

2003-03-05 Thread Miguel A. Urech
Hello Januk,

> Look at the headers of the message you are replying to, and you'll
> see the quotation marks there. My templates merely separate the
> provided list into a vertical list.

You are darn right! Sorry about that. I was confused because the
quotations marks are stripped by TB when displaying in the header
pane.

> Yes. Just change which subpatterns you output in the
> print_recipient2 template. The following should do the trick.

I will try it later. But anyhow, now that I know that I am not
"introducing" the quotation marks in the reply, it is not "so
important".

Thanks for your help. Great macros, yes sir! :-)

-- 
Best regards,

Miguel A. Urech (El Escorial - Spain)
Using The Bat! v1.62i



 Current version is 1.61 | "Using TBTECH" information:
http://www.silverstones.com/thebat/TBUDLInfo.html


Re: [eng] Re: Question about Januk's print template

2003-03-05 Thread Miguel A. Urech
Hello Januk,

> By the way, you'd probably want to change the BCCList macro.

I have actually deleted the whole BCC %IF line. It has no sense on a
reply template.

-- 
Best regards,

Miguel A. Urech (El Escorial - Spain)
Using The Bat! v1.62i



 Current version is 1.61 | "Using TBTECH" information:
http://www.silverstones.com/thebat/TBUDLInfo.html


Re: [eng] Re: Question about Januk's print template

2003-03-08 Thread Miguel A. Urech
Hello Januk,

Sorry to bother you about your macro again.

> Yes.  Just change which subpatterns you output in the print_recipient2
> template.  The following should do the trick.

I tried the changes suggested, it works but anyhow I am still using
the original version.

However I have detected a few occasions where something strange
happens, and I must admit I'm totally lost. Your macro is not easy to
follow and understand by RegExp beginners.

Here are the two cases:

,- [ Message I'm replying to includes: ]
| From: =?iso-8859-1?q?Sergi=20Bernal?= <[EMAIL PROTECTED]>
| Subject: Re: [SIG] Archivo Autocad
| To:   [EMAIL PROTECTED]
`-
,- [ And this is what I get in my reply ]
| - Original Message -
|From: Sergi Bernal <[EMAIL PROTECTED]>
|Date: Saturday, March 8, 2003 4:00:48 AM  
|  To:  
| Subject: Re: [SIG] Archivo Autocad
`-

As you can see, the To is blank.

,- [ Here is another case ]
| From: "Axel Ollmann" <[EMAIL PROTECTED]>
| To: "Miguel A. Urech" <[EMAIL PROTECTED]>
| Subject: MailScan
`-
,- [  ]
| - Original Message -
|From: Axel Ollmann <[EMAIL PROTECTED]>
|Date: Thursday, March 6, 2003 10:42:57 AM  
|  To:  
| Subject: MailScan
`-

Same thing here, the To: is again blank.

As I have told you, I tried to understand why this happens but I am
totally lost.

I already owe you a few beers, but I'll be happy to owe you a few more
;-)

TIA.

-- 
Best regards,

Miguel A. Urech (El Escorial - Spain)
Using The Bat! v1.62i



 Current version is 1.61 | "Using TBTECH" information:
http://www.silverstones.com/thebat/TBUDLInfo.html


Re: [eng] Re: Question about Januk's print template

2003-03-08 Thread Januk Aggarwal
Hello Miguel,

On Saturday, March 8, 2003 at 12:47 GMT +0100, earthworms were
entertained when Miguel A. Urech [MAU] exposed:

MAU> However I have detected a few occasions where something strange
MAU> happens,

Can you please post the exact templates you are using to produce these
outputs?  Use cut and paste, so go into the QT to be copied, press
CTRL-A to select all, then CTRL-C to copy.  Then paste that into your
reply.  I don't really see why you should be experiencing the problem
you describe.

MAU> and I must admit I'm totally lost. Your macro is not easy to
MAU> follow and understand by RegExp beginners.

No, I don't imagine it is.  The structure is not that terrible, but it
looks complex.  And without comments, it might not be trivial to
extract the algorithm.

MAU> Here are the two cases:

MAU> | To:   [EMAIL PROTECTED]

MAU> | To: "Miguel A. Urech" <[EMAIL PROTECTED]>

MAU> Same thing here, the To: is again blank.

What is the output of a bare %OTOLIST on these messages?

-- 
Thanks for writing,
 Januk Aggarwal






 Current version is 1.61 | "Using TBTECH" information:
http://www.silverstones.com/thebat/TBUDLInfo.html


Re: [eng] Re: Question about Januk's print template

2003-03-08 Thread Miguel A. Urech
Hello Januk,

> Can you please post the exact templates you are using to produce these
> outputs?

,- [ My reply template ]
| %Cursor%QINCLUDE="SLANG"%-
| 
| - Original Message -
|From: %OFromName <%OFromAddr>
|Date: %ODateEn %OTimeLongEn  %IF:'%OTOLIST'<>'':'
|  To: %COMMENT="%OTOLIST; "%QINCLUDE="print_recipient"' %IF:'%OCCLIST'<>'':'
|  Cc: %COMMENT="%OCCLIST; "%QINCLUDE="print_recipient"'
| Subject: %OFULLSUBJ
| 
| %TEXT
`-
,- [ My print_recipient ]
| %COMMENT="9
| %COMMENT"%-
| %SETPATTREGEXP="(?s-m)^\s{9}(.*)\n$"%-
| %REGEXPMATCH="%QINCLUDE='print_recipient2'"%-
| %COMMENT=""%-
`-
,- [ My print_recipient2 ]
| %REM='
|   Recipient List reformating routine.
|   recipient2 = recursive engine QT
|   
|   Written by Januk Aggarwal
|   November 2002
| '%-
| %-
| %IF:'%-
| %SETPATTREGEXP=$(?i)^\d*\n(\"?(.*?)\"?\s*(\<.*?\>)?\s*[;,]\s*)$%-
| %REGEXPMATCH=$%COMMENT$'<>'':'%-
| %-
| %SETPATTREGEXP="\s{%-
| %-%-%SETPATTREGEXP=#^\d*#%-
| %-%-%REGEXPMATCH=#%COMMENT#}"%-
| %REGEXPMATCH=""%-
| %-
| %SETPATTREGEXP=$(?i)^\d*\n((\"?(.*?)\"?\s*(\<.*?\>)?)\s*[;,]\s*)?$%-
| %REGEXPBLINDMATCH=$%COMMENT$%-
| %SUBPATT=$2$
| %-
| %COMMENT=_%-
| %-%-%SETPATTREGEXP=$(?i)^(\d*\n)(\"?(.*?)\"?\s*(\<.*?\>)?\s*[;,]\s*)?(.*)$%-
| %-%-%REGEXPBLINDMATCH=$%COMMENT$%-
| %-%-%SUBPATT=$1$%-
| %-%-%SUBPATT=$5$_%-
| %-
| %QINCLUDE="print_recipient2"'%-
`-

MAU> | To:   [EMAIL PROTECTED]
MAU> | To: "Miguel A. Urech" <[EMAIL PROTECTED]>
> What is the output of a bare %OTOLIST on these messages?

If I use a template with To: %OTOLIST I get:

   To: [EMAIL PROTECTED]
and
   To: "Miguel A. Urech" <[EMAIL PROTECTED]>

respectively.

Januk, thank you so much for the trouble your are taking for trying to
help :-))

-- 
Best regards,

Miguel A. Urech (El Escorial - Spain)
Using The Bat! v1.62i



 Current version is 1.61 | "Using TBTECH" information:
http://www.silverstones.com/thebat/TBUDLInfo.html


Re: [eng] Re: Question about Januk's print template

2003-03-08 Thread Januk Aggarwal
Hello Miguel,

On Sunday, March 9, 2003 at 01:25 GMT +0100, a beagle known as Miguel
A. Urech [MAU] barked:

I don't see any problem with your templates, so there must be
something odd being passed to the print_recipient2 template.

For testing purposes, let's try a few things to figure out what's
happening:

1. Change the reply template so you remove the % symbol from in front
   of the %COMMENT macros and the %QINCLUDE macros.
 - This will show us what exactly is being sent to print_recipient

2. Reverse the change above and change the last line in the
   print_recipient template from %COMMENT="" to %COMMENT
 - This will let us see how far the print_recipient2 template got
   before failing.

3. Reverse the change above and *add* a line to the beginning of the
   print_recipient2 template. Put the macro %COMMENT="" as the very
   first line of print_recipient2.
 - This will tell us if print_recipient2 is being called, and what
   text is being sent to be processed.

4. Reverse the change above and change print_recipient2 to the
   following.
 - This template is slightly modified to ignore some more
   white space.  The modification shouldn't hurt the performance
   of the template in normal cases.

=[Begin print_recipient2]=
%REM='
  Recipient List reformating routine.
  recipient2 = recursive engine QT

  Written by Januk Aggarwal
  November 2002
'%-
%-
%IF:'%-
%SETPATTREGEXP=$(?i)^\d*\n\s*?(\"?(.*?)\"?\s*(\<.*?\>)?\s*[;,]\s*)$%-
%REGEXPMATCH=$%COMMENT$'<>'':'%-
%-
%SETPATTREGEXP="\s{%-
%-%-%SETPATTREGEXP=#^\d*#%-
%-%-%REGEXPMATCH=#%COMMENT#}"%-
%REGEXPMATCH=""%-
%-
%SETPATTREGEXP=$(?i)^\d*\n\s*?((\"?(.*?)\"?\s*(\<.*?\>)?)\s*[;,]\s*)?$%-
%REGEXPBLINDMATCH=$%COMMENT$%-
%SUBPATT=$2$
%-
%COMMENT=_%-
%-%-%SETPATTREGEXP=$(?i)^(\d*\n)\s*?(\"?(.*?)\"?\s*(\<.*?\>)?\s*[;,]\s*)?(.*)$%-
%-%-%REGEXPBLINDMATCH=$%COMMENT$%-
%-%-%SUBPATT=$1$%-
%-%-%SUBPATT=$5$_%-
%-
%QINCLUDE="print_recipient2"'%-
=[ End  print_recipient2]=

MAU> If I use a template with To: %OTOLIST I get:

MAU>To: [EMAIL PROTECTED]
MAU> and
MAU>To: "Miguel A. Urech" <[EMAIL PROTECTED]>

That seems ok.  Test number 1 above should give me the last bit of
confidence to rule this out as the source of the problem.

-- 
Thanks for writing,
 Januk Aggarwal




 Current version is 1.61 | "Using TBTECH" information:
http://www.silverstones.com/thebat/TBUDLInfo.html


Re: [eng] Re: Question about Januk's print template

2003-03-09 Thread Miguel A. Urech
Hello Januk,

> 1. Change the reply template so you remove the % symbol from in front
>of the %COMMENT macros and the %QINCLUDE macros.
>  - This will show us what exactly is being sent to print_recipient

 To: COMMENT="[EMAIL PROTECTED]; "QINCLUDE="print_recipient"
 To: COMMENT=""Miguel A. Urech" <[EMAIL PROTECTED]>; "QINCLUDE="print_recipient"

> 2. Reverse the change above and change the last line in the
>print_recipient template from %COMMENT="" to %COMMENT
>  - This will let us see how far the print_recipient2 template got
>before failing.

 To:
 To:

> 3. Reverse the change above and *add* a line to the beginning of the
>print_recipient2 template. Put the macro %COMMENT="" as the very
>first line of print_recipient2.
>  - This will tell us if print_recipient2 is being called, and what
>text is being sent to be processed.

 To:
 To:

> 4. Reverse the change above and change print_recipient2 to the
>following.
>  - This template is slightly modified to ignore some more
>white space.  The modification shouldn't hurt the performance
>of the template in normal cases.

 To:
 To:

> That seems ok.  Test number 1 above should give me the last bit of
> confidence to rule this out as the source of the problem.

Hope I haven't made any mistake when doing the changes.

Thanks a lot :)

-- 
Best regards,

Miguel A. Urech (El Escorial - Spain)
Using The Bat! v1.62i



 Current version is 1.61 | "Using TBTECH" information:
http://www.silverstones.com/thebat/TBUDLInfo.html


Re: [eng] Re: Question about Januk's print template

2003-03-10 Thread Januk Aggarwal
Hello Miguel,

On Sunday, March 9, 2003 at 11:31 GMT +0100, an infinite number of
monkeys posting as Miguel A. Urech [MAU] typed:

Sorry I somehow missed your reply.

>> 1. Change the reply template so you remove the % symbol from in front
>>of the %COMMENT macros and the %QINCLUDE macros.
>>  - This will show us what exactly is being sent to print_recipient

MAU>  To: COMMENT="[EMAIL PROTECTED]; "QINCLUDE="print_recipient"
MAU>  To: COMMENT=""Miguel A. Urech" <[EMAIL PROTECTED]>; "QINCLUDE="print_recipient"

Ok, so this makes me confident that the problem is not in your main
template.

>> 2. Reverse the change above and change the last line in the
>>print_recipient template from %COMMENT="" to %COMMENT
>>  - This will let us see how far the print_recipient2 template got
>>before failing.

MAU>  To:
MAU>  To:

This one is less clear.  I don't really understand why it should be
blank.  Can you please try the following two modifications (one at a
time would be good) to your print_recipient template:

,- [ My print_recipient ]
| %COMMENT="9
| %COMMENT"%-
| %COMMENT
| %SETPATTREGEXP="(?s-m)^\s{9}(.*)\n$"%-
| %REGEXPMATCH="%QINCLUDE='print_recipient2'"%-
| %COMMENT=""%-
`-

,- [ My print_recipient ]
| %COMMENT="9
| %COMMENT"%-
| SETPATTREGEXP="(?s-m)^\s{9}(.*)\n$"%-
| REGEXPMATCH="%QINCLUDE='print_recipient2'"%-
| %COMMENT=""%-
`-

>> 3. Reverse the change above and *add* a line to the beginning of the
>>print_recipient2 template. Put the macro %COMMENT="" as the very
>>first line of print_recipient2.
>>  - This will tell us if print_recipient2 is being called, and what
>>text is being sent to be processed.

MAU>  To:
MAU>  To:

This is just mystifying, however, in light of Nick's problem &
solution, I don't know what to think.

>> 4. Reverse the change above and change print_recipient2 to the
>>following.
>>  - This template is slightly modified to ignore some more
>>white space.  The modification shouldn't hurt the performance
>>of the template in normal cases.

MAU>  To:
MAU>  To:

Hmm, and you said that this is the same output as when you run the
version in ...  The plot
thickens.

Sorry I'm making you do all these changes, but I can't replicate the
problem over here to test my brainstorming ideas.

One thing we should consider: if this is only happening on two
specific messages, _but_NO_others_, we may be beating a dead horse here.
It would be nice to understand why the templates failed, but we should
think about how much time is being spent versus how widespread the
problem is.

-- 
Thanks for writing,
 Januk Aggarwal





 Current version is 1.61 | "Using TBTECH" information:
http://www.silverstones.com/thebat/TBUDLInfo.html


Re: [eng] Re: Question about Januk's print template

2003-03-11 Thread Miguel A. Urech
Hello Januk,

> On Sunday, March 9, 2003 at 11:31 GMT +0100, an infinite number of
> monkeys posting as Miguel A. Urech [MAU] typed:

What do you mean an infinite number of monkeys! Just one, but very
stupid.

Yes, I must apologize because I'm stupid, I'm stupid, I'm stupid, I'm
stupid, I'm stupid, I'm stupid, I'm stupid, I'm stupid, I'm stupid,
I'm stupid, I'm stupid, I'm stupid, I'm stupid, I'm stupid, I'm
stupid, I'm stupid, I'm stupid, I'm stupid, I'm stupid, I'm stupid,
I'm stupid, I'm stupid, I'm stupid, I'm stupid, I'm stupid, I'm
stupid, I'm stupid, and _I_ _am_ s-t-u-p-i-d! :-(((

Your QT's are perfect. I created my reply template and entered it in
each and every account, but I created your QT's just in my main
account and _forgot_ to share them   So, the two "failures" I
noticed were due to the fact the *only* my template was being used but
not your QTs.

I apologize again. I owe you an infinite number of beers.

-- 
Best regards,

Miguel A. Urech (El Escorial - Spain)
Using The Bat! v1.62i



 Current version is 1.61 | "Using TBTECH" information:
http://www.silverstones.com/thebat/TBUDLInfo.html


Re: [eng] Re: Question about Januk's print template

2003-03-12 Thread Januk Aggarwal
Hello Miguel,

On Tuesday, March 11, 2003 at 20:56 GMT +0100, aliens probed Miguel A.
Urech [MAU] and found:

MAU> What do you mean an infinite number of monkeys! Just one, but very
MAU> stupid.

In case you haven't noticed (most probably don't), I put the "cookie"
type part of my message in the attribution line.  So like any random
cookie system, it tends to insert meaning where there should be none.
:-)

MAU> Yes, I must apologize

MAU> I created your QT's just in my main account and _forgot_ to share
MAU> them 

Ah, a very insidious problem.  Well at least we have something new to
keep in mind when debugging templates.

MAU> I apologize again.

No worries.  That's why we have these lists.

MAU> I owe you an infinite number of beers.

I would have said that would take a long time to drink, but I'm
Canadian... 

-- 
Thanks for writing,
 Januk Aggarwal




 Current version is 1.61 | "Using TBTECH" information:
http://www.silverstones.com/thebat/TBUDLInfo.html


Re: [eng] Re: Question about Januk's print template

2003-03-12 Thread Miguel A. Urech
Hello Januk,

> In case you haven't noticed (most probably don't), I put the "cookie"
> type part of my message in the attribution line.  So like any random
> cookie system, it tends to insert meaning where there should be none.
> :-)

Yes, of course I had noticed :)

> Ah, a very insidious problem. Well at least we have something new to
> keep in mind when debugging templates.

I will certainly not forget next time. At least next time :)

MAU>> I owe you an infinite number of beers.
> 
> I would have said that would take a long time to drink, but I'm
> Canadian... 

Oh dear! =:-O  I offered that because I though you were an Ozzie ;-)


-- 
Best regards,

Miguel A. Urech (El Escorial - Spain)
Using The Bat! v1.62i



 Current version is 1.61 | "Using TBTECH" information:
http://www.silverstones.com/thebat/TBUDLInfo.html