Bug 150334 - Libre Office crashed whilst trying to send an email using Writer's Mail Merge facility
Summary: Libre Office crashed whilst trying to send an email using Writer's Mail Merge...
Status: RESOLVED WORKSFORME
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Writer (show other bugs)
Version:
(earliest affected)
unspecified
Hardware: x86 (IA32) Windows (All)
: medium normal
Assignee: Not Assigned
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2022-08-10 17:46 UTC by Laurie Spragg
Modified: 2023-02-27 15:52 UTC (History)
3 users (show)

See Also:
Crash report or crash signature:


Attachments
Screen shot of error messages (890.96 KB, image/png)
2022-08-13 09:33 UTC, Laurie Spragg
Details
Last message before crash (34.49 KB, image/png)
2023-02-25 12:46 UTC, Klaus
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Laurie Spragg 2022-08-10 17:46:30 UTC
Description:
I created my first email using LibreOffice Writer. I opened Libre Mail Merge Wizard, and tried sending the email to a list of seven email messages (as a test) that I had set up in LibreOffice Calc, with 'Email' being in cell A1, and my list of emails in A2 to A8.  Everything seemed to be going along smoothly, until I went to 'Send Documents', and then LibreOffice crashed.

LibreOffice 7.3 Document Recovery
Due to an error, LibreOffice crashed. All the files you were working on will now be saved. The next time .................. etc


Steps to Reproduce:
1. Create an email on LibreOffice Writer, then click on Tools / Mail Merge Wizard
2. Tick ‘Use the current document’, and click ‘Next’
3. Tick ‘Email message’, and click ‘Next’
4. Click ‘Select Address List’
5. Click ‘Add’, chose the LibreOffice Calc worksheet holding the list of email addresses, and click ‘OK’
6. When presented with the ‘Insert Address Block’ mini-screen, click ‘Next’
7. Choose ‘Hello’ as the ‘General salutation’, and click ‘Next’
8. When ‘Adjust Layout of Address Block and Salutation’ appears, move the Salutation Position to the top of the email (surely that should be the default), and click ‘Finish’
9. Click on the icon Send Email Messages, enter a subject, and click on ‘Send Documents’

Actual Results:
LibreOffice crashed

Expected Results:
LibreOffice Writer mail merge wizard to have circulated my emails


Reproducible: Always


User Profile Reset: No



Additional Info:
I am using a Lenovo Ideal pad 310 running Windows 10

Not sure which hardware I am using (X86 IA32 or X86-AMD64), or which 'version'
Comment 1 Roman Kuznetsov 2022-08-12 19:17:19 UTC
no repro in

Version: 7.5.0.0.alpha0+ / LibreOffice Community
Build ID: d75c5c1f61a174b3b333e9db6536ab15cc37d00b
CPU threads: 4; OS: Mac OS X 12.5; UI render: Skia/Metal; VCL: osx
Locale: ru-RU (ru_RU.UTF-8); UI: en-US
Calc: threaded Jumbo


Please write here an info from your LibreOffice's Help-About dialog (use Copy button there)
Comment 2 Laurie Spragg 2022-08-13 09:33:29 UTC
Created attachment 181755 [details]
Screen shot of error messages

These error messages appeared after I had clicked on 'Send Documents'
Comment 3 QA Administrators 2022-08-14 04:12:16 UTC Comment hidden (obsolete)
Comment 4 Timur 2022-08-14 09:27:17 UTC
This may be a duplicate of bug 150188. 
To be sure, please do 2 things:
1. rename LO user profile folder, so that new folder is created, as indicated in report form with "user profile reset" 
2. if still crashes, please test with LO daily master that installs separately to your working LO and doesn't take extensions. 

Bug is not generally reproducible and even not in LO 7.4 and master 7.5+ for those who see it with 7.3.
Comment 5 QA Administrators 2023-02-11 03:24:08 UTC Comment hidden (obsolete)
Comment 6 Klaus 2023-02-25 12:46:25 UTC
Created attachment 185582 [details]
Last message before crash

