Opened 6 years ago

Closed 6 years ago

#5971 closed defect (fixed)

TB: NameError: global name 'reason' is not defined when destroying a room

Reported by: Zash Owned by:
Priority: normal Milestone: 0.15
Component: None Version: hg
Severity: normal Keywords: patch
Cc: Blocked By:
Blocking: OS: All


Bug description

Traceback (most recent call last):
  File "/home/zash/src/gajim/src/common/xmpp/", line 528, in _process_events
    return IdleQueue._process_events(self, fd, flags)
  File "/home/zash/src/gajim/src/common/xmpp/", line 393, in _process_events
  File "/home/zash/src/gajim/src/common/xmpp/", line 414, in pollin
  File "/home/zash/src/gajim/src/common/xmpp/", line 600, in _do_receive
  File "/home/zash/src/gajim/src/common/xmpp/", line 614, in _on_receive
  File "/home/zash/src/gajim/src/common/xmpp/", line 452, in dispatch
    handler['func'](session, stanza)
  File "/home/zash/src/gajim/src/common/", line 1773, in _presenceCB
    conn=self, iq_obj=prs))
  File "/home/zash/src/gajim/src/common/", line 62, in push_incoming_event
  File "/home/zash/src/gajim/src/common/", line 80, in _generate_events_based_on_incoming_event
    if new_event_object.generate():
  File "/home/zash/src/gajim/src/common/", line 720, in generate
    conn=self.conn, iq_obj=self.iq_obj, presence_obj=self))
  File "/home/zash/src/gajim/src/common/", line 61, in push_incoming_event
    gajim.ged.raise_event(, event_object)
  File "/home/zash/src/gajim/src/common/", line 70, in raise_event
    if handler(*args, **kwargs):
  File "/home/zash/src/gajim/src/", line 1399, in _nec_gc_presence_received
    self.print_conversation(reason, 'info', graphics=False)
NameError: global name 'reason' is not defined

Steps to reproduce

Destroy a room without entering a reason

Attachments (1)

5971.patch (601 bytes) - added by Zash 6 years ago.

Download all attachments as: .zip

Change History (3)

Changed 6 years ago by Zash

comment:1 Changed 6 years ago by Zash

  • Keywords patch added

It was when handling the <presence/> saying the room was destroyed. Attached a patch that seems to fix it.

comment:2 Changed 6 years ago by Yann Leboulanger <asterix@…>

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

(In [54e44a287300]) [Zash] fix wrong var name. Fixes #5971

Note: See TracTickets for help on using tickets.