When logging into the Yahoo transport I’‘m finding that the status messages aren’'t always matching the user they belong to.
Really? Hrm. I thought I had that fixed!!! Crap! Does there appear to be any rhyme or reason to who’'s getting what messages? At one point there was a problem where only the last person to log in was getting messages.
Hey George, any more info on this?
I forgot.
I’‘ll mess with it this morning and see if I can spot where they’'re getting mixed up or at least get more info.
The bug is in ymsg and was reported last year but never fixed.
http://sourceforge.net/forum/forum.php?thread_id=1318224&forum_id=261845
When I tried the patch suggested, it sent both wf and psi into a tight spin loop when I logged on.
I’'ll look at it more this afternoon and see if I can come up with a patch that works.
Wow, a bug that’'s not in my code! Woohoo!
Thanks!!!
I created an issue for it btw, GATE-65.
Did you use the 0.6 version of the ymsg library and did you use the pre-built jars or did you compile from source?
When I compile from source with no code changes, I get very wierd breakage involving tigh spin loops on both the client and server after the transport logs in.
Unfortunately, I don’‘t remember anymore. I vaguely remember building it myself because I had to tweak something. I’'m definitely using at a minimum the “patched” version, which is kinda sorta referred to as 0.61.
Still have the source tree? I can’‘t seem to get a working copy even after appying the patches which means I can’'t test the patch that fixes the problem.
Message was edited by: gtj
Nevermind. I finally found the right patch set to get the base and the patch referenced in the link above does work. After applying it I now get the custom status messages to appear for the correct contacts.
So wait… it looks like I missed the 0.61 patch from the site? That patch already fixes this issue?
You didn’‘t miss anything. Look a few posts up in this thread, there’‘s a link to a ymsg forum post that contains a code fragment that fixed the problem I reported. It’‘s NOT fixed in 0.61. I had a problem testing it yesterday because I couldn’'t find the 0.61 patch to use as the base. Last night I finally found the correct 0.61 patch from javakiddy, re-created a working library, then applied the code fragment and observed that the original problem went away and no new problems seemed to creep in.
Here’'s where I got the 0.61 patch…
http://sourceforge.net/forum/forum.php?thread_id=1296702&forum_id=261845
Message was edited by: gtj
Oh excellent! Thanks!!
I don’'t think your latest jar checkin fixed this. Did you add the method to YMSG9Packet and make the change in Session to use the new method?
I think I missed part of it. I was having trouble understanding exactly what the person was saying. I replaced Session.java with the patched one from the patches tree. You say there’'s another part I was supposed to do?
Yep…
Copy the following method to YMSG9Packet.java
String getNthValue2(String k,int n)
{
int currentIndex = getNthLocation(“7”,n);
int nextIndex = getNthLocation(“7”,n+1);
int max = 0;
if(currentIndex != -1){
if(nextIndex == -1){
max = body.length;
}else{
max = nextIndex;
}
for(;currentIndex <max;currentIndex +=2){
if(body[currentIndex].equals(k)){
return body[currentIndex];
}
}
}
return null;
}
Then in Session.java (after copying javakiddy’'s 0.61 patch)…
Edit the method updateFriendsStatus(YMSG9Packet pkt) where the custom message is added to the Yahoo User
// -
Custom message?
if(pkt.getNthValue2(“19”,i) != null && pkt.getNthValue2(“47”,i) != null)
{
yu.setCustom(pkt.getNthValue2(“19”,i),pkt.getNthValue2(“47”,i));
}
Message was edited by: gtj
How the heck do you get code to paste correctly in a post
Message was edited by: gtj
Oh forget it…just cut and paste from here…[http://sourceforge.net/forum/forum.php?thread_id=1318224&forum_id=261845]
Message was edited by: gtj
Weird man, the patch I found was “different”. Either way, could you take a look again and see how it’'s going? (just commited to svn)
Yep, another project that’'s just kind of wilted and is begging for a new home.
Anyway, the jars you just checked in fixed the problem but another one has crept in not related to the jars.
Since Saturday, the yahoo transport does not appear as logged in even though it actually is. This confuses some clients (like Webmessenger for Blackberry) because the contacts are ok but the transport isn’'t.
For what it’‘s worth, I contacted the guy and he’'s still working on it, just running out of free time. He has a 0.70 release “pending”.
As for the other problem, I believe I’'ve fixed that with the svn commit -after- that one.
Cool, seems to be fixed. Thanks.