* [sup-talk] sources.yaml labels
@ 2009-09-06 0:19 Ben Walton
2009-09-06 13:22 ` William Morgan
0 siblings, 1 reply; 8+ messages in thread
From: Ben Walton @ 2009-09-06 0:19 UTC (permalink / raw)
Hi All,
After still requiring modifications to the LabelManager to manage my
xapian conversion, I'm wondering if I've done something wrong in my
sources.yaml (most of which was put together by hand instead of via
sup-add). What format should a labels definition be using? On of my
sources looks like:
--snip--
- !masanjin.net,2006-10-01/Redwood/Maildir
uri: maildir:///u/bwalton/Maildir/.systemtap/
cur_offset: 12264068440005086
usual: true
archived: false
id: 6
labels:
- systemtap
mtimes:
cur: 2008-10-23 13:22:54 -04:00
new: 2008-11-11 07:34:04 -05:00
--snip--
Should the '- systemtap' be '- :systemtap'?
Thanks
-Ben
--
Ben Walton
Systems Programmer - CHASS
University of Toronto
C:416.407.5610 | W:416.978.4302
GPG Key Id: 8E89F6D2; Key Server: pgp.mit.edu
Contact me to arrange for a CAcert assurance meeting.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
URL: <http://rubyforge.org/pipermail/sup-talk/attachments/20090905/7dc9994f/attachment.bin>
^ permalink raw reply [flat|nested] 8+ messages in thread
* [sup-talk] sources.yaml labels
2009-09-06 0:19 [sup-talk] sources.yaml labels Ben Walton
@ 2009-09-06 13:22 ` William Morgan
2009-09-06 13:47 ` Ben Walton
2009-09-06 14:07 ` Ben Walton
0 siblings, 2 replies; 8+ messages in thread
From: William Morgan @ 2009-09-06 13:22 UTC (permalink / raw)
Reformatted excerpts from Ben Walton's message of 2009-09-05:
> Should the '- systemtap' be '- :systemtap'?
The former is "correct". But if you put in the latter, it should be
converted automatically, and written out as the former when you exit
Sup.
I'm a little disturbed that you're still seeing problems with this. Can
you confirm that SerializeLabelsNicely#after_unmarshal! (source.rb circa
line 167) is being run in your sources after they're loaded from
sources.yaml? That should ensure that you end up with a Set of symbols
when Sup's running, regardless of what's in the file.
The other source of bad labels is the serialized version of the messages
stored by Xapian, if you use Xapian. But if you've regenerated your
Xapian index recently, this shouldn't be a problem...
It strikes me now that the other possible source of non-symbol labels is
a hook like before-add. Are you using that to call Message#add_label
with a string argument, by any chance?
If none of the above, can you post the latest version of the exceptions
you're seeing?
--
William <wmorgan-sup at masanjin.net>
^ permalink raw reply [flat|nested] 8+ messages in thread
* [sup-talk] sources.yaml labels
2009-09-06 13:22 ` William Morgan
@ 2009-09-06 13:47 ` Ben Walton
2009-09-06 14:16 ` Ingmar Vanhassel
2009-09-06 14:07 ` Ben Walton
1 sibling, 1 reply; 8+ messages in thread
From: Ben Walton @ 2009-09-06 13:47 UTC (permalink / raw)
Excerpts from William Morgan's message of Sun Sep 06 09:22:21 -0400 2009:
> The former is "correct". But if you put in the latter, it should be
> converted automatically, and written out as the former when you exit
> Sup.
Ok, so my sources.yaml is 'good.'
> I'm a little disturbed that you're still seeing problems with this. Can
> you confirm that SerializeLabelsNicely#after_unmarshal! (source.rb circa
> line 167) is being run in your sources after they're loaded from
> sources.yaml? That should ensure that you end up with a Set of symbols
> when Sup's running, regardless of what's in the file.
Yes, I added a debug in that method and saw a message for each source.
> The other source of bad labels is the serialized version of the messages
> stored by Xapian, if you use Xapian. But if you've regenerated your
> Xapian index recently, this shouldn't be a problem...
I generated this about 2 days ago with a current (at the time) head of
next.
> It strikes me now that the other possible source of non-symbol labels is
> a hook like before-add. Are you using that to call Message#add_label
> with a string argument, by any chance?
I was doing this. I had a hook from my very early sup days still in
play. Since it was actually completely redundant (procmail filtering
and autolabelling via sources) now, I've simply removed it.
> If none of the above, can you post the latest version of the exceptions
> you're seeing?
I still can't load sup without coercing strings to symbols in the <<
method though. The exception log is attached (from a clean startup).
Thanks
-Ben
--
Ben Walton
Systems Programmer - CHASS
University of Toronto
C:416.407.5610 | W:416.978.4302
GPG Key Id: 8E89F6D2; Key Server: pgp.mit.edu
Contact me to arrange for a CAcert assurance meeting.
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: exception-log.txt
URL: <http://rubyforge.org/pipermail/sup-talk/attachments/20090906/8e8d8383/attachment.txt>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
URL: <http://rubyforge.org/pipermail/sup-talk/attachments/20090906/8e8d8383/attachment.bin>
^ permalink raw reply [flat|nested] 8+ messages in thread
* [sup-talk] sources.yaml labels
2009-09-06 13:47 ` Ben Walton
@ 2009-09-06 14:16 ` Ingmar Vanhassel
0 siblings, 0 replies; 8+ messages in thread
From: Ingmar Vanhassel @ 2009-09-06 14:16 UTC (permalink / raw)
Excerpts from Ben Walton's message of Sun Sep 06 15:47:06 +0200 2009:
> I still can't load sup without coercing strings to symbols in the <<
> method though. The exception log is attached (from a clean startup).
That looks like you're using labels as strings, or at least not as
symbols, in one of your hooks.
--
Exherbo KDE, X.org maintainer
^ permalink raw reply [flat|nested] 8+ messages in thread
* [sup-talk] sources.yaml labels
2009-09-06 13:22 ` William Morgan
2009-09-06 13:47 ` Ben Walton
@ 2009-09-06 14:07 ` Ben Walton
2009-09-06 15:06 ` William Morgan
1 sibling, 1 reply; 8+ messages in thread
From: Ben Walton @ 2009-09-06 14:07 UTC (permalink / raw)
Excerpts from William Morgan's message of Sun Sep 06 09:22:21 -0400 2009:
> The other source of bad labels is the serialized version of the messages
> stored by Xapian, if you use Xapian. But if you've regenerated your
> Xapian index recently, this shouldn't be a problem...
Since I had a bad hook and imported to Xapian with that hook live,
should I reimport my dumpfile after having the hook removed? I'm
thinking that I did the damage in a permanent fashion while doing the
import...
Thanks
-Ben
--
Ben Walton
Systems Programmer - CHASS
University of Toronto
C:416.407.5610 | W:416.978.4302
GPG Key Id: 8E89F6D2; Key Server: pgp.mit.edu
Contact me to arrange for a CAcert assurance meeting.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
URL: <http://rubyforge.org/pipermail/sup-talk/attachments/20090906/e357aff1/attachment.bin>
^ permalink raw reply [flat|nested] 8+ messages in thread
* [sup-talk] sources.yaml labels
2009-09-06 14:07 ` Ben Walton
@ 2009-09-06 15:06 ` William Morgan
2009-09-06 15:26 ` Ben Walton
2009-09-06 16:41 ` Ben Walton
0 siblings, 2 replies; 8+ messages in thread
From: William Morgan @ 2009-09-06 15:06 UTC (permalink / raw)
Reformatted excerpts from Ben Walton's message of 2009-09-06:
> Since I had a bad hook and imported to Xapian with that hook live,
> should I reimport my dumpfile after having the hook removed? I'm
> thinking that I did the damage in a permanent fashion while doing the
> import...
I suspect that would fix it. I've just pushed a change to to make
Message#add_label coerce arguments to symbols, anyways, so that writing
your hook wrong won't destroy your index for all eternity.
Sorry about all this. The silver lining is that it's a side effect of
lots of development activity. :)
--
William <wmorgan-sup at masanjin.net>
^ permalink raw reply [flat|nested] 8+ messages in thread
* [sup-talk] sources.yaml labels
2009-09-06 15:06 ` William Morgan
@ 2009-09-06 15:26 ` Ben Walton
2009-09-06 16:41 ` Ben Walton
1 sibling, 0 replies; 8+ messages in thread
From: Ben Walton @ 2009-09-06 15:26 UTC (permalink / raw)
Excerpts from William Morgan's message of Sun Sep 06 11:06:16 -0400 2009:
> I suspect that would fix it. I've just pushed a change to to make
> Message#add_label coerce arguments to symbols, anyways, so that writing
> your hook wrong won't destroy your index for all eternity.
Ok, that's cool. I was going to write the same change but with a
'raise ArgumentError' similar to the one in << to stick with the fail
fast approach you prefer.
> Sorry about all this. The silver lining is that it's a side effect of
> lots of development activity. :)
Hey, it's not a problem. I don't mind guinea pigging this stuff at
all. Sup has steadily improved since I've been using it, so I'm a
happy camper. [Plus, I'm running next, so I 'get what I get.']
Thanks
-Ben
--
Ben Walton
Systems Programmer - CHASS
University of Toronto
C:416.407.5610 | W:416.978.4302
GPG Key Id: 8E89F6D2; Key Server: pgp.mit.edu
Contact me to arrange for a CAcert assurance meeting.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
URL: <http://rubyforge.org/pipermail/sup-talk/attachments/20090906/26890640/attachment.bin>
^ permalink raw reply [flat|nested] 8+ messages in thread
* [sup-talk] sources.yaml labels
2009-09-06 15:06 ` William Morgan
2009-09-06 15:26 ` Ben Walton
@ 2009-09-06 16:41 ` Ben Walton
1 sibling, 0 replies; 8+ messages in thread
From: Ben Walton @ 2009-09-06 16:41 UTC (permalink / raw)
Excerpts from William Morgan's message of Sun Sep 06 11:06:16 -0400 2009:
> I suspect that would fix it. I've just pushed a change to to make
> Message#add_label coerce arguments to symbols, anyways, so that writing
> your hook wrong won't destroy your index for all eternity.
Verified. I've re-imported my dump file after removing my hook. The
import ran successfully with an unmodified sup.
I think this makes me a full-time xapian convert.
Thanks for all your effort on this William and Rich!
-Ben
--
Ben Walton
Systems Programmer - CHASS
University of Toronto
C:416.407.5610 | W:416.978.4302
GPG Key Id: 8E89F6D2; Key Server: pgp.mit.edu
Contact me to arrange for a CAcert assurance meeting.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
URL: <http://rubyforge.org/pipermail/sup-talk/attachments/20090906/6eddaa77/attachment.bin>
^ permalink raw reply [flat|nested] 8+ messages in thread
end of thread, other threads:[~2009-09-06 16:41 UTC | newest]
Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-09-06 0:19 [sup-talk] sources.yaml labels Ben Walton
2009-09-06 13:22 ` William Morgan
2009-09-06 13:47 ` Ben Walton
2009-09-06 14:16 ` Ingmar Vanhassel
2009-09-06 14:07 ` Ben Walton
2009-09-06 15:06 ` William Morgan
2009-09-06 15:26 ` Ben Walton
2009-09-06 16:41 ` Ben Walton
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox