Bug 146497 - Crash in: std::_Tree<std::_Tset_traits<ScFormulaCell *,std::less<ScFormulaCell *>,std::allocator<ScFormulaCell *>,0> >::erase
Summary: Crash in: std::_Tree<std::_Tset_traits<ScFormulaCell *,std::less<ScFormulaCel...
Status: RESOLVED WORKSFORME
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Calc (show other bugs)
Version:
(earliest affected)
7.2.4.1 release
Hardware: All All
: medium normal
Assignee: Not Assigned
URL:
Whiteboard:
Keywords:
: 146634 146939 (view as bug list)
Depends on:
Blocks: Crash
  Show dependency treegraph
 
Reported: 2021-12-31 12:19 UTC by Colin
Modified: 2024-02-05 02:03 UTC (History)
2 users (show)

See Also:
Crash report or crash signature: ["std::_Tree<std::_Tset_traits<ScFormulaCell *,std::less<ScFormulaCell *>,std::allocator<ScFormulaCell *>,0> >::erase"]


Attachments
Sample sheet - nothing confidential (473.32 KB, application/vnd.oasis.opendocument.spreadsheet)
2022-01-23 14:12 UTC, Colin
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Colin 2021-12-31 12:19:51 UTC
This bug was filed from the crash reporting server and is br-79bc34af-4664-4da2-a5cb-fb870435ff85.
=========================================
It appears to be related to but not identical to other crash reports generated from my PC where I have removed or inserted rows into autofiltered arrays.
In this instance, I neither inserted nor deleted but I did filter and sort two different arrays.
One array I simply overtyped amendments into the presented SORTED and filtered array.
With the second array, I ended up with four items (of3500). I edited one and cut and pasted it to its "neighbour".
I did not "drag" copy.
Comment 1 Colin 2022-01-07 09:57:13 UTC
Again 
https://crashreport.libreoffice.org/stats/crash_details/72dc922e-f356-4ca9-95c5-aeb4682b603d

Advice needed: Should I suppress the sending of the crash reports as they're defining the same issue?

Unsure whether you need the volume to signify any kind of urgency or just "One report is sufficient"
Comment 2 raal 2022-01-22 15:23:28 UTC
Hello,

