Bug 147921 - Filesave DOC: wrong layout and then all missing from 7.3
Summary: Filesave DOC: wrong layout and then all missing from 7.3
Status: RESOLVED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Writer (show other bugs)
Version:
(earliest affected)
7.3.0.0.alpha1+
Hardware: All All
: medium normal
Assignee: Not Assigned
URL:
Whiteboard: target:7.4.0 target:7.3.3
Keywords: bibisected, bisected, filter:doc, regression
Depends on:
Blocks:
 
Reported: 2022-03-11 11:00 UTC by Timur
Modified: 2022-03-17 14:54 UTC (History)
4 users (show)

See Also:
Crash report or crash signature:


Attachments
Example compared (79.49 KB, image/webp)
2022-03-11 11:00 UTC, Timur
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Timur 2022-03-11 11:00:48 UTC
Created attachment 178810 [details]
Example compared

Save ODT attachment 164488 [details] from bug 135943 as DOC.
Reopen and see empty page in LO and error in MSO.
Regression, but it also wasn't OK before, as seen in screenshot attachment 165228 [details].
Comment 1 Timur 2022-03-11 11:09:22 UTC
Console error: 
measure_conversion.xsl: Find no conversion for  to 'twip'!
 36ce32072658c6ffca75b200f116ddfc11cab138 is the first bad commit
Date:   Tue Jun 22 08:50:00 2021 +0200
    source 990b2cb056788f7f412656a303456d90c003cf83
    previous 949658028e722e5d2657b503eb20e16e41dbd8cf
author	Noel Grandin <noel@peralex.com>	2021-06-21
simplify and improve Wildcard

CC Noel please see how this is related. 
Source not mentioned elsewhere.
Comment 2 Commit Notification 2022-03-12 07:42:14 UTC
Noel Grandin committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/commit/a378ac93e1b4e3c0dacdd3f0a3500813714537c7

tdf#147921 Filesave DOC: wrong layout and then all missing from 7.3

It will be available in 7.4.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 3 Timur 2022-03-14 10:51:53 UTC
Sorry, I don't see a change with updated master, same console error and empty DOC.
Comment 4 Noel Grandin 2022-03-14 11:29:37 UTC
Sorry, no idea, this works fine for me on current master (on Linux), I don't see any console error and the DOC file loads and looks also identical.
Comment 5 Xisco Faulí 2022-03-14 13:34:24 UTC
(In reply to Timur from comment #3)
> Sorry, I don't see a change with updated master, same console error and
> empty DOC.

Hi Timur,
it works fine in

Version: 7.4.0.0.alpha0+ / LibreOffice Community
Build ID: 28f97d8292cb0ac8bf8f328064566353f88224df
CPU threads: 8; OS: Linux 5.10; UI render: default; VCL: gtk3
Locale: es-ES (es_ES.UTF-8); UI: en-US
Calc: threaded

Could you please share the help - about LibreOffice info ?
Comment 6 Xisco Faulí 2022-03-14 14:59:33 UTC Comment hidden (obsolete)
Comment 7 Xisco Faulí 2022-03-14 15:00:32 UTC
(In reply to Xisco Faulí from comment #6)
> OTOH,
> @Timur, could you please attach a screenshot of the problem you see? In my
> case, the page is not empty after RT, even before the fix.

nevermind, I saw it in the left bottom corner of the attached screenshot
Comment 8 Xisco Faulí 2022-03-14 15:02:22 UTC
I can't reproduce the issue on Linux, thus Win only
Comment 9 Timur 2022-03-14 15:52:58 UTC
Version: 7.4.0.0.alpha0+ / LibreOffice Community
Build ID: 89fb3f7e87fd7ab9312bc43dffea842ffc34b140 (of today) 
CPU threads: 4; OS: Linux 5.4; UI render: default; VCL: gtk3

I found the problem. I converted with headless in Linux and it's really empty. 
With GUI all is fine, DOC and DOCX, so bug 135943 seems resolved.
Comment 10 Xisco Faulí 2022-03-14 16:02:20 UTC Comment hidden (no-value)
Comment 11 Xisco Faulí 2022-03-14 16:06:50 UTC
Either way, not reproducible in

Version: 7.4.0.0.alpha0+ / LibreOffice Community
Build ID: 89fb3f7e87fd7ab9312bc43dffea842ffc34b140
CPU threads: 8; OS: Linux 5.10; UI render: default; VCL: gtk3
Locale: es-ES (es_ES.UTF-8); UI: en-US
Calc: threaded

when using "--headless --convert-to doc"
Comment 12 Timur 2022-03-15 10:30:39 UTC
Lin Headless DOC NOK in LO - empty for some, why?, NOK in MSO - cannot open (this bug 147921 ?)
Lin GUI DOC OK in LO, OK in MSO (both resolved in bug 147921)
Win Headless DOC OK in LO, OK in MSO 
Win GUI DOC OK in LO, OK in MSO

Lin Headless DOCX OK in LO (resolved in bug 147921), NOK in MSO - image on the left (bug 135943)
Lin GUI DOCX OK in LO, NOK in MSO - image left, same as headless
Win Headless DOCX OK in LO, NOK in MSO 
Win GUI DOCX OK in LO, NOK in MSO

Note: convert in Windows gives warnings:
warn:sw.core:3736:512:sw/source/core/docnode/node.cxx:1983: Wrong cond collection, skipping check of Cond Colls.

I don't see why I see problem in Lin headless convert that Xisco doesn't see, and that is the only issue left here.
Comment 13 Timur 2022-03-15 10:52:25 UTC
OK, I narrow down problem in headless:
only for "--convert-to doc" and not for "--convert-to doc:"MS Word 97"
But I always use doc because it should be enough, and not doc:"MS Word 97".
Comment 14 Timur 2022-03-15 10:55:11 UTC
This is not general --convert-to issue, but one that started with bibisected commit and still bugged for me.
Comment 15 Xisco Faulí 2022-03-15 10:57:19 UTC
(In reply to Timur from comment #13)
> OK, I narrow down problem in headless:
> only for "--convert-to doc" and not for "--convert-to doc:"MS Word 97"
> But I always use doc because it should be enough, and not doc:"MS Word 97".

I always use '--convert-to doc' as well...
Comment 16 Noel Grandin 2022-03-15 17:35:21 UTC
I dont see problem when using
  --convert-to doc
under Linux, and I don't see any console error about measure_conversion.xsl

I'm guessing you are building with system libs and you have some old version of some XSLT library that is causing a problem.
Comment 17 Timur 2022-03-15 21:36:32 UTC
I'm using bibisect repos in Mint 19 which is Ubuntu 18.04.
But since others don't reproduce, let's close this. 

Noel please comment on backport to 7.3.
Comment 18 Timur 2022-03-16 09:19:55 UTC
Julien, could you please test this headless save. 
I noticed you had once similar error in https://bugs.documentfoundation.org/show_bug.cgi?id=139073#c3.
Comment 19 Commit Notification 2022-03-16 18:27:27 UTC
Noel Grandin committed a patch related to this issue.
It has been pushed to "libreoffice-7-3":

https://git.libreoffice.org/core/commit/a4fb9afedea2efed62880d0b3a7e1c36da58c748

tdf#147921 Filesave DOC: wrong layout and then all missing from 7.3

It will be available in 7.3.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 20 Julien Nabet 2022-03-16 19:20:42 UTC
On pc Debian x86-64 with master sources updated today, I downloaded odt file from comment 1, then did this:
julien@debianamd:~/lo/libreoffice/instdir/program$ ./soffice --convert-to doc /tmp/ABCE.odt 
warn:sw.core:35987:35987:sw/source/core/docnode/node.cxx:1983: Wrong cond collection, skipping check of Cond Colls.
warn:sw.core:35987:35987:sw/source/core/docnode/node.cxx:1983: Wrong cond collection, skipping check of Cond Colls.
warn:sw.core:35987:35987:sw/source/core/docnode/node.cxx:1983: Wrong cond collection, skipping check of Cond Colls.
warn:sw.core:35987:35987:sw/source/core/docnode/node.cxx:1983: Wrong cond collection, skipping check of Cond Colls.
warn:sw.core:35987:35987:sw/source/core/docnode/node.cxx:1983: Wrong cond collection, skipping check of Cond Colls.
warn:sw.core:35987:35987:sw/source/core/docnode/node.cxx:1983: Wrong cond collection, skipping check of Cond Colls.
convert /tmp/ABCE.odt -> /home/julien/lo/libreoffice/instdir/program/ABCE.doc using filter : MS Word 97
warn:vcl.schedule.deinit:35987:35987:vcl/source/app/scheduler.cxx:177: DeInit task: Timer a: 1 p: 1 graphic::Manager maSwapOutTimer 10000ms (0x7fa1fd4c7b38)
warn:vcl.schedule.deinit:35987:35987:vcl/source/app/scheduler.cxx:198: DeInit active tasks: 1 (ignored: 0)

When I opened the file, I got a bunch of console logs but the result was similar to the odt:
julien@debianamd:~/lo/libreoffice/instdir/program$ ./soffice ABCE.doc 
WPSDocument::isFileFormatSupported()
warn:legacy.osl:36178:36178:sw/source/filter/ww8/ww8scan.cxx:1392: Can't create these from the menus, please report
warn:legacy.osl:36178:36178:sw/source/filter/ww8/ww8scan.cxx:1392: Can't create these from the menus, please report
warn:legacy.osl:36178:36178:sw/source/filter/ww8/ww8scan.cxx:1392: Can't create these from the menus, please report
warn:legacy.osl:36178:36178:sw/source/filter/ww8/ww8scan.cxx:1392: Can't create these from the menus, please report
warn:legacy.osl:36178:36178:sw/source/filter/ww8/ww8scan.cxx:1392: Can't create these from the menus, please report
warn:legacy.osl:36178:36178:sw/source/filter/ww8/ww8scan.cxx:1392: Can't create these from the menus, please report
warn:legacy.osl:36178:36178:sw/source/filter/ww8/ww8scan.cxx:1392: Can't create these from the menus, please report
warn:legacy.osl:36178:36178:sw/source/filter/ww8/ww8scan.cxx:1392: Can't create these from the menus, please report
warn:legacy.osl:36178:36178:sw/source/filter/ww8/ww8scan.cxx:1392: Can't create these from the menus, please report
warn:legacy.osl:36178:36178:sw/source/filter/ww8/ww8scan.cxx:1392: Can't create these from the menus, please report
warn:filter.ms:36178:36178:filter/source/msfilter/msdffimp.cxx:6306: remaining record longer than available data, ppt or parser is wrong
warn:legacy.osl:36178:36178:sw/source/filter/ww8/ww8scan.cxx:1392: Can't create these from the menus, please report
warn:legacy.osl:36178:36178:sw/source/filter/ww8/ww8scan.cxx:1392: Can't create these from the menus, please report
warn:legacy.osl:36178:36178:sw/source/filter/ww8/ww8scan.cxx:1392: Can't create these from the menus, please report
warn:legacy.osl:36178:36178:sw/source/filter/ww8/ww8scan.cxx:1392: Can't create these from the menus, please report
warn:legacy.osl:36178:36178:sw/source/filter/ww8/ww8scan.cxx:1392: Can't create these from the menus, please report
warn:legacy.osl:36178:36178:sw/source/filter/ww8/ww8scan.cxx:1392: Can't create these from the menus, please report
warn:legacy.osl:36178:36178:sw/source/filter/ww8/ww8scan.cxx:1392: Can't create these from the menus, please report
warn:legacy.osl:36178:36178:sw/source/filter/ww8/ww8scan.cxx:1392: Can't create these from the menus, please report
warn:legacy.osl:36178:36178:sw/source/filter/ww8/ww8scan.cxx:1392: Can't create these from the menus, please report
warn:legacy.osl:36178:36178:sw/source/filter/ww8/ww8scan.cxx:1392: Can't create these from the menus, please report
warn:legacy.osl:36178:36178:sw/source/filter/ww8/ww8scan.cxx:1392: Can't create these from the menus, please report
warn:legacy.osl:36178:36178:sw/source/filter/ww8/ww8scan.cxx:1392: Can't create these from the menus, please report
warn:legacy.osl:36178:36178:sw/source/filter/ww8/ww8scan.cxx:1392: Can't create these from the menus, please report
warn:legacy.osl:36178:36178:sw/source/filter/ww8/ww8scan.cxx:1392: Can't create these from the menus, please report
warn:legacy.osl:36178:36178:sw/source/filter/ww8/ww8scan.cxx:1392: Can't create these from the menus, please report
warn:legacy.osl:36178:36178:sw/source/filter/ww8/ww8scan.cxx:1392: Can't create these from the menus, please report
Comment 21 Timur 2022-03-17 14:54:10 UTC
(In reply to Timur from comment #1)
> Console error: 
> measure_conversion.xsl: Find no conversion for  to 'twip'!

(In reply to Timur from comment #13)
> OK, I narrow down problem in headless:
> only for "--convert-to doc" and not for "--convert-to doc:"MS Word 97"

I found more. With "--convert-to doc" it somehow converts using filter : MS Word 2003 XML while it should be using filter : MS Word 97.