Skip to content

Add consistent logging to Electron main process #45

@fnune

Description

@fnune

Problem

The Electron UI has no consistent logging to ~/.local/state/kyaraben/kyaraben.log. The daemon logs are captured, but electron main process events (IPC, window lifecycle, errors) are not. This makes debugging production issues difficult.

The pairing:progress IPC event flow (daemon stdout -> readline -> JSON parse -> webContents.send -> renderer) has no observability. Similar issues affect pendingDevice events.

Proposed solution

Implement structured logging in electron/main.ts that writes to the same log file as the daemon, or to a separate electron.log file in the same directory.

Ensure the log path is resolved correctly (kyarabenStateDir uses XDG_STATE_HOME which may not be set at module load time).

Alternatives considered

None.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions