Friday, April 6, 2007

Lost a Drive

My little 1U, Sherman, has lost it's main drive this evening. I won't be able to access the machine until midnight tonight. I'm starting to think about all of the directories /not/ on automated backups. My jabberd 1.4.4 spool directory is one of them. This could really, really suck. You won't be able to check out any of my SVN repos tonight anyway. I hope the drive will mount as a secondary long enough for me to pull most stuff off of it. I'm in for a long night.

Thursday, April 5, 2007

SleekXMPP 0.1 Plans

See my previous post if you don't know what SleekXMPP is.

Well, before my first release, there are a handful of things to do:

1. I'm really not happy with how stream:features works in my lib; it's messy.
2. Possibly add post-send handlers.
3. Write a data-forms (XEP-0004) plugin.
4. Stabilize the API so that it doesn't keep changing on developers.

I should be able to take care of that this weekend so that I can start on the bot framework. The bot framework will be all about configuration. You'll be able to register chat commands, command help, command context. And then, of course, comes the events, and MUC support. After all of that, I will begin developing a bot plugin system (separate from the protocol plugins) for drop in and configurable Edgar, Thinkbot, RSS feed readers, voting bots, etc. People will be able to drop in as many plugins as they want and configure them how they want. Ideally this will be doable by non-programmers.

Several people have asked me about licensing of SleekXMPP. To answer the question, 0.1 will likely be GPL. I'm sorry, but that's the way it is as I don't have enough time to research licenses between now and then. 0.2 will likely be a much less restrictive license, and hopefully everyone is happy with it. Current candidates are MIT, BSD, and Apache.

In other news, I applied for XSF membership today. I'll know on the 15th (Tax Day) whether I'm in or not.

Tuesday, April 3, 2007

SleekXMPP

As a self-taught, professional programmer, I have a few habits that many more formally educated peers of mine do not. One of those habits is to apply knowledge I've learned to "pet projects." Every time I learn a new technique or come up with a new idea, I tend to apply them to one of my pet projects, often requiring a full rewrite. Naturally, I see no end in sight as far as being able to improve upon my skills, however, this time I think that I've arrived somewhere.

SleekXMPP is an XMPP library for Python. Why have I written my own when there are at least 2 others out there? Well, the first write was for a company that I worked for, and subsequent rewrites have simply been out of obsession with Jabber/XMPP. Who knows, maybe I can even use my knowledge and libraries to make money. I have purposely avoided even looking at the code of other Python XMPP implementations in order to maintain solid copyright.

The idea is that the Jabber/XMPP community could use this to test new XEPs (XMPP Extension Protocol) very, very quickly and easily. In fact, my goal is to implement every draft XEP in existence as plugins. This ensures that I write my code in a very extensible fashion, making it easy to extend the class in any way. I am writing the core RFC's as part of the main classes, and XEPs as plugins.

Beyond protocol testing, what am I trying to accomplish? Once I hit version 0.1 (not quite there yet), I will begin working on a bot framework. The bot framework will use the SleekXMPP lib, and in it's own right, be extensible. Bot behaviors will be configurable and extended with plugins like Thinkbot, Edgar, Mapbot, etc. Kevin Smith, of Psi fame, has promised to write a plugin for eggdrop scripts. Ideally, this framework will enable people who are not programmers to customize and run a bot. Maybe there'll be some optional GUI plugins to boot. In a related train of thought, why have I not seen more bots take advantage of data forms?

Here is some output from what I've been working on so far:

fritzy@peabody:~/dev/sleekxmpp$ ./example.py -d -c myconfig.xml
INFO Loading config file: myconfig.xml
INFO Logging in as [address-removed]@gmail.com/sleekxmpp_
DEBUG Loaded Plugin (XEP-0030) Service Discovery
DEBUG Loaded Plugin (XEP-0076) Malicious Stanzas
DEBUG Loaded Plugin (XEP-0078) Non-SASL Authentication
DEBUG Loaded Plugin (XEP-0092) Software Version
DEBUG Connecting via client method to talk.google.com:5222
DEBUG Starting TLS
DEBUG Starting SASL Auth
DEBUG Requesting resource: sleekxmpp_
INFO Node set to: [address-removed]@gmail.com/sleekxmpp_A4E39FDC
DEBUG Established Session


Some of the astute amongst you may notice that I've implemented XEP-0076 as a plugin, following right behind Psi.

Before an 0.1 release, I would like to add a well thought through plugin for XEP-0004 (Data Forms) as well as solidify some of my naming scheme for class variables and methods a little better. I should be there by this weekend. After that I will start reviewing patches and hopefully receiving contributions in the form of additional plugins. Keep in mind that a plugin does not have to be a XEP.

Feel free to check out the code using subversion at svn://netflint.net/sleekxmpp . Any feedback would be welcome.