Pidgin status history

June 29th, 2008

I've switched from PSI to Pidgin. Mostly because there were no Gentoo extras for 0.11, still no scripting support and no plugin support at all. Nevertheless vanilla Pidgin had the same issue as vanilla PSI - no status logging. Also I couldn't find any plugin which would do the work. Maybe I've missed something... but why don't people want to be able to see someone statuses from the past week? Why is it so hard to make such a simple functionality?

General installation instructions:
1. See the warning at the bottom of this page.
2a. Under Linux (or other unix-like systems running pidgin) to compile the plugin you need Pidgin/libpurple "header files". Usually they might be installed with a package manager (search for names like pidgin-dev, purple-dev).
2b. If that fails, you can grab Pidgin source and install it from sources.
3. Unpack and type 'make' inside.
3a. Should compilation fail, and you have headers - fix it. ;)
4. After the compilation simply copy file into ~/.purple/plugins/ and enable "Buddy Status History" in Pidgin plugin list.
5. If you've used 0.6 version before consider using Python clean-up script to cleanup small logs a bit.

0.8v Release notes:
- Fixed memory leak

0.7v Release notes:
- Fixes the problem the 0.6 had. With no open conversation status changes are logged now into previously created log file. If no such file exists - one is created.
- Windows .dll was compiled by fei_ferry, who also reported that it's working fine! Also he proposed a solution to the day-change-date-problem: "(...)it can be solved with "Message Timestamp Format" plugins, set the timestamp to always write date on logs, that's fine for me."

Possible problems:
Might have problem with date during day changes. Might not work with non-standard loggers (text logger and html logger should be fine). Trick is that is reopens last log so the loggers will write to it. Some other logger might want to do this in a different manner which will surely fail.

Source code:

Signature for source tarball (logstatus genuine advantage;d).
repository at github

Windows binary by fei_ferry:

System log patch
Fartash proposed a logstatus patch, which is supposed to log everything into a system log instead of a user log if a conversation is not opened. I haven't tested it as I like having statuses logged into a user log so it can be easily related to previous/future conversations and to the contact itself. Feel free to test it and use it if you like, and thanks to Fartash for contribution. :)

Historical entries follow

0.6v Release notes:
- Internal logger was not created with such ideas in mind... therefore if there's no buddy conversation open each status change is logged as a separate conversation (into a separate, new file). Still I guess it's better than nothing - I can use py scripts to merge such files into one.

Windows binary made by BigBrownChunx for 0.6v: pidgin-logstatus-0.6.dll.

Cleanup of multiple log files created by 0.6v
To cleanup log file mess made by logstatus an example Python script which might be used (grab it here). USE AT YOUR OWN RESPONSIBILITY. It's dumb simple and doesn't parse the data in files at all (it only moves it). By default (see the code) it won't remove anything just rename to *.removed (Then script like this will totally remove those files: find . -iname "*.removed" -type f -exec rm {} \;). I used this script recently after a long time of using the plugin; it removed 166562 small files leaving 17936 merged log files which shrinked size of directory from 751MB (ext4) to 129MB.

Various other. Try if anything else fails:
safety link to the pidgin-logstatus-0.7v.tar.bz2
safety link to the pidgin-logstatus-0.6.tar.bz2
safety link to the dll

Modified version which won't log statuses if the conversation is not open (not tested, but modification was simple; required compilation before use.)

THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION. This is especially important if you decide to use compiled versions. I haven't compiled it myself and I simply trust their authors that they haven't put anything weird inside.

Comment by Jericho Mathis

submitted on July 5th, 2008 at 05:11

How do you install this plugin into Pidgin? Pidgin's plugins come in a .DLL format.

Comment by Jericho Mathis

submitted on July 7th, 2008 at 01:25

Thank you!

Comment by Anon

submitted on July 26th, 2008 at 22:54

Thank you so much.

This really needs to be incorporated into Pidgin.

Comment by Onyx

submitted on September 4th, 2008 at 06:37

How do you install this dll?

Comment by Darryl Levi

submitted on October 25th, 2008 at 19:04

Hi, can you post up a precompiled .so file pls? my OS does not have a compiler....

Comment by bla

submitted on October 25th, 2008 at 21:34

Try this:
or this: depending on your architecture. CAN'T tell if it will work at all. ;) It links to the libraries I have compiled and optimized for my platform so I rather doubt... but you can try it.

Comment by Darryl Levi

submitted on October 26th, 2008 at 20:17

Hey i'm posting this here in case other people have the same problem i did.

anyway, lol, you won't believe this, but what I ended up doing was installing Wine and installing the win32 version of pidgin! Then I just used the dll you provided. SO easy! No compiling/building/terminal-work needed :D

Thanks Tomazs!

Comment by Emi

submitted on December 30th, 2008 at 08:26

That's exactly what i was looking for :) Thanks a lot!

Comment by Kevdog

submitted on January 20th, 2009 at 08:38

Hmm, I compiled with pidgin 2.5.4. Got the Copied to /usr/local/lib/pidgin (since I compiled pidgin) and the plugin is not showing on the plugin list when I start pidgin. What is the name of the plugin as displayed on the list?

Comment by bla

submitted on January 20th, 2009 at 10:20

Buddy Status history. (PS. You can keep it in ~/.purple/plugins/

Comment by Kevdog

submitted on January 20th, 2009 at 15:24

Ok, I did have plugin available. You might want to add the name of the plugin presented within the plugin list to your instructions. I kept looking for a plugin called logstatus which of course I couldn't find.

Comment by Fahrstuhl

submitted on April 13th, 2009 at 16:32

Woo, thank you very much!

Comment by ionel

submitted on April 13th, 2009 at 17:42

Kudos! Good stuff.

Comment by Jarshvor

submitted on June 27th, 2009 at 08:11

great plugin,
im finding the zillion small (1KB) files a bit annoying however since they waste a significant amount of space,

is there any way i can use the script intended to fix this under windows? if so, do I need a python interpreter or such?

Comment by bla

submitted on June 27th, 2009 at 15:04

Copying there and back again can significantly descrease size they take, also when you have an python interpreter you can use this script. I guess it should work without modyfications; it just has to be given correct directory.

Comment by Jarshvor

submitted on June 27th, 2009 at 18:04

I've Installed Python 2.6, and im trying to access the script through the windows command prompt. I've moved the script to my account folder inside the .purple\logs folder, and i change to that directory inside the command line and attempt the ./clean-up (and clean-up, .\clean-up, /clean-up etc) command, however i still get that its not a recognized command.


Comment by bla

submitted on June 28th, 2009 at 00:26

Hey, I really don't know how this windows-thing is working. But you can try calling [path to python executable] [script] - so passing the script as an argument to the intepreter. That's what #!/usr/bin/python is supposed to do on unix systems.

Comment by KovuTheHusky

submitted on August 27th, 2009 at 01:02

An option for not logging status changes when a conversion with that person is not open would be nice. I'm not interested in people I'm not talking to. If that is added at some point, send me a mail.


Comment by Zhemarcus

submitted on November 4th, 2009 at 12:39


First, thank you for this plugin, then i am under windows, when conact changes his status, it's not logged when status revert back.

Would you fix this please, if possible.


Comment by Matt

submitted on January 3rd, 2010 at 19:35

Wonderful. Thank you.

In case this is useful to anyone, I compiled this for Pidgin on Debian Lenny from the lenny-backports repository. Prior to running make, make sure to "apt-get install -t lenny-backports pidgin-dev libpurple-dev". If you install the regular lenny versions of these packages instead of the backports, it will say something like "/usr/bin/ld: cannot find -lpurple".

Comment by Voldemort

submitted on January 15th, 2010 at 17:56

Awesome work man!!!

Comment by G-Lo

submitted on January 17th, 2010 at 20:53

Any update planned?

Comment by bla

submitted on January 17th, 2010 at 22:18

All the time. But I'm kind of discouraged by the fact that pidgin needs major rewrite of it's logging mechanisms to make this work nicely.

Comment by bla

submitted on January 17th, 2010 at 22:43

Update: Ok, I've got idea...

Comment by bla

submitted on January 18th, 2010 at 03:53

Ha. Updated. :P

Comment by Mono

submitted on February 17th, 2010 at 12:03

Hey, i very much like and appreciate your plugin, buuuut ;)
it seems that only time is logged but not the date which is quite confusing when everything is written into the last log - which could be weeks old.

can you somehow influence this behavior? i like that old one-file-per-user idea so dates would be extra nice.

i see i have problems with oldlogger though, it would not work as expected. maybe i will reinstall pidgin these days...

btw, i'm using windows and therefore would also like dlls.

please don't feel nerved, i am in fact kind of grateful because you are engaged in making pidgins logging system BETTER. this is great! so please keep on the good work (if you like...)

Comment by Mono

submitted on February 17th, 2010 at 17:15

okay, i didn't read the full article. sry

Comment by Tobi

submitted on March 10th, 2010 at 14:28


nice Plugin ;)
There's one thing I don't like about its current behaviour: When there's any log for a contact, no matter how old it is, the new status events are just appended to it (as Mono already pointed out). The result is that they are logged with the wrong date (using the standard text logger).

What about the following patch? It changes the behaviour of try_to_append() so that a new log will be started when the last one is older than 24 hours. This is not a perfect solution, but you can recognize the actual date of the event that way.

diff -r pidgin-logstatus-0.8v/logstatus.c pidgin-logstatus-0.8v-mto/logstatus.c
> time_t now = time(NULL);
> if (difftime(now, log->time) > 86400) {
> if (DEBUG)
> printf(INTRO "Last existing log is older than 24 hours\n");
> goto cleanup;
> }
< purple_log_write(log, PURPLE_MESSAGE_SYSTEM, alias, time(NULL), message);
> purple_log_write(log, PURPLE_MESSAGE_SYSTEM, alias, now, message);

Comment by bla

submitted on March 10th, 2010 at 18:08

1) timestamp plugin is nice workaround
2) pidgin/purple itself generates timestamp in log_get_timestamp (log.c) like this:

show_date = (log->type == PURPLE_LOG_SYSTEM) || (time(NULL) > when + 20*60);

*** Then it sends signal log-timestamp which I guess we can grab somehow and return our own date string there.

timestamp should be generated like this:
struct tm tm = *(localtime(&when));
return g_strdup(purple_date_format_long(&tm));

*** Connecting this signal:
purple_signal_connect(purple_log_get_handle(), "log-timestamp",
plugin, PURPLE_CALLBACK(log_timestamp_cb), NULL);

*** Handling:

static char *log_timestamp_cb(PurpleLog *log, time_t t, gboolean show_date, gpointer data)
// if show_date is 1 always show date (late message) otherwise use some our data (global variable?) to determine if we need it.
return "free-able timestamp";

I guess I can code it but I doubt I can do this this weekend. ;) Nevertheless your patch also seems to be ok, but I'd prefer to have date included in every message (eases grepping) than to create so many files. Hm. ;d

Comment by Elenaluz

submitted on March 13th, 2010 at 06:00

This is exactly what I need. Now if only they'd make one for Trillian. -_-

Comment by Kevman

submitted on April 4th, 2010 at 05:59

Hey, this is great plug in!
It's very useful for me to surprise my gf.
Thanks for your effort.

BTW, I'm not familiar with programming, so I have no idea if it's possible.

While I'm using google talk, pidin shows which client software users are using in their status - like gmail, gtalk, or even phone. Not sure it's from XMPP protocol, but is it possible to log this information, too?

Comment by bla

submitted on April 4th, 2010 at 16:22

It's for sure possible. I guess we'd have to catch login event, grab this data and add another log line... Logged in with. Possibly filtering out empty data. Doable but still requires time which is our main problem. ;-)

Comment by Ricardo

submitted on June 25th, 2010 at 11:59

Where is the logs file?I'm looking for the logs,I can't see the logs anywhere?

Comment by bla

submitted on June 25th, 2010 at 14:43

Status logs goes into standard pidgin log files. Under linux this is ~/.purple/logs, under windows I assume it's User directory (Whereever it is located).

You can browse this log with pidgin interface also.

Comment by fartash

submitted on August 27th, 2010 at 11:23

It's not good to have all the status logged into the previous log when we don't have an open conversation. Also you're doing something just like extending the purple system log.
I've changed the code to log everything into system log and for opened conversations story is the same as before. Find the patch below.

(PATCH MOVED INTO FILE; Link accessible in the article)

Comment by Ch333

submitted on April 20th, 2012 at 19:12

Is the window file still available? I get a 404 when I try the link.

Comment by Ch333

submitted on April 20th, 2012 at 19:18

The link to the windows .dll gives me a 404. Anyone have a link to this file so I can download it please?

Comment by Ch333

submitted on April 20th, 2012 at 19:23

Found it - change the root to "" and voila.

Comment by bla

submitted on April 21st, 2012 at 09:29

Blog was migrated recently and still external links are sometimes invalid. I'll try fixing it at least for this article.

Comment by JJ

submitted on May 12th, 2014 at 04:21

I couldnt get this to work in windows. Placed the dll in C:\ProgramFiles\Pidgin\Plugins.
Cannot find this under tools-->plugins. Looked for Buddy Status History, Pidgin Status History, Status History etc..
Whats the trick? Please help.

Add a comment [+] Hide the comment form [-]

I'm a bot, please ignore this comment.

I'm not a bot. Tick this box.

This is a mail of my good friend who loves rubbish email. Send him some if you want to land on my not-so-welcome lists: John Sparrow john(at)