https://bugzilla.redhat.com/show_bug.cgi?id=2171140
Bug ID: 2171140 Summary: [abrt] ibus-typing-booster: on_gsettings_value_changed(): hunspell_table.py:7038:on_gsettings_value_changed:Attr ibuteError: 'TypingBoosterEngine' object has no attribute '_set_get_functions' Product: Fedora Version: 37 Hardware: x86_64 Status: NEW Whiteboard: abrt_hash:55bb325f294216e1e5be0a1ae112085ddc7a8f5d;VAR IANT_ID=workstation; Component: ibus-typing-booster Assignee: mfabian@redhat.com Reporter: fedora@oursique.net QA Contact: extras-qa@fedoraproject.org CC: anish.developer@gmail.com, i18n-bugs@lists.fedoraproject.org, mfabian@redhat.com Target Milestone: --- Classification: Fedora
Version-Release number of selected component: ibus-typing-booster-2.21.3-1.fc37
Additional info: reporter: libreport-2.17.4 cgroup: 0::/user.slice/user-1000.slice/user@1000.service/session.slice/org.freedesktop.IBus.session.GNOME.service cmdline: /usr/bin/python3 /usr/share/ibus-typing-booster/engine/main.py --ibus crash_function: on_gsettings_value_changed exception_type: AttributeError executable: /usr/share/ibus-typing-booster/engine/main.py interpreter: python3-3.11.1-3.fc37.x86_64 kernel: 6.1.11-200.fc37.x86_64 runlevel: N 5 type: Python3 uid: 1000
Truncated backtrace: hunspell_table.py:7038:on_gsettings_value_changed:AttributeError: 'TypingBoosterEngine' object has no attribute '_set_get_functions'
Traceback (most recent call last): File "/usr/share/ibus-typing-booster/engine/hunspell_table.py", line 7038, in on_gsettings_value_changed if (key in self._set_get_functions ^^^^^^^^^^^^^^^^^^^^^^^ AttributeError: 'TypingBoosterEngine' object has no attribute '_set_get_functions'
Local variables in innermost frame: self: <hunspell_table.TypingBoosterEngine object at 0x7f19f751a600 (hunspell_table+TypingBoosterEngine at 0x5562b24f1130)> _settings: <Gio.Settings object at 0x7f19f7317880 (GSettings at 0x5562b1c30a60)> key: 'dictionary' value: 'en_US_POSIX,fr,fr_FR'
https://bugzilla.redhat.com/show_bug.cgi?id=2171140
Mike FABIAN mfabian@redhat.com changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |gustaw.daniel@gmail.com
--- Comment #7 from Mike FABIAN mfabian@redhat.com --- *** Bug 2171129 has been marked as a duplicate of this bug. ***
https://bugzilla.redhat.com/show_bug.cgi?id=2171140
Mike FABIAN mfabian@redhat.com changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |mihai@lazarescu.org
--- Comment #8 from Mike FABIAN mfabian@redhat.com --- *** Bug 2170023 has been marked as a duplicate of this bug. ***
https://bugzilla.redhat.com/show_bug.cgi?id=2171140
Mike FABIAN mfabian@redhat.com changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |rodrigojvallejos@gmail.com
--- Comment #9 from Mike FABIAN mfabian@redhat.com --- *** Bug 2169586 has been marked as a duplicate of this bug. ***
https://bugzilla.redhat.com/show_bug.cgi?id=2171140
Mike FABIAN mfabian@redhat.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |ASSIGNED Doc Type|--- |If docs needed, set a value
--- Comment #11 from Mike FABIAN mfabian@redhat.com --- Is there any procedure how to reproduce this? Looking at the dictionary settings 'en_US_POSIX,fr,fr_FR' I guess it has something to do with the on-screen-keyboard (OSK).
https://bugzilla.redhat.com/show_bug.cgi?id=2171140
--- Comment #13 from Mike FABIAN mfabian@redhat.com --- I find it also very strange that the traceback complains about a missing _set_get_functions
Traceback (most recent call last): File "/usr/share/ibus-typing-booster/engine/hunspell_table.py", line 7038, in on_gsettings_value_changed if (key in self._set_get_functions ^^^^^^^^^^^^^^^^^^^^^^^ AttributeError: 'TypingBoosterEngine' object has no attribute '_set_get_functions'
because that exists:
mfabian@hathi:/local/mfabian/src/ibus-typing-booster ((2.21.3) $) $ git grep self._set_get_functions engine/hunspell_table.py: self._set_get_functions: Dict[str, Dict[str, Any]] = { engine/hunspell_table.py: or setting not in self._set_get_functions engine/hunspell_table.py: or 'set' not in self._set_get_functions[setting] engine/hunspell_table.py: or 'get' not in self._set_get_functions[setting]): engine/hunspell_table.py: current_value = self._set_get_functions[setting]['get']() engine/hunspell_table.py: self._set_get_functions[setting]['set']( engine/hunspell_table.py: self._set_get_functions[setting]['set']( engine/hunspell_table.py: if (key in self._set_get_functions engine/hunspell_table.py: and 'set' in self._set_get_functions[key]): engine/hunspell_table.py: self._set_get_functions[key]['set'](value, update_gsettings=False) lines 1-10/10 (END)
And when I trigger the call of the `on_gsettings_value_changed` function on the command line with
$ dconf write /org/freedesktop/ibus/engine/typing-booster/dictionary "'en_US_POSIX,fr,fr_FR'" $ dconf write /org/freedesktop/ibus/engine/typing-booster/dictionary "'de_DE,it_IT,en_GB,fr_FR'"
I see that the function is called in the debug log, and not only is it called but it does what it is supposed to do, i.e. change the dictionary settings.
mfabian@hathi:~ $ tail -F ~/.local/share/ibus-typing-booster/debug.log | grep on_gsettings_value 2023-02-21 21:26:23,712 hunspell_table.py line 7037 on_gsettings_value_changed DEBUG: Settings changed: key=dictionary value=en_US_POSIX,fr,fr_FR 2023-02-21 21:26:30,395 hunspell_table.py line 7037 on_gsettings_value_changed DEBUG: Settings changed: key=dictionary value=de_DE,it_IT,en_GB,fr_FR
That function is very simple:
def on_gsettings_value_changed( self, _settings: Gio.Settings, key: str) -> None: ''' Called when a value in the settings has been changed.
:param settings: The settings object :param key: The key of the setting which has changed ''' value = itb_util.variant_to_value(self._gsettings.get_value(key)) LOGGER.debug('Settings changed: key=%s value=%s\n', key, value) if (key in self._set_get_functions and 'set' in self._set_get_functions[key]): self._set_get_functions[key]['set'](value, update_gsettings=False) return LOGGER.warning('Unknown key\n') return
and if it failed as in the backtrace, I would not see the effect of setting the dictionaries.
https://bugzilla.redhat.com/show_bug.cgi?id=2171140
--- Comment #15 from Mihai Lazarescu mihai@lazarescu.org --- This has happened to me quite often and for many months now. I filled in the steps to reproduce it in my notebook in the bug 2172442.
Press the lock screen button (ASUS DUO). The screen is both locked and getting dark. Then press the power button to suspend to memory. The locked screen flashes on briefly, then starts the suspend procedure. It waits for a while, without progress (30s or so) Then it shows an error with some register dumps. I guess that somewhere in the two steps above happens the crash. Then I'm returned to the lock screen. I press the power button again the suspend went on regularly.
Given the talks on the other similar bugs, I think there is a race condition, where ibus-typing-buster expects some module to be loaded (e.g, the on-screen keyboard, while it may take some time to be pulled up. BTW, I have the on-screen keyboard blocked in my Gnome session using the "Block Caribou" extension.
https://bugzilla.redhat.com/show_bug.cgi?id=2171140
--- Comment #16 from Paul Hernaus paul@hernaus.com --- Similar problem has been detected:
On the Surface Go 2: - Open Firefox - Open new tab - Disable the keyboad by folding it behind the display or disconnecting it - "Click" the URL field with your finger
reporter: libreport-2.17.4 cgroup: 0::/user.slice/user-1000.slice/user@1000.service/session.slice/org.freedesktop.IBus.session.GNOME.service cmdline: /usr/bin/python3 /usr/share/ibus-typing-booster/engine/main.py --ibus crash_function: on_gsettings_value_changed exception_type: AttributeError executable: /usr/share/ibus-typing-booster/engine/main.py interpreter: python3-3.11.1-3.fc37.x86_64 kernel: 6.1.12-200.fc37.x86_64 package: ibus-typing-booster-2.21.3-1.fc37 reason: hunspell_table.py:7038:on_gsettings_value_changed:AttributeError: 'TypingBoosterEngine' object has no attribute '_set_get_functions' runlevel: N 5 type: Python3 uid: 1000
https://bugzilla.redhat.com/show_bug.cgi?id=2171140
--- Comment #17 from robin@rkslot.nl --- Similar problem has been detected:
I don't know exactly, it appeared after I enabled the virtual keyboard and attempted to get it to show up. It did show up.
reporter: libreport-2.17.4 cgroup: 0::/user.slice/user-1000.slice/user@1000.service/session.slice/org.freedesktop.IBus.session.GNOME.service cmdline: /usr/bin/python3 /usr/share/ibus-typing-booster/engine/main.py --ibus crash_function: on_gsettings_value_changed exception_type: AttributeError executable: /usr/share/ibus-typing-booster/engine/main.py interpreter: python3-3.11.1-3.fc37.x86_64 kernel: 6.1.12-200.fc37.x86_64 package: ibus-typing-booster-2.21.3-1.fc37 reason: hunspell_table.py:7038:on_gsettings_value_changed:AttributeError: 'TypingBoosterEngine' object has no attribute '_set_get_functions' runlevel: N 5 type: Python3 uid: 1000
https://bugzilla.redhat.com/show_bug.cgi?id=2171140
fujiwara tfujiwar@redhat.com changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |tfujiwar@redhat.com
--- Comment #20 from fujiwara tfujiwar@redhat.com --- I tried to switch OSK and physical keyboard but I cannot reproduce any SEGVs. Could you provide the reproducing steps with detail?
https://bugzilla.redhat.com/show_bug.cgi?id=2171140
--- Comment #22 from Mike FABIAN mfabian@redhat.com --- (In reply to fujiwara from comment #20)
I tried to switch OSK and physical keyboard but I cannot reproduce any SEGVs. Could you provide the reproducing steps with detail?
Until now, I was never able to reproduce this myself. I still cannot reproduce this. It is a complete mystery to me how this can happen.
See this comment: https://bugzilla.redhat.com/show_bug.cgi?id=2171140#c13
The backtrace complains about self._set_get_functions not existing, but that definitely exists *and* works.
https://bugzilla.redhat.com/show_bug.cgi?id=2171140
Mike FABIAN mfabian@redhat.com changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |abhirup.m92@gmail.com
--- Comment #24 from Mike FABIAN mfabian@redhat.com --- *** Bug 2176816 has been marked as a duplicate of this bug. ***
https://bugzilla.redhat.com/show_bug.cgi?id=2171140
Mike FABIAN mfabian@redhat.com changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |droidbittin@gmail.com
--- Comment #25 from Mike FABIAN mfabian@redhat.com --- *** Bug 2175663 has been marked as a duplicate of this bug. ***
https://bugzilla.redhat.com/show_bug.cgi?id=2171140
--- Comment #26 from Denis Smal denissmal@yahoo.com --- Upgrade from Fedora 37 to Fedora 38
reporter: libreport-2.17.9 runlevel: N 5 crash_function: on_gsettings_value_changed executable: /usr/share/ibus-typing-booster/engine/main.py package: ibus-typing-booster-2.22.2-1.fc37 type: Python3 cmdline: /usr/bin/python3 /usr/share/ibus-typing-booster/engine/main.py --ibus reason: hunspell_table.py:7050:on_gsettings_value_changed:AttributeError: 'TypingBoosterEngine' object has no attribute '_set_get_functions' exception_type: AttributeError kernel: 5.17.5-300.fc36.x86_64 interpreter: python3-3.11.3-1.fc37.x86_64 cgroup: 0::/user.slice/user-1000.slice/user@1000.service/session.slice/org.freedesktop.IBus.session.GNOME.service comment: Upgrade from Fedora 37 to Fedora 38 uid: 1000
https://bugzilla.redhat.com/show_bug.cgi?id=2171140
--- Comment #27 from D. Hugh Redelmeier hugh@mimosa.com --- I didn't notice this crash so I don't know what I was doing at the time.
reporter: libreport-2.17.10 uid: 1104 interpreter: python3-3.11.1-3.fc37.x86_64 cgroup: 0::/user.slice/user-1104.slice/user@1104.service/session.slice/org.freedesktop.IBus.session.GNOME.service package: ibus-typing-booster-2.21.0-1.fc37 kernel: 6.1.10-200.fc37.x86_64 type: Python3 exception_type: AttributeError executable: /usr/share/ibus-typing-booster/engine/main.py comment: I didn't notice this crash so I don't know what I was doing at the time. reason: hunspell_table.py:7038:on_gsettings_value_changed:AttributeError: 'TypingBoosterEngine' object has no attribute '_set_get_functions' crash_function: on_gsettings_value_changed cmdline: /usr/bin/python3 /usr/share/ibus-typing-booster/engine/main.py --ibus runlevel: N 5
https://bugzilla.redhat.com/show_bug.cgi?id=2171140
--- Comment #28 from xingkunliu@qq.com --- Just reboot the device and the error always shows
reporter: libreport-2.17.9 kernel: 6.3.3-1.surface.fc38.x86_64 cmdline: /usr/bin/python3 /usr/share/ibus-typing-booster/engine/main.py --ibus cgroup: 0::/user.slice/user-1000.slice/user@1000.service/session.slice/org.freedesktop.IBus.session.GNOME.service uid: 1000 reason: hunspell_table.py:7050:on_gsettings_value_changed:AttributeError: 'TypingBoosterEngine' object has no attribute '_set_get_functions' executable: /usr/share/ibus-typing-booster/engine/main.py type: Python3 package: ibus-typing-booster-2.22.1-1.fc38 runlevel: N 5 exception_type: AttributeError crash_function: on_gsettings_value_changed interpreter: python3-3.11.2-1.fc38.x86_64 comment: Just reboot the device and the error always shows
https://bugzilla.redhat.com/show_bug.cgi?id=2171140
Mike FABIAN mfabian@redhat.com changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |nos1609@hotmail.com
--- Comment #29 from Mike FABIAN mfabian@redhat.com --- *** Bug 2188139 has been marked as a duplicate of this bug. ***
https://bugzilla.redhat.com/show_bug.cgi?id=2171140
Mike FABIAN mfabian@redhat.com changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |redhar@moonman.dk
--- Comment #30 from Mike FABIAN mfabian@redhat.com --- *** Bug 2188251 has been marked as a duplicate of this bug. ***
https://bugzilla.redhat.com/show_bug.cgi?id=2171140
Mike FABIAN mfabian@redhat.com changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |dramisgiorgio@outlook.com
--- Comment #31 from Mike FABIAN mfabian@redhat.com --- *** Bug 2189279 has been marked as a duplicate of this bug. ***
https://bugzilla.redhat.com/show_bug.cgi?id=2171140
Mike FABIAN mfabian@redhat.com changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |vgerris@gmail.com
--- Comment #32 from Mike FABIAN mfabian@redhat.com --- *** Bug 2189797 has been marked as a duplicate of this bug. ***
https://bugzilla.redhat.com/show_bug.cgi?id=2171140
Mike FABIAN mfabian@redhat.com changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |amitverma@gmail.com
--- Comment #33 from Mike FABIAN mfabian@redhat.com --- *** Bug 2219585 has been marked as a duplicate of this bug. ***
https://bugzilla.redhat.com/show_bug.cgi?id=2171140
Mike FABIAN mfabian@redhat.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Version|37 |38
https://bugzilla.redhat.com/show_bug.cgi?id=2171140
--- Comment #34 from hiroppy zusann123@gmail.com --- fcitx5ã®è¨å®ãã¡ã¤ã«ã«ibus-mozcã®è¨å®ãè¨è¿°ãã¦ãã¾ãã¾ããã
~/.config/environment.d ãã£ã¬ã¯ããªé ä¸ã«"00-fcitx5.conf"ã以ä¸ã®å容ã§ä½æã
INPUT_METHOD=ibus-mozc GTK_IM_MODULE=ibus-mozc QT_IM_MODULE=ibus-mozc XMODIFIERS=@im=ibus-mozc
reporter: libreport-2.17.11 exception_type: AttributeError executable: /usr/share/ibus-typing-booster/engine/main.py package: ibus-typing-booster-2.23.1-1.fc38 reason: hunspell_table.py:7118:on_gsettings_value_changed:AttributeError: 'TypingBoosterEngine' object has no attribute '_set_get_functions' interpreter: python3-3.11.4-1.fc38.x86_64 type: Python3 runlevel: N 5 crash_function: on_gsettings_value_changed cmdline: /usr/bin/python3 /usr/share/ibus-typing-booster/engine/main.py --ibus uid: 1000 kernel: 6.3.12-200.fc38.x86_64
https://bugzilla.redhat.com/show_bug.cgi?id=2171140
--- Comment #35 from Mike FABIAN mfabian@redhat.com --- I may have finally understood the problem.
self._gsettings.connect('changed', self.on_gsettings_value_changed)
is in line 162 of __init__() and the variable self._set_get_functions is later defined in __init__() in line 619.
So with unlucky timing the method self.on_gsettings_value_changed might be called already before self._set_get_functions is defined and then that method fails because it needs that variable.
I hope this idea is correct as I am still unable to reproduce the problem myself but this idea is probably correct.
So I think I can finally fix this.
https://bugzilla.redhat.com/show_bug.cgi?id=2171140
--- Comment #36 from Mike FABIAN mfabian@redhat.com --- ibus-typing-booster-2.23.2 should fix this: https://github.com/mike-fabian/ibus-typing-booster/releases/tag/2.23.2
https://bugzilla.redhat.com/show_bug.cgi?id=2171140
Mike FABIAN mfabian@redhat.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Link ID| |Github | |mike-fabian/ibus-typing-boo | |ster/issues/454
https://bugzilla.redhat.com/show_bug.cgi?id=2171140
Mike FABIAN mfabian@redhat.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Status|ASSIGNED |MODIFIED
--- Comment #37 from Mike FABIAN mfabian@redhat.com --- Fedora 37: https://bodhi.fedoraproject.org/updates/FEDORA-2023-a5849d935f Fedora 38: https://bodhi.fedoraproject.org/updates/FEDORA-2023-8ad4948a00
https://bugzilla.redhat.com/show_bug.cgi?id=2171140
--- Comment #38 from Erik Nord nindoone+bugzilla@gmail.com --- Screen keyboard over gnome terminal after fresh boot
reporter: libreport-2.17.11 kernel: 6.4.6-200.fc38.x86_64 cmdline: /usr/bin/python3 /usr/share/ibus-typing-booster/engine/main.py --ibus cgroup: 0::/user.slice/user-1000.slice/user@1000.service/session.slice/org.freedesktop.IBus.session.GNOME.service uid: 1000 reason: hunspell_table.py:7118:on_gsettings_value_changed:AttributeError: 'TypingBoosterEngine' object has no attribute '_set_get_functions' executable: /usr/share/ibus-typing-booster/engine/main.py type: Python3 package: ibus-typing-booster-2.23.1-1.fc38 runlevel: N 5 exception_type: AttributeError crash_function: on_gsettings_value_changed interpreter: python3-3.11.4-1.fc38.x86_64 comment: Screen keyboard over gnome terminal after fresh boot
https://bugzilla.redhat.com/show_bug.cgi?id=2171140
--- Comment #39 from Konstantinos loveisfoss@gmail.com --- Laptop turned on from suspend by opening lid. Could not write anything (physical keyboard disabled). Solved by opening the laptop keyboard side completely, by turning it into a full tablet, and then remaking it into a laptop to trigger the transition from a laptop to tablet again.
reporter: libreport-2.17.11 kernel: 6.4.6-200.fc38.x86_64 cmdline: /usr/bin/python3 /usr/share/ibus-typing-booster/engine/main.py --ibus cgroup: 0::/user.slice/user-1000.slice/user@1000.service/session.slice/org.freedesktop.IBus.session.GNOME.service uid: 1000 reason: hunspell_table.py:7118:on_gsettings_value_changed:AttributeError: 'TypingBoosterEngine' object has no attribute '_set_get_functions' executable: /usr/share/ibus-typing-booster/engine/main.py type: Python3 package: ibus-typing-booster-2.23.1-1.fc38 runlevel: N 5 exception_type: AttributeError crash_function: on_gsettings_value_changed interpreter: python3-3.11.4-1.fc38.x86_64
https://bugzilla.redhat.com/show_bug.cgi?id=2171140
--- Comment #40 from Jonathan Haas jonha87@outlook.de --- enabling on screen keyboard
reporter: libreport-2.17.9 executable: /usr/share/ibus-typing-booster/engine/main.py exception_type: AttributeError type: Python3 uid: 1000 interpreter: python3-3.11.2-1.fc38.i686 runlevel: N 5 kernel: 6.2.9-300.fc38.x86_64 reason: hunspell_table.py:7050:on_gsettings_value_changed:AttributeError: 'TypingBoosterEngine' object has no attribute '_set_get_functions' comment: enabling on screen keyboard crash_function: on_gsettings_value_changed cgroup: 0::/user.slice/user-1000.slice/user@1000.service/session.slice/org.freedesktop.IBus.session.GNOME.service cmdline: /usr/bin/python3 /usr/share/ibus-typing-booster/engine/main.py --ibus package: ibus-typing-booster-2.22.1-1.fc38
https://bugzilla.redhat.com/show_bug.cgi?id=2171140
Parag Nemade pnemade@redhat.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Resolution|--- |CURRENTRELEASE Status|MODIFIED |CLOSED Last Closed| |2024-01-22 10:13:33
i18n-bugs@lists.fedoraproject.org