Skip to content

Bug: Refresh interval setting not persisted to UserDefaults (resets to default on every launch) #506

@Lunar-actuary

Description

@Lunar-actuary

Bug Report

CodexBar version: 0.17.0
macOS: 15.3.2 (Sequoia), Apple Silicon (arm64)

Summary

The refresh interval setting in Settings is not written to com.steipete.codexbar UserDefaults. Every time CodexBar restarts, the interval resets to the default value, requiring the user to manually go into Settings to set it again.

Steps to Reproduce

  1. Open CodexBar Settings
  2. Change the refresh interval (e.g., to 1 minute)
  3. Close Settings — data refreshes correctly while app is running
  4. Quit and relaunch CodexBar
  5. Refresh interval has reset to default

Verification

Monitored com.steipete.codexbar plist before and after changing the setting:

defaults read com.steipete.codexbar > before.txt
# (changed setting in UI)
defaults read com.steipete.codexbar > after.txt
diff before.txt after.txt
# → no output (plist unchanged)

The plist file's modification timestamp does update on Settings changes, but the refresh interval key is absent from the output both before and after.

Expected Behavior

Refresh interval should be persisted to UserDefaults (like other settings such as menuBarShowsBrandIconWithPercent, launchAtLogin, etc.) so it survives app restarts.

Workaround

None available without knowing the internal key name to write manually via defaults write.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions