Bug 129081

Summary: kopete: jabber treats contact as account
Product: [Unmaintained] kopete Reporter: Michal Svec <rebel>
Component: Jabber PluginAssignee: Kopete Developers <kopete-bugs-null>
Status: RESOLVED FIXED    
Severity: normal CC: scherer.michael
Priority: NOR    
Version First Reported In: unspecified   
Target Milestone: ---   
Platform: unspecified   
OS: Linux   
Latest Commit: Version Fixed/Implemented In:
Sentry Crash Report:
Attachments: log snippet

Description Michal Svec 2006-06-13 10:04:51 UTC
Version:           0.12.0 (using KDE 3.5.1 Level "a" , SUSE 10.1)
Compiler:          Target: i586-suse-linux
OS:                Linux (i686) release 2.6.16.13-4-default

I added two contacts on my jabber account, both in the form NUMBER@sms.netlab.cz pointing to the sms gateway. However, now (I suppose after update to 0.12) they both appear as two accounts and even if I delete them in kopete they reappear next time kopete is started.

This is saved to kopeterc:

[Account_JabberProtocol_rebel@jabber.cz/+420608XXXXXX@sms.netlab.cz]
AccountId=rebel@jabber.cz/+420608XXXXXX@sms.netlab.cz
Color=0,255,0
GatewayJID=+42060XXXXXX@sms.netlab.cz
Icon=jabber_gateway_sms
Protocol=JabberProtocol
Comment 1 Michal Svec 2006-06-13 10:07:21 UTC
Created attachment 16577 [details]
log snippet

This log snippet could have more information what happened.
Comment 2 Olivier Goffart 2006-06-13 12:03:48 UTC
Yes, each contact pretends to be a gateway by itself.

I'm used to gateway like msn or icq where you have one global gateway contact, and some subcontacts.


Comment 3 Olivier Goffart 2006-06-14 10:59:42 UTC
I cannot reproduce the bug.
I registered to sms.netlab.cz , the gateway has been added as account (normal)
and then i was able to add contacts to my list.
Comment 4 Michal Svec 2006-06-14 11:09:17 UTC
Still can reproduce it:

  * my account is at jabber.cz, login@jabber.cz
  * and I added _contact_ +420777XXXXXX@sms.jabber.cz
  -> the contact got immediately moved to accounts

I didn't do any registration to the gateway, etc, just added that contact.

And it seems that pre-0.12 it worked (I could use that contact to send messages), but just 0.12 treats these contacts as accounts.
Comment 5 Michael Scherer 2006-06-14 14:57:27 UTC
I see a similar behavior on the yahoo gateway of my server. I never seen it before kopete 0.12, and it work fine for other clients. The server is running jabberd1, and yahoo transport from debian sid ( http://www.jabberstudio.org/projects/yahoo-transport-2/, according to the documentation ).

I have removed my account from kopete and readded, and I still have multiple accounts created, one for each yahoo contact i have. 
Comment 6 Sebastian TurzaƄski 2006-06-18 10:10:31 UTC
i confirm - kopete 0.12 from suse 10.1 backport

all my jabber "tlen" ports contacts became kopete accounts
Comment 7 Olivier Goffart 2006-06-18 11:42:13 UTC
SVN commit 552559 by ogoffart:

Fix Bug 129081: jabber treats contact as account

BUG: 129081

(Don't consider a contact with something before the @ is a transport anymore)




 M  +4 -0      jabbercontact.cpp  


--- branches/kopete/0.12/kopete/protocols/jabber/jabbercontact.cpp #552558:552559
@@ -423,6 +423,8 @@
 	{
 		if(transport()) //no need to disco if this is a legacy contact
 			mDiscoDone = true;
+		else if(!rosterItem().jid().node().isEmpty())
+			mDiscoDone = true; //contact with an @ are not transport for sure
 		else
 		{
 			mDiscoDone = true; //or it will happen twice, we don't want that.
@@ -470,6 +472,8 @@
 	{
 		if(transport()) //no need to disco if this is a legacy contact
 			mDiscoDone = true;
+		else if(!rosterItem().jid().node().isEmpty())
+			mDiscoDone = true; //contact with an @ are not transport for sure
 		else
 		{
 			//disco to see if it's not a transport