Skip to content

fix(dashboard): console.warn in production SettingsPage should use structured logging #4066

@OneStepAt4time

Description

@OneStepAt4time

Code Quality

SettingsPage has 3 console.warn calls that ship to production:

File: dashboard/src/pages/SettingsPage.tsx

  • Line 41: console.warn('SettingsPage: failed to load settings from localStorage:', err);
  • Line 50: console.warn('SettingsPage: failed to save settings to localStorage:', err);
  • Line 158: console.warn('SettingsPage: failed to clear onboarding flag:', err);

Also:

  • TerminalPassthrough.tsx line 104: console.info (guarded by import.meta.env.DEV — OK)
  • Icon.tsx line 101: console.warn for unknown icons — acceptable for dev debugging

Impact: Console noise in production. Not a user-visible bug but violates the "no console.log in production" principle from SOUL.md.

Acceptance criteria:

  • Replace console.warn in SettingsPage with silent error handling or a structured logger
  • Or gate behind import.meta.env.DEV

Labels: dashboard, tech-debt

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions