aether icon indicating copy to clipboard operation
aether copied to clipboard

Duplicate wallpaper in blueprint causes background basename collision and freezes GUI in infinite IPC reactive loop

Open AlasdairAnderson opened this issue 2 months ago • 0 comments

Summary

When applying a blueprint containing duplicate wallpaper paths (or wallpapers sharing identical basenames), Aether's backend errors with background basename collision. This unhandled failure triggers an infinite reactive synchronization loop ($effect / SyncState) in the WebKit frontend, pegging CPU at 100% and completely freezing the application window.

Steps to Reproduce

  1. Save or import a blueprint where palette.additionalImages contains duplicate wallpaper entries (or two wallpapers with the same filename/basename).
  2. Open Aether GUI -> go to the Blueprints tab -> click Use on the blueprint.
  3. Click Apply (or wait for the debounced live preview).

Expected Behavior

  1. Deduplication: Aether should automatically deduplicate wallpapers in additionalImages (by path and basename) when saving blueprints and when staging backgrounds into Omarchy theme directories.
  2. Graceful Error Handling: If background staging or theme generation fails, the frontend should display an error toast/banner, clear the isApplyingTheme lock, and avoid entering an infinite retry/reactive sync loop.

Actual Behavior

  1. The Go backend rejects the duplicate image with:
    Error: background basename collision "<filename>": "<path>" and "<path>"
    
  2. The frontend promise rejection is caught, but the applied signature (_l) is never updated to match the active state (gl()).
  3. Svelte 5's reactive $effect continuously detects a state mismatch and repeatedly dispatches IPC state synchronizations (SyncState), resulting in an infinite ping-pong between WebKit and the Go backend (>17,000 context switches/sec).
  4. Both aether and WebKitWebProcess saturate CPU cores at ~85-100%, causing the GUI window to become completely unresponsive and freeze until killed via terminal (killall aether).

Environment

  • Aether Version: 4.30.0-1
  • OS: Omarchy (Arch Linux)
  • Compositor: Hyprland
  • WebKit2GTK: 4.1

AlasdairAnderson avatar Sep 23 '26 19:09 AlasdairAnderson