From b801ac90b5b4fdf89ac71e7af4be7004bd1842e7 Mon Sep 17 00:00:00 2001 From: Claude Date: Wed, 2 Sep 2026 16:09:33 +0000 Subject: [PATCH] Fix settings panel crash: AdwEntryRow has no subtitle property (1.0.3) Reported by Core447 (StreamController maintainer) while reviewing the Store submission PR: opening the action's settings threw TypeError: gobject 'AdwEntryRow' doesn't support property 'subtitle' AdwEntryRow only inherits AdwPreferencesRow's 'title' - unlike AdwActionRow/AdwComboRow, it has no 'subtitle' property, so passing one as a GObject construct kwarg crashes immediately. The log-path and sessions-directory rows did this; the third EntryRow (refresh interval) never passed subtitle and was unaffected. Moved the hint text to set_tooltip_text() on each row instead of dropping it. Co-Authored-By: Claude Sonnet 5 Claude-Session: https://claude.ai/code/session_01UJ3K16EeaK24LWUksYKcBd --- CHANGELOG.md | 4 ++++ about.json | 2 +- actions/GrokUsage/GrokUsage.py | 15 +++++++++------ main.py | 2 +- manifest.json | 2 +- 5 files changed, 16 insertions(+), 9 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 073941b..e05e4cd 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,9 @@ # Changelog +## 1.0.3 + +- Fixed the settings panel crashing on open (`TypeError: gobject 'AdwEntryRow' doesn't support property 'subtitle'`), reported by [@Core447](https://github.com/Core447) while reviewing the StreamController Store submission. `AdwEntryRow` has no `subtitle` property (unlike `AdwActionRow`/`AdwComboRow`, which do) — passing one as a construct argument crashed as soon as the log-path or sessions-directory rows were built. Moved that hint text to a tooltip on each row instead. + ## 1.0.2 Real-world fixes from [@parkour86](https://github.com/parkour86) testing against actual Grok Build/SuperGrok installs ([#3](https://github.com/ENjxzlt/Grok-Usage-Streamcontroller/issues/3), [#4](https://github.com/ENjxzlt/Grok-Usage-Streamcontroller/pull/4), [#5](https://github.com/ENjxzlt/Grok-Usage-Streamcontroller/pull/5), [#6](https://github.com/ENjxzlt/Grok-Usage-Streamcontroller/pull/6)): diff --git a/about.json b/about.json index e3d8bd3..909d10b 100644 --- a/about.json +++ b/about.json @@ -2,7 +2,7 @@ "author": "ENjxzlt", "release-notes": { "path": "CHANGELOG.md", - "version": "1.0.2" + "version": "1.0.3" }, "credits": {}, "comments": {}, diff --git a/actions/GrokUsage/GrokUsage.py b/actions/GrokUsage/GrokUsage.py index f6dcd63..596adcd 100644 --- a/actions/GrokUsage/GrokUsage.py +++ b/actions/GrokUsage/GrokUsage.py @@ -332,15 +332,18 @@ def _settings(self) -> dict: def get_config_rows(self) -> list: settings = self._settings() - log_path_row = Adw.EntryRow( - title=self.tr("grok-usage.log-path.title"), subtitle=self.tr("grok-usage.log-path.subtitle") - ) + # AdwEntryRow (unlike AdwActionRow/AdwComboRow below) has no "subtitle" + # property - passing one as a construct kwarg crashes with + # "TypeError: gobject 'AdwEntryRow' doesn't support property + # 'subtitle'" as soon as the settings panel is opened. Set it as a + # tooltip instead so the hint isn't lost entirely. + log_path_row = Adw.EntryRow(title=self.tr("grok-usage.log-path.title")) + log_path_row.set_tooltip_text(self.tr("grok-usage.log-path.subtitle")) log_path_row.set_text(str(settings.get("log_path", DEFAULT_LOG_PATH))) log_path_row.connect("notify::text", self._on_log_path_changed) - sessions_dir_row = Adw.EntryRow( - title=self.tr("grok-usage.sessions-dir.title"), subtitle=self.tr("grok-usage.sessions-dir.subtitle") - ) + sessions_dir_row = Adw.EntryRow(title=self.tr("grok-usage.sessions-dir.title")) + sessions_dir_row.set_tooltip_text(self.tr("grok-usage.sessions-dir.subtitle")) sessions_dir_row.set_text(str(settings.get("sessions_dir", DEFAULT_SESSIONS_DIR))) sessions_dir_row.connect("notify::text", self._on_sessions_dir_changed) diff --git a/main.py b/main.py index 576d1f0..7b8c425 100644 --- a/main.py +++ b/main.py @@ -47,6 +47,6 @@ def __init__(self): self.register( plugin_name=self.lm.get("plugin.name"), github_repo="https://github.com/ENjxzlt/Grok-Usage-Streamcontroller", - plugin_version="1.0.2", + plugin_version="1.0.3", app_version="1.5.0-beta", ) diff --git a/manifest.json b/manifest.json index b1d817c..5690ff0 100644 --- a/manifest.json +++ b/manifest.json @@ -1,5 +1,5 @@ { - "version": "1.0.2", + "version": "1.0.3", "thumbnail": "store/Thumbnail.png", "id": "dev_enjxz_GrokUsage", "name": "Grok Usage",