[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 10:37:52
Message-ID: 20130204103752.16803.63737 () vidsolbach ! de
[Download RAW message or body]
-----------------------------------------------------------
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.
Changes
-------
Hello Andras!
Thanks for reading my proposal.
I tested your patch --> the problem is solved.
Now I get, this looks pretty fine.
The patch I now propose is a merge of our two.
List of objects of mMaildirsForCollection
+--------------------------------------------------+------------+------------------------------------------------------------------------+
+ key + name + remoteId \
+ +--------------------------------------------------+------------+------------------------------------------------------------------------+
| /home/guy-kde/.local/share/local-mail/sent-mail | sent-mail | \
/home/guy-kde/.local/share/local-mail/sent-mail | | \
/home/guy-kde/.local/share/local-mail/outbox | outbox | \
/home/guy-kde/.local/share/local-mail/outbox | | \
/home/guy-kde/.local/share/local-mail/inbox/A/a1 | a1 | \
/home/guy-kde/.local/share/local-mail/.inbox.directory/.A.directory/a1 | | \
/home/guy-kde/.local/share/local-mail/inbox/a3 | a3 | \
/home/guy-kde/.local/share/local-mail/.inbox.directory/a3 | | \
/home/guy-kde/.local/share/local-mail/inbox/A/a2 | a2 | \
/home/guy-kde/.local/share/local-mail/.inbox.directory/.A.directory/a2 | | \
/home/guy-kde/.local/share/local-mail/inbox | inbox | \
/home/guy-kde/.local/share/local-mail/inbox | | \
/home/guy-kde/.local/share/local-mail | local-mail | \
/home/guy-kde/.local/share/local-mail | | \
/home/guy-kde/.local/share/local-mail/inbox/A | A | \
/home/guy-kde/.local/share/local-mail/.inbox.directory/A | \
+--------------------------------------------------+------------+------------------------------------------------------------------------+
8 objects
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 (updated)
-----
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