[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-pim
Subject:    Re: [Kde-pim] Review Request 108755: akonadi_maildir_resource doesn't work as expected, can anybody
From:       "Guy Maurel" <guy-kde () maurel ! de>
Date:       2013-02-04 11:39:28
Message-ID: 20130204113928.22234.90495 () vidsolbach ! de
[Download RAW message or body]



> On Feb. 4, 2013, 11:12 a.m., Andras Mantia wrote:
> > Hi,
> > 
> > to be honest I'm not in favour to commit the debug code in. It pretty much looks \
> > like that the hash works now, and writing the debug code is not hard should there \
> > a need of such code arise in the future. The typedef for the hash is also \
> > something I'm not the fan of, especially that the hash type is never used \
> > anywhere else, but in the member variable declaration (and the debug code \
> > itself). I will put my patch into the repository today (both to 4.10 and master).

Fine.


- Guy


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
http://git.reviewboard.kde.org/r/108755/#review26602
-----------------------------------------------------------


On Feb. 4, 2013, 10:37 a.m., Guy Maurel wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> http://git.reviewboard.kde.org/r/108755/
> -----------------------------------------------------------
> 
> (Updated Feb. 4, 2013, 10:37 a.m.)
> 
> 
> Review request for KDEPIM, Andras Mantia, Kevin Krammer, and Till Adam.
> 
> 
> Description
> -------
> 
> I implemented a little dump to examine what is happening with the QHash \
> mMaildirsForCollection. 
> It doesn't work as we could expect.
> 
> At the start of /usr/local/bin/akonadi_agent_launcher akonadi_maildir_resource \
> akonadi_maildir_resource_0 we get this:
> 
> List of objects of mMaildirsForCollection
> +------+------------+----------------------------------------------------------------------------------+
>  |   id | name       | remoteId                                                     \
> | +------+------------+----------------------------------------------------------------------------------+
>  |   -5 | local-mail | /home/guy-kde/.local/share/local-mail                        \
> | |   -6 | inbox      | /home/guy-kde/.local/share/local-mail/inbox                 \
> | +------+------------+----------------------------------------------------------------------------------+
>  2 objects
> 
> After starting kmail:
> 
> List of objects of mMaildirsForCollection
> +------+------------+----------------------------------------------------------------------------------+
>  |   id | name       | remoteId                                                     \
> | +------+------------+----------------------------------------------------------------------------------+
>  |   -5 | local-mail | /home/guy-kde/.local/share/local-mail                        \
> | |   -6 | inbox      | /home/guy-kde/.local/share/local-mail/inbox                 \
> | |   -7 | A          | /home/guy-kde/.local/share/local-mail/.inbox.directory/A    \
> | |   -8 | a1         | \
> /home/guy-kde/.local/share/local-mail/.inbox.directory/.A.directory/a1           | \
> |   -9 | a2         | /home/guy-kde/.local/share/local-mail/.inbox.directory/a2     \
> | |  -10 | a3         | /home/guy-kde/.local/share/local-mail/.inbox.directory/a3   \
> | +------+------------+----------------------------------------------------------------------------------+
>  6 objects
> 
> All the id are negativ.
> This comes because the function:
> Collection::List MaildirResource::listRecursive
> (file kdepim-runtime/resources/maildir/maildirresource.cpp)
> 
> doesn't set the id itself. The default value is set by entity.
> 
> This explains why the if at:
> Maildir MaildirResource::maildirForCollection( const Collection& col )
> ...
> if ( mMaildirsForCollection.contains( col.id() ) ) {
> 
> is never TRUE.
> 
> After having some click at some Folder, the correct "id", which is stored in the \
> mysql-database, is found. 
> List of objects of mMaildirsForCollection
> +------+------------+----------------------------------------------------------------------------------+
>  |   id | name       | remoteId                                                     \
> | +------+------------+----------------------------------------------------------------------------------+
>  |    2 | local-mail | /home/guy-kde/.local/share/local-mail                        \
> | |    3 | outbox     | /home/guy-kde/.local/share/local-mail/outbox                \
> | |   -5 | local-mail | /home/guy-kde/.local/share/local-mail                       \
> | |   21 | A          | /home/guy-kde/.local/share/local-mail/.inbox.directory/A    \
> | |    4 | sent-mail  | /home/guy-kde/.local/share/local-mail/sent-mail             \
> | |   -6 | inbox      | /home/guy-kde/.local/share/local-mail/inbox                 \
> | |   22 | a1         | \
> /home/guy-kde/.local/share/local-mail/.inbox.directory/.A.directory/a1           | \
> |   -7 | A          | /home/guy-kde/.local/share/local-mail/.inbox.directory/A      \
> | |   23 | a2         | /home/guy-kde/.local/share/local-mail/.inbox.directory/a2   \
> | |   -8 | a1         | \
> /home/guy-kde/.local/share/local-mail/.inbox.directory/.A.directory/a1           | \
> |   24 | a3         | /home/guy-kde/.local/share/local-mail/.inbox.directory/a3     \
> | |   -9 | a2         | /home/guy-kde/.local/share/local-mail/.inbox.directory/a2   \
> | |    8 | inbox      | /home/guy-kde/.local/share/local-mail/inbox                 \
> | |  -10 | a3         | /home/guy-kde/.local/share/local-mail/.inbox.directory/a3   \
> | |  -11 | outbox     | /home/guy-kde/.local/share/local-mail/outbox                \
> | |  -12 | sent-mail  | /home/guy-kde/.local/share/local-mail/sent-mail             \
> | +------+------------+----------------------------------------------------------------------------------+
>  16 objects
> 
> BUT, making some more folder-moves, I get:
> 
> List of objects of mMaildirsForCollection
> +------+------------+----------------------------------------------------------------------------------+
>  |   id | name       | remoteId                                                     \
> | +------+------------+----------------------------------------------------------------------------------+
>  | -223 | a2         | /home/guy-kde/.local/share/local-mail/.inbox.directory/a2    \
> | | -224 | outbox     | /home/guy-kde/.local/share/local-mail/outbox                \
> | |    2 | local-mail | /home/guy-kde/.local/share/local-mail                       \
> | | -225 | sent-mail  | /home/guy-kde/.local/share/local-mail/sent-mail             \
> | |    3 | outbox     | /home/guy-kde/.local/share/local-mail/outbox                \
> | |   -5 | local-mail | /home/guy-kde/.local/share/local-mail                       \
> | |    4 | sent-mail  | /home/guy-kde/.local/share/local-mail/sent-mail             \
> | |   -6 | inbox      | /home/guy-kde/.local/share/local-mail/inbox                 \
> | |   -7 | A          | /home/guy-kde/.local/share/local-mail/.inbox.directory/A    \
> | |   -8 | a1         | \
> /home/guy-kde/.local/share/local-mail/.inbox.directory/.A.directory/a1           | \
> |   -9 | a2         | /home/guy-kde/.local/share/local-mail/.inbox.directory/a2     \
> | |    8 | inbox      | /home/guy-kde/.local/share/local-mail/inbox                 \
> | |  -10 | a3         | /home/guy-kde/.local/share/local-mail/.inbox.directory/a3   \
> | |  -11 | outbox     | /home/guy-kde/.local/share/local-mail/outbox                \
> | |  -12 | sent-mail  | /home/guy-kde/.local/share/local-mail/sent-mail             \
> | | -277 | local-mail | /home/guy-kde/.local/share/local-mail                       \
> | | -278 | inbox      | /home/guy-kde/.local/share/local-mail/inbox                 \
> | | -279 | A          | /home/guy-kde/.local/share/local-mail/.inbox.directory/A    \
> | | -280 | a1         | \
> /home/guy-kde/.local/share/local-mail/.inbox.directory/.A.directory/a1           | \
> |   21 | A          | /home/guy-kde/.local/share/local-mail/.inbox.directory/A      \
> | | -281 | a2         | \
> /home/guy-kde/.local/share/local-mail/.inbox.directory/.A.directory/a2           | \
> |   22 | a1         | \
> /home/guy-kde/.local/share/local-mail/.inbox.directory/.A.directory/a1           | \
> | -282 | a3         | \
> /home/guy-kde/.local/share/local-mail/.inbox.directory/.A.directory/a3           | \
> |   23 | a2         | /home/guy-kde/.local/share/local-mail/.inbox.directory/a2     \
> | | -283 | outbox     | /home/guy-kde/.local/share/local-mail/outbox                \
> | |   24 | a3         | /home/guy-kde/.local/share/local-mail/.inbox.directory/a3   \
> | | -284 | sent-mail  | /home/guy-kde/.local/share/local-mail/sent-mail             \
> | | -218 | local-mail | /home/guy-kde/.local/share/local-mail                       \
> | | -219 | inbox      | /home/guy-kde/.local/share/local-mail/inbox                 \
> | | -220 | A          | /home/guy-kde/.local/share/local-mail/.inbox.directory/A    \
> | | -221 | a1         | \
> /home/guy-kde/.local/share/local-mail/.inbox.directory/.A.directory/a1           | \
> | -222 | a3         | \
> /home/guy-kde/.local/share/local-mail/.inbox.directory/.A.directory/a3           | \
> +------+------------+----------------------------------------------------------------------------------+
>  32 objects
> 
> I have no solution to solve this.
> Can anybody help me?
> Thanks.
> 
> 
> Diffs
> -----
> 
> resources/maildir/maildirresource.h b0c595a 
> resources/maildir/maildirresource.cpp df989c1 
> 
> Diff: http://git.reviewboard.kde.org/r/108755/diff/
> 
> 
> Testing
> -------
> 
> 
> Thanks,
> 
> Guy Maurel
> 
> 

_______________________________________________
KDE PIM mailing list kde-pim@kde.org
https://mail.kde.org/mailman/listinfo/kde-pim
KDE PIM home page at http://pim.kde.org/


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic