After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 345304 - gossip support
gossip support
Status: RESOLVED WONTFIX
Product: beagle
Classification: Other
Component: General
unspecified
Other Linux
: Normal enhancement
: ---
Assigned To: Beagle Bugs
Beagle Bugs
gnome[unmaintained]
Depends on:
Blocks:
 
 
Reported: 2006-06-19 11:40 UTC by Johannes Berg
Modified: 2018-07-03 09:54 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
patch adding gossip IM support (13.09 KB, patch)
2006-06-19 11:41 UTC, Johannes Berg
none Details | Review
Gossip Backend (14.09 KB, patch)
2006-11-13 08:29 UTC, Kevin Kubasik
needs-work Details | Review

Description Johannes Berg 2006-06-19 11:40:47 UTC
I thought supporting gossip would be a good thing and made a preliminary patch. It doesn't load the contacts yet but it can actually index and find things, and display them in the log viewer (though gossip's log viewer is much much better). The log viewer doesn't seem to understand the HTML either...

I'll attach the patch.
Comment 1 Johannes Berg 2006-06-19 11:41:54 UTC
Created attachment 67620 [details] [review]
patch adding gossip IM support
Comment 2 Kevin Kubasik 2006-06-19 15:51:17 UTC
its a nice start near as I can tell. (But again, I've never used Gossip, so I can't say if the parsing is being done completely correct). 
Just a note:
You directly access some hit properties like this

hit ["fixme:speakingto_alias"]

its generally safer and better to use

hit.GetFirstProperty ("fixme:speakingto_alias")
Comment 3 Debajyoti Bera 2006-06-19 16:45:43 UTC
Just adding to what Kevin suggested.
If you are sure that there is and should be _only_one_ property-value with the key "fixme:speakingto_alias" and its an error otherwise, then use hit["fixme:speakingto_alias"]. Use the method GetFirstProperty() in other cases. GetFirstProperty is not designed to access single-valued properties. 
Comment 4 Johannes Berg 2006-06-19 17:05:59 UTC
Hm, ok. So far I had mostly copied from Gaim and/or Kopete :)

I failed to mention that I put this here for discussion and am hoping someone else picks it up as I won't have time to work on it in the next 2 weeks and possibly more.
Comment 5 Debajyoti Bera 2006-06-19 17:09:29 UTC
I'd suggest you post a message to the mailing list. I doubt any of the developers and h4x3rz use "gossip" to actively review/fix/text the backend.
Comment 6 Joe Shaw 2006-06-19 17:11:23 UTC
Does Gossip store its logs in one large file per user?  If so, additional work will be needed so that the entire file isn't parsed and reparsed each time.

Johannes, you have a bunch of FIXMEs in the GossipLog constructor and some hardcoded values.  Are those easy to fix?  What information do you need to complete those?

Other than this and what Bera suggested, it looks good!
Comment 7 Johannes Berg 2006-06-19 17:20:58 UTC
No, gossip stores below
~/.gnome2/Gossip/logs/

for each account a directory:
~/.gnome2/Gossip/logs/johannes@sipsolutions.net/

in which you find:
contacts.ini - containing config and nicknames (needs to be parsed), the format is:
[Self]
Name=Johannes
[Contacts]
xxxx@icq.sipsolutions.net=Xxx Yyy
...repeat...

and a directory for each user:
~/.gnome2/Gossip/logs/johannes@sipsolutions.net/xxxxx%25hotmail.com%40msn.sipsolutions.net/

in which you find a log file per day:
20041015.log
but not all days must exist, if you haven't talked to that person that day.

Now, gossip itself separates discussions based on the elapsed time between utterances, which we should do as well.

As for the hardcoded values, I wasn't quite sure what to put there and didn't implement parsing of any nickname stuff and thought that'd be needed.
Comment 8 Johannes Berg 2006-06-19 17:22:48 UTC
Uh note that in my code there's some "config.ini" value, that should be "contacts.ini".
Comment 9 Johannes Berg 2006-06-19 17:38:03 UTC
And for the
// FIXME: This is not safe for all kinds of file/screennames
comment, I have no idea :)
I copied it from Kopete, I think it probably ought to be fine though it'll be url-encoded in some cases.