Thank you for filing the bug. Please send us a sample document and steps to reproduce, as this makes it easier for us to verify the bug. 
I have set the bug's status to 'NEEDINFO', so please do change it back to 'UNCONFIRMED' once you have attached a document.
(Please note that the attachment will be public, remove any sensitive information before attaching it.)
How can I eliminate confidential data from a sample document?
https://wiki.documentfoundation.org/QA/FAQ#How_can_I_eliminate_confidential_data_from_a_sample_document.3F
Thank you
Comment 3 Colin 2022-01-22 16:22:21 UTC
(In reply to raal from comment #2)
> Hello,
> 
> Thank you for filing the bug. Please send us a sample document and steps to
> reproduce, as this makes it easier for us to verify the bug. 

I was able to reproduce the bug (I was testing/verifying the procedure) and it indeed crashed - I suppressed the crash report

I then re-edited the file to revert so I could provide a copy and it didn't crash either with the reverting edits or with another intentional crash scenario.
I am now convinced that editing two unrelated autofilter arrays and then saving is the cause of the crash and will experiment further.
What is interesting is that having exited Libre and simply typing this response my cooling fan is maxing.
Task manager informs me that LO is still running but I have blank icons on the task bar.
LO is using 28% CPU and very high power usage is indicated.
Probably all part and parcel of the crash which is inconsistent in its presentation.
Would you like the file with my steps to reproduce to see if it crashes on another machine or do you have any utilities that I can run to understand and report why LO is still consuming all the resources but supposedly inactive after that crash file recovery routine?
I just manually killed LO and now the fan has slowed down to normal speed.
Comment 4 QA Administrators 2022-01-23 03:44:14 UTC Comment hidden (obsolete)
Comment 5 Colin 2022-01-23 06:44:48 UTC Comment hidden (obsolete)
Comment 6 raal 2022-01-23 08:38:40 UTC
(In reply to Colin from comment #3)
> (In reply to raal from comment #2)
> > Hello,

> Would you like the file with my steps to reproduce to see if it crashes on
> another machine or do you have any utilities that I can run to understand

Yes, please attach test file and write steps to reproduce the bug. Thank you.
Comment 7 Colin 2022-01-23 14:11:27 UTC
DO NOT HAVE ANY OTHER ACTIVE SHEETS
It has been known to trash my user profile - culminating in everything I attempt causing crashes until I replace the profile so, be prepared.

In sheet two "Product&ContainerMetrics"
Sort Autofilter -E- Descending
Select A15:H15 then insert - shifting cells DOWN
Type or dragfill into new B C D & E cells
Sort on A
Find your new entry - it's the one without an Index Number
Select the new ROW range A - H and delete cells.
If it's the last row you won't need to shift UP
if it's the first row then shift cells UP

The file should be unchanged but saving with the eXit button will force a save and MAY force the crash and error handling.

If it doesn't crash, reopen the file and perform the same steps but DON'T eXit
THEN
Focus Sheet one "Body Weights"
Open autofilter on -T- and type "Hot" in the "Search Items" Box
This will provide 2 selections which should be accepted - THREE entries
Change the first "2 Hot Dogs" entry to "4 Hot Dogs"
Copy and paste to the remaining "2 Hot Dogs" entry
Open the autofilter to "All"
Save & Exit or eXit & Save

There are few recent occasions where this sequence of actions did not cause a crash. If it doesn't fail for your first attempt then please simply persevere.

You may also observe that exiting and crashing will probably result in Task Manager implying that LO is still active and consuming substantial CPU with heavy power usage and an accelerating cooling fan - despite the fact that according to the taskbar icon, LO is now inactive.
Comment 8 Colin 2022-01-23 14:12:53 UTC
Created attachment 177724 [details]
Sample sheet - nothing confidential
Comment 9 Colin 2022-01-23 14:28:21 UTC
(In reply to Colin from comment #8)
> Created attachment 177724 [details]
> Sample sheet - nothing confidential

I also proved it locally, generating bug 146939 in the process.
For the record, Task Manager is still indicating active LO 29.3% CPU and very high power usage
Taskbar token is inactive
Comment 10 Xisco Faulí 2022-01-24 13:14:09 UTC
*** Bug 146939 has been marked as a duplicate of this bug. ***
Comment 11 Colin 2022-01-29 04:52:02 UTC
Auditing my reports; Bug 146634 also generated in response to a crash report is the same issue.
My apologies, perhaps I should have audited before allowing the crash report off my desktop
Comment 12 Colin 2022-03-12 13:35:26 UTC
And Again.

Always appears to be related to repairing the corrupted Conditional Formatting Register which constantly appends Literally 100's of orphan entries when triple colour sorted conditioned arrays have their formulae amended by copying a small array 8x5 to the entire array 4217x5 - currently, grows x8 daily.

In this instance, the offending CFRegister related to my re-establishing the formulae in sheet 1 Columns J-N.

I had been experimenting to ascertain whether removing 20000 formulae and replacing them with the calculated values ALT+CTRL+V would impact the loading time as I now see the load progress bar incrementally stepping along the bottom of my screen.

https://crashreport.libreoffice.org/stats/crash_details/64720929-1bc3-4ff0-9249-e290e21d6469
Comment 13 Colin 2022-04-22 14:21:40 UTC
@raal
@xisco Fauli

Would there be any benefit to providing one of your appropriate developers/experts with TeamViewer access to my computer whilst I create the circumstances that invariably precede the crash?
That session could be recorded in order that all your colleagues could be provided with an insight into all aspects of that crash.

The simple editing of an auto filter array with conditional formatting
The resultant corruption to conditional formatting
The crash upon exit & save
The empty advisory pane for the recovery items
The pointless offer to recover "nothing" and start in "safe mode"
The auto submission of the crash report 
The failure of LO to unload itself after the crash
The failure of LO to unload itself following a regular load, edit, save & exit
The excessive CPU demand attributable to the rogue LO process
The excessive Disk Activity attributable to the rogue LO process
The requirement for the rogue LO to be manually disabled via Task Manager

It is increasingly apparent that the situation is far more significant than just "editing an auto filtered array causes LO to crash - Fix it;)"

Also, a new insight - the auto filtered array is adjacent to a second auto filtered array where both have been created as Defined Named Data Ranges. Whilst they both sort independently, where one may be filtered it does indeed impinge upon the visible rows of the second array. Is that a significant revelation?
Comment 14 Buovjaga 2022-12-07 12:30:20 UTC
*** Bug 146634 has been marked as a duplicate of this bug. ***
Comment 15 Buovjaga 2022-12-07 12:34:13 UTC
I see 7.4 among the reports for this crash signature, so this probably still exists.
Comment 16 Dhiraj Holden 2024-02-03 15:40:06 UTC
Could not reproduce using sample steps.

either

Version: 7.4.7.2 (x64) / LibreOffice Community
Build ID: 723314e595e8007d3cf785c16538505a1c878ca5
CPU threads: 16; OS: Windows 10.0 Build 22621; UI render: Skia/Raster; VCL: win
Locale: en-US (en_US); UI: en-US
Calc: threaded

or

Version: 24.8.0.0.alpha0+ (X86_64) / LibreOffice Community
Build ID: abc81c4a24256de12ac0a48cc9b811bc1f63da0f
CPU threads: 16; OS: Windows 10.0 Build 22621; UI render: Skia/Vulkan; VCL: win
Locale: en-US (en_US); UI: en-US
Calc: CL threaded
Comment 17 Stéphane Guillou (stragu) 2024-02-03 23:48:30 UTC
Colin, looks like the crash signature hasn't popped up recently in the Crash Report website, starting with 7.5.3.

Can you please test your steps in 7.6 or 24.2 and confirm that it is now resolved? Or provide us with a new crash report if the signature has changed.
Comment 18 Colin 2024-02-04 07:06:14 UTC
(In reply to Stéphane Guillou (stragu) from comment #17)
> Colin, looks like the crash signature hasn't popped up recently in the Crash
> Report website, starting with 7.5.3.
> 
> Can you please test your steps in 7.6 or 24.2 and confirm that it is now
> resolved? Or provide us with a new crash report if the signature has changed.

Version: 7.6.4.1 (X86_64) / LibreOffice Community
Build ID: e19e193f88cd6c0525a17fb7a176ed8e6a3e2aa1
CPU threads: 4; OS: Windows 10.0 Build 19045; UI render: Skia/Raster; VCL: win
Locale: en-US (en_SE); UI: en-US
Calc: threaded

Flawless
Comment 19 Stéphane Guillou (stragu) 2024-02-05 02:03:04 UTC
Great to hear, thanks! Let's set to "works for me" until we can identify a commit.