Leibniz-HBI / tegracli

A Telegram/telethon research convenience wrapper for the terminal.
https://pypi.org/project/tegracli/
MIT License
5 stars 1 forks source link

fix(hydrate): memory leak, somewhere #48

Open pekasen opened 1 year ago

pekasen commented 1 year ago

After (only) 135,313 messages ubuntu's OOM killer came and took out hte processes:

[Sa Apr 22 00:20:52 2023] Out of memory: Killed process 18967 (tegracli) total-vm:532276kB, anon-rss:291708kB, file-rss:0kB, shmem-rss:0kB, UID:1000 pgtables:872kB oom_score_adj:0
pekasen commented 1 year ago

And it seems it's here.

pekasen commented 1 year ago

OK, @FlxVctr, seems there's no easy solution atm, suggest to amend the documentation with a warning and enforcing a limit to approx. 50,000 messages in one go.

FlxVctr commented 1 year ago

Sounds sensible to me for now.