Skip to content

[P2] Duplicate Error Notifications Displayed #129

@JoshuaAFerguson

Description

@JoshuaAFerguson

Severity: P2 - LOW (Cosmetic)
Component: UI - Notification System
Pages: My Applications, possibly others

Issue

Error messages displayed twice in notification toasts simultaneously.

Example: "Failed to create session" shown twice

Impact

  • Poor UX
  • Visual clutter
  • Users see redundant error messages

Root Cause

Likely one of:

  1. Error handler called twice (component + global handler)
  2. Notification triggered in both API interceptor and component
  3. Error bubbling through multiple layers

Files to Check

  • ui/src/api/client.ts - Axios interceptors
  • ui/src/hooks/useNotification.ts - Notification hook
  • ui/src/pages/user/MyApplications.tsx - Component error handling

Fix Required

// BEFORE (likely causing duplicates):
try {
    await api.post('/sessions', data)
} catch (error) {
    showNotification(error.message, 'error') // Called here
    // AND also called in axios interceptor
}

// AFTER (only show once):
try {
    await api.post('/sessions', data)
} catch (error) {
    // Error already shown by axios interceptor
    // OR show here but disable interceptor notification
}

Fix Strategy

  • Decide: Show errors in components OR in global interceptor, not both
  • Add flag to prevent duplicate notifications
  • Use notification deduplication (track recent messages)

Testing

  • Error shown only once
  • Multiple errors don't duplicate
  • Success messages don't duplicate
  • Error messages across all pages

Effort: 1-2 hours
Priority: Can defer to v2.1
Source: .claude/reports/UI_BUG_FIXES_REQUIRED.md

Metadata

Metadata

Assignees

No one assigned

    Labels

    P2agent:builderAgent 2 - BuilderbugSomething isn't workingsize:s2-4 hoursstaleNo recent activity - will be closed if no responseuiux

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions