Bug 2224145

Summary: [abrt] terminator: get_menu_item_mask(): terminal_popup_menu.py:33:get_menu_item_mask:AttributeError: 'NoneType' object has no attribute 'lower'
Product: [Fedora] Fedora Reporter: Azyrod <fmichaut74>
Component: terminatorAssignee: Dominic Hopf <dmaphy>
Status: NEW --- QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 38CC: dmaphy, fmichaut74, mattrose
Target Milestone: ---   
Target Release: ---   
Hardware: x86_64   
OS: Unspecified   
URL: https://retrace.fedoraproject.org/faf/reports/bthash/cece7c901e3a7bc753208b8ed1db5c6308b4735
Whiteboard: abrt_hash:49551506ae5ed33402ad27101403c87d8290e0c3;VARIANT_ID=;
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 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: open_fds
none
File: namespaces
none
File: environ
none
File: os_info
none
File: mountinfo
none
File: backtrace
none
File: cpuinfo none

Description Azyrod 2023-07-20 00:25:30 UTC
Description of problem:
I tried to right click in terminator to open the context menu.

I currently cannot access the menu anymore - I cannot go to terminator settings anymore

Version-Release number of selected component:
terminator-2.1.3-1.fc38

Additional info:
reporter:       libreport-2.17.11
exception_type: AttributeError
uid:            1000
interpreter:    python3-3.11.4-1.fc38.x86_64
cmdline:        /usr/bin/python3 -sP /usr/bin/terminator -m
crash_function: get_menu_item_mask
reason:         terminal_popup_menu.py:33:get_menu_item_mask:AttributeError: 'NoneType' object has no attribute 'lower'
executable:     /usr/bin/terminator
kernel:         6.3.12-200.fc38.x86_64
cgroup:         0::/user.slice/user-1000.slice/session-2.scope
type:           Python3
package:        terminator-2.1.3-1.fc38
runlevel:       N 5

Truncated backtrace:
terminal_popup_menu.py:33:get_menu_item_mask:AttributeError: 'NoneType' object has no attribute 'lower'

Traceback (most recent call last):
  File "/usr/lib/python3.11/site-packages/terminatorlib/terminal.py", line 1031, in on_buttonpress
    right_click[0](*right_click[1])
  File "/usr/lib/python3.11/site-packages/terminatorlib/terminal.py", line 1077, in popup_menu
    menu.show(widget, event)
  File "/usr/lib/python3.11/site-packages/terminatorlib/terminal_popup_menu.py", line 270, in show
    item = self.menu_item(Gtk.CheckMenuItem, 'toggle_scrollbar',
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.11/site-packages/terminatorlib/terminal_popup_menu.py", line 55, in menu_item
    mask    = self.get_menu_item_mask(maskstr)
              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.11/site-packages/terminatorlib/terminal_popup_menu.py", line 33, in get_menu_item_mask
    maskstr = maskstr.lower()
              ^^^^^^^^^^^^^
AttributeError: 'NoneType' object has no attribute 'lower'

Local variables in innermost frame:
self: <terminatorlib.terminal_popup_menu.TerminalPopupMenu object at 0x7fb70ca11590>
maskstr: None
mask: 0

Comment 1 Azyrod 2023-07-20 00:25:34 UTC
Created attachment 1976612 [details]
File: open_fds

Comment 2 Azyrod 2023-07-20 00:25:36 UTC
Created attachment 1976613 [details]
File: namespaces

Comment 3 Azyrod 2023-07-20 00:25:37 UTC
Created attachment 1976614 [details]
File: environ

Comment 4 Azyrod 2023-07-20 00:25:39 UTC
Created attachment 1976615 [details]
File: os_info

Comment 5 Azyrod 2023-07-20 00:25:40 UTC
Created attachment 1976616 [details]
File: mountinfo

Comment 6 Azyrod 2023-07-20 00:25:42 UTC
Created attachment 1976617 [details]
File: backtrace

Comment 7 Azyrod 2023-07-20 00:25:43 UTC
Created attachment 1976618 [details]
File: cpuinfo

Comment 8 Matt Rose 2023-07-20 04:28:37 UTC
You've disabled the keybinding for toggle_scrollbar in .config/terminator/config.  There was a bug introduced in 2.1.3 that causes the context menu not to render properly if items in the contexet menu do not have a keybinding.  This is fixed in masterm, but If you remove the toggle_scrollbar = None line from your config file while I release a new version your context menu will work again