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

limit cache size config #1066

Closed
trisbele opened this issue Mar 9, 2022 · 1 comment · Fixed by #1092
Closed

limit cache size config #1066

trisbele opened this issue Mar 9, 2022 · 1 comment · Fixed by #1092
Labels
enhancement A new feature that would improve Spotifyd

Comments

@trisbele
Copy link

trisbele commented Mar 9, 2022

Thanks for spotifyd. I have to clear my cache manually every two weeks, because the cache on my raspberry2 is full and the daemon — and of coarse other processes as well — stucks and doesn't play any songs.
Limit the maximum cache size possibility in config file would be nice.
Delete the oldest when max size is reached would be the smartest way, if it is easy to implement. But clear cache completely is also a valid solution for me and the easiest way....
THX

@trisbele trisbele added the enhancement A new feature that would improve Spotifyd label Mar 9, 2022
@eladyn
Copy link
Member

eladyn commented Mar 10, 2022

To fix your specific problem, I guess you could disable caching completely (by omitting the cache_directory from your config file). If you don't need any of the features that spotifyd provides on top of librespot you could also use the upstream project directly and use their --cache-size-limit cli option.


For anyone looking to implement this: librespot (the upstream dependency that spotifyd uses) allows to specify a max cache size and spotifyd could make use of that in this line:

None,

which would need to be replaced by a proper value instead of None.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement A new feature that would improve Spotifyd
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants