Skip to content

Fix several crashes, add install/uninstall scripts#572

Closed
cycloarcane wants to merge 7 commits intocatsout:mainfrom
cycloarcane:stability-fixes-and-install
Closed

Fix several crashes, add install/uninstall scripts#572
cycloarcane wants to merge 7 commits intocatsout:mainfrom
cycloarcane:stability-fixes-and-install

Conversation

@cycloarcane
Copy link
Copy Markdown

A few crash fixes that bit me on CachyOS/KDE 6, plus some UX tweaks and a pair of install scripts.

Crash fixes

TTYSwitchMonitor was calling qFatal() when it couldn't connect to the D-Bus system bus. That tears down plasmashell entirely — swapped it for qWarning() so sleep detection just gets skipped instead.

main.qml had two problems:

  • mouseHooker.destroy was missing (), so the old MouseGrabber was never actually destroyed when mouse input was toggled off. It accumulated across reloads.
  • backendLoader.item can be null briefly during backend transitions. Added guards in autoPause() and the pause timer so they don't fire on a null reference.

Scene.qml — the displayModeChanged() call and volume fade were both wired up before SceneViewer had finished its Component.onCompleted, which could touch player before it existed. Added a playerReady flag; everything that talks to the player now checks it first.

QML fixes

Small bugs in WallpaperPage.qml: typo cofnigconfig in the config save path, a wrong Object.assign target that was clobbering the object instead of merging into it, and reoslveresolve in a Promise callback.

UX

  • InfoShow (the error screen) got a redesign — was just a wall of yellow text, now shows a proper card with the workshop ID, type, error message, and a recovery command for when a scene wallpaper has crashed KDE and left the config stuck.
  • Added a small VULKAN badge on wallpaper thumbnails in the picker so it's obvious at a glance which ones run the in-process renderer. Scene wallpapers carry real risk since a renderer fault kills plasmashell; felt worth surfacing.

Install scripts

install.sh — detects distro, installs deps, builds and installs the plugin. Two bugs fixed vs the draft:

  • On Arch/CachyOS the package list had ${KDE_VER:-5} left in it verbatim, so on KDE 6 it tried to install a package literally called 6. Removed it.
  • sndio was missing from the Arch dep list. libmpv links libsndio.so.7 at runtime; without the package installed the plugin fails to load silently and plasmashell crashes trying its fallback wallpapers.

uninstall.sh — removes the system QML plugin (needs sudo) and the user plasma package via kpackagetool, then restarts plasmashell.

Also added CRASH_GUIDE.md explaining why scene wallpapers can crash KDE and how to recover, and bumped the version to 0.5.5.

cycloarcane and others added 3 commits February 17, 2026 14:40
Crash fixes:
- TTYSwitchMonitor: qFatal -> qWarning when D-Bus is unavailable;
  no reason to kill plasmashell if sleep detection can't set up
- main.qml: guard backendLoader.item before calling pause/play in
  timers; fix mouseHooker.destroy which was missing () so never ran
- Scene.qml: add playerReady flag so volume fade and displayMode
  changes don't fire before the SceneViewer finishes initialising

QML correctness:
- WallpaperPage.qml: fix typo cfg.cofnig -> cfg.config in config
  save path; fix Object.assign call that was clobbering wrong target;
  rename reoslve -> resolve in Promise callback
- main.qml: null-check backendLoader.item in autoPause()

UX:
- InfoShow.qml: replace raw text dump with a proper error card showing
  workshop ID, type and recovery hint for scene wallpapers
- WallpaperPage.qml: add small VULKAN/? badge on thumbnails so it is
  obvious at a glance which wallpapers run the in-process renderer
- Common.qml/WallpaperListModel.qml: track compatibility field
  (stable/vulkan/unknown) per wallpaper item

Install:
- install.sh: add sndio to Arch deps (mpv links libsndio.so.7; without
  it the plugin silently fails to load and plasmashell crashes when
  trying fallback wallpapers); drop ${KDE_VER:-5} which was being
  passed literally as a package name to pacman, causing "target not
  found: 6" on KDE 6 systems
- uninstall.sh: new script; removes system QML plugin (sudo) and user
  plasma package via kpackagetool with rm fallback, then restarts shell
- CRASH_GUIDE.md: explain why scene wallpapers can crash KDE and how
  to recover; document the in-process Vulkan renderer risk
- CHANGES.md: add changelog entry for this batch of changes
- Bump version to 0.5.5
Crash fixes:
- Fix plasmashell crash when particle wallpapers use sprite-animated
  materials with zero or malformed frames. LoadMaterial now catches
  std::out_of_range exceptions from particle objects and skips them
  gracefully rather than terminating the process (submodule bump).
- Changed two qFatal() calls in TTYSwitchMonitor to qWarning() so
  D-Bus failures don't kill plasmashell.

Install / uninstall:
- Fixed 'error: target not found: 6' in install.sh caused by
  ${KDE_VER:-5} being passed literally as a package name on KDE 6.
- Added sndio to Arch dependencies to provide libsndio.so.7 required
  by libmpv (missing library prevented the plugin from loading at all).
- Added uninstall.sh with --yes and --skip-restart flags.

UI:
- Added crash-risk badge (red) to wallpaper picker for scene wallpapers
  with scene.json version >= 4 or workshop cross-references, which are
  known to crash the Vulkan renderer.
- Existing VULKAN badge (orange) and unknown badge (grey) preserved.
- Added analyse_pkg Python/QML helper that parses scene.pkg headers to
  detect risk factors without extracting the full archive.

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
Remove VULKAN and BROWSER badges — scene and web wallpapers both work
fine in practice, so labelling them was misleading noise.

Keep only the NO TEXT badge (yellow) for scene wallpapers that contain
text objects, since the renderer has no text implementation and these
wallpapers genuinely will not display correctly.

The analyse_pkg helper now detects text objects instead of computing
crash_risk, which is no longer relevant since the particle crash was
fixed in the scene renderer.

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
@ShadowRZ
Copy link
Copy Markdown

@catsout Can you review this?

cycloarcane and others added 4 commits April 15, 2026 18:01
Adds a trash-icon button on each grid thumbnail and on the right-side
panel toolbar that deletes the wallpaper folder from disk after a
confirmation dialog. The Python helper refuses paths that aren't a
directory containing project.json, and also cleans up the per-wallpaper
config file under ~/.config/wekde/wallpaper/.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Adds a global Rotation config entry and ComboBox in the Settings page.
The backend loader's width/height are swapped for 90/270 so rotated
wallpapers fill the screen correctly.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@catsout catsout closed this Apr 18, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants