Version-Release number of selected component: ibus-typing-booster-2.7.0-1.fc31 Additional info: reporter: libreport-2.10.1 cgroup: 0::/user.slice/user-1000.slice/user/gnome-shell-wayland.service cmdline: /usr/bin/python3 /usr/share/ibus-typing-booster/engine/main.py --xml crash_function: makedirs exception_type: FileExistsError executable: /usr/share/ibus-typing-booster/engine/main.py interpreter: python3-3.7.5-1.fc31.x86_64 kernel: 5.3.8-300.fc31.x86_64 runlevel: N 5 type: Python3 uid: 1000 Truncated backtrace: os.py:221:makedirs:FileExistsError: [Errno 17] File exists: '/home/glassy/.local/share/ibus-typing-booster/data' Traceback (most recent call last): File "/usr/share/ibus-typing-booster/engine/main.py", line 34, in <module> import factory File "/usr/share/ibus-typing-booster/engine/factory.py", line 32, in <module> import hunspell_table File "/usr/share/ibus-typing-booster/engine/hunspell_table.py", line 45, in <module> import itb_emoji File "/usr/share/ibus-typing-booster/engine/itb_emoji.py", line 78, in <module> USER_DATADIR = itb_util.xdg_save_data_path('ibus-typing-booster/data') File "/usr/share/ibus-typing-booster/engine/itb_util.py", line 3487, in xdg_save_data_path return xdg.BaseDirectory.save_data_path(*resource) File "/usr/lib/python3.7/site-packages/xdg/BaseDirectory.py", line 70, in save_data_path os.makedirs(path) File "/usr/lib64/python3.7/os.py", line 221, in makedirs mkdir(name, mode) FileExistsError: [Errno 17] File exists: '/home/glassy/.local/share/ibus-typing-booster/data' Local variables in innermost frame: name: '/home/glassy/.local/share/ibus-typing-booster/data' mode: 511 exist_ok: False head: '/home/glassy/.local/share/ibus-typing-booster' tail: 'data' cdir: '.'
Created attachment 1633843 [details] File: backtrace
Created attachment 1633844 [details] File: cpuinfo
Created attachment 1633845 [details] File: environ
Created attachment 1633846 [details] File: mountinfo
Created attachment 1633847 [details] File: namespaces
Created attachment 1633848 [details] File: open_fds
https://bugs.python.org/issue1675
https://stackoverflow.com/questions/1586648/race-condition-creating-folder-in-python
*** Bug 1713963 has been marked as a duplicate of this bug. ***
*** Bug 1764520 has been marked as a duplicate of this bug. ***
*** Bug 1768016 has been marked as a duplicate of this bug. ***
I think this will fix it: $ git show commit 5f0a46a5dbf4f99fb1eae2fd80831f60616007e9 (HEAD -> release-2.7.3) Author: Mike FABIAN <mfabian> Date: Tue Nov 12 17:47:37 2019 +0900 Fix race condition in itb_util.xdg_save_data_path() Resolves: rhbz#1770072 (https://bugzilla.redhat.com/show_bug.cgi?id=1770072) Resolves: rhbz#1713963 (https://bugzilla.redhat.com/show_bug.cgi?id=1713963) Resolves: rhbz#1764520 (https://bugzilla.redhat.com/show_bug.cgi?id=1764520) Resolves: rhbz#1768016 (https://bugzilla.redhat.com/show_bug.cgi?id=1768016) [abrt] ibus-typing-booster: makedirs(): os.py:221:makedirs:FileExistsError: [Errno 17] Fil e exists: '/home/uncle/.local/share/ibus-typing-booster/data' diff --git a/engine/itb_util.py b/engine/itb_util.py index 0494a08..c53fc9b 100644 --- a/engine/itb_util.py +++ b/engine/itb_util.py @@ -3500,17 +3500,23 @@ def xdg_save_data_path(*resource): Compatibility function for systems which do not have pyxdg. (For example openSUSE Leap 42.1) ''' - if IMPORT_XDG_BASEDIRECTORY_SUCCESSFUL: - return xdg.BaseDirectory.save_data_path(*resource) + # if IMPORT_XDG_BASEDIRECTORY_SUCCESSFUL: + # return xdg.BaseDirectory.save_data_path(*resource) + # + # xdg.BaseDirectory.save_data_path(*resource) unfortunately + # can fail because it calls os.makedirs() without the exist_ok=True + # option, and then os.makedirs() can fail in a race condition + # (see: https://bugs.python.org/issue1675) + # # Replicate implementation of xdg.BaseDirectory.save_data_path - # here: + # here (and add the exist_ok=True parameter to os.makedirs()): xdg_data_home = os.environ.get('XDG_DATA_HOME') or os.path.join( os.path.expanduser('~'), '.local', 'share') resource = os.path.join(*resource) assert not resource.startswith('/') path = os.path.join(xdg_data_home, resource) if not os.path.isdir(path): - os.makedirs(path) + os.makedirs(path, exist_ok=True) return path class KeyvalsToKeycodes: lines 1-45/45 (END)
FEDORA-2019-6398f828eb has been submitted as an update to Fedora 29. https://bodhi.fedoraproject.org/updates/FEDORA-2019-6398f828eb
FEDORA-2019-8eb6c00da1 has been submitted as an update to Fedora 30. https://bodhi.fedoraproject.org/updates/FEDORA-2019-8eb6c00da1
FEDORA-2019-41b9e70195 has been submitted as an update to Fedora 31. https://bodhi.fedoraproject.org/updates/FEDORA-2019-41b9e70195
ibus-typing-booster-2.7.3-1.fc29 has been pushed to the Fedora 29 testing repository. If problems still persist, please make note of it in this bug report. See https://fedoraproject.org/wiki/QA:Updates_Testing for instructions on how to install test updates. You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2019-6398f828eb
ibus-typing-booster-2.7.3-1.fc31 has been pushed to the Fedora 31 testing repository. If problems still persist, please make note of it in this bug report. See https://fedoraproject.org/wiki/QA:Updates_Testing for instructions on how to install test updates. You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2019-41b9e70195
ibus-typing-booster-2.7.3-1.fc30 has been pushed to the Fedora 30 testing repository. If problems still persist, please make note of it in this bug report. See https://fedoraproject.org/wiki/QA:Updates_Testing for instructions on how to install test updates. You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2019-8eb6c00da1
*** Bug 1777669 has been marked as a duplicate of this bug. ***
*** Bug 1778985 has been marked as a duplicate of this bug. ***
*** Bug 1778433 has been marked as a duplicate of this bug. ***
*** Bug 1779424 has been marked as a duplicate of this bug. ***
ibus-typing-booster-2.7.3-1.fc30 has been pushed to the Fedora 30 stable repository. If problems still persist, please make note of it in this bug report.
ibus-typing-booster-2.7.3-1.fc31 has been pushed to the Fedora 31 stable repository. If problems still persist, please make note of it in this bug report.
*** Bug 1780080 has been marked as a duplicate of this bug. ***
*** Bug 1780957 has been marked as a duplicate of this bug. ***
*** Bug 1789064 has been marked as a duplicate of this bug. ***
*** Bug 1772726 has been marked as a duplicate of this bug. ***
*** Bug 1773746 has been marked as a duplicate of this bug. ***
*** Bug 1814064 has been marked as a duplicate of this bug. ***