Skip to content

Auto-refresh email list when folder counter increments via system cron #13071

@lhreymond

Description

@lhreymond

Steps to reproduce

Context

  • Nextcloud version: Latest
  • Mail app version: Latest
  • Cron type: System Cron (running every minute)
  • Mail provider: External IMAP (OVHcloud MX Plan)

Description

When using the system cron configured at a 1-minute interval, Nextcloud correctly checks the external IMAP server and detects new emails in the background.

However, there is an asynchronous inconsistency in the web UI:

  1. The unread folder counter (left sidebar) increments in real-time as soon as the cron runs (e.g., changes from 3 to 5 unread emails).
  2. The central email list (main view) remains completely frozen and stale.

Currently, users have to manually click the "Refresh" button or switch folders to force the central list to fetch and display the new messages that the server already knows about.

Expected behavior

The central email list view should subscribe to the same event or state change that updates the folder counter. When the left sidebar counter increments via a background cron job, the main UI list should automatically trigger an internal refresh and inject the new emails seamlessly without requiring manual user action.

Additional information

This creates a confusing user experience where the UI indicates new mail has arrived (via the counter), but the main interface fails to display them until a manual action is taken. A modern webmail experience should reactively push or render these new items in the list automatically.

Image

Expected behavior

The central email list view should subscribe to the same event or state change that updates the folder counter. When the left sidebar counter increments via a background cron job, the main UI list should automatically trigger an internal refresh and inject the new emails seamlessly without requiring manual user action.

Actual behavior

This creates a confusing user experience where the UI indicates new mail has arrived (via the counter), but the main interface fails to display them until a manual action is taken. A modern webmail experience should reactively push or render these new items in the list automatically.

Mail app version

No response

Nextcloud version

No response

Mailserver or service

No response

Operating system

No response

PHP engine version

None

Nextcloud memory caching

No response

Web server

None

Database

None

Additional info

No response

Metadata

Metadata

Type

No fields configured for Bug.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions