tests: fix tearDown() issue in test_lnrouter.py
similar to 05fd424548
from logs when running tests:
--- Logging error ---
Traceback (most recent call last):
File "...\Python39\lib\logging\__init__.py", line 1082, in emit
stream.write(msg + self.terminator)
ValueError: I/O operation on closed file.
Call stack:
File "...\Python39\lib\threading.py", line 912, in _bootstrap
self._bootstrap_inner()
File "...\Python39\lib\threading.py", line 954, in _bootstrap_inner
self.run()
File "...\Python39\lib\threading.py", line 892, in run
self._target(*self._args, **self._kwargs)
File "...\electrum\electrum\sql_db.py", line 71, in run_sql
self.logger.info("SQL thread terminated")
Message: 'SQL thread terminated'
Arguments: ()
This commit is contained in:
@@ -67,8 +67,8 @@ class SqlDB(Logger):
|
||||
self.conn.commit()
|
||||
self.conn.close()
|
||||
|
||||
self.asyncio_loop.call_soon_threadsafe(self.stopped_event.set)
|
||||
self.logger.info("SQL thread terminated")
|
||||
self.asyncio_loop.call_soon_threadsafe(self.stopped_event.set)
|
||||
|
||||
def create_database(self):
|
||||
raise NotImplementedError()
|
||||
|
||||
Reference in New Issue
Block a user