nextcloud / nextcloud/mail

Unable to load mailbox

Open
#10,163 3 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

0. to triage bug
Dominant language
JavaScript
Stars
1k
Forks
348
Avg merge
12h 28m
Merged PRs (30d)
91

Description

Steps to reproduce
  1. enter account information
  2. Account is created, logon succeeds
  3. Account creation creates an error when loading the mailbox
Expected behavior

loading of mailboxes succeeds

Actual behavior

loading of mailboxes failes

Mail app version

4.0.0

Mailserver or service

Own iMAP (courier-imap-ssl) on Nextcloud server

Operating system

OpenSuse

PHP engine version

PHP 8.2

Web server

Apache (supported)

Database

MariaDB

Additional info

Connection to my own IMAP used to work - with around 3.2.x it stopped working, however, only with my account.
For the accounts of my wife and daughter the mail app still works (same server, only different mailboxes)

If I recreate my account, it cannot be added and fails with provided log entry after successful account creation / logon.

There are no errors in the SysLog of the server. (Courier mentions the login, no other report nor error)

NextCloud Log:
{"reqId":"KjZvNc6nsrgJ3iXLGt5A","level":3,"time":"2024-09-17T14:43:05+00:00","remoteAddr":"192.168.1.5","user":"quippy","app":"mail","method":"GET","url":"/nextcloud/apps/mail/","message":"Could not load account mailboxes: IMAP error synchronizing account 27: IMAP error reported by server.","userAgent":"Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:130.0) Gecko/20100101 Firefox/130.0","version":"30.0.0.14","exception":{"Exception":"OCA\Mail\Exception\ServiceException","Message":"IMAP error synchronizing account 27: IMAP error reported by server.","Code":0,"Trace":[{"file":"/srv/www/htsdocs/nextcloud/apps/mail/lib/Service/MailManager.php","line":134,"function":"sync","class":"OCA\Mail\IMAP\MailboxSync","type":"->","args":["*** sensitive parameters replaced "]},{"file":"/srv/www/htsdocs/nextcloud/apps/mail/lib/Controller/PageController.php","line":156,"function":"getMailboxes","class":"OCA\Mail\Service\MailManager","type":"->"},{"file":"/srv/www/htsdocs/nextcloud/lib/private/AppFramework/Http/Dispatcher.php","line":208,"function":"index","class":"OCA\Mail\Controller\PageController","type":"->"},{"file":"/srv/www/htsdocs/nextcloud/lib/private/AppFramework/Http/Dispatcher.php","line":114,"function":"executeController","class":"OC\AppFramework\Http\Dispatcher","type":"->"},{"file":"/srv/www/htsdocs/nextcloud/lib/private/AppFramework/App.php","line":161,"function":"dispatch","class":"OC\AppFramework\Http\Dispatcher","type":"->"},{"file":"/srv/www/htsdocs/nextcloud/lib/private/Route/Router.php","line":302,"function":"main","class":"OC\AppFramework\App","type":"::"},{"file":"/srv/www/htsdocs/nextcloud/lib/base.php","line":1001,"function":"match","class":"OC\Route\Router","type":"->"},{"file":"/srv/www/htsdocs/nextcloud/index.php","line":24,"function":"handleRequest","class":"OC","type":"::"}],"File":"/srv/www/htsdocs/nextcloud/apps/mail/lib/IMAP/MailboxSync.php","Line":109,"Previous":{"Exception":"Horde_Imap_Client_Exception_ServerResponse","Message":"IMAP error reported by server.","Code":0,"Trace":[{"file":"/srv/www/htsdocs/nextcloud/apps/mail/vendor/bytestream/horde-imap-client/lib/Horde/Imap/Client/Socket.php","line":4319,"function":"_getLine","class":"Horde_Imap_Client_Socket","type":"->"},{"file":"/srv/www/htsdocs/nextcloud/apps/mail/vendor/bytestream/horde-imap-client/lib/Horde/Imap/Client/Socket.php","line":4243,"function":"_sendCmdChunk","class":"Horde_Imap_Client_Socket","type":"->"},{"file":"/srv/www/htsdocs/nextcloud/apps/mail/vendor/bytestream/horde-imap-client/lib/Horde/Imap/Client/Socket.php","line":3903,"function":"_sendCmd","class":"Horde_Imap_Client_Socket","type":"->"},{"file":"/srv/www/htsdocs/nextcloud/apps/mail/vendor/bytestream/horde-imap-client/lib/Horde/Imap/Client/Base.php","line":3330,"function":"_getMyACLRights","class":"Horde_Imap_Client_Socket","type":"->"},{"file":"/srv/www/htsdocs/nextcloud/apps/mail/lib/IMAP/FolderMapper.php","line":118,"function":"getMyACLRights","class":"Horde_Imap_Client_Base","type":"->"},{"file":"/srv/www/htsdocs/nextcloud/apps/mail/lib/IMAP/MailboxSync.php","line":107,"function":"fetchFolderAcls","class":"OCA\Mail\IMAP\FolderMapper","type":"->"},{"file":"/srv/www/htsdocs/nextcloud/apps/mail/lib/Service/MailManager.php","line":134,"function":"sync","class":"OCA\Mail\IMAP\MailboxSync","type":"->","args":[" sensitive parameters replaced ***"]},{"file":"/srv/www/htsdocs/nextcloud/apps/mail/lib/Controller/PageController.php","line":156,"function":"getMailboxes","class":"OCA\Mail\Service\MailManager","type":"->"},{"file":"/srv/www/htsdocs/nextcloud/lib/private/AppFramework/Http/Dispatcher.php","line":208,"function":"index","class":"OCA\Mail\Controller\PageController","type":"->"},{"file":"/srv/www/htsdocs/nextcloud/lib/private/AppFramework/Http/Dispatcher.php","line":114,"function":"executeController","class":"OC\AppFramework\Http\Dispatcher","type":"->"},{"file":"/srv/www/htsdocs/nextcloud/lib/private/AppFramework/App.php","line":161,"function":"dispatch","class":"OC\AppFramework\Http\Dispatcher","type":"->"},{"file":"/srv/www/htsdocs/nextcloud/lib/private/Route/Router.php","line":302,"function":"main","class":"OC\AppFramework\App","type":"::"},{"file":"/srv/www/htsdocs/nextcloud/lib/base.php","line":1001,"function":"match","class":"OC\Route\Router","type":"->"},{"file":"/srv/www/htsdocs/nextcloud/index.php","line":24,"function":"handleRequest","class":"OC","type":"::"}],"File":"/srv/www/htsdocs/nextcloud/apps/mail/vendor/bytestream/horde-imap-client/lib/Horde/Imap/Client/Socket.php","Line":4620},"message":"Could not load account mailboxes: IMAP error synchronizing account 27: IMAP error reported by server.","exception":{},"CustomMessage":"Could not load account mailboxes: IMAP error synchronizing account 27: IMAP error reported by server."}}

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start in apps/mail/lib/IMAP/MailboxSync.php around sync and FolderMapper.php around fetchFolderAcls, following the logged call into Horde_Imap_Client_Socket. Reproduce the account-specific failure with Courier IMAP and inspect the server response. Done means the affected mailbox loads successfully without the reported synchronization error.

Written by the indexing model from the issue text.

Assessment

Tech stack
php
Domain
backend
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
20/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.