[PR #154] [MERGED] fix: poor error handling for missing images #8944

Closed
opened 2026-05-23 03:55:12 +01:00 by JakeStanger · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/JakeStanger/ironbar/pull/154
Author: @JakeStanger
Created: 5/20/2023
Status: Merged
Merged: 5/20/2023
Merged by: @JakeStanger

Base: masterHead: fix/image-errors


📝 Commits (1)

  • 87ca399 fix: poor error handling for missing images

📊 Changes

7 files changed (+52 additions, -62 deletions)

View changed files

📝 src/image/gtk.rs (+5 -10)
📝 src/image/provider.rs (+28 -15)
📝 src/modules/custom/image.rs (+2 -7)
📝 src/modules/focused.rs (+3 -6)
📝 src/modules/launcher/item.rs (+6 -9)
📝 src/modules/music/mod.rs (+6 -10)
📝 src/modules/upower.rs (+2 -5)

📄 Description

Previously images that could not be located were handled by throwing a full report error, which incorrectly stated it was an invalid image type.

This changes the image handling to instead log a single-line warning directly in the image provider code, reducing the error handling required by each consumer.

Resolves #146.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/JakeStanger/ironbar/pull/154 **Author:** [@JakeStanger](https://github.com/JakeStanger) **Created:** 5/20/2023 **Status:** ✅ Merged **Merged:** 5/20/2023 **Merged by:** [@JakeStanger](https://github.com/JakeStanger) **Base:** `master` ← **Head:** `fix/image-errors` --- ### 📝 Commits (1) - [`87ca399`](https://github.com/JakeStanger/ironbar/commit/87ca399220e5d48eefe2f295d1dba1b9452c4472) fix: poor error handling for missing images ### 📊 Changes **7 files changed** (+52 additions, -62 deletions) <details> <summary>View changed files</summary> 📝 `src/image/gtk.rs` (+5 -10) 📝 `src/image/provider.rs` (+28 -15) 📝 `src/modules/custom/image.rs` (+2 -7) 📝 `src/modules/focused.rs` (+3 -6) 📝 `src/modules/launcher/item.rs` (+6 -9) 📝 `src/modules/music/mod.rs` (+6 -10) 📝 `src/modules/upower.rs` (+2 -5) </details> ### 📄 Description Previously images that could not be located were handled by throwing a full report error, which incorrectly stated it was an invalid image *type*. This changes the image handling to instead log a single-line warning directly in the image provider code, reducing the error handling required by each consumer. Resolves #146. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
JakeStanger 2026-05-23 03:55:12 +01:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
JakeStanger/ironbar#8944
No description provided.