Ticket #11774 (closed PLIP: fixed)

Opened 5 years ago

Last modified 5 years ago

Add "test mail server" form to Mail Settings

Reported by: aclark Owned by: aclark
Priority: minor Milestone: 4.2
Component: User Experience and Interface Version:
Keywords: Cc: eleddy

Description (last modified by aclark) (diff)

Proposer: Alex Clark
Seconder: Elizabeth Leddy

Motivation

After one configures a mail server in Plone, he or she must then add a user (or perform some other task that sends an email) in order to test the mail server. This is silly. Instead, we should have a form that allows one to input an email address and click a button labeled "Test mail server" to test the mail server. This form will: use the configured mail settings to try and send an email to the specified address then return the results: success or failure. This will provide a much more intuitive way to test the mail server settings.

Assumptions

We assume this feature will be universally desired by all users regardless of skill level (i.e. beginners will appreciate the hand holding, power users will appreciate the power.)

Proposal & Implementation

We need to add a form the to the current mail settings control panel (i.e. @@mail-controlpanel). It is expected this will be done via "form tabs" similar to the users/groups control panel (i.e. @@usergroup-userprefs)

We will also need to test the mail server in Python; we plan to set a reasonable socket timeout while waiting for the server to respond.

Deliverables

Primarily we need to edit the controlpanel code: plone/app/controlpanel/mail.py

  • We will not break any existing related tests, and we will add new tests as needed (probably at least one to demonstrate the new functionality.)
  • We will need to handle localization in the same way it is currently handled for fields in the existing mail control panel.
  • We will suggest to the doc team that end user documentation reflect this improvement and/or we are willing to provide additional documentation as needed/requested.

Risks

There is some risk inherent in waiting for a request to be processed by an external service, but it should be mitigate by Python [1]

Participants

Alex Clark [aclark]

Progress

No progress yet (there is no 4.2 buildout yet). But if accepted, work can begin immediately. This is expected to be an 8-16 hour task.

[1] E.g. via graceful handling of errors provided by  http://docs.python.org/library/email.errors.html or something similar.

Attachments

Screen shot 2011-06-14 at 2.44.21 PM.png Download (99.6 KB) - added by aclark 5 years ago.
The existing UI w/form tabs added
Screen shot 2011-06-14 at 2.44.31 PM.png Download (68.7 KB) - added by aclark 5 years ago.
The tab for sending a test mail
Screen shot 2011-06-17 at 8.49.29 PM.png Download (126.9 KB) - added by aclark 5 years ago.
New, simpler UI suggested by elro

Change History

comment:1 Changed 5 years ago by aclark

  • Description modified (diff)

comment:2 Changed 5 years ago by aclark

  • Description modified (diff)

comment:3 Changed 5 years ago by ldr

Is adding a whole fieldset really necessary here, perhaps just a "Send test email" button would suffice?

comment:4 follow-up: ↓ 5 Changed 5 years ago by eleddy

  • Cc eleddy added

this is approved. Can you complete this email by the end of this week?

comment:5 in reply to: ↑ 4 Changed 5 years ago by eleddy

Replying to eleddy:

this is approved. Can you complete this email by the end of this week?

I can't type. I mean complete this IMPLEMENTATION by the end of this week :) We want to hit this cycle

Changed 5 years ago by aclark

The existing UI w/form tabs added

Changed 5 years ago by aclark

The tab for sending a test mail

Changed 5 years ago by aclark

New, simpler UI suggested by elro

comment:6 Changed 5 years ago by aclark

  • Status changed from new to assigned
  • Owner changed from limi to aclark

Ready for review/merge.

comment:7 Changed 5 years ago by ldr

(In [50602]) For testing a mail server you always want immediate=True. Refs #11774.

comment:8 Changed 5 years ago by ldr

Also see [50603] - Better to use a separate try/finally for restoring the default socket timeout.

comment:9 Changed 5 years ago by ldr

(In [50604]) Copy actions from base class instead of duplicating code. Refs #11774.

comment:10 Changed 5 years ago by ldr

(In [50605]) Tidy up imports now code is not duplicated. Refs #11774.

comment:11 Changed 5 years ago by ldr

(In [50606]) Save changes to form before testing. Ensure correct status message is displayed to user. Refs #11774.

comment:12 Changed 5 years ago by ldr

(In [50607]) PLIP review. Refs #11774.

comment:13 Changed 5 years ago by cah190

(In [50791]) PLIP review. Refs #11774

comment:14 Changed 5 years ago by aclark

Feel free to change the message wording. Also, as the PLIP *motivation* suggests, we want this button expressly for the purpose of not having to rely on the contact form, or any other mechanism in Plone that sends e-mail. "Browse to the contact form, or do something else to send mail in Plone" is far less intuitive than "click the test mail button" to test the mail server functionality.

comment:15 Changed 5 years ago by WouterVH

The 7-year old ticket #2444 is set as a duplicate of this one.

comment:16 Changed 5 years ago by esteele

  • Status changed from assigned to closed
  • Resolution set to fixed

(In [51156]) Merge PLIP #11774. Closes #11774.

Note: See TracTickets for help on using tickets.