6.0.0-beta1
7/27/25

[#9172] Imap folders don't show in IMP on the very first login
Summary Imap folders don't show in IMP on the very first login
Queue Horde Groupware Webmail Edition
Queue Version 1.2.6
Type Bug
State Not A Bug
Priority 1. Low
Owners
Requester luc.germain (at) usherbrooke (dot) ca
Created 08/11/2010 (5464 days ago)
Due
Updated 09/28/2010 (5416 days ago)
Assigned 08/13/2010 (5462 days ago)
Resolved 09/28/2010 (5416 days ago)
Github Issue Link
Github Pull Request
Milestone
Patch No

History
09/28/2010 08:27:05 PM Jan Schneider Comment #9
State ⇒ Not A Bug
Reply to this comment
Uh, that CAS patch fiddles with IMAP.php, you could have imagined that 
this would be the first place to look.
09/28/2010 08:24:58 PM Jan Schneider Comment #8 Reply to this comment
It seems to work for anybody else just fine, so there's no need to 
remove that hook. And honestly, I have no idea how calling that API 
method in the hook would cause IMAP folders to not appear. This 
doesn't make any sense.
I can only guess that this has to do with the CAS authentication that 
requires some heavy patching of Horde IIRC, so it's not a pristine 
installation anyway.
09/07/2010 06:52:01 PM Luc (dot) Germain (at) usherbrooke (dot) ca Comment #7 Reply to this comment
This sounds like an error in contacts/getDefaultShare registry call 
then and has nothing to do with IMP.
This bug is filed in the "Horde Groupware Webmail Edition" queue. 
Maybe it's not IMP, but it's certainly somewhere in the "Horde 
Groupware Edition"...

And if nobody knows how to solve the problem, you should at least 
remove the code from being activated by default in 
imp/config/hooks.php, at least until a solution is found. We lost 
quite a lot of time tracking down the source of the missing folders on 
first login... (It was a big problem for us because many users were 
calling thinking we had lost all their folders during the upgrade to 
this version)
09/03/2010 08:11:30 PM Michael Slusarz Comment #6 Reply to this comment
This sounds like an error in contacts/getDefaultShare registry call 
then and has nothing to do with IMP.
09/02/2010 06:00:03 PM luc (dot) germain (at) usherbrooke (dot) ca Comment #5 Reply to this comment
So what is failing within the add_source hook?  Do you have custom 
code in there?  Obviously, we can't guarantee that the example hook 
provided is going to work in all environments.
It's the code that is activated by default in the horde-webmail-1.2.6 
distribution. We have not touched it. Since it's there by default, I 
guess it should be working?

# cat hooks.php
<?php

if (!function_exists('_prefs_hook_add_source')) {
     function _prefs_hook_add_source($username = null)
     {
         if (!$username) {
             return;
         }
         return $GLOBALS['registry']->call('contacts/getDefaultShare');
     }
}

09/02/2010 05:38:18 PM Michael Slusarz Comment #4 Reply to this comment
Then, by removing each preference entry one by one, we found out 
that the problem was triggered when the "add_source" preference was 
not there, and hence, the call to the hook function. Unfortunately, 
we have no idea why this function is causing the problem.
So what is failing within the add_source hook?  Do you have custom 
code in there?  Obviously, we can't guarantee that the example hook 
provided is going to work in all environments.
09/01/2010 07:46:06 PM luc (dot) germain (at) usherbrooke (dot) ca Comment #3 Reply to this comment
I can't reproduce this. Can you provide more details about what you 
find out while tracking this down?
We found out that we could reproduce the problem for a user by 
deleting all his preference entries in the "horde_prefs" table. Then, 
by removing each preference entry one by one, we found out that the 
problem was triggered when the "add_source" preference was not there, 
and hence, the call to the hook function. Unfortunately, we have no 
idea why this function is causing the problem.

Notes: We are using the CAS driver for authentication, provided by the 
ESUP group, available here: 
https://sourcesup.cru.fr/frs/?group_id=264&release_id=1769. We also 
run our PHP processes through the fastcgi protocol under a chrooted 
environment. I don't think those have anything to do with this problem 
(since everything else is working perfectly), but maybe it can help...
08/13/2010 12:41:47 PM Jan Schneider Comment #2
State ⇒ Feedback
Reply to this comment
I can't reproduce this. Can you provide more details about what you 
find out while tracking this down?
08/11/2010 07:29:29 PM luc (dot) germain (at) usherbrooke (dot) ca Comment #1
Milestone ⇒
State ⇒ Unconfirmed
Patch ⇒ No
Queue ⇒ Horde Groupware Webmail Edition
Summary ⇒ Imap folders don't show in IMP on the very first login
Type ⇒ Bug
Priority ⇒ 1. Low
Reply to this comment
When a user login for the very first time to Horde, only the Inbox 
show up in IMP, all other folders are not visible. If the user logout 
and login again, all folders are there.

I tracked down the problem to the $_prefs['add_source'], which call 
the hook function _prefs_hook_add_source() the first time a user 
login. I changed 'hook' to 'false' and now the new users see their 
imap folders the first time they login. (But, of course, their default 
address book is not setup automatically anymore).






Saved Queries