Skip to content

tweaks: warn before enabling psd on low-memory systems - #305

Open
Rockykln wants to merge 1 commit into
CachyOS:developfrom
Rockykln:psd-low-memory-warning
Open

Rockykln wants to merge 1 commit into
CachyOS:developfrom
Rockykln:psd-low-memory-warning

Conversation

@Rockykln

Copy link
Copy Markdown

Fixes #136

Enabling profile-sync-daemon on a system with 8 GB of RAM or less now asks for confirmation first. psd keeps browser profiles in /run/user, which logind limits to 10% of RAM by default (RuntimeDirectorySize), so on low-memory systems it can fill up and applications fail to start.

  • total RAM is read from /proc/meminfo (with a unit test for the parser) and shown rounded up to whole GB
  • answering "No" leaves psd disabled and the checkbox unchecked
  • the path is passed as a variable with word joiners, so the dialog does not wrap it at the slashes
  • English and German strings added, other languages fall back to English

Tested with a local build (threshold temporarily raised, toggle stubbed out): the dialog only appears when enabling psd, "No" keeps the checkbox unchecked and "Yes" proceeds as before.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Suggestion] Add a warning when enabling profile-sync-daemon on systems with ≤8 GB RAM

1 participant