Bug 2131410

Summary: [abrt] ibus-table: write_xml(): main.py:281:write_xml:AttributeError: 'NoneType' object has no attribute 'lower'
Product: [Fedora] Fedora Reporter: Hin-Tak Leung <htl10>
Component: ibus-tableAssignee: Mike FABIAN <mfabian>
Status: CLOSED ERRATA QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 36CC: dchen, i18n-bugs, kent.neo, mfabian, pwu, shawn.p.huang
Target Milestone: ---   
Target Release: ---   
Hardware: x86_64   
OS: Unspecified   
URL: https://retrace.fedoraproject.org/faf/reports/bthash/e6c479bf49de28d62c46d072a81509919b57d33b
Whiteboard: abrt_hash:c1c988c5171ac578b2c05008cd0b68c23521a949;VARIANT_ID=workstation;
Fixed In Version: ibus-table-1.16.14-1.fc38 ibus-table-1.16.14-1.fc36 ibus-table-1.16.14-1.fc35 ibus-table-1.16.14-1.fc37 Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2022-11-10 14:32:45 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
File: backtrace
none
File: cpuinfo
none
File: environ
none
File: mountinfo
none
File: namespaces
none
File: open_fds none

Description Hin-Tak Leung 2022-09-30 22:29:24 UTC
Description of problem:


Version-Release number of selected component:
ibus-table-1.16.12-1.fc36

Additional info:
reporter:       libreport-2.17.4
cgroup:         0::/system.slice/packagekit.service
cmdline:        /usr/bin/python3 /usr/share/ibus-table/engine/main.py --xml
crash_function: write_xml
exception_type: AttributeError
executable:     /usr/share/ibus-table/engine/main.py
interpreter:    python3-3.10.6-1.fc36.i686
kernel:         5.19.7-200.fc36.x86_64
runlevel:       N 5
type:           Python3
uid:            0

Truncated backtrace:
main.py:281:write_xml:AttributeError: 'NoneType' object has no attribute 'lower'

Traceback (most recent call last):
  File "/usr/share/ibus-table/engine/main.py", line 390, in <module>
    main()
  File "/usr/share/ibus-table/engine/main.py", line 344, in main
    write_xml()
  File "/usr/share/ibus-table/engine/main.py", line 281, in write_xml
    _locale = locale.getlocale(locale.LC_MESSAGES)[0].lower()
AttributeError: 'NoneType' object has no attribute 'lower'

Local variables in innermost frame:
dbs: ['cns11643.db', 'latex.db', 'emoji-table.db']
_all_dbs: ['/usr/share/ibus-table/tables/cns11643.db', '/usr/share/ibus-table/tables/latex.db', '/usr/share/ibus-table/tables/emoji-table.db']
_db: '/usr/share/ibus-table/tables/cns11643.db'
egs: <Element 'engines' at 0x7f808256e390>
_sq_db: <tabsqlitedb.TabSqliteDb object at 0x7f8082bfd900>
_engine: <Element 'engine' at 0x7f808273a3e0>
_name: <Element 'name' at 0x7f808273a5c0>
engine_name: 'cns11643'
setup_arg: '/usr/libexec/ibus-setup-table --engine-name table:cns11643'
_longname: <Element 'longname' at 0x7f808273a840>

Comment 1 Hin-Tak Leung 2022-09-30 22:29:27 UTC
Created attachment 1915369 [details]
File: backtrace

Comment 2 Hin-Tak Leung 2022-09-30 22:29:28 UTC
Created attachment 1915370 [details]
File: cpuinfo

Comment 3 Hin-Tak Leung 2022-09-30 22:29:29 UTC
Created attachment 1915371 [details]
File: environ

Comment 4 Hin-Tak Leung 2022-09-30 22:29:31 UTC
Created attachment 1915372 [details]
File: mountinfo

Comment 5 Hin-Tak Leung 2022-09-30 22:29:32 UTC
Created attachment 1915373 [details]
File: namespaces

Comment 6 Hin-Tak Leung 2022-09-30 22:29:33 UTC
Created attachment 1915374 [details]
File: open_fds

Comment 7 Hin-Tak Leung 2022-10-26 12:27:20 UTC
Similar problem has been detected:

restarting gnome-shell, I think.

reporter:       libreport-2.17.4
cgroup:         0::/system.slice/packagekit.service
cmdline:        /usr/bin/python3 /usr/share/ibus-table/engine/main.py --xml
crash_function: write_xml
exception_type: AttributeError
executable:     /usr/share/ibus-table/engine/main.py
interpreter:    python3-3.10.7-1.fc36.i686
kernel:         5.19.12-200.fc36.x86_64
package:        ibus-table-1.16.12-1.fc36
reason:         main.py:281:write_xml:AttributeError: 'NoneType' object has no attribute 'lower'
runlevel:       N 5
type:           Python3
uid:            0

Comment 8 Hin-Tak Leung 2022-10-31 21:57:53 UTC
Similar problem has been detected:

No idea - don't remember doing anything around then.

reporter:       libreport-2.17.4
cgroup:         0::/system.slice/packagekit.service
cmdline:        /usr/bin/python3 /usr/share/ibus-table/engine/main.py --xml
crash_function: write_xml
exception_type: AttributeError
executable:     /usr/share/ibus-table/engine/main.py
interpreter:    python3-3.10.7-1.fc36.i686
kernel:         6.0.5-200.fc36.x86_64
package:        ibus-table-1.16.12-1.fc36
reason:         main.py:281:write_xml:AttributeError: 'NoneType' object has no attribute 'lower'
runlevel:       N 5
type:           Python3
uid:            0

Comment 9 Mike FABIAN 2022-11-10 08:00:12 UTC
$ LC_MESSAGES=nonsense python3
Python 3.10.6 (main, Aug  2 2022, 00:00:00) [GCC 12.1.1 20220507 (Red Hat 12.1.1-1)] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import locale 
>>> locale.setlocale(locale.LC_ALL, '')
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/usr/lib64/python3.10/locale.py", line 620, in setlocale
    return _setlocale(category, locale)
locale.Error: unsupported locale setting
>>> locale.getlocale(locale.LC_MESSAGES)
(None, None)
>>>

Comment 10 Mike FABIAN 2022-11-10 08:16:33 UTC
Fix (will be in the next release):
https://github.com/mike-fabian/ibus-table/commit/ca296cba952e56a9171b4daed471203c365b4464

Comment 11 Fedora Update System 2022-11-10 14:31:46 UTC
FEDORA-2022-9a3b4c745e has been submitted as an update to Fedora 38. https://bodhi.fedoraproject.org/updates/FEDORA-2022-9a3b4c745e

Comment 12 Fedora Update System 2022-11-10 14:32:45 UTC
FEDORA-2022-9a3b4c745e has been pushed to the Fedora 38 stable repository.
If problem still persists, please make note of it in this bug report.

Comment 13 Fedora Update System 2022-11-10 15:45:12 UTC
FEDORA-2022-b6eda3aa30 has been submitted as an update to Fedora 35. https://bodhi.fedoraproject.org/updates/FEDORA-2022-b6eda3aa30

Comment 14 Fedora Update System 2022-11-10 15:45:38 UTC
FEDORA-2022-af9a944a01 has been submitted as an update to Fedora 36. https://bodhi.fedoraproject.org/updates/FEDORA-2022-af9a944a01

Comment 15 Fedora Update System 2022-11-10 15:46:16 UTC
FEDORA-2022-2daf69d418 has been submitted as an update to Fedora 37. https://bodhi.fedoraproject.org/updates/FEDORA-2022-2daf69d418

Comment 16 Fedora Update System 2022-11-11 02:33:20 UTC
FEDORA-2022-b6eda3aa30 has been pushed to the Fedora 35 testing repository.
Soon you'll be able to install the update with the following command:
`sudo dnf upgrade --enablerepo=updates-testing --refresh --advisory=FEDORA-2022-b6eda3aa30`
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2022-b6eda3aa30

See also https://fedoraproject.org/wiki/QA:Updates_Testing for more information on how to test updates.

Comment 17 Fedora Update System 2022-11-11 02:44:37 UTC
FEDORA-2022-af9a944a01 has been pushed to the Fedora 36 testing repository.
Soon you'll be able to install the update with the following command:
`sudo dnf upgrade --enablerepo=updates-testing --refresh --advisory=FEDORA-2022-af9a944a01`
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2022-af9a944a01

See also https://fedoraproject.org/wiki/QA:Updates_Testing for more information on how to test updates.

Comment 18 Fedora Update System 2022-11-12 04:19:09 UTC
FEDORA-2022-2daf69d418 has been pushed to the Fedora 37 testing repository.
Soon you'll be able to install the update with the following command:
`sudo dnf upgrade --enablerepo=updates-testing --refresh --advisory=FEDORA-2022-2daf69d418`
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2022-2daf69d418

See also https://fedoraproject.org/wiki/QA:Updates_Testing for more information on how to test updates.

Comment 19 Hin-Tak Leung 2022-11-13 21:34:43 UTC
Similar problem has been detected:

Possibly happened when restarting gnome-shell?

reporter:       libreport-2.17.4
cgroup:         0::/system.slice/packagekit.service
cmdline:        /usr/bin/python3 /usr/share/ibus-table/engine/main.py --xml
crash_function: write_xml
exception_type: AttributeError
executable:     /usr/share/ibus-table/engine/main.py
interpreter:    python3-3.10.8-1.fc36.i686
kernel:         6.0.5-200.fc36.x86_64
package:        ibus-table-1.16.13-1.fc36
reason:         main.py:281:write_xml:AttributeError: 'NoneType' object has no attribute 'lower'
runlevel:       N 5
type:           Python3
uid:            0

Comment 20 Fedora Update System 2022-11-19 01:10:23 UTC
FEDORA-2022-af9a944a01 has been pushed to the Fedora 36 stable repository.
If problem still persists, please make note of it in this bug report.

Comment 21 Fedora Update System 2022-11-19 02:49:01 UTC
FEDORA-2022-b6eda3aa30 has been pushed to the Fedora 35 stable repository.
If problem still persists, please make note of it in this bug report.

Comment 22 Fedora Update System 2022-11-20 01:22:57 UTC
FEDORA-2022-2daf69d418 has been pushed to the Fedora 37 stable repository.
If problem still persists, please make note of it in this bug report.