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

deltachat-desktop on Linux misuses XDG configuration location for storing cached data, not just configuration #3986

Open
dkg opened this issue Jun 28, 2024 · 3 comments
Labels
bug Something isn't working technical debt

Comments

@dkg
Copy link

dkg commented Jun 28, 2024

I am testing DeltaChat 1.46.1 on Debian stable (12.5).

It looks to me like DeltaChat is storing configuration information, application state, application data, and ephemeral (cached) material all within ~/.config/DeltaChat.

The XDG basedir spec identifies ~/.config (as $XDG_CONFIG_HOME) specifically for "user-specific configuration". However, i see at least two things stored here that are definitely not local configuration:

  • logfiles written to ~/.config/DeltaChat/logs/ (these should probably be logged to the system's journal)
  • cached data written to ~/.config/DeltaChat/{Cache,GPUCache,Code Cache,DawnWebGPUCache,DawnGraphiteCache} (these should probably live in $XDG_CACHE_HOME/DeltaChat, or ~/.cache/DeltaChat if $XDG_CACHE_HOME is unset)

Using the XDG basedirs will make the application integrate more smoothly with arbitrary machine setups.

@Simon-Laux Simon-Laux added bug Something isn't working technical debt labels Jul 1, 2024
@farooqkz
Copy link
Collaborator

farooqkz commented Jul 2, 2024

Thanks even I didn't know that. Yeah it makes perfect sense that cache data should live in their own home not someone else's.

@Simon-Laux Who is in charge of Cache? I mean what part of Desktop?

@Simon-Laux
Copy link
Member

Simon-Laux commented Jul 2, 2024

electron / main process code is, not sure yet how to change that, might be electron api that we call on startup (like a chrome cli switch, or standard electron api), might be an env var, or electron-builder config. or if we are unlucky it's an upstream issue in electron.

@farooqkz farooqkz self-assigned this Jul 11, 2024
@nicodh
Copy link
Contributor

nicodh commented Jul 25, 2024

There is an old issue still unsolved but still active discussed:
electron/electron#8124
and a project related to that problem: https://github.com/danisztls/ephemeral

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working technical debt
Projects
None yet
Development

No branches or pull requests

4 participants