cypht icon indicating copy to clipboard operation
cypht copied to clipboard

🐛 [Bug] Duplicate default SMTP servers appearing

Open mcjoshea opened this issue 11 months ago • 4 comments

🐛 Bug

When I add a default SMTP server in the .env file, I get a duplicate server appearing each time I save and log back in.

This is how my server settings look after a few saves:

Image

These are my SMTP settings:

DEFAULT_SMTP_NAME=localhost
DEFAULT_SMTP_SERVER=localhost
DEFAULT_SMTP_PORT=25
DEFAULT_SMTP_TLS=false
DEFAULT_SMTP_NO_AUTH=true

I have used version v1.4 before with similar settings and this did not happen. That is still running on the same server but in a different folder, using a different database and credentials, with older PHP, but still good. No issues with that.

If I update the config file and change the details, that default server appears as an additional server when I save and log back in.

I'm using the database for storing user settings. I can delete the config from the database and when I log on after that they are all gone. But they soon build up again.

If I comment out the above settings, delete the unwanted servers, do a save, and log out and back in, everything is fine. I no longer get the additional default SMTP servers building up.

I'm going to revert back to before I installed version 2.4 tonight and try installing it again in a few days time to see if I've done anything wrong, but if you can think of anything to try next time, please let me know.

Version & Environment

Rev: v2.4.0 OS: Debian 12 (Bookworm) PHP version: 8.3.20 Zend version: 4.3.20 SAPI: fpm-fcgi Enabled Modules: core, contacts, local_contacts, ldap_contacts, gmail_contacts, feeds, jmap, imap, smtp, account, idle_timer, desktop_notifications, calendar, themes, nux, developer, profiles, imap_folders, sievefilters, 2fa Git version: at revision (May 11, 2025)

mcjoshea avatar May 11 '25 22:05 mcjoshea

🐛 Bug

When I add a default SMTP server in the .env file, I get a duplicate server appearing each time I save and log back in.

This is how my server settings look after a few saves:

Image

These are my SMTP settings:

DEFAULT_SMTP_NAME=localhost
DEFAULT_SMTP_SERVER=localhost
DEFAULT_SMTP_PORT=25
DEFAULT_SMTP_TLS=false
DEFAULT_SMTP_NO_AUTH=true

I have used version v1.4 before with similar settings and this did not happen. That is still running on the same server but in a different folder, using a different database and credentials, with older PHP, but still good. No issues with that.

If I update the config file and change the details, that default server appears as an additional server when I save and log back in.

I'm using the database for storing user settings. I can delete the config from the database and when I log on after that they are all gone. But they soon build up again.

If I comment out the above settings, delete the unwanted servers, do a save, and log out and back in, everything is fine. I no longer get the additional default SMTP servers building up.

I'm going to revert back to before I installed version 2.4 tonight and try installing it again in a few days time to see if I've done anything wrong, but if you can think of anything to try next time, please let me know.

Version & Environment

Rev: v2.4.0 OS: Debian 12 (Bookworm) PHP version: 8.3.20 Zend version: 4.3.20 SAPI: fpm-fcgi Enabled Modules: core, contacts, local_contacts, ldap_contacts, gmail_contacts, feeds, jmap, imap, smtp, account, idle_timer, desktop_notifications, calendar, themes, nux, developer, profiles, imap_folders, sievefilters, 2fa Git version: at revision (May 11, 2025)

Hi @mcjoshea,

Thank for this catch, can we have a screen sharing session if you don't mind please?

christer77 avatar May 20 '25 13:05 christer77

Hi @mcjoshea,

Thank for this catch, can we have a screen sharing session if you don't mind please?

Yes, I'd be happy to do this, How do we set one up?

mcjoshea avatar May 24 '25 08:05 mcjoshea

Thank you @mcjoshea,

I have finally managed to reproduce the issue. We are working on it.

christer77 avatar May 28 '25 10:05 christer77

Hi @mcjoshea,

can we discuss on Cypht Community please!

thanks

christer77 avatar May 30 '25 08:05 christer77

Hello @mcjoshea, we retried reproducing this issue more than twice and we are not able to reproduce it. Please reopen if still exist and we'll likely want you to join us at Cypht Community and help where needed.

Baraka24 avatar Jul 11 '25 10:07 Baraka24