@agoric/client-utils 0.1.1-dev-76ad0fc.0 → 0.1.1-dev-5fd303a.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +7 -7
- package/src/sync-tools.js +6 -4
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@agoric/client-utils",
|
|
3
|
-
"version": "0.1.1-dev-
|
|
3
|
+
"version": "0.1.1-dev-5fd303a.0+5fd303a",
|
|
4
4
|
"description": "Utilities for building Agoric clients",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"publishConfig": {
|
|
@@ -27,11 +27,11 @@
|
|
|
27
27
|
"ts-blank-space": "^0.4.1"
|
|
28
28
|
},
|
|
29
29
|
"dependencies": {
|
|
30
|
-
"@agoric/casting": "0.4.3-dev-
|
|
31
|
-
"@agoric/ertp": "0.16.3-dev-
|
|
32
|
-
"@agoric/internal": "0.3.3-dev-
|
|
33
|
-
"@agoric/smart-wallet": "0.5.4-dev-
|
|
34
|
-
"@agoric/vats": "0.15.2-dev-
|
|
30
|
+
"@agoric/casting": "0.4.3-dev-5fd303a.0+5fd303a",
|
|
31
|
+
"@agoric/ertp": "0.16.3-dev-5fd303a.0+5fd303a",
|
|
32
|
+
"@agoric/internal": "0.3.3-dev-5fd303a.0+5fd303a",
|
|
33
|
+
"@agoric/smart-wallet": "0.5.4-dev-5fd303a.0+5fd303a",
|
|
34
|
+
"@agoric/vats": "0.15.2-dev-5fd303a.0+5fd303a",
|
|
35
35
|
"@cosmjs/stargate": "^0.32.3",
|
|
36
36
|
"@cosmjs/tendermint-rpc": "^0.32.3",
|
|
37
37
|
"@endo/common": "^1.2.7",
|
|
@@ -58,5 +58,5 @@
|
|
|
58
58
|
],
|
|
59
59
|
"timeout": "20m"
|
|
60
60
|
},
|
|
61
|
-
"gitHead": "
|
|
61
|
+
"gitHead": "5fd303aa11d393f2f6ceefe0ad83ba8cf5178a44"
|
|
62
62
|
}
|
package/src/sync-tools.js
CHANGED
|
@@ -41,10 +41,12 @@ export const sleep = (ms, { log = () => {}, setTimeout }) =>
|
|
|
41
41
|
/**
|
|
42
42
|
* From https://github.com/Agoric/agoric-sdk/blob/442f07c8f0af03281b52b90e90c27131eef6f331/multichain-testing/tools/sleep.ts#L24
|
|
43
43
|
*
|
|
44
|
-
* @
|
|
45
|
-
* @param {(
|
|
44
|
+
* @template [T=unknown]
|
|
45
|
+
* @param {() => Promise<T>} operation
|
|
46
|
+
* @param {(result: T) => boolean} condition
|
|
46
47
|
* @param {string} message
|
|
47
48
|
* @param {RetryOptions & {log?: typeof console.log, setTimeout: typeof global.setTimeout}} options
|
|
49
|
+
* @returns {Promise<T>}
|
|
48
50
|
*/
|
|
49
51
|
export const retryUntilCondition = async (
|
|
50
52
|
operation,
|
|
@@ -183,7 +185,7 @@ const checkCosmosBalance = (balances, threshold) => {
|
|
|
183
185
|
|
|
184
186
|
/**
|
|
185
187
|
* @param {string} destAcct
|
|
186
|
-
* @param {{ log
|
|
188
|
+
* @param {{ log?: (message: string) => void, query: () => Promise<object>, setTimeout: typeof global.setTimeout}} io
|
|
187
189
|
* @param {{denom: string, value: number}} threshold
|
|
188
190
|
* @param {WaitUntilOptions} options
|
|
189
191
|
*/
|
|
@@ -232,7 +234,7 @@ const checkOfferState = (offerStatus, waitForPayouts, offerId) => {
|
|
|
232
234
|
* @param {string} addr
|
|
233
235
|
* @param {string} offerId
|
|
234
236
|
* @param {boolean} waitForPayouts
|
|
235
|
-
* @param {{ log
|
|
237
|
+
* @param {{ log?: typeof console.log, follow: () => object, setTimeout: typeof global.setTimeout }} io
|
|
236
238
|
* @param {WaitUntilOptions} options
|
|
237
239
|
*/
|
|
238
240
|
export const waitUntilOfferResult = (
|