mirror of
https://github.com/aome510/spotify-player.git
synced 2026-04-26 09:25:49 +03:00
[GH-ISSUE #318] Leak of memory on iTerm2 after long period of usage #1103
Labels
No labels
bug
documentation
enhancement
good first issue
help wanted
pull-request
question
third-party
third-party
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/spotify-player#1103
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @diegoulloao on GitHub (Dec 10, 2023).
Original GitHub issue: https://github.com/aome510/spotify-player/issues/318
Describe the bug
For some reason after open spotify player the iterm2 memory is increasing little by little in the meanwhile the TUI is opened and playing music.
To Reproduce
Just play music for a more than 30 minutes and check the memory usage every so often.
Expected behavior
Do not see anomalies in the memory usage while using the TUI for long amount of time.
Log and backtrace
Not important, no error occurred.
Screenshots

Environment
Additional context
Running on Iterm2 Build 3.4.22
Only 2 tabs/processes opened:
spotify_playerThis behavior only occurs when spotify player is open.
important
After a couple of hours of usage, the memory reached even
38GB!!The capture above is after 15 minutes of usage, it reached
3GB.@diegoulloao commented on GitHub (Dec 10, 2023):
By the way I'm in love with this project, I was using it all the past days, now, the only thing that's stopping me of using it is the memory usage leak it causes.
Hope I can find some kind of solution on this issue.
Thank you!
@aome510 commented on GitHub (Dec 10, 2023):
@diegoulloao what is the value of
Scrollback linesin the Terminal tab of your ITerm2 settings? Using a large or unbounded scrollback buffer may cause a memory issue as rendered images are kept inside the scrollback buffer.@aome510 commented on GitHub (Dec 10, 2023):
FYI, I use
1000for scrollback lines and have never seen ITerm2 memory usage exceed2GB. Memory usage can be estimated with each image's size is about1MB, so1000means memory usage (only for images) is about1GB.Edit: it does exceed 2GB for me after a while, so this issue may not be related to the scrollback buffer
@diegoulloao commented on GitHub (Dec 10, 2023):
Using
1000too. Is very weird, after 3-4 hours of usage my memory reached38GBusing +swap@aome510 commented on GitHub (Dec 11, 2023):
@diegoulloao try to resolve the issue in https://github.com/aome510/spotify-player/pull/319. Can you checkout the branch and test the changes?
@diegoulloao commented on GitHub (Dec 11, 2023):
Sure! first I need to know, how do I change the branch? Sorry, I'm not familiar with rust or cargo.
I installed the app using cargo so long time ago.
Thanks for the quick fix and PR! ❤️
@aome510 commented on GitHub (Dec 11, 2023):
You can run the below command in the repo's root
@diegoulloao commented on GitHub (Dec 11, 2023):
Ok, let me try it for 30 minutes 🕦 I'll reply
@diegoulloao commented on GitHub (Dec 11, 2023):
replied.