Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Chat export 2000 MiB limit too low for attachments #20445

Open
dali99 opened this issue Jan 8, 2022 · 10 comments
Open

Chat export 2000 MiB limit too low for attachments #20445

dali99 opened this issue Jan 8, 2022 · 10 comments
Labels
A-Export-Chat O-Uncommon Most users are unlikely to come across this or unexpected workflow T-Enhancement

Comments

@dali99
Copy link
Contributor

dali99 commented Jan 8, 2022

Your use case

What would you like to do?

I would like to export my complete chat history but currently there's a limit of 2 000 MiB
This seems kind of like an arbitrary limit, though I understand that getting all the files and zipping them on the client side could get problematic for very big exports.
Unfortunately a 1:1 chat that is 4 years old can easilly have a larger footprint like thsi

How would you like to achieve it?

Allow more than 2 000 MiB of data to be exported

Have you considered any alternatives?

An alternative would be to allow paginating the export, I don't mind getting part1 part2 part3 zips each 2 GB in size.

Or if we could select date ranges like #19310 I could manually try split it up (though that would be a pain)

Additional context

No response

@SimonBrandner SimonBrandner added the O-Uncommon Most users are unlikely to come across this or unexpected workflow label Jan 9, 2022
@germain-gg
Copy link
Contributor

All the chat exporting is done client side and everything gets loaded in RAM if I remember correctly. The max file size limit is most likely to work around that.

Taking advantage of streams could be very useful to waive this limit, but browser support was too sporadic at the time of writing this functionality

@soda-pop-ice-cream
Copy link

I think devs added 2GB restriction to protect matrix.org from huge exports.
Also, I managed to export mine 4,5GB chat before restriction was added. At first export was failed because laptop had only 8GB RAM, but then i tried on other one, that had 16GB and that was barely enough. If you don't have that much RAM, at least use swap.
@dali99 if you really need that export you can install element-web docker v1.9.1 on some server, there was no 2GB size limit.

@t3chguy
Copy link
Member

t3chguy commented Mar 30, 2022

I think devs added 2GB restriction to protect matrix.org from huge exports.

Nope, it was added as anything larger often gets killed by the memory protections of modern browsers, even if you have far more ram the per-tab limit is far lower.

@Agent-Rogue
Copy link

for browsers, it's understandable since they wouldn't allow someone to export more than that anyway. however the native version (assuming electron doesn't have this limitation) shouldn't have this limitation.

@Szybet
Copy link

Szybet commented Apr 17, 2024

classic Matrix, such a stupid issue and still not solved after 2 years

@t3chguy
Copy link
Member

t3chguy commented Apr 17, 2024

@Szybet contributions welcome, the limit was imposed by the original external contributor of the feature based on experimental testing of common browser limitations which yield crashes

@Szybet
Copy link

Szybet commented Apr 17, 2024

Is it server side limited or client, because if server then I have tied hands

@t3chguy
Copy link
Member

t3chguy commented Apr 17, 2024

Client, there's no server-side export API, it just uses standard pagination APIs. It has to load the entire download into memory, hence the problem. Server can't help given end-to-end encryption.

@Szybet
Copy link

Szybet commented Apr 17, 2024

How do I build element desktop with a custom matrix-react-sdk

@t3chguy
Copy link
Member

t3chguy commented Apr 17, 2024

You build element-web with your matrix-react-sdk yarn link'ed in as per the README, then you symlink the resultant webapp into element-desktop/webapp and run yarn asar-webapp then build Element Desktop as normal ignoring the fetch instructions

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-Export-Chat O-Uncommon Most users are unlikely to come across this or unexpected workflow T-Enhancement
Projects
None yet
Development

No branches or pull requests

8 participants