Bug: Changing a setting while Forge is disabled (e.g. screen locked) throws errors; old handlers keep running
评估
- 难度
- 3/5
- 预计耗时
- 1-2 天
- 新手友好度
- 35/100
- Issue 类型
- 缺陷
- 描述清晰度
- 描述清楚
- 活跃度
- 停滞
- 技术栈
- javascript
- 领域
- desktop
调研方向
Read lib/extension/window.js at _bindSignals() (line 300) and the disable path that sets this.settings = null. Disconnect the settings handlers on disable and avoid duplicate connections on enable. Confirm with scenarios/29_settings_after_disable.py: no JS errors and each setting change handled once.
由索引模型根据 Issue 内容生成。
描述
Problem. Forge connects "changed" handlers to its settings, the window manager's (_bindSignals()) and the quick-settings indicator's, and never disconnects them. When Forge is disabled, the extension drops its settings object (this.settings = null), but the handlers stay connected. That happens on the lock screen too (_onSessionModeChanged()). Every later change of a Forge setting runs them, and they throw:
JS ERROR: TypeError: can't access property "get_boolean", this.ext.settings is null
renderTree@.../lib/extension/window.js:1167
_bindSignals/<@.../lib/extension/window.js:300
The same errors show in the journal log attached to #469. After Forge is enabled again, the old handlers keep running next to the new ones.
Desired outcome. Disabling Forge disconnects its settings handlers. Changing a setting while Forge is disabled does nothing, and after it is enabled again each change is handled once.
Acceptance criteria.
- Disable Forge, then change a Forge setting (for example from the preferences, or with
gsettings): no JS errors. - Enable it again: Forge works, and changing a setting raises no errors.
Steps to reproduce.
- With Forge enabled, run
journalctl --user -f -o cat /usr/bin/gnome-shellin a terminal. - Disable Forge (
gnome-extensions disable [email protected], or lock the screen). - Change a Forge setting, for example
gsettings --schemadir ~/.local/share/gnome-shell/extensions/[email protected]/schemas set org.gnome.shell.extensions.forge focus-border-toggle false(from a second terminal or over ssh when the screen is locked). - The journal shows
JS ERROR: TypeError: can't access property "get_boolean", this.ext.settings is nullfor each change.
Automated reproduction: scenarios/29_settings_after_disable.py (in a nested GNOME Shell sandbox; it never touches your session). On main:
FAIL 29.1 settings changed while Forge is disabled: new Forge errors 4 (expected 0)
PASS 29.2 enabled again: a new window tiled: True; new Forge errors 0 (expected 0)
- 主要语言
- JavaScript
- 星标
- 1.3k
- 派生
- 112
- PR 合并指标
- 30 天内没有已合并 PR
环境准备
这个项目没有提供开发容器、Dockerfile 或贡献指南,环境需要你自己搭建:先看它的 README,通用步骤见我们的新手贡献指南。
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
forge-ext/forge 的其他 Issue
-
难度 2/5 1-3 小时 新手友好度 76/100
-
Bug: Windows overlap while resizing, until slower apps catch up可能已有人在做 @mattchristenson 于 39 天前认领。 未关闭
难度 4/5 3-5 天 新手友好度 30/100
-
Bug: Tabbed and stacked groups that contain a split show windows on top of each other可能已有人在做 @mattchristenson 于 39 天前认领。 未关闭
难度 4/5 3-5 天 新手友好度 20/100
-
Bug: Windows in a stacked group are hidden without a trace可能已有人在做 @mattchristenson 于 39 天前认领。 未关闭
难度 4/5 3-5 天 新手友好度 35/100
-
Bug: Toggling stacked or tabbed layout off changes the container's split direction可能已有人在做 @mattchristenson 于 39 天前认领。 未关闭
难度 3/5 1-2 天 新手友好度 30/100
相似的 Issue
-
难度 2/5 1-3 小时 新手友好度 78/100
Fei2411/DeepSeek-Bot#1113 ·
-
bug
难度 2/5 1-3 小时 新手友好度 75/100
arfct/timezone.fyi#19 ·
-
难度 2/5 1-3 小时 新手友好度 82/100
fastify/fastify-http-proxy#493 ·
-
难度 2/5 1-3 小时 新手友好度 76/100
eliasstravik/herdr-projects#785 ·
-
难度 2/5 1-3 小时 新手友好度 82/100
tensorflow/tfjs#8754 ·