But if I use the actual hard name (777@icq-gateway.my.jabber) will some other code look it up in the contacts list or do I need to do that myself?
Comment 10 Joe Shaw 2006-07-05 20:32:14 UTC
Adding Martyn Russell to the CC; he's the Gossip maintainer and expressed some interest in a Gossip backend at GUADEC.
Comment 11 Martyn Russell 2006-07-06 15:12:32 UTC
Thanks Joe.

First let me say, this rocks! I have been meaning to get some Beagle support for Gossip for a while, and I only knew about this after Joe pointed it out at GUADEC. So thanks Johannes, great start!

I have mentioned this recently on the gossip-dev list, but we intend to add support for conversation breaks in the logging at some point. This will probably be some sort of short xml attribute or element. This should make it easier to show chats in "conversations".

Keep up the good work, and thanks again for this.
Comment 12 Johannes Berg 2006-07-06 15:17:01 UTC
Martyn,

maybe you could take a look through the discussion here and note what should be done. Or maybe a small chat with you and a person from beagle who knows how the nickname handling works... I wasn't able to figure out yet what I should do with nicknames and what the list is used for etc.

I'm 'johill' on various IRC networks (gimpnet,freenode,oftc) if you want to ping me on IRC.
Comment 13 Kevin Kubasik 2006-08-07 18:31:24 UTC
Does anyone have the status on this patch?
Comment 14 Martyn Russell 2006-08-07 19:37:12 UTC
Sorry, I think this is waiting on me.

Johannes: Ok, yea the nicknames which are in ~/.gnome2/Gossip/logs/<account id>/contacts.ini are basically the last known nick name of the contact. This is saved so we can use the nickname in the logs when we are offline.

There are two sections: [Contacts] for everyone else, and [Self] for the name you are using for yourself with <account id>.

In gossip, we then just replace the ID (in "to" or "from") with the name from contacts.ini.  The nickname in the .log file is a backup and is the nickname that was used at the time of writing the log (which may not be up to date).

I hope this answers your questions. You can find me in #imendio, #gnome-hackers, #gtk+ on gimpnet or #telepathy on freenode (as martyn).
Comment 15 Johannes Berg 2006-08-18 12:04:07 UTC
Martyn, thanks for your comments and sorry that I took such a long time to reply.

Unfortunately, at this time I'm unable to work on this patch at all, probably until December or so. I'd appreciate if someone else would pick it up, but if not I may be able to do it myself sometime toward the end of the year.
Comment 16 Enver ALTIN 2006-09-14 08:36:12 UTC
I have some spare time and I think I can work on this, if nobody is working on this yet.
Comment 17 Martyn Russell 2006-09-14 08:41:11 UTC
Yes please!
Comment 18 Johannes Berg 2006-09-14 09:17:32 UTC
Enver, go ahead, I'm not working on this at the moment.
Comment 19 Joe Shaw 2006-09-14 17:56:02 UTC
You should feel free to completely refactor the IM log code as necessary in Beagle; it's a big mess right now.
Comment 20 Enver ALTIN 2006-09-15 06:45:29 UTC
(In reply to comment #19)
> You should feel free to completely refactor the IM log code as necessary in
> Beagle; it's a big mess right now.

I'll consider this Joe, thanks a lot.
Comment 21 Kevin Kubasik 2006-10-05 02:04:53 UTC
Any word?
Comment 22 Enver ALTIN 2006-10-05 08:08:08 UTC
(In reply to comment #21)
> Any word?

Nothing yet, I'm sorry :/
Comment 23 Kevin Kubasik 2006-11-13 08:29:43 UTC
Created attachment 76463 [details] [review]
Gossip Backend

Damn, I had 'Gossip backend' on my todo list, and didn't realize that I must have meant update this one....

Oh well, heres some majorly replicated code.
Comment 24 Kevin Kubasik 2007-01-04 06:51:07 UTC
Any thoughts on this one? I backed off since someone else had already started, but I can keep working if theres no one else...
Comment 25 André Klapper 2018-07-03 09:54:28 UTC
Beagle is not under active development anymore and had its last code changes in early 2011. Its codebase has been archived (see bug 796735):
https://gitlab.gnome.org/Archive/beagle/commits/master

"tracker" is an available alternative.

Closing this report as WONTFIX as part of Bugzilla Housekeeping to reflect
reality. Please feel free to reopen this ticket (or rather transfer the project
to GNOME Gitlab, as GNOME Bugzilla is deprecated) if anyone takes the
responsibility for active development again.