Net::Jabber (really, XML::Stream) Hates My Server

| | Comments (1)

So I tried connecting our Jabber bot to our new Jabber server (OpenFire). It wasn't happy.

At first I thought it might be SSL, and after wrestling with that and many other things, I finally decided to randomly comment out things I didn't understand. Well, not randomly: one of the errors I kept seeing when I was pretty sure I had everything right was:

Can't use an undefined value as a HASH reference at
/usr/local/lib/perl5/site_perl/5.10.0/XML/ line 1165.

But I don't know what the heck is going on in there. Poking around though, I see that $self->GetRoot($sid) is returning undef, and right above that, there's a call to delete($self->{SIDS}->{$currsid}). And GetRoot($sid), in fact, accesses $self->{SIDS}->{$sid}.

So I add in some print statements and see that, in fact, $sid and $currsid are the same.

So, I says to myself, comment out the delete call. And so I do. And so it works.

I don't know why that was necessary. And I should send this to the XML::Stream author. Tomorrow.


lottadot Author Profile Page said:

We've had problems with the Slash jabberbot too. Though we are using an XServe (10.4) as the jabber server. I know I ended up writing a quick-n-dirty script that would verify that Net::Jabber could authenticate and connect ok. Once I saw that it could, I went poking around in the bot code. I don't recall if I changed anything or not, I think I did, but if you're interested I'll grab it and diff it. I know I had to fiddle with the values in the vars table too.

Note that we are not using SSL, which doesn't seem to the consensus and was I think part of our problem.

Oh, and I did build a 5.8 lamp dev on this laptop. I haven't got the nerve, nor the spare time yet, to try 5.10, yet :)

This mt that you have installed, it's losing the checkbox value when you 'preview' your comment, btw.

Leave a comment

<pudge/*> (pronounced "PudgeGlob") is thousands of posts over many years by Pudge.

"It is the common fate of the indolent to see their rights become a prey to the active. The condition upon which God hath given liberty to man is eternal vigilance; which condition if he break, servitude is at once the consequence of his crime and the punishment of his guilt."

About this Entry

This page contains a single entry by pudge published on January 3, 2008 4:32 PM.

Pop Quiz was the previous entry in this site.

Studio Tour is the next entry in this site.

Find recent content on the main index or look in the archives to find all content.