Browse Source

irc: fix logging on connection lost

add-joinmarket
zebra-lucky 1 year ago
parent
commit
ff73e62333
  1. 2
      electrum/plugins/joinmarket/jm_qt.py
  2. 7
      electrum/plugins/joinmarket/jmdaemon/irc.py
  3. 4
      electrum/plugins/joinmarket/notes.txt

2
electrum/plugins/joinmarket/jm_qt.py

@ -1500,7 +1500,7 @@ class SpendTab(QWidget):
# complexity/duplication # complexity/duplication
if (self.spendstate.typestate == 'multiple' if (self.spendstate.typestate == 'multiple'
and not self.tumbler_options): and not self.tumbler_options):
self.taker.jmman.wallet.save_db() # FIXME? self.taker.jmman.wallet.save_db()
return return
if fromtx: if fromtx:
if res: if res:

7
electrum/plugins/joinmarket/jmdaemon/irc.py

@ -220,9 +220,10 @@ class txIRC_Client(IRCClient):
IRCClient.connection_made(self, transport) IRCClient.connection_made(self, transport)
def connection_lost(self, reason): def connection_lost(self, reason):
wlog(self.logger, "INFO", msg = f'Lost IRC connection to: {self.hostname}.'
"Lost IRC connection to: " + str(self.hostname) + if not self.wrapper.give_up:
" . Should reconnect automatically soon.") msg += ' Should reconnect automatically soon.'
wlog(self.logger, "INFO", msg)
if not self.wrapper.give_up and self.wrapper.on_disconnect: if not self.wrapper.give_up and self.wrapper.on_disconnect:
commands.callLater(0.0, self.wrapper.on_disconnect, self.wrapper) commands.callLater(0.0, self.wrapper.on_disconnect, self.wrapper)
IRCClient.connection_lost(self, reason) IRCClient.connection_lost(self, reason)

4
electrum/plugins/joinmarket/notes.txt

@ -1,9 +1,5 @@
------------------------------------------------------------------------------- -------------------------------------------------------------------------------
plugin: plugin:
- change message on JMDLG.shutdown:
> 62.08 | I | J/plugins.joinmarket.jm_main.JMManager.[wallet_jm] |
Lost IRC connection to: irc1.dword.ga . Should reconnect automatically soon.
- jm_wallet.py: look where to add save_db
- потрібно якось документувати - потрібно якось документувати
- окремий пункт до якого я взагалі ще не дійшов це qml gui - окремий пункт до якого я взагалі ще не дійшов це qml gui
- jm_qt_obwatch: advanced sorting by columns, filter by text - jm_qt_obwatch: advanced sorting by columns, filter by text

Loading…
Cancel
Save