From 101058054bb6375f1e3a1c2b75d903747b56a999 Mon Sep 17 00:00:00 2001 From: DhananjayPurohit Date: Wed, 5 Jun 2024 15:10:19 +0530 Subject: [PATCH] fix: lockheight of mercury server --- .github/workflows/tests.yml | 8 +++++++- clients/libs/nodejs/index.js | 3 +++ docker-compose-test.yml | 2 +- 3 files changed, 11 insertions(+), 2 deletions(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 014b8889..1c58f469 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -47,7 +47,7 @@ jobs: docker exec $container_id bitcoin-cli -regtest -rpcuser=user -rpcpassword=pass createwallet $wallet_name address=$(docker exec $container_id bitcoin-cli -regtest -rpcuser=user -rpcpassword=pass getnewaddress $wallet_name) echo "New Wallet Address: $address" - docker exec $container_id bitcoin-cli -regtest -rpcuser=user -rpcpassword=pass generatetoaddress 101 "$address" + docker exec $container_id bitcoin-cli -regtest -rpcuser=user -rpcpassword=pass generatetoaddress 100 "$address" docker exec $container_id bitcoin-cli -regtest -rpcuser=user -rpcpassword=pass sendtoaddress bcrt1pcngfxjdkf4r2h26k52dh5nunxg8m68uf4lkfhmfjvjj6agfkm5jqmftw4e 0.0001 - name: Verify ElectrumX Service with Curl run: | @@ -121,6 +121,12 @@ jobs: run: | cd clients/apps/nodejs node test_basic_workflow2.js + - name: Print environment variables + run: printenv + - name: Print working directory + run: pwd + - name: List files in working directory + run: ls -al - name: Tear Down run: | docker-compose down diff --git a/clients/libs/nodejs/index.js b/clients/libs/nodejs/index.js index f1813be3..add8de25 100644 --- a/clients/libs/nodejs/index.js +++ b/clients/libs/nodejs/index.js @@ -18,6 +18,9 @@ const wallet_manager = require('./wallet'); const getDatabase = async (clientConfig) => { const databaseFile = clientConfig.databaseFile; + const absolutePath = path.resolve(databaseFile); + console.log(`Database file will be created at: ${absolutePath}`); + const db = new sqlite3.Database(databaseFile); await sqlite_manager.createTables(db); return db; diff --git a/docker-compose-test.yml b/docker-compose-test.yml index b94e6d6c..04cb86ed 100644 --- a/docker-compose-test.yml +++ b/docker-compose-test.yml @@ -55,7 +55,7 @@ services: environment: LOCKBOX_URL: http://mercurylayer_enclave-sgx_1:18080 NETWORK: regtest - LOCKHEIGHT_INIT: 1000 + LOCKHEIGHT_INIT: 100 LH_DECREMENT: 10 CONNECTION_STRING: postgres://postgres:pgpassword@postgres:5432/postgres ports: