Bug 139167 - FILESAVE XLSX Extended conditional styles are saved but should not
Summary: FILESAVE XLSX Extended conditional styles are saved but should not
Status: VERIFIED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Calc (show other bugs)
Version:
(earliest affected)
7.2.0.0.alpha0+
Hardware: All All
: medium normal
Assignee: Tibor Nagy (NISZ)
URL:
Whiteboard: target:7.2.0 target:7.1.1
Keywords: bibisected, bisected, filter:xlsx, regression
Depends on:
Blocks: XLSX-Conditional-Formatting
  Show dependency treegraph
 
Reported: 2020-12-22 18:52 UTC by NISZ LibreOffice Team
Modified: 2021-02-08 11:43 UTC (History)
3 users (show)

See Also:
Crash report or crash signature:


Attachments
attachment #152829 saved by Calc (6.35 KB, application/vnd.openxmlformats-officedocument.spreadsheetml.sheet)
2020-12-22 18:52 UTC, NISZ LibreOffice Team
Details
Screenshot of the problem in Calc (113.44 KB, image/png)
2020-12-22 18:53 UTC, NISZ LibreOffice Team
Details

Note You need to log in before you can comment on or make changes to this bug.
Description NISZ LibreOffice Team 2020-12-22 18:52:44 UTC
Created attachment 168423 [details]
attachment #152829 [details] saved by Calc

This is a continuation of bug #122102 

Now Calc started to import a few more condition types, and generates temporary cell styles for them named ExtConditionalStyle_N. This did not happen before that fix, as a quick bibisect shows on the 7.2 repo.

Unlike ConditionalStyle_N styles these get written to XLSX format as cell styles, then upon reopening in Calc a new set of “ExtConditionalStyle_N N” styles gets generated, which are again written to the file upon a next save, making the custom cell styles list grow by each save-reload.

Steps to reproduce:
    1. Open attachment #152829 [details] 
    2. Save as XLSX, reload

Actual results:
Styles sidebar shows 8 ExtConditionalStyle_N styles, of which 4 has the format “ExtConditionalStyle_N 1”

Expected results:
Styles sidebar shows 4 ExtConditionalStyle_N styles

LibreOffice details:
Version: 7.2.0.0.alpha0+ (x64)
Build ID: e57665ea6f812aff9fc87073ce947f40a8b26e9d
CPU threads: 4; OS: Windows 6.3 Build 9600; UI render: default; VCL: win
Locale: hu-HU (hu_HU); UI: en-US
Calc: CL
Comment 1 NISZ LibreOffice Team 2020-12-22 18:53:00 UTC
Created attachment 168424 [details]
Screenshot of the problem in Calc
Comment 2 Xisco Faulí 2020-12-23 09:41:25 UTC
Reproduced in

Version: 7.2.0.0.alpha0+
Build ID: 6156a419a2d3f09d91afd00f84c84ba717442f43
CPU threads: 4; OS: Linux 5.7; UI render: default; VCL: gtk3
Locale: en-US (en_US.UTF-8); UI: en-US
Calc: threaded
Comment 3 Commit Notification 2021-01-26 10:42:01 UTC
Tibor Nagy committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/commit/807a63d66010b1969cfbb61d3609b91909872399

tdf#139167 XLSX export: fix proliferation of conditional styles

It will be available in 7.2.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 4 NISZ LibreOffice Team 2021-02-08 11:40:57 UTC
Verified in
Version: 7.2.0.0.alpha0+ (x64) / LibreOffice Community
Build ID: 44b914b1e2616ca8f70e896e653a46ca93610234
CPU threads: 4; OS: Windows 10.0 Build 17134; UI render: Skia/Raster; VCL: win
Locale: hu-HU (hu_HU); UI: hu-HU
Calc: threaded
Comment 5 Commit Notification 2021-02-08 11:43:02 UTC
Tibor Nagy committed a patch related to this issue.
It has been pushed to "libreoffice-7-1":

https://git.libreoffice.org/core/commit/20ce9f5de3c9d3081d197b0a0138d51d75ae3950

tdf#139167 XLSX export: fix proliferation of conditional styles

It will be available in 7.1.1.

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.