ElectrumX 1.4.3
Close connections more aggressively on shutdown We need VERSION in its own file, unfortunately Fixes #442
This commit is contained in:
parent
142aa48dbb
commit
1a0eea25c3
@ -1,6 +1,11 @@
|
|||||||
ChangeLog
|
ChangeLog
|
||||||
=========
|
=========
|
||||||
|
|
||||||
|
Version 1.4.3
|
||||||
|
-------------
|
||||||
|
|
||||||
|
* Fix `#442`_.
|
||||||
|
|
||||||
Version 1.4.2
|
Version 1.4.2
|
||||||
-------------
|
-------------
|
||||||
|
|
||||||
@ -137,3 +142,4 @@ LKaFk4KkVpw9pYoUpbckQSKKgCVC4oj78b
|
|||||||
.. _#287: https://github.com/kyuupichan/electrumx/issues/287
|
.. _#287: https://github.com/kyuupichan/electrumx/issues/287
|
||||||
.. _#301: https://github.com/kyuupichan/electrumx/issues/301
|
.. _#301: https://github.com/kyuupichan/electrumx/issues/301
|
||||||
.. _#302: https://github.com/kyuupichan/electrumx/issues/302
|
.. _#302: https://github.com/kyuupichan/electrumx/issues/302
|
||||||
|
.. _#442: https://github.com/kyuupichan/electrumx/issues/442
|
||||||
|
|||||||
@ -28,6 +28,7 @@ from server.daemon import DaemonError
|
|||||||
from server.mempool import MemPool
|
from server.mempool import MemPool
|
||||||
from server.peers import PeerManager
|
from server.peers import PeerManager
|
||||||
from server.session import LocalRPC, BAD_REQUEST, DAEMON_ERROR
|
from server.session import LocalRPC, BAD_REQUEST, DAEMON_ERROR
|
||||||
|
from server.version import VERSION
|
||||||
|
|
||||||
|
|
||||||
class SessionGroup(object):
|
class SessionGroup(object):
|
||||||
@ -48,7 +49,7 @@ class Controller(ServerBase):
|
|||||||
CATCHING_UP, LISTENING, PAUSED, SHUTTING_DOWN = range(4)
|
CATCHING_UP, LISTENING, PAUSED, SHUTTING_DOWN = range(4)
|
||||||
PROTOCOL_MIN = '1.0'
|
PROTOCOL_MIN = '1.0'
|
||||||
PROTOCOL_MAX = '1.2'
|
PROTOCOL_MAX = '1.2'
|
||||||
VERSION = 'ElectrumX 1.4.2'
|
VERSION = VERSION
|
||||||
|
|
||||||
def __init__(self, env):
|
def __init__(self, env):
|
||||||
'''Initialize everything that doesn't require the event loop.'''
|
'''Initialize everything that doesn't require the event loop.'''
|
||||||
@ -140,7 +141,7 @@ class Controller(ServerBase):
|
|||||||
# Close servers and sessions, and cancel all tasks
|
# Close servers and sessions, and cancel all tasks
|
||||||
self.close_servers(list(self.servers.keys()))
|
self.close_servers(list(self.servers.keys()))
|
||||||
for session in self.sessions:
|
for session in self.sessions:
|
||||||
self.close_session(session)
|
session.abort()
|
||||||
self.tasks.cancel_all()
|
self.tasks.cancel_all()
|
||||||
|
|
||||||
# Wait for the above to take effect
|
# Wait for the above to take effect
|
||||||
|
|||||||
@ -491,6 +491,7 @@ class PeerManager(object):
|
|||||||
await self.retry_peers()
|
await self.retry_peers()
|
||||||
finally:
|
finally:
|
||||||
for session in list(PeerSession.sessions):
|
for session in list(PeerSession.sessions):
|
||||||
|
session.abort()
|
||||||
await session.wait_closed()
|
await session.wait_closed()
|
||||||
|
|
||||||
def is_coin_onion_peer(self, peer):
|
def is_coin_onion_peer(self, peer):
|
||||||
|
|||||||
1
server/version.py
Normal file
1
server/version.py
Normal file
@ -0,0 +1 @@
|
|||||||
|
VERSION = 'ElectrumX 1.4.3'
|
||||||
6
setup.py
6
setup.py
@ -1,10 +1,10 @@
|
|||||||
import setuptools
|
import setuptools
|
||||||
from server.controller import Controller
|
from server.version import VERSION
|
||||||
|
|
||||||
|
|
||||||
setuptools.setup(
|
setuptools.setup(
|
||||||
name='electrumx',
|
name='electrumx',
|
||||||
version=Controller.short_version(),
|
version=VERSION,
|
||||||
scripts=['electrumx_server.py', 'electrumx_rpc.py'],
|
scripts=['electrumx_server.py', 'electrumx_rpc.py'],
|
||||||
python_requires='>=3.6',
|
python_requires='>=3.6',
|
||||||
# via environment variables, in which case I've tested with 15.0.4
|
# via environment variables, in which case I've tested with 15.0.4
|
||||||
@ -17,7 +17,7 @@ setuptools.setup(
|
|||||||
author='Neil Booth',
|
author='Neil Booth',
|
||||||
author_email='kyuupichan@gmail.com',
|
author_email='kyuupichan@gmail.com',
|
||||||
license='MIT Licence',
|
license='MIT Licence',
|
||||||
url='https://github.com/kyuupichan/electrumx/',
|
url='https://github.com/kyuupichan/electrumx',
|
||||||
long_description='Server implementation for the Electrum wallet',
|
long_description='Server implementation for the Electrum wallet',
|
||||||
classifiers=[
|
classifiers=[
|
||||||
'Development Status :: 5 - Production/Stable',
|
'Development Status :: 5 - Production/Stable',
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user