Bug 119206 - Freeze if Option “Edit document properties before saving” is Enabled
Summary: Freeze if Option “Edit document properties before saving” is Enabled
Status: RESOLVED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: LibreOffice (show other bugs)
Version:
(earliest affected)
6.1.0.0.alpha0+
Hardware: All All
: high major
Assignee: Caolán McNamara
URL:
Whiteboard: target:7.3.0 target:7.2.3
Keywords: bibisected, bisected, regression
Depends on:
Blocks: Save File-Properties Regressions-Dialog-Tunneling
  Show dependency treegraph
 
Reported: 2018-08-10 19:40 UTC by Harald Koester
Modified: 2021-11-04 12:18 UTC (History)
8 users (show)

See Also:
Crash report or crash signature:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Harald Koester 2018-08-10 19:40:50 UTC
In order to reproduce:

[1] I used a new user profile. Therefor rename or delete existing user profile.
[2] Start LibreOffice and enable option “Edit document properties before saving”: Extras > Options... > Load/Save > General. Click option and then “OK”.
[3] Open new text document and insert a bit of text.
[4] Close and save document:
(a) Menu: File > Close. Dialogue “Save Document?” is displayed
(b) Click “Save” and insert file name. Then “Save”. The Document Properties dialogue is displayed for a moment. Then the Start Centre is displayed, but it is freezed. An operation is no longer possible. You have to cancel LibreOffice with the Task Manager. Expected: No freeze.
[5] Start LibreOffice again. A recovery process is not performed.

Works for me with version 6.0.6. Hence regression.
Comment 1 Xisco Faulí 2018-08-15 11:07:00 UTC
Reproduced in

Version: 6.2.0.0.alpha0+
Build ID: 18e20676024baecaf5719139f80f053f5f1e784a
CPU threads: 4; OS: Linux 4.15; UI render: default; VCL: gtk3; 
Locale: ca-ES (ca_ES.UTF-8); Calc: threaded
Comment 2 Xisco Faulí 2018-08-15 11:46:21 UTC
Regression introduced by:

https://cgit.freedesktop.org/libreoffice/core/commit/?id=0950917b9514069e8dbf92b9c0fbd44b492a7cd1

author	Henry Castro <hcastro@collabora.com>	2018-03-01 16:11:44 -0400
committer	Henry Castro <hcastro@collabora.com>	2018-03-02 19:55:01 +0100
commit 0950917b9514069e8dbf92b9c0fbd44b492a7cd1 (patch)
tree fa450d498c714295791e2f0a29d1bce87a52dd4e
parent e802e960f8f7343eec1a14eba70b7affc6298968 (diff)
lokdialog: convert the dialog File -> Properties... to async exec

Bisected with: bibisect-win32-6.1

Adding Cc: to Henry Castro
Comment 3 Harald Koester 2019-03-08 20:23:26 UTC
Bug still exists in version 6.2.1 (64 bit) with Win10.
Comment 4 Oliver Brinzing 2020-01-26 12:28:20 UTC
reproducible with:

Version: 7.0.0.0.alpha0+ (x64)
Build ID: a6192281a04c20bc57b1ffa4f6645ca639d5b1a4
CPU threads: 4; OS: Windows 10.0 Build 18363; UI render: default; VCL: win; 
Locale: de-DE (de_DE); UI-Language: en-US
Calc: threaded

crashes with an unsatisfied query for interface of type
com.sun.star.document.XDocumentPropertiesSupplier

I guess, the root cause for this bug, is that the document is already closed.
Comment 5 Justin L 2021-01-14 11:25:19 UTC
repro 7.2+
Why hasn't Collabora responded at all to this crash report?
Comment 6 Justin L 2021-01-16 07:49:03 UTC
A proof of concept patch is at http://gerrit.libreoffice.org/c/core/+/109412
Comment 7 Xisco Faulí 2021-01-16 13:31:07 UTC Comment hidden (obsolete)
Comment 8 Justin L 2021-01-16 14:22:08 UTC
OK - but note that I have already asked Ashod to review and he is a pretty heavy hitter all by himself.
Comment 9 Justin L 2021-03-03 14:52:14 UTC
(In reply to Xisco Faulí from comment #7)
> I'm adding Caolán to the loop. He fixed some async dialog issues in the past
Still no useful response from Collabora one month later, so Caolán won't be stepping on anyone's toes if he decides to become interested.

I abandoned my PoC, and will only be an interested observer on the sidelines.
Comment 10 Justin L 2021-10-14 11:59:31 UTC
still repro 7.3+.
Comment 11 Xisco Faulí 2021-10-14 18:58:21 UTC
Hi Caolán,
Since you fixed bug 120343, I thought you might be interested in this issue
Comment 12 Justin L 2021-10-20 07:08:37 UTC
fallback proposal to just ignore the doc properties request is at http://gerrit.libreoffice.org/c/core/+/123870 tdf#119206
Comment 13 Caolán McNamara 2021-11-02 15:00:35 UTC
I think on the close path that running this async can't really be made work without way way more work than anyone is going to put in.

So I'll take this and...

undo fix for tdf#120343 and undo fix for tdf#117895 and instead rearrange things to that file, properties continues to be run async, but when the properties dialog is launched from close its run sync
Comment 14 Commit Notification 2021-11-02 17:31:58 UTC
Caolán McNamara committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/commit/39994c43bf6610f2a8fde55f54ed9a7e279935b4

Resolves: tdf#119206 run properties sync when launched during save

It will be available in 7.3.0.

The patch should be included in the daily builds available at
https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
https://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 15 Caolán McNamara 2021-11-02 18:51:03 UTC
well, that should make it not fail horribly.
Comment 16 Commit Notification 2021-11-03 13:36:48 UTC
Caolán McNamara committed a patch related to this issue.
It has been pushed to "libreoffice-7-2":

https://git.libreoffice.org/core/commit/9e52f282200dd3cd02fe3aa1b5566f16a470f7e9

Resolves: tdf#119206 run properties sync when launched during save

It will be available in 7.2.3.

The patch should be included in the daily builds available at
https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
https://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 17 Commit Notification 2021-11-04 12:18:55 UTC
Xisco Fauli committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/commit/01cbdcc6dd0cf575997e9899496115ac41ab4be1

tdf#119206: sw: Add UItest

It will be available in 7.3.0.

The patch should be included in the daily builds available at
https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
https://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.