element-hq / element-hq/element-web
Export chat - memory leak, and ridiculously resource heavy
- Dominant language
- TypeScript
- Stars
- 13.5k
- Forks
- 2.8k
- PR merge metrics
- PR metrics pending
Description
### Steps to reproduce

### Outcome
I'm using the "export chat" function, it has found 16479 events.
Somehow this:
* Took 29 minutes!
* Using ~33% of 16 cores for the entire time!
* Using over 2.7GB of RAM.
* The UI locked up after a few mins, including the spinning thing stopping spinning.
*
The final file is only 1.85MB.
As someone who has done tons of log analysis and text manipulation over the years, this is unfathomably bad; 16000 records is basically nothing. I can see why the other export issues exist on here if this is so bad with just 16000 records (https://github.com/element-hq/element-web/issues/25007 https://github.com/element-hq/element-web/issues/27615 https://github.com/element-hq/element-web/issues/21403 etc ).
Also: Element hasn't freed up the RAM usage. It's still using 2.9GB (it was about 320MB when I started.)

### Operating system
Windows 10
### Application version
Element desktop 1.11.80
### How did you install the app?
_No response_
### Homeserver
_No response_
### Will you send logs?
No
Contributor guide
Assessment
This issue has not been assessed yet.