Skip to content

Commit

Permalink
fix: host for node server
Browse files Browse the repository at this point in the history
  • Loading branch information
DhananjayPurohit committed Aug 12, 2024
1 parent 31fe519 commit 4567efe
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion clients/libs/web/wallet.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import utils from './utils.js';
const createWallet = async (clientConfig, name) => {

await init(wasmUrl);

console.log(`${clientConfig.esploraServer}/api/blocks/tip/height`)
const response = await axios.get(`${clientConfig.esploraServer}/api/blocks/tip/height`);

const blockheight = response.data;
Expand Down
4 changes: 2 additions & 2 deletions clients/tests/web/test-utils.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ const generateBlocks = async (blocks) => {
blocks
};

const url = `http://0.0.0.0:3000/generate_blocks`;
const url = `http://node-server:3000/generate_blocks`;

let response = await axios.post(url, body);

Expand All @@ -21,7 +21,7 @@ const depositCoin = async (address, amount) => {
amount
};

const url = `http://0.0.0.0:3000/deposit_amount`;
const url = `http://node-server:3000/deposit_amount`;

let response = await axios.post(url, body);

Check failure on line 26 in clients/tests/web/test-utils.js

View workflow job for this annotation

GitHub Actions / test

test/ta02-duplicate-deposits.test.js > TA02 - Duplicated Deposits > withdraw flow

AxiosError: Network Error ❯ XMLHttpRequest.handleError ../../../../../../../../node_modules/.vite/deps/axios.js:1581:14 ❯ Axios.request ../../../../../../../../node_modules/.vite/deps/axios.js:2067:41 ❯ depositCoin test-utils.js:26:20 ❯ test/ta02-duplicate-deposits.test.js:29:9 ⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯ Serialized Error: { config: { transitional: { silentJSONParsing: true, forcedJSONParsing: true, clarifyTimeoutError: false }, adapter: [ 'xhr', 'http', 'fetch' ], transformRequest: [ 'Function<transformRequest>' ], transformResponse: [ 'Function<transformResponse>' ], timeout: +0, xsrfCookieName: 'XSRF-TOKEN', xsrfHeaderName: 'X-XSRF-TOKEN', maxContentLength: -1, maxBodyLength: -1, env: { FormData: 'Function<FormData>', Blob: 'Function<Blob>' }, validateStatus: 'Function<validateStatus>', headers: { Accept: 'application/json, text/plain, */*', 'Content-Type': 'application/json' }, method: 'post', url: 'http://node-server:3000/deposit_amount', data: '{"address":"bcrt1pkygl356c6fvk6ptx72c64hrjkhcxecj4hjzfzc430svzczuv6m0s42lvwx","amount":1000}' }, code: 'ERR_NETWORK', status: null }

Check failure on line 26 in clients/tests/web/test-utils.js

View workflow job for this annotation

GitHub Actions / test

test/ta02-duplicate-deposits.test.js > TA02 - Duplicated Deposits > transfer flow

AxiosError: Network Error ❯ XMLHttpRequest.handleError ../../../../../../../../node_modules/.vite/deps/axios.js:1581:14 ❯ Axios.request ../../../../../../../../node_modules/.vite/deps/axios.js:2067:41 ❯ depositCoin test-utils.js:26:20 ❯ test/ta02-duplicate-deposits.test.js:126:9 ⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯ Serialized Error: { config: { transitional: { silentJSONParsing: true, forcedJSONParsing: true, clarifyTimeoutError: false }, adapter: [ 'xhr', 'http', 'fetch' ], transformRequest: [ 'Function<transformRequest>' ], transformResponse: [ 'Function<transformResponse>' ], timeout: +0, xsrfCookieName: 'XSRF-TOKEN', xsrfHeaderName: 'X-XSRF-TOKEN', maxContentLength: -1, maxBodyLength: -1, env: { FormData: 'Function<FormData>', Blob: 'Function<Blob>' }, validateStatus: 'Function<validateStatus>', headers: { Accept: 'application/json, text/plain, */*', 'Content-Type': 'application/json' }, method: 'post', url: 'http://node-server:3000/deposit_amount', data: '{"address":"bcrt1prpqakttp48gkaay9ejq97eq4zza9ltyn0ff8jcr30q55647vhulqlq6twu","amount":1000}' }, code: 'ERR_NETWORK', status: null }

Check failure on line 26 in clients/tests/web/test-utils.js

View workflow job for this annotation

GitHub Actions / test

test/ta02-duplicate-deposits.test.js > TA02 - Duplicated Deposits > withdraw flow

AxiosError: Network Error ❯ XMLHttpRequest.handleError ../../../../../../../../node_modules/.vite/deps/axios.js:1581:14 ❯ Axios.request ../../../../../../../../node_modules/.vite/deps/axios.js:2067:41 ❯ depositCoin test-utils.js:26:20 ❯ test/ta02-duplicate-deposits.test.js:29:9 ⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯ Serialized Error: { config: { transitional: { silentJSONParsing: true, forcedJSONParsing: true, clarifyTimeoutError: false }, adapter: [ 'xhr', 'http', 'fetch' ], transformRequest: [ 'Function<transformRequest>' ], transformResponse: [ 'Function<transformResponse>' ], timeout: +0, xsrfCookieName: 'XSRF-TOKEN', xsrfHeaderName: 'X-XSRF-TOKEN', maxContentLength: -1, maxBodyLength: -1, env: { FormData: 'Function<FormData>', Blob: 'Function<Blob>' }, validateStatus: 'Function<validateStatus>', headers: { Accept: 'application/json, text/plain, */*', 'Content-Type': 'application/json' }, method: 'post', url: 'http://node-server:3000/deposit_amount', data: '{"address":"bcrt1pd7kvrar9w03nvy72q530wklz3m0w2mpm672s7c9a3la6rpg3y9cq6hw4tu","amount":1000}' }, code: 'ERR_NETWORK', status: null }

Check failure on line 26 in clients/tests/web/test-utils.js

View workflow job for this annotation

GitHub Actions / test

test/ta02-duplicate-deposits.test.js > TA02 - Duplicated Deposits > transfer flow

AxiosError: Network Error ❯ XMLHttpRequest.handleError ../../../../../../../../node_modules/.vite/deps/axios.js:1581:14 ❯ Axios.request ../../../../../../../../node_modules/.vite/deps/axios.js:2067:41 ❯ depositCoin test-utils.js:26:20 ❯ test/ta02-duplicate-deposits.test.js:126:9 ⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯ Serialized Error: { config: { transitional: { silentJSONParsing: true, forcedJSONParsing: true, clarifyTimeoutError: false }, adapter: [ 'xhr', 'http', 'fetch' ], transformRequest: [ 'Function<transformRequest>' ], transformResponse: [ 'Function<transformResponse>' ], timeout: +0, xsrfCookieName: 'XSRF-TOKEN', xsrfHeaderName: 'X-XSRF-TOKEN', maxContentLength: -1, maxBodyLength: -1, env: { FormData: 'Function<FormData>', Blob: 'Function<Blob>' }, validateStatus: 'Function<validateStatus>', headers: { Accept: 'application/json, text/plain, */*', 'Content-Type': 'application/json' }, method: 'post', url: 'http://node-server:3000/deposit_amount', data: '{"address":"bcrt1pqpgmg2g05ju3jt0jrwa9nyvl9uf3v8eqghk784c4dc8qg2djversjchpuz","amount":1000}' }, code: 'ERR_NETWORK', status: null }

Check failure on line 26 in clients/tests/web/test-utils.js

View workflow job for this annotation

GitHub Actions / test

test/tb01-simple-transfer.test.js > TB01 - Simple Transfer > expected flow

AxiosError: Network Error ❯ XMLHttpRequest.handleError ../../../../../../../../node_modules/.vite/deps/axios.js:1581:14 ❯ Axios.request ../../../../../../../../node_modules/.vite/deps/axios.js:2067:41 ❯ depositCoin test-utils.js:26:20 ❯ test/tb01-simple-transfer.test.js:29:9 ⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯ Serialized Error: { config: { transitional: { silentJSONParsing: true, forcedJSONParsing: true, clarifyTimeoutError: false }, adapter: [ 'xhr', 'http', 'fetch' ], transformRequest: [ 'Function<transformRequest>' ], transformResponse: [ 'Function<transformResponse>' ], timeout: +0, xsrfCookieName: 'XSRF-TOKEN', xsrfHeaderName: 'X-XSRF-TOKEN', maxContentLength: -1, maxBodyLength: -1, env: { FormData: 'Function<FormData>', Blob: 'Function<Blob>' }, validateStatus: 'Function<validateStatus>', headers: { Accept: 'application/json, text/plain, */*', 'Content-Type': 'application/json' }, method: 'post', url: 'http://node-server:3000/deposit_amount', data: '{"address":"bcrt1p8yzuh632j8glps48qa909eyv4rrhzktl9pnt3vypca0dm6dm97rsnapn45","amount":1000}' }, code: 'ERR_NETWORK', status: null }

Check failure on line 26 in clients/tests/web/test-utils.js

View workflow job for this annotation

GitHub Actions / test

test/tb01-simple-transfer.test.js > TB01 - Simple Transfer > expected flow

AxiosError: Network Error ❯ XMLHttpRequest.handleError ../../../../../../../../node_modules/.vite/deps/axios.js:1581:14 ❯ Axios.request ../../../../../../../../node_modules/.vite/deps/axios.js:2067:41 ❯ depositCoin test-utils.js:26:20 ❯ test/tb01-simple-transfer.test.js:29:9 ⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯ Serialized Error: { config: { transitional: { silentJSONParsing: true, forcedJSONParsing: true, clarifyTimeoutError: false }, adapter: [ 'xhr', 'http', 'fetch' ], transformRequest: [ 'Function<transformRequest>' ], transformResponse: [ 'Function<transformResponse>' ], timeout: +0, xsrfCookieName: 'XSRF-TOKEN', xsrfHeaderName: 'X-XSRF-TOKEN', maxContentLength: -1, maxBodyLength: -1, env: { FormData: 'Function<FormData>', Blob: 'Function<Blob>' }, validateStatus: 'Function<validateStatus>', headers: { Accept: 'application/json, text/plain, */*', 'Content-Type': 'application/json' }, method: 'post', url: 'http://node-server:3000/deposit_amount', data: '{"address":"bcrt1psvugt6a8dgjksz9t2s8vvawwh9rrtmwft3ut4kd068c36dj8araqcsry59","amount":1000}' }, code: 'ERR_NETWORK', status: null }

Check failure on line 26 in clients/tests/web/test-utils.js

View workflow job for this annotation

GitHub Actions / test

test/tb03-simple-atomic-transfer.test.js > TB03 - Simple Atomic Transfer > expected flow

AxiosError: Network Error ❯ XMLHttpRequest.handleError ../../../../../../../../node_modules/.vite/deps/axios.js:1581:14 ❯ Axios.request ../../../../../../../../node_modules/.vite/deps/axios.js:2067:41 ❯ depositCoin test-utils.js:26:20 ❯ test/tb03-simple-atomic-transfer.test.js:40:9 ⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯ Serialized Error: { config: { transitional: { silentJSONParsing: true, forcedJSONParsing: true, clarifyTimeoutError: false }, adapter: [ 'xhr', 'http', 'fetch' ], transformRequest: [ 'Function<transformRequest>' ], transformResponse: [ 'Function<transformResponse>' ], timeout: +0, xsrfCookieName: 'XSRF-TOKEN', xsrfHeaderName: 'X-XSRF-TOKEN', maxContentLength: -1, maxBodyLength: -1, env: { FormData: 'Function<FormData>', Blob: 'Function<Blob>' }, validateStatus: 'Function<validateStatus>', headers: { Accept: 'application/json, text/plain, */*', 'Content-Type': 'application/json' }, method: 'post', url: 'http://node-server:3000/deposit_amount', data: '{"address":"bcrt1p5v3td77mf3jgtlu0e6s0pd54684c2ecra26ctre344ucymtqwlzspv8pxx","amount":1000}' }, code: 'ERR_NETWORK', status: null }

Check failure on line 26 in clients/tests/web/test-utils.js

View workflow job for this annotation

GitHub Actions / test

test/tb03-simple-atomic-transfer.test.js > TB03 - Simple Atomic Transfer > expected flow

AxiosError: Network Error ❯ XMLHttpRequest.handleError ../../../../../../../../node_modules/.vite/deps/axios.js:1581:14 ❯ Axios.request ../../../../../../../../node_modules/.vite/deps/axios.js:2067:41 ❯ depositCoin test-utils.js:26:20 ❯ test/tb03-simple-atomic-transfer.test.js:40:9 ⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯ Serialized Error: { config: { transitional: { silentJSONParsing: true, forcedJSONParsing: true, clarifyTimeoutError: false }, adapter: [ 'xhr', 'http', 'fetch' ], transformRequest: [ 'Function<transformRequest>' ], transformResponse: [ 'Function<transformResponse>' ], timeout: +0, xsrfCookieName: 'XSRF-TOKEN', xsrfHeaderName: 'X-XSRF-TOKEN', maxContentLength: -1, maxBodyLength: -1, env: { FormData: 'Function<FormData>', Blob: 'Function<Blob>' }, validateStatus: 'Function<validateStatus>', headers: { Accept: 'application/json, text/plain, */*', 'Content-Type': 'application/json' }, method: 'post', url: 'http://node-server:3000/deposit_amount', data: '{"address":"bcrt1pe3tkq6aumqmwgnssgjnym447e9wn6dqs4wyg0dl2ulgzkgyle63sy8p9tq","amount":1000}' }, code: 'ERR_NETWORK', status: null }

Check failure on line 26 in clients/tests/web/test-utils.js

View workflow job for this annotation

GitHub Actions / test

test/tb04-simple-lightning-latch.test.js > TB04 - Simple Lightning Latch > expected flow

AxiosError: Network Error ❯ XMLHttpRequest.handleError ../../../../../../../../node_modules/.vite/deps/axios.js:1581:14 ❯ Axios.request ../../../../../../../../node_modules/.vite/deps/axios.js:2067:41 ❯ depositCoin test-utils.js:26:20 ❯ test/tb04-simple-lightning-latch.test.js:59:9 ⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯ Serialized Error: { config: { transitional: { silentJSONParsing: true, forcedJSONParsing: true, clarifyTimeoutError: false }, adapter: [ 'xhr', 'http', 'fetch' ], transformRequest: [ 'Function<transformRequest>' ], transformResponse: [ 'Function<transformResponse>' ], timeout: +0, xsrfCookieName: 'XSRF-TOKEN', xsrfHeaderName: 'X-XSRF-TOKEN', maxContentLength: -1, maxBodyLength: -1, env: { FormData: 'Function<FormData>', Blob: 'Function<Blob>' }, validateStatus: 'Function<validateStatus>', headers: { Accept: 'application/json, text/plain, */*', 'Content-Type': 'application/json' }, method: 'post', url: 'http://node-server:3000/deposit_amount', data: '{"address":"bcrt1p2dhhjcxs6vw7j8wngnjpck7d8lfaaxxf4xrxysmptnyfx7rx4s9sahnspv","amount":1000}' }, code: 'ERR_NETWORK', status: null }

Check failure on line 26 in clients/tests/web/test-utils.js

View workflow job for this annotation

GitHub Actions / test

test/tb04-simple-lightning-latch.test.js > TB04 - Simple Lightning Latch > expected flow

AxiosError: Network Error ❯ XMLHttpRequest.handleError ../../../../../../../../node_modules/.vite/deps/axios.js:1581:14 ❯ Axios.request ../../../../../../../../node_modules/.vite/deps/axios.js:2067:41 ❯ depositCoin test-utils.js:26:20 ❯ test/tb04-simple-lightning-latch.test.js:59:9 ⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯ Serialized Error: { config: { transitional: { silentJSONParsing: true, forcedJSONParsing: true, clarifyTimeoutError: false }, adapter: [ 'xhr', 'http', 'fetch' ], transformRequest: [ 'Function<transformRequest>' ], transformResponse: [ 'Function<transformResponse>' ], timeout: +0, xsrfCookieName: 'XSRF-TOKEN', xsrfHeaderName: 'X-XSRF-TOKEN', maxContentLength: -1, maxBodyLength: -1, env: { FormData: 'Function<FormData>', Blob: 'Function<Blob>' }, validateStatus: 'Function<validateStatus>', headers: { Accept: 'application/json, text/plain, */*', 'Content-Type': 'application/json' }, method: 'post', url: 'http://node-server:3000/deposit_amount', data: '{"address":"bcrt1pzzqr9t0kwztfglart2yfzue32cm7msd0nw3mpqkwpy42xu3djq7s8xaztw","amount":1000}' }, code: 'ERR_NETWORK', status: null }

Expand Down

0 comments on commit 4567efe

Please sign in to comment.