Bug 284685

Summary: korganizer-generated mails cannot be sent
Product: [Applications] korganizer Reporter: Gunter Ohrner <kdebugs>
Component: generalAssignee: kdepim bugs <kdepim-bugs>
Status: RESOLVED FIXED    
Severity: normal CC: aldebarab, divan, johann-nikolaus, montel
Priority: NOR    
Version: 4.7   
Target Milestone: ---   
Platform: Ubuntu   
OS: Linux   
Latest Commit: Version Fixed In: 4.8.1
Sentry Crash Report:
Attachments: Adress-selection dialog after right-clicking an event, selecting "Send as iCal" and selection an address from the address book.
Error-notification popping up shortly after confirmation of the address selection dialog.
Folder view with the iCal-message stuck in the outbox. If I now select the outbox, the mail will be silently deleted without asking for confirmation.
Stuck mail with error message. Curiously, it was not deleted this time when opening the outbox.

Description Gunter Ohrner 2011-10-22 10:04:51 UTC
Version:           4.7 (using KDE 4.7.2) 
OS:                Linux

Sounds strange and probably is:

Mails generated by korganizer, eg. invitations or confirmations cannot be sent if the receipient address line contains a real name besides the email address. They get stuck in kmail2's out folder with the following error message:

Fehler beim Übertragen der Nachricht. Mailversand fehlgeschlagen, da die folgende Empfängeradresse vom Server abgelehnt wurde: Gunter Ohrner <gunter@ohrner.net> (Meldung des Servers: <Gunter Ohrner <gunter@ohrner.net>>: "@" or "." expected after "Gunter")

The mail itself however looks fine (mail source code), and actually double-clicking and re-sending it suffices to get it out.

Reproducible: Always

Steps to Reproduce:
Right click a calendar entry, "Send as iCal", select a receipient from the address book such that "Name" and "eMail" are correctly filled, click "ok".

Actual Results:  
The above-mentioned error message will occur and the message will be stuck in kmails output folder.


Expected Results:  
The mail is sent successfully.

The configured MTA is exim4 which works fine since ages and also works fine with other mails generated by this kmail2 installation.

Sending an event works if no "Name" is entered, ie. the email address only.
Comment 1 Johann-Nikolaus Andreae 2011-12-24 12:43:21 UTC
Still happend with 4.8 beta 2.
Comment 2 aldebarab 2012-01-17 23:10:29 UTC
This seems to be related to Bug 283821 (http://bugs.kde.org/show_bug.cgi?id=283821)
Comment 3 Divan Santana 2012-01-20 03:30:30 UTC
I can confirm this.
Comment 4 Laurent Montel 2012-01-20 10:34:47 UTC
Fixed in 4.8
Comment 5 Gunter Ohrner 2012-01-27 19:56:36 UTC
Nope, unfortunately it does not seem to be fixed:

*********
Fehler beim Übertragen der Nachricht. Mailversand fehlgeschlagen, da die folgende Empfängeradresse vom Server abgelehnt wurde: Gunter Ohrner <gunter@ohrner.net> (Meldung des Servers: <Gunter Ohrner <gunter@ohrner.net>>: "@" or "." expected after "Gunter")
*********

KMail
Version 4.8.0
Unter KDE 4.8.00 (4.8.0

KOrganizer
Version 4.8.0- ()
Unter KDE 4.8.00 (4.8.0
Comment 6 Gunter Ohrner 2012-01-27 19:58:33 UTC
What I did: Right-click an event in KOrganizer, select "Send as iCal", select my own address from the address book, and confirm.

(And I forgot to disguise the address in my comment, yuck... Well, let's collect some spam then...)
Comment 7 Laurent Montel 2012-01-31 14:30:55 UTC
How do you write you email ? from hand ?
Because from addressbook it's parse correctly and we can't add it as we show in your error.
Comment 8 Gunter Ohrner 2012-01-31 23:44:21 UTC
No, testcase 1:

1) Right-click appointment in kOrganizer.
2) Select "Send as iCalendar"
3) Click the button "Select"
4) A window will open showing the address book contents.
   Select an entry from this addressbook.
   The name will be shown in the "Name" field and the eMail address will be
   shown in the "e-Mail" field.
5) Click the "Ok"-button.
6) kMail will show an error window in the KDE notification area and the message 
   will be stuck in the outbox.

Testcase 2:

1) Right-click appointment in kOrganizer.
2) Select "Edit"
3) Select the "Participants" tab.
4) Click the "Select participant"-button.
5) A window will open showing the address book contents.
   Select an entry from this addressbook.
   The participant will be added to the list.
6) Click the "Ok"-button.
7) Click "Send Updates" in the dialog box which appears.
8) kMail will show an error window in the KDE notification area and the message 
   will be stuck in the outbox.
Comment 9 Gunter Ohrner 2012-01-31 23:51:24 UTC
Addendum:

What did work before was
1) to switch to the outbox with the stuck mails,
2) open a mail by double-clicking it,
3) and just pressing the "Send"-button again.
   kMail would then somehow reformat the mail slightly, or so it seemed at
   least, and the mail would be send.
4) Proceed the same with with the next stuck mail until all mails are sent.

Now with kMail 4.8.0, it seems as if I manually enter the outbox, the stuck mails simply disappear. According to the mailserver's logs, there's no additional try to send them, but the mails are gone afterwards. Strange...
Comment 10 Laurent Montel 2012-02-01 08:09:57 UTC
comment8: screenshot please (in private if you want) you selected dialogbox with your email, and screenshot of error in send mail folder (select it and we will see the error message). Thanks.
Comment 11 Laurent Montel 2012-02-03 09:00:19 UTC
wait for infos
Comment 12 Laurent Montel 2012-02-04 08:37:52 UTC
As see in screenshot it's not the same error.
I close it
Comment 13 Gunter Ohrner 2012-02-05 15:42:33 UTC
Mh, what screenshot are you referring to? I did not attach any so far, as I only had time to make the screenshots a few minutes ago. As you can see, the displayed error message is exactly the message I wrote in my original report.

Unfortunately, I cannot show the error message if I select the mail in the outbox, as this mail just disappears when I open the outbox since KDE 4.8.0. (Data loss / message is lost.)

This did not happen with KDE 4.7.x, there the message was preserved and after opening it, the error message had been displayed at the top of the message window.
Comment 14 Gunter Ohrner 2012-02-05 15:43:51 UTC
Created attachment 68528 [details]
Adress-selection dialog after right-clicking an event, selecting "Send as iCal" and selection an address from the address book.
Comment 15 Gunter Ohrner 2012-02-05 15:44:39 UTC
Created attachment 68529 [details]
Error-notification popping up shortly after confirmation of the address selection dialog.
Comment 16 Gunter Ohrner 2012-02-05 15:46:05 UTC
Created attachment 68530 [details]
Folder view with the iCal-message stuck in the outbox. If I now select the outbox, the mail will be silently deleted without asking for confirmation.
Comment 17 Gunter Ohrner 2012-02-05 18:03:29 UTC
Created attachment 68535 [details]
Stuck mail with error message. Curiously, it was not deleted this time when opening the outbox.

From the kMail about dialog:

KMail
Version 4.8.0
Unter KDE 4.8.00 (4.8.0

From the KDE about dialog:

KDE – Frei sein!
Plattform-Version 4.8.00 (4.8.0
Comment 18 Laurent Montel 2012-02-06 10:57:18 UTC
Git commit b55df6bf09510a0d0eb6d7b40ff3c3717dd077e2 by Montel Laurent.
Committed on 06/02/2012 at 11:56.
Pushed by mlaurent into branch 'master'.

Fix Bug 284685 - korganizer-generated mails cannot be sent

FIXED-IN: 4.8.1

M  +17   -3    calendarsupport/mailclient.cpp

http://commits.kde.org/kdepim/b55df6bf09510a0d0eb6d7b40ff3c3717dd077e2
Comment 19 Laurent Montel 2012-02-06 11:00:17 UTC
Git commit 10a7a626e1b8f652734e8cc02387557ec847aa61 by Montel Laurent.
Committed on 06/02/2012 at 11:56.
Pushed by mlaurent into branch 'KDE/4.8'.

Fix Bug 284685 - korganizer-generated mails cannot be sent

FIXED-IN: 4.8.1
(cherry picked from commit b55df6bf09510a0d0eb6d7b40ff3c3717dd077e2)

Conflicts:

	calendarsupport/mailclient.cpp

M  +18   -4    calendarsupport/mailclient.cpp

http://commits.kde.org/kdepim/10a7a626e1b8f652734e8cc02387557ec847aa61