Bug 124948 - Calc EDITING: Frequent "Fatal Error: Invalid child index" while editing long multi-line comments in cells crashing LibreOffice Calc
Summary: Calc EDITING: Frequent "Fatal Error: Invalid child index" while editing long ...
Status: NEW
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Calc (show other bugs)
Version:
(earliest affected)
6.2.0.3 release
Hardware: All macOS (All)
: medium normal
Assignee: Not Assigned
URL:
Whiteboard:
Keywords:
: 124949 (view as bug list)
Depends on:
Blocks: Calc-Comments Crash
  Show dependency treegraph
 
Reported: 2019-04-25 09:37 UTC by t0rt1e
Modified: 2024-02-23 03:14 UTC (History)
3 users (show)

See Also:
Crash report or crash signature:


Attachments
Anonymised generic grades table as test case (15.90 KB, application/vnd.oasis.opendocument.spreadsheet)
2019-05-10 12:17 UTC, t0rt1e
Details
screenshot from the website (1.12 MB, image/png)
2022-02-22 12:59 UTC, tymcik
Details

Note You need to log in before you can comment on or make changes to this bug.
Description t0rt1e 2019-04-25 09:37:51 UTC
Description:
I have a table in a LibreOffice Calc document, which calculates the final grade and some statistics for student projects of a course I give. Besides the points, there is a column for comments, in which I note down my observations of the work of the individual groups. Each cell in the column holds typically a multi-line text, where the first character of each line is either '+' (positive), '-' (negative), or '*' (neutral) followed by a short note text. I enter this text live during the project presentation so that the current cell is in mode editing for several minutes. This has been working fine for me since 2015 and LibreOffice Calc would run reliably without crashes as far as I can remember.

Since LibreOffice 6.2.0.3, I am observing frequent crashes (approx. 3 to 5 times per 90 minute session) while editing these multi-line comments. The comment cells have no particular assigned cell format. However, it may be relevant for the bug to trigger, that I copy the multi-line comment using a formula to other lines of the comment column using a cell formula, e.g., "=G6". The error message preceding the crash is always the same "Fatal Error: Invalid child index". After confirming it, LibreOffice Calc crashes and needs to be restarted. The file recovery succeeded so far each time, however entered comments were losts: at least the one I was actively editing and sometimes also previously edited comments (depending on the last moment of saving the document).

So far, I was able to reproduce this error on LibreOffice 6.2.0.3 as well as 6.2.2.2, which were always running on macOS High Sierra 10.13.16 of a MacBook Pro 15 inch 2017 model.

Steps to Reproduce:
1. Repeatedly edit multi-line comments, where the lines start with '+', '-', or '*'
2. Have these comments copied to other cells using a cell formula, e.g., "=G6"
3. Don't assign any particular cell format such as "Text"

Actual Results:
Application crashes while editing multi-line comments containing characters, which may be treated as mathematical operators

Expected Results:
Application does not crash due to editing multi-line comments containing characters, which may be treated as mathematical operators


Reproducible: Always


User Profile Reset: No



Additional Info:
Version: 6.2.2.2
Build-ID: 2b840030fec2aae0fd2658d8d4f9548af4e3518d
CPU-Threads: 8; BS: Mac OS X 10.13.6; UI-Render: Standard; VCL: osx; 
Gebietsschema: de-CH (de_CH.UTF-8); UI-Sprache: de-DE
Calc: threaded
Comment 1 Xisco Faulí 2019-04-25 10:05:22 UTC
Thank you for reporting the bug. Please attach a sample document, as this makes it easier for us to verify the bug. 
(Please note that the attachment will be public, remove any sensitive information before attaching it. 
See https://wiki.documentfoundation.org/QA/FAQ#How_can_I_eliminate_confidential_data_from_a_sample_document.3F for help on how to do so.)

I have set the bug's status to 'NEEDINFO'. Please change it back to 'UNCONFIRMED' once the requested document is provided.
Comment 2 Julien Nabet 2019-04-25 12:44:28 UTC
*** Bug 124949 has been marked as a duplicate of this bug. ***
Comment 3 t0rt1e 2019-05-10 12:17:44 UTC
Created attachment 151291 [details]
Anonymised generic grades table as test case

Sorry, that it took so long to provide the requested test case. I just now managed to find some time to anonymise fully the grades table. I observed the repeated crashes of Libreoffice Calc while editing the cells in the "Feedback" column of table "Project". Thanks you for looking into this bug report! I hope that you can localise and fix the source of the crashes!
Comment 4 Xisco Faulí 2019-08-14 10:17:44 UTC
Thanks for providing the file.
So, how do you reproduce the crash? You double click on many cells in column P until it crashes ?
Comment 5 t0rt1e 2019-08-14 10:34:13 UTC
The crash happens while editing the feedback comments entered into the cells of column P. I do this primarily using the keyboard (F2, arrow keys, various editing shortcuts, CMD-Return to enter a newline in the cell, etc.). I hardly use the mouse / touchpad for navigating the table. I was not able to narrow the crashes to a particular sequence of key strokes. However, it happens very frequently for me while repeatedly adding/editing the multi-line comments, where the lines start with '+', '-', or '*'. As I do write down the comments during the project presentation and evaluation of its report, editing a cell may take several minutes. To reduce the risk of loosing notes, I try to remember to save the cell entry frequently by pushing Return after entering a longer sequence of notes. Sometimes, I save the whole document at this moment and other times, I will simply continue adding notes to a cell by pressing F2 again.
Comment 6 Roman Kuznetsov 2019-09-21 13:35:41 UTC
no crash in

Version: 6.2.7.1
Build ID: 23edc44b61b830b7d749943e020e96f5a7df63bf
CPU threads: 4; OS: Mac OS X 10.14.6; UI render: default; VCL: osx; 
Locale: ru-RU (ru_RU.UTF-8); UI-Language: en-US
Calc: threaded
Comment 7 Roman Kuznetsov 2019-09-21 13:36:35 UTC
try update LibreOffice to 6.2.7.1 and your macOS to 10.14.6
Comment 8 Xisco Faulí 2019-09-24 11:31:06 UTC
(In reply to Roman Kuznetsov from comment #7)
> try update LibreOffice to 6.2.7.1 and your macOS to 10.14.6

Hello t0rt1e@gmx.de,
Could you please try to reproduce it with the latest version of LibreOffice
from https://www.libreoffice.org/download/libreoffice-fresh/ ?
I have set the bug's status to 'NEEDINFO'. Please change it back to
'UNCONFIRMED' if the bug is still present in the latest version.
Comment 9 Jens 2019-10-21 13:24:50 UTC
Hi, 
I can reproduce this bug in the current version (6.2.8.2) on MacOS 10.14.6 as follows:

1. create a new empty calc document
2. enter in first cell below some multi line text with three lines (must be three lines)
3. click on any other cell to select it
4. click into input line and the error occurs

Sometimes the error does not occur after step 4. but when I repeat steps 2. to 4. the error occurs. 

Version: 6.2.8.2
Build ID: f82ddfca21ebc1e222a662a32b25c0c9d20169ee
CPU threads: 6; OS: Mac OS X 10.14.6; UI render: default; VCL: osx; 
Locale: de-DE (de_DE.UTF-8); UI-Language: en-US
Calc: threaded
Comment 10 t0rt1e 2019-10-21 13:35:10 UTC
I can confirm the steps to reproduce this issue posted by Jens. With them, my Libreoffice 6.2.5.2 installation on macOS High Sierra 10.13.6 (17G8037) crashes systematically.
Comment 11 t0rt1e 2019-10-21 13:44:05 UTC
Also Libreoffice 6.3.2.2 is affected on macOS High Sierra 10.13.6 (17G8037). Sorry, I cannot test on a more recent version of macOS.
Comment 12 Alex Thurgood 2019-11-08 06:29:54 UTC
(In reply to Jens from comment #9)

Tried with Version: 6.3.1.2
Build ID: b79626edf0065ac373bd1df5c28bd630b4424273
Threads CPU : 4; OS : Mac OS X 10.15.1; UI Render : par défaut; VCL: osx; 
Locale : fr-FR (fr_FR.UTF-8); Langue IHM : fr-FR
Calc: threaded

> 
> 1. create a new empty calc document
> 2. enter in first cell below some multi line text with three lines (must be
> three lines)
> 3. click on any other cell to select it
> 4. click into input line and the error occurs
> 
> Sometimes the error does not occur after step 4. but when I repeat steps 2.
> to 4. the error occurs. 
> 


Still unreproducible for me. Never get a crash. Even tried starting the text entry with characters like +, *, -, etc made no difference.
In first cell I entered at least 4 lines of text, then select another cell with mouse, then the line input with the mouse, entered some more multiline text, chose another cell, repeat, etc, no crash.
Comment 13 Alex Thurgood 2019-11-08 06:38:00 UTC
Can someone tell me the difference between Shift-Return and Cmd-Return when doing multi-line entry ?

I've tried both in attempting to reproduce this bug, but still no crash, sorry.
Comment 14 Alex Thurgood 2019-11-08 06:46:14 UTC
Tried to reproduce with test file submitted by OP. Still no repro.

The only common theme I see so far in the versions that crash is the German locale (whether de_CH or de_DE).
Comment 15 3c75qui6edcb 2019-12-02 05:00:40 UTC
I can reproduce this bug using the test file submitted by OP. I can get it to crash by changing the background color of cells in column P. I can also get it to crash using the steps specified by OP.

Version: 6.3.1.2
Build ID: b79626edf0065ac373bd1df5c28bd630b4424273
CPU threads: 4; OS: Mac OS X 10.14.6; UI render: default; VCL: osx; 
Locale: en-AU (en_AU.UTF-8); UI-Language: en-US
Calc:
Comment 16 t0rt1e 2019-12-15 17:38:56 UTC
Sorry for the big delays in responding to this issue. I have less frequently access to my MacBook Pro these days, as I had to shift my day-to-day work on a different computer. I am still observing the issue with Libreoffice:

Version: 6.3.4.2
Build-ID: 60da17e045e08f1793c57c00ba83cdfce946d0aa
CPU-Threads: 8; BS: Mac OS X 10.13.6; UI-Render: Standard; VCL: osx; 
Gebietsschema: de-CH (de_CH.UTF-8); UI-Sprache: de-DE
Calc: threaded

The steps reported by @Jens still trigger the issue reliably. Steps 2 to 4 just need to be repeated several times. On macOS, a new line is inserted into a cell using CMD-Return. Shift-Return moves to the cell above the current cell.
Comment 17 Timur 2019-12-15 19:34:38 UTC
I am not with Mac but I see this was reproduced.
Comment 18 divinerites 2020-04-24 10:14:49 UTC
Confirmed with :

- LibreOffice 6.4.3.2
- MAC OSX Mojave 10.14.6 (18G4032)

Same crash with multi-line text in cells
Comment 19 t0rt1e 2020-04-24 12:32:48 UTC
I also still observe the bug in 

LibreOffice Version: 6.4.3.2
Build-ID: 747b5d0ebf89f41c860ec2a39efd7cb15b54f2d8
CPU-Threads: 8; BS: Mac OS X 10.13.6; UI-Render: Standard; VCL: osx; 
Gebietsschema: de-CH (de_CH.UTF-8); UI-Sprache: de-DE
Calc: threaded

@divinerites: Did you find by any chance a more simple way to provoke the crash in a reproducible way?
Comment 20 andy.hase 2020-12-19 14:16:23 UTC
I can confirm this bug still persist with the current version 7.0.3.1 on MacOS 10.14.6 during various different scenarios: For example using clone formatting and clear formatting functions while editing multiline cells. Also sometimes even when I select the libre office window when it is out of focus.
Comment 21 t0rt1e 2020-12-19 16:19:06 UTC
@Andy: Thanks for confirming that the bug is still present! Were you able to determine a reliable sequence of actions that triggers the crash (e.g., a variation of the steps reported by @Jens on 2019-10-21)? Would be great to get finally to the root of that problem! It is a very annoying bug, which can cause data loss if you don't frequently save your calc sheet while editing multiline cells.
Comment 22 andy.hase 2021-02-08 13:04:12 UTC
(In reply to t0rt1e from comment #21)
> @Andy: Thanks for confirming that the bug is still present! Were you able to
> determine a reliable sequence of actions that triggers the crash (e.g., a
> variation of the steps reported by @Jens on 2019-10-21)? Would be great to
> get finally to the root of that problem! It is a very annoying bug, which
> can cause data loss if you don't frequently save your calc sheet while
> editing multiline cells.

Sorry for the late response. Yes this seems to happen very frequently when I paste + copy from another application in Mac OS for example Google Chrome into a cell. Then I do "Clear Direct Formatting", select the cell I pasted text into and the error pop-ups.
LibreOffice Version 7.0.3.1
Comment 23 AndreasHengst 2021-02-12 21:09:42 UTC
Hi - I joined Bugzilla to search for this bug "invalid child index", so glad I found it already identified, sort of.

Error appears frequently in one sheet, in LibreOffice 7.0.4.2 on OSX High Sierra 10.13.6 (not 10.13.16) and older macbook pro 15".  The same sheet when copied to my PC... LibreOffice 7.0.3.1(x64) on Windows 10 - so far- has not produced the error for me -- based on the many frequent OSX crashes, Win10 has been a much better experience in comparison, but it's not a through test. My data cells include multi-line text and size was changed. Error sometimes appears after adjusting column width, cut/paste within or between sheets, when clicking the "size" dropdown, or even the "save" button (!). Restarting in Safe mode and selecting last-good-user-config seemed to help but it wasn't long before another crash happened.

Thanks
Andy
Comment 24 AndreasHengst 2021-02-13 20:06:23 UTC
Since it wasn't specifically mentioned in this thread, I tested 6.0.5.2 and could not reproduce the error after a few minutes of admittedly random testing. Also could not reproduce in 5.3.2.2. So I adjusted "Version" here back down to the original 6.2.0.3 which the OP reported.
I continued using my same test file and 6.3.3.2 and crash appeared when pressing Left Justify button on a selected single cell, after changing some cell colors and font sizes, multi-line text edits etc.
Comment 25 tymcik 2022-02-22 11:41:36 UTC
It lately happens to me every 10 Minutes when inserting text from a Website. Sometimes there are pictures in the text which might trigger it, but it takes some time after they are placed, while dealing with them or with the text.

I cannot reliably reproduce it yet, but it certainly has to do with multiple line text. 
I don't use / or * and it didn't happen with =


Macbook Pro Retina late 2012
Mac OS X 10.15.7
LibreOffice Calc 7.0
Comment 26 tymcik 2022-02-22 11:48:59 UTC
It lately happens to me every 10 Minutes when inserting text from a Website. Sometimes there are pictures in the text which might trigger it, but it takes some time after they are placed, while dealing with them or with the text.

I cannot reliably reproduce it yet, but it certainly has to do with multiple line text. 
I don't use / or * and it didn't happen with =


Macbook Pro Retina late 2012
Mac OS X 10.15.7
LibreOffice Calc 7.0.6.2
Comment 27 tymcik 2022-02-22 12:40:07 UTC
This time it happened when I changed the vertical orientation of inserted text.
When inserting text from a website automatically, it changes to 'bottom'.
My default vertical arrangement is 'top'.
It seems some formatting of the text influences LO Calc.
Comment 28 tymcik 2022-02-22 12:59:41 UTC
Created attachment 178457 [details]
screenshot from the website

perhaps it gives a hint what type of text it might be. My guess would be html. The website shows a preview for usage in a mobile app. Its orientation on the screen is top. Inserting it in an LibreOffice Text file doesn't reveal special formatting.
Comment 29 QA Administrators 2024-02-23 03:14:48 UTC
Dear t0rt1e,

To make sure we're focusing on the bugs that affect our users today, LibreOffice QA is asking bug reporters and confirmers to retest open, confirmed bugs which have not been touched for over a year.

There have been thousands of bug fixes and commits since anyone checked on this bug report. During that time, it's possible that the bug has been fixed, or the details of the problem have changed. We'd really appreciate your help in getting confirmation that the bug is still present.

If you have time, please do the following:

Test to see if the bug is still present with the latest version of LibreOffice from https://www.libreoffice.org/download/

If the bug is present, please leave a comment that includes the information from Help - About LibreOffice.
 
If the bug is NOT present, please set the bug's Status field to RESOLVED-WORKSFORME and leave a comment that includes the information from Help - About LibreOffice.

Please DO NOT

Update the version field
Reply via email (please reply directly on the bug tracker)
Set the bug's Status field to RESOLVED - FIXED (this status has a particular meaning that is not 
appropriate in this case)


If you want to do more to help you can test to see if your issue is a REGRESSION. To do so:
1. Download and install oldest version of LibreOffice (usually 3.3 unless your bug pertains to a feature added after 3.3) from https://downloadarchive.documentfoundation.org/libreoffice/old/

2. Test your bug
3. Leave a comment with your results.
4a. If the bug was present with 3.3 - set version to 'inherited from OOo';
4b. If the bug was not present in 3.3 - add 'regression' to keyword


Feel free to come ask questions or to say hello in our QA chat: https://web.libera.chat/?settings=#libreoffice-qa

Thank you for helping us make LibreOffice even better for everyone!

Warm Regards,
QA Team

MassPing-UntouchedBug