I get here the same results.
Version: 7.3.7.2 / LibreOffice Community
Build ID: 30(Build:2)
CPU threads: 8; OS: Linux 5.19; UI render: default; VCL: gtk3
Locale: de-DE (de_DE.UTF-8); UI: de-DE
Ubuntu package version: 1:7.3.7-0ubuntu0.22.04.1
Calc: threaded
Comment 7 Klaus 2023-02-25 14:20:31 UTC
1. Create new document -> Insert -> Field command -> More field commands
2. Add database -> Browse -> Calc-table.odt -> Table -> Mail merge fields
3. Click on field name -> Insert
4. -> Close
5. Tools -> Mail Merge Wizard
6. -> To: -> Choose address field from the database with the pulldown menu
7. -> Subject: Enter subject if necessary
8. -> Send as: Select format (here: PDF document) -> Properties
9. -> Send documents -> Crash

Of particular interest is the text regarding the transfer status: "0 of 2 sent" and at the same time "Unsent emails: 0" (sic!) By the way, "Details" cannot be opened!
Comment 8 Roman Kuznetsov 2023-02-25 14:38:49 UTC
(In reply to Klaus from comment #6)
> Created attachment 185582 [details]
> Last message before crash
> 
> I get here the same results.
> Version: 7.3.7.2 / LibreOffice Community
> Build ID: 30(Build:2)
> CPU threads: 8; OS: Linux 5.19; UI render: default; VCL: gtk3
> Locale: de-DE (de_DE.UTF-8); UI: de-DE
> Ubuntu package version: 1:7.3.7-0ubuntu0.22.04.1
> Calc: threaded

Klaus, could you please retest it in 7.5 version?
Comment 9 Klaus 2023-02-25 15:41:45 UTC
The test of mail-settings show OK

On send I get the following error:

<class 'smtplib.SMTPSenderRefused'>: (530, b'5.7.0 Authentication Required. Learn more at\n5.7.0  https://support.google.com/mail/?p=WantAuthError fm16-20020a05600c0c1000b003dd1bd0b915sm6639753wmb.22 - gsmtp', 'Klaus.Bogotz@gr7.org'), traceback follows
  File "/usr/lib/libreoffice/program/mailmerge.py", line 262, in sendMailMessage
    self.server.sendmail(sendermail, truerecipients, msg.as_string())
  File "/usr/lib/python3.10/smtplib.py", line 887, in sendmail
    raise SMTPSenderRefused(code, resp, from_addr)

In Thunderbird my authentication settings are OAuth2. Could this be the problem?
Comment 10 Klaus 2023-02-25 16:07:25 UTC
There should probably be an authentification option for OAuth2 in writer smpt configuration.
(by the way how can I edit my posts?)
Comment 11 Klaus 2023-02-25 16:18:55 UTC Comment hidden (obsolete)
Comment 12 Klaus 2023-02-27 15:26:03 UTC
I have now tested the serial mail dispatch with LO V 7.5. Writer no longer crashes and the mails are obviously processed, but the sending stops with an error message (see above). After reading the error message carefully, my suspicions were confirmed. Gmail no longer accepts authorisation with password only. Unfortunately, the option "less-secure access" is no longer available in Google Mail. So I can only access Thunderbird either via OAuth2 or with 2-factor authentication. I assume that this also applies with Writers mail client. So it is clear that sending serial mail with Writer will not work even in version 7.5 as long as the mail client does not handle OAuth, at least with G-Mail. I would be really grateful if someone could try this under the same conditions to verify my hypothesis, or with a mailer that does not require this authentication.

Translated with www.DeepL.com/Translator (free version)
Comment 13 Roman Kuznetsov 2023-02-27 15:52:35 UTC
So, let's close this one as WFM because there is no crash today.

Klaus, please create a new bug report about OAuth2/Gmail problem in mail merge. And thank you so much for (re)testing.