Skip to content

Add uniform save-failure UX (toast/log) for useSaving.runSave onError paths #5276

Description

@coderabbitai

Summary

During review of PR #5273 (save-consolidation onto useSaving.runSave / useReboot), it was noted that useSaving's runSave (and every migrated onError callback across the 10 migrated tabs) only logs failures via console.error. There is no user-facing toast/notification when a save fails.

Rationale

Users currently get no visible feedback if a configuration save fails (e.g. MSP write rejection, timeout, etc.), beyond a browser console error. A uniform "save failed" UX would improve error visibility across all save flows.

Affected areas

  • src/composables/useSaving.js (runSave default error handling)
  • All tabs/composables migrated to runSave in PR refactor(save): consolidate all config saves onto one runSave + saveToEeprom path #5273, including:
    • src/components/tabs/PowerTab.vue
    • src/components/tabs/GpsTab.vue
    • src/components/tabs/OnboardLoggingTab.vue
    • src/components/tabs/ServosTab.vue
    • src/components/tabs/AuxiliaryTab.vue
    • src/composables/adjustments/useAdjustmentsSave.js
    • src/components/tabs/LedStripTab.vue
    • src/components/tabs/VtxTab.vue
    • src/components/tabs/PidTuningTab.vue
    • src/components/tabs/MotorsTab.vue

Proposed change

Introduce a consistent failure notification (e.g. via gui_log) either as a default behavior inside useSaving's runSave when no onError is provided, or as a shared helper that all onError callbacks invoke, so users see a clear "save failed" message instead of only a console error.

Acceptance criteria

  • A failed save surfaces a user-visible error message (toast/log) consistently across all tabs using runSave.
  • Behavior is centralized (not duplicated per-tab) to avoid drift.

References

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions