Bug 65305

Summary: double contacts in toplevel and in a group
Product: [Unmaintained] kopete Reporter: Roberto Pariset <victorheremita>
Component: generalAssignee: Kopete Developers <kopete-bugs-null>
Status: RESOLVED FIXED    
Severity: normal CC: paul.sandulescu
Priority: NOR    
Version: unspecified   
Target Milestone: ---   
Platform: Debian testing   
OS: Linux   
Latest Commit: Version Fixed In:
Sentry Crash Report:

Description Roberto Pariset 2003-10-01 12:33:41 UTC
Version:           today cvs (using KDE KDE 3.1.3)
Installed from:    Debian testing/unstable Packages
Compiler:          gcc (GCC) 3.3.2 20030908 (Debian prerelease) 
OS:          Linux

in today cvs, i added gregj using gadu in group 'kopete'. now he is in 'koepte', but also in top level, out of any group. if i erase one of the two contacts, the other is erased as well. i tried adding sigthor with icq just to make sure it was not a gadu problem, and i got the same bahaviour. if you want a screenshot maybe it will be more intuitive to understand, in case i have not been so clear. i didnt have any problem a week ago or so when i added gregj for the first time.
Comment 1 Casey Allen Shobe 2003-10-01 12:55:55 UTC
I can confirm this on at least ICQ and MSN - I don't think it's 
protocol-specific. 
 
In the contactlist.xml file, the contact has two group entries: 
<groups> 
    <group id="7" /> 
    <group id="1" /> 
</groups> 
 
Seems to be a flaw in addcontact. 
Comment 2 Matt Rogers 2003-10-18 18:27:09 UTC
I don't suppose this has been fixed with a more recent CVS build has it?
Comment 3 Casey Allen Shobe 2003-10-19 02:45:10 UTC
> I don't suppose this has been fixed with a more recent CVS build has it?

It most certainly has not.  This has been there since the day this bug was reported (and possibly one or two days before that).

A workaround is to drag the duplicate contact to the group the second identical copy is in, which makes them magically merge into one contact.
Comment 4 Stefan Gehn 2003-10-19 12:14:49 UTC
Works fine here, I need a proper description of how to reproduce this bug, it never occured for me whenever I added contacts.
Comment 5 Casey Allen Shobe 2003-10-19 17:10:04 UTC
File --> Add Contact
Uncheck Address Book, Next
Check some group (or don't and you'll have two contacts at toplevel), Next
Select some protocol, Next.
Enter some account ID, Next.
Next, again.

See results.  I've never been not able to reproduce this bug since it started happening.  Every time I add a contact this happens.
Comment 6 Olivier Goffart 2003-10-19 17:40:58 UTC
Subject: kdenetwork/kopete/kopete/addcontactwizard

CVS commit by ogoffart: 

CCMAIL: 65305-done@bugs.kde.org


Hehe, i don't know what Martijn smoke when he wrote this code, but it's at least the second stupid mistake i find in this commit
(revision 1.17 of addcontactwizard.cpp)    The first one was even in the log message  (with the `if ( s_temporary )` )  
:-D


  M +2 -1      addcontactwizard.cpp   1.33


--- kdenetwork/kopete/kopete/addcontactwizard/addcontactwizard.cpp  #1.32:1.33
@@ -258,4 +258,5 @@ void AddContactWizard::accept()
                 }
         }
+        if(topLevel)
         metaContact->addToGroup( KopeteGroup::topLevel() );
 


Comment 7 Casey Allen Shobe 2003-12-21 08:54:10 UTC
*** Bug 62607 has been marked as a duplicate of this bug. ***