Bug 120660 - cells not recalculated after copy/paste different range of cells
Summary: cells not recalculated after copy/paste different range of cells
Status: VERIFIED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Calc (show other bugs)
Version:
(earliest affected)
4.4 all versions
Hardware: All All
: medium normal
Assignee: Dennis Francis
URL:
Whiteboard: target:6.3.0 target:6.2.3 target:7.2.0
Keywords: bibisected, bisected, regression
Depends on:
Blocks: Calculate
  Show dependency treegraph
 
Reported: 2018-10-17 14:35 UTC by Xisco Faulí
Modified: 2021-01-21 08:31 UTC (History)
7 users (show)

See Also:
Crash report or crash signature:


Attachments
no recalculation even when changing formula (71.08 KB, image/png)
2018-10-17 15:05 UTC, Xavier Van Wijmeersch
Details
new test (13.35 KB, application/vnd.oasis.opendocument.spreadsheet)
2018-10-17 17:17 UTC, Xavier Van Wijmeersch
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Xisco Faulí 2018-10-17 14:35:14 UTC
Steps to reproduce:
1. Open attachment 145073 [details] from bug 120013
2. Copy A8:E8 to A4 -> It's recalculated
3. Undo -> it's recalculated
4. Copy A8:D8 to A4 -> it's not recalculated
4. Undo -> it's not recalculated

Reproduced in

Version: 6.2.0.0.alpha0+
Build ID: 49c87270f7176312806d1759967c247a312f0acf
CPU threads: 4; OS: Linux 4.15; UI render: default; VCL: gtk3; 
Locale: ca-ES (ca_ES.UTF-8); Calc: threaded
Comment 1 Xisco Faulí 2018-10-17 14:40:08 UTC
This worked fine until

author	Kohei Yoshida <kohei.yoshida@collabora.com>	2014-11-17 17:37:07 -0500
committer	Kohei Yoshida <kohei.yoshida@collabora.com>	2014-11-18 08:31:57 -0500
commit 6b4e767cf90e4f384a6b3dd43aa51c09b500b97b (patch)
tree a9a06d522bab185c7df24a6958daf9e59dbefa6a
parent 627bfb4e664a3fde23c06aa4dd0809de84ec97c5 (diff)
Use group-area listeners during copy & paste if we can.

Bisected with: bibisect-44max

Adding Cc: to Kohei Yoshida

when it was no longer recalculated after undoing the first paste. Later ( in 5.1 repo which I don't have ) the undo recalculation was fixed but not step 4 and 5
Comment 2 Xisco Faulí 2018-10-17 14:40:39 UTC
@Eike, I thought you could be interested in this issue...
Comment 3 Xavier Van Wijmeersch 2018-10-17 15:04:38 UTC
Even changing the formula to =IF(OR(C3>0;D3>0);SUM(C$3:C3)-SUM(D$3:D3);"") for the cells E4:E8 it wont recalculate from step 4 to step 5 in description

Version: 6.2.0.0.alpha0+
Build ID: ccb2a1f650bc505f8a4f1abebf8ce4f9396562a8
CPU threads: 8; OS: Linux 4.14; UI render: default; VCL: kde4; 
Locale: nl-BE (en_US.UTF-8); Calc: threaded
Comment 4 Xavier Van Wijmeersch 2018-10-17 15:05:35 UTC
Created attachment 145783 [details]
no recalculation even when changing formula
Comment 5 Xavier Van Wijmeersch 2018-10-17 17:17:03 UTC
Created attachment 145787 [details]
new test

I hope new test file will help
did follow steps from 1 to 5

Version: 6.2.0.0.alpha0+
Build ID: ccb2a1f650bc505f8a4f1abebf8ce4f9396562a8
CPU threads: 8; OS: Linux 4.14; UI render: default; VCL: kde4; 
Locale: nl-BE (en_US.UTF-8); Calc: threaded
Comment 6 b. 2019-02-27 17:14:22 UTC
pls. check the following: 

while cells in D4:D12 are clean copys of D3 - just copy D3 over the range - column D works fine on moving around and changing the values to be calculated, 

once you edit the formula in any of these copied cells (may be they form something like a 'shared formula group'?) autocalculate is broken for some or all of the others, 

same for col. E, 

if you find that happen the bug might likely be a facet of tdf#123736

what's driving me nuts on this bug ... no differences in the cells or formulas are apparent to the user, but cells work dramatically different while their copies are untouched - correct, or when they get the 'stamp' 'a copy of mine has been altered' - they become excluded from autocalculate, 

it's not relevant how you copy the source formula, dragging works as well as ctrl-c ctrl-v on the range or individual cells sequentially, when you copy them 'chaotic' (not below or above another but with spaces) the bug doesn't occur ...
Comment 7 Oliver Brinzing 2019-03-09 14:31:20 UTC
the scenario mentioned in Comment 1 is still repoducible with:

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

Steps to reproduce:
1. Open attachment 145073 [details] from bug 120013
   -> Note that the sample document is stored with wrong result values in 
      E9:E12, which needs a hard recalc Shift+Ctrl+F9 before trying things.
2. Copy A8:E8 to A4 -> It's recalculated
3. Undo -> it's recalculated
4. Copy A8:D8 to A4 -> it's not recalculated
4. Undo -> it's not recalculated
Comment 8 Oliver Brinzing 2019-03-15 19:41:19 UTC
reproducible with:

Version: 6.3.0.0.alpha0+ (x64)
Build ID: 3140194a85fe4a6ac69c8cddc4d3b019430cd6e8
CPU threads: 4; OS: Windows 10.0; UI render: default; VCL: win; 
Locale: de-DE (de_DE); UI-Language: en-US
Calc: threaded
Comment 9 Dennis Francis 2019-03-27 08:58:45 UTC
Patch submitted to gerrit for review : https://gerrit.libreoffice.org/69737
Comment 10 Commit Notification 2019-03-28 21:44:23 UTC
Dennis Francis committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/+/e7d0785a7d2a07e64dc58dee4f1b072a72e32aa5%5E%21

tdf#120660: Populate rNewSharedRows even if no FC...

It will be available in 6.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 11 Commit Notification 2019-03-29 10:42:05 UTC
Dennis Francis committed a patch related to this issue.
It has been pushed to "libreoffice-6-2":

https://git.libreoffice.org/core/+/75571c296198dcc23f1c15887035bed5bfdc3863%5E%21

tdf#120660: Populate rNewSharedRows even if no FC...

It will be available in 6.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 12 Xisco Faulí 2019-04-01 13:29:01 UTC
Issue verified in

Version: 6.3.0.0.alpha0+
Build ID: d31d77b7199ecc9a7edc899d9703e9da52d5cbd1
CPU threads: 1; OS: Windows 6.1; UI render: default; VCL: win; 
TinderBox: Win-x86@42, Branch:master, Time: 2019-04-01_00:04:09
Locale: es-ES (es_ES); UI-Language: en-US
Calc: threaded

@Dennis Francis, thanks for fixing this issue!!
Comment 13 Commit Notification 2019-04-22 18:52:01 UTC
Zdeněk Crhonek committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/+/cd4d6187a24119cb4954ec10539902c2aa120c0f%5E%21

uitest for bug tdf#120660

It will be available in 6.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 14 Commit Notification 2021-01-21 08:31:28 UTC
Xisco Fauli committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/commit/47966dfb6ddab661f93d63be6eb34ef00e24ac90

tdf#120660: sc: Move UItest to CppUnitTest

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.