Compare commits

..
6 Commits
Author SHA1 Message Date
Chris Troutner 61d52c8ebe Merge pull request #135 from Permissionless-Software-Foundation/ct-unstable
fix(debugging): Adding additional debugging info to SLP utils
2021-03-26 12:53:35 -08:00
Chris Troutner d89bbe0bf6 fix(debugging): Adding additional debugging info to SLP utils 2021-03-26 13:51:29 -07:00
Chris Troutner 2a1c2500e6 Merge pull request #134 from Permissionless-Software-Foundation/ct-unstable
fix(slp): Adding more verbose error messages for SLP utility functions
2021-03-26 12:16:55 -08:00
Chris Troutner 8879a5170a fix(slp): Adding more verbose error messages for SLP utility functions 2021-03-26 13:11:40 -07:00
Chris Troutner b29cb7c12b Merge pull request #133 from Permissionless-Software-Foundation/ct-unstable
fix(integration tests): slowing down integration tests for the sake o…
2021-03-26 08:28:46 -07:00
Chris Troutner 69fa10d3a6 fix(integration tests): slowing down integration tests for the sake of rate limits 2021-03-26 08:25:39 -07:00
5 changed files with 15 additions and 4 deletions
+11
View File
@@ -1098,6 +1098,7 @@ class Utils {
* }
*/
async tokenUtxoDetails (utxos, usrObj = null) {
console.log('Entering tokenUtxoDetails()')
try {
// Throw error if input is not an array.
if (!Array.isArray(utxos)) throw new Error('Input must be an array.')
@@ -1156,8 +1157,11 @@ class Utils {
}
}
console.log('Existing tokenUtxoDetails()')
return outAry
} catch (error) {
console.log('Error in tokenUtxoDetails()')
if (error.response && error.response.data) throw error.response.data
throw error
}
@@ -1282,6 +1286,7 @@ class Utils {
// If the usrObj has a utxoDelay property, then it will delay the loop for
// each UTXO by that many milliseconds.
async _hydrateUtxo (utxos, usrObj = null) {
console.log('Entering _hydrateUtxo()')
try {
const decodeOpReturnCache = {}
@@ -1501,8 +1506,10 @@ class Utils {
}
}
console.log('Exiting _hydrateUtxo()')
return outAry
} catch (error) {
console.log('Error in _hydrateUtxo()')
// console.log('_hydrateUtxo error: ', error)
throw error
}
@@ -1545,6 +1552,7 @@ class Utils {
* true
*/
async waterfallValidateTxid (txid, usrObj = null) {
console.log('Entering waterfallValidateTxid()')
try {
// console.log('txid: ', txid)
@@ -1634,10 +1642,13 @@ class Utils {
return isValid
}
console.log('Exiting waterfallValidateTxid()')
// If isValid is still null, return that value, signaling that the txid
// could not be validated.
return isValid
} catch (error) {
console.log('Error in waterfallValidateTxid()')
if (error.response && error.response.data) throw error.response.data
throw error
}
@@ -20,7 +20,7 @@ util.inspect.defaultOptions = {
describe('#rawtransaction', () => {
beforeEach(async () => {
if (process.env.IS_USING_FREE_TIER) await sleep(1000)
if (process.env.IS_USING_FREE_TIER) await sleep(3000)
})
/*
+1 -1
View File
@@ -25,7 +25,7 @@ describe('#SLP', () => {
beforeEach(async () => {
// Introduce a delay so that the BVT doesn't trip the rate limits.
if (process.env.IS_USING_FREE_TIER) await sleep(2000)
if (process.env.IS_USING_FREE_TIER) await sleep(3000)
bchjs = new BCHJS()
})
@@ -11,7 +11,7 @@ describe('#UTXO', () => {
beforeEach(async () => {
// sandbox = sinon.createSandbox()
if (process.env.IS_USING_FREE_TIER) await sleep(2000)
if (process.env.IS_USING_FREE_TIER) await sleep(3000)
})
describe('#get', () => {
+1 -1
View File
@@ -24,7 +24,7 @@ describe('#SLP', () => {
beforeEach(async () => {
// Introduce a delay so that the BVT doesn't trip the rate limits.
if (process.env.IS_USING_FREE_TIER) await sleep(1000)
if (process.env.IS_USING_FREE_TIER) await sleep(3000)
bchjs = new BCHJS()
})