Opened 8 years ago

Closed 8 years ago

#4076 closed defect (fixed)

TBs after right-clicking on group name when zero contacts on-line

Reported by: rabio Owned by: asterix
Priority: normal Milestone: 0.12
Component: None Version: hg
Severity: normal Keywords:
Cc: Blocked By:
Blocking: OS: All

Description

After disconnect and right-clicking on some group name (but not on a single contact) I got this Traceback:

Traceback (most recent call last):
  File "/home/rabio/tmp/gajim/gajim/src/roster_window.py", line 2865, in on_roster_treeview_button_press_event
    return self.show_treeview_menu(event)
  File "/tmp/gajim/gajim/src/roster_window.py", line 5683, in show_treeview_menu
    self.show_appropriate_context_menu(event, iters)
  File "/tmp/gajim/gajim/src/roster_window.py", line 5655, in show_appropriate_context_menu
    self.make_group_menu(event, iters[0])
  File "/tmp/gajim/gajim/src/roster_window.py", line 4724, in make_group_menu
    self.build_invite_submenu(invite_menuitem, list_online)
  File "/tmp/gajim/gajim/src/roster_window.py", line 5516, in build_invite_submenu
    if gajim.capscache.is_supported(contact, NS_MUC):
UnboundLocalError: local variable 'contact' referenced before assignment

Change History (4)

comment:1 Changed 8 years ago by anonymous

  • Milestone set to 0.12

comment:2 Changed 8 years ago by rabio

  • Summary changed from TB after disconnect and right-clicking on group name to TBs after right-clicking on group name

Now, I got similar TB when I'm connected too:

Traceback (most recent call last):
  File "/tmp/gajim/gajim/src/roster_window.py", line 2845, in on_roster_treeview_button_press_event
    return self.show_treeview_menu(event)
  File "/tmp/gajim/gajim/src/roster_window.py", line 5664, in show_treeview_menu
    self.show_appropriate_context_menu(event, iters)
  File "/tmp/gajim/gajim/src/roster_window.py", line 5636, in show_appropriate_context_menu
    self.make_group_menu(event, iters[0])
  File "/tmp/gajim/gajim/src/roster_window.py", line 4705, in make_group_menu
    self.build_invite_submenu(invite_menuitem, list_online)
  File "/tmp/gajim/gajim/src/roster_window.py", line 5497, in build_invite_submenu
    if gajim.capscache.is_supported(contact, NS_MUC):
UnboundLocalError: local variable 'contact' referenced before assignment

comment:3 Changed 8 years ago by rabio

  • Summary changed from TBs after right-clicking on group name to TBs after right-clicking on group name when zero contacts on-line

My recently investigation showed that problem is related to availability of contacts in group. When all contacts in some groups are off-line, then right-clicking on this group name (but not on one of contacts from it) produce a Traceback like those I showed before.

comment:4 Changed 8 years ago by steve-e

  • Resolution set to fixed
  • Status changed from new to closed

(In [d01a12b8320a5d73d3ac8bc2eea70c53025d3ec9]) Fix two caps related tracebacks:

Quick fix: What does not exist cannot support anything. Fixes #4031. Fix variable referencing. Fixes #4076.

Note: See TracTickets for help on using tickets.