coins: Update DASH version.

See https://github.com/dashpay/dash/releases/tag/v19.1.0
When upgrading from a version < 19.0, a migration process will occur.

It's recommended to start the DASH node manually to complete the migration and get on the correct chain.
This commit is contained in:
tecnovert 2023-06-18 22:00:27 +02:00
parent 57554d4fec
commit 04d4d89e96
No known key found for this signature in database
GPG key ID: 8ED6D8750C4E3F93
2 changed files with 24 additions and 8 deletions

View file

@ -55,7 +55,7 @@ XMR_SITE_COMMIT = 'a3b195eb90c7d5564cc9d9ec09c873783d21901b' # Lock hashes.txt
PIVX_VERSION = os.getenv('PIVX_VERSION', '5.5.0') PIVX_VERSION = os.getenv('PIVX_VERSION', '5.5.0')
PIVX_VERSION_TAG = os.getenv('PIVX_VERSION_TAG', '') PIVX_VERSION_TAG = os.getenv('PIVX_VERSION_TAG', '')
DASH_VERSION = os.getenv('DASH_VERSION', '18.1.0') DASH_VERSION = os.getenv('DASH_VERSION', '19.1.0')
DASH_VERSION_TAG = os.getenv('DASH_VERSION_TAG', '') DASH_VERSION_TAG = os.getenv('DASH_VERSION_TAG', '')
FIRO_VERSION = os.getenv('FIRO_VERSION', '0.14.99.1') FIRO_VERSION = os.getenv('FIRO_VERSION', '0.14.99.1')
@ -1094,7 +1094,7 @@ def initialise_wallets(particl_wallet_mnemonic, with_coins, data_dir, settings,
try: try:
swap_client = BasicSwap(fp, data_dir, settings, chain) swap_client = BasicSwap(fp, data_dir, settings, chain)
coins_to_create_wallets_for = (Coins.PART, Coins.BTC, Coins.LTC) coins_to_create_wallets_for = (Coins.PART, Coins.BTC, Coins.LTC, Coins.DASH)
# Always start Particl, it must be running to initialise a wallet in addcoin mode # Always start Particl, it must be running to initialise a wallet in addcoin mode
# Particl must be loaded first as subsequent coins are initialised from the Particl mnemonic # Particl must be loaded first as subsequent coins are initialised from the Particl mnemonic
start_daemons = ['particl', ] + [c for c in with_coins if c != 'particl'] start_daemons = ['particl', ] + [c for c in with_coins if c != 'particl']

View file

@ -287,13 +287,23 @@ class Test(unittest.TestCase):
btc_data_dir = os.path.join(cfg.TEST_DATADIRS, str(BTC_NODE)) btc_data_dir = os.path.join(cfg.TEST_DATADIRS, str(BTC_NODE))
if os.path.exists(os.path.join(cfg.BITCOIN_BINDIR, 'bitcoin-wallet')): if os.path.exists(os.path.join(cfg.BITCOIN_BINDIR, 'bitcoin-wallet')):
logging.info('Creating BTC wallet.')
try: try:
callrpc_cli(cfg.BITCOIN_BINDIR, btc_data_dir, 'regtest', '-wallet=wallet.dat -legacy create', 'bitcoin-wallet') callrpc_cli(cfg.BITCOIN_BINDIR, btc_data_dir, 'regtest', '-wallet=wallet.dat -legacy create', 'bitcoin-wallet')
except Exception: except Exception:
callrpc_cli(cfg.BITCOIN_BINDIR, btc_data_dir, 'regtest', '-wallet=wallet.dat create', 'bitcoin-wallet') callrpc_cli(cfg.BITCOIN_BINDIR, btc_data_dir, 'regtest', '-wallet=wallet.dat create', 'bitcoin-wallet')
cls.daemons.append(startDaemon(btc_data_dir, cfg.BITCOIN_BINDIR, cfg.BITCOIND)) cls.daemons.append(startDaemon(btc_data_dir, cfg.BITCOIN_BINDIR, cfg.BITCOIND))
logging.info('Started %s %d', cfg.BITCOIND, cls.daemons[-1].pid) logging.info('Started %s %d', cfg.BITCOIND, cls.daemons[-1].pid)
cls.daemons.append(startDaemon(os.path.join(cfg.TEST_DATADIRS, str(DASH_NODE)), cfg.DASH_BINDIR, cfg.DASHD))
dash_data_dir = os.path.join(cfg.TEST_DATADIRS, str(DASH_NODE))
'''
dash-wallet does not seem to create valid wallet files.
if os.path.exists(os.path.join(cfg.DASH_BINDIR, 'dash-wallet')):
logging.info('Creating DASH wallet.')
callrpc_cli(cfg.DASH_BINDIR, dash_data_dir, 'regtest', '-wallet=wallet.dat create', 'dash-wallet')
'''
cls.daemons.append(startDaemon(dash_data_dir, cfg.DASH_BINDIR, cfg.DASHD))
logging.info('Started %s %d', cfg.DASHD, cls.daemons[-1].pid) logging.info('Started %s %d', cfg.DASHD, cls.daemons[-1].pid)
for i in range(NUM_NODES): for i in range(NUM_NODES):
@ -326,12 +336,18 @@ class Test(unittest.TestCase):
settings = json.load(fs) settings = json.load(fs)
fp = open(os.path.join(basicswap_dir, 'basicswap.log'), 'w') fp = open(os.path.join(basicswap_dir, 'basicswap.log'), 'w')
cls.swap_clients.append(BasicSwap(fp, basicswap_dir, settings, 'regtest', log_name='BasicSwap{}'.format(i))) cls.swap_clients.append(BasicSwap(fp, basicswap_dir, settings, 'regtest', log_name='BasicSwap{}'.format(i)))
cls.swap_clients[-1].setDaemonPID(Coins.BTC, cls.daemons[0].pid) swap_client = cls.swap_clients[-1]
cls.swap_clients[-1].setDaemonPID(Coins.DASH, cls.daemons[1].pid) swap_client.setDaemonPID(Coins.BTC, cls.daemons[0].pid)
cls.swap_clients[-1].setDaemonPID(Coins.PART, cls.daemons[2 + i].pid) swap_client.setDaemonPID(Coins.DASH, cls.daemons[1].pid)
cls.swap_clients[-1].start() swap_client.setDaemonPID(Coins.PART, cls.daemons[2 + i].pid)
t = HttpThread(cls.swap_clients[i].fp, TEST_HTTP_HOST, TEST_HTTP_PORT + i, False, cls.swap_clients[i]) waitForRPC(dashRpc, expect_wallet=False)
if len(dashRpc('listwallets')) < 1:
dashRpc('createwallet wallet.dat')
swap_client.start()
t = HttpThread(cls.swap_clients[i].fp, TEST_HTTP_HOST, TEST_HTTP_PORT + i, False, swap_client)
cls.http_threads.append(t) cls.http_threads.append(t)
t.start() t.start()