@agoric/internal 0.3.3-dev-409d5b4.0.409d5b4 → 0.3.3-dev-14b75b9.0.14b75b9
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 +4 -4
- package/src/config.d.ts +19 -0
- package/src/config.d.ts.map +1 -1
- package/src/config.js +21 -0
- package/src/js-utils.d.ts +5 -2
- package/src/js-utils.d.ts.map +1 -1
- package/src/js-utils.js +4 -1
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@agoric/internal",
|
|
3
|
-
"version": "0.3.3-dev-
|
|
3
|
+
"version": "0.3.3-dev-14b75b9.0.14b75b9",
|
|
4
4
|
"description": "Externally unsupported utilities internal to agoric-sdk",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "src/index.js",
|
|
@@ -20,7 +20,7 @@
|
|
|
20
20
|
"lint:types": "yarn run -T tsc"
|
|
21
21
|
},
|
|
22
22
|
"dependencies": {
|
|
23
|
-
"@agoric/base-zone": "0.1.1-dev-
|
|
23
|
+
"@agoric/base-zone": "0.1.1-dev-14b75b9.0.14b75b9",
|
|
24
24
|
"@endo/cache-map": "^1.1.0",
|
|
25
25
|
"@endo/common": "^1.2.13",
|
|
26
26
|
"@endo/compartment-mapper": "^1.6.3",
|
|
@@ -38,7 +38,7 @@
|
|
|
38
38
|
"jessie.js": "^0.3.4"
|
|
39
39
|
},
|
|
40
40
|
"devDependencies": {
|
|
41
|
-
"@agoric/cosmic-proto": "0.4.1-dev-
|
|
41
|
+
"@agoric/cosmic-proto": "0.4.1-dev-14b75b9.0.14b75b9",
|
|
42
42
|
"@endo/exo": "^1.5.12",
|
|
43
43
|
"@endo/init": "^1.1.12",
|
|
44
44
|
"@endo/ses-ava": "^1.3.2",
|
|
@@ -66,5 +66,5 @@
|
|
|
66
66
|
"typeCoverage": {
|
|
67
67
|
"atLeast": 92.89
|
|
68
68
|
},
|
|
69
|
-
"gitHead": "
|
|
69
|
+
"gitHead": "14b75b95620bd25b9a0f8f4ace551bb44b1f52de"
|
|
70
70
|
}
|
package/src/config.d.ts
CHANGED
|
@@ -32,4 +32,23 @@ export namespace VBankAccount {
|
|
|
32
32
|
export { address_1 as address };
|
|
33
33
|
}
|
|
34
34
|
}
|
|
35
|
+
/**
|
|
36
|
+
* ClusterName specifies a collection of networks. The specific networks
|
|
37
|
+
* associated with a particular name may vary from context to context, and may
|
|
38
|
+
* also overlap (e.g. a "local" cluster may connect to the same remote networks
|
|
39
|
+
* as a "testnet" cluster), but this type nevertheless supports cross-package
|
|
40
|
+
* coordination where the values associated with static labels are subject to
|
|
41
|
+
* choice of cluster. Some examples:
|
|
42
|
+
*
|
|
43
|
+
* - the chain ID for a static label like "Agoric" or "Ethereum"
|
|
44
|
+
* - the cryptographic hash for a static label like "BLD" or "USDC"
|
|
45
|
+
* - the URL for a service like "Agoric RPC" or "Axelar" or "Spectrum"
|
|
46
|
+
*
|
|
47
|
+
* "mainnet" should always include the Agoric network described by
|
|
48
|
+
* https://main.agoric.net/network-config rather than some other alternative.
|
|
49
|
+
*
|
|
50
|
+
* XXX This actually belongs somewhere else, possibly with refactoring.
|
|
51
|
+
* https://github.com/Agoric/agoric-sdk/pull/12185#discussion_r2500123226
|
|
52
|
+
*/
|
|
53
|
+
export type ClusterName = "local" | "testnet" | "mainnet";
|
|
35
54
|
//# sourceMappingURL=config.d.ts.map
|
package/src/config.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"config.d.ts","sourceRoot":"","sources":["config.js"],"names":[],"mappings":";;;
|
|
1
|
+
{"version":3,"file":"config.d.ts","sourceRoot":"","sources":["config.js"],"names":[],"mappings":";;;uBAuCU,CAAC,OAAO,QAAQ,EAAE,MAAM,OAAO,QAAQ,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;0BANrC,OAAO,GAAG,SAAS,GAAG,SAAS"}
|
package/src/config.js
CHANGED
|
@@ -13,6 +13,27 @@
|
|
|
13
13
|
* package are placed here.
|
|
14
14
|
*/
|
|
15
15
|
|
|
16
|
+
/**
|
|
17
|
+
* ClusterName specifies a collection of networks. The specific networks
|
|
18
|
+
* associated with a particular name may vary from context to context, and may
|
|
19
|
+
* also overlap (e.g. a "local" cluster may connect to the same remote networks
|
|
20
|
+
* as a "testnet" cluster), but this type nevertheless supports cross-package
|
|
21
|
+
* coordination where the values associated with static labels are subject to
|
|
22
|
+
* choice of cluster. Some examples:
|
|
23
|
+
*
|
|
24
|
+
* - the chain ID for a static label like "Agoric" or "Ethereum"
|
|
25
|
+
* - the cryptographic hash for a static label like "BLD" or "USDC"
|
|
26
|
+
* - the URL for a service like "Agoric RPC" or "Axelar" or "Spectrum"
|
|
27
|
+
*
|
|
28
|
+
* "mainnet" should always include the Agoric network described by
|
|
29
|
+
* https://main.agoric.net/network-config rather than some other alternative.
|
|
30
|
+
*
|
|
31
|
+
* XXX This actually belongs somewhere else, possibly with refactoring.
|
|
32
|
+
* https://github.com/Agoric/agoric-sdk/pull/12185#discussion_r2500123226
|
|
33
|
+
*
|
|
34
|
+
* @typedef {'local' | 'testnet' | 'mainnet'} ClusterName
|
|
35
|
+
*/
|
|
36
|
+
|
|
16
37
|
/**
|
|
17
38
|
* Event source ids used by the bridge device.
|
|
18
39
|
*
|
package/src/js-utils.d.ts
CHANGED
|
@@ -3,7 +3,10 @@ export const TRUE: true;
|
|
|
3
3
|
/**
|
|
4
4
|
* @typedef {<O extends Record<string, unknown>>(
|
|
5
5
|
* obj: O,
|
|
6
|
-
* ) =>
|
|
6
|
+
* ) => Exclude<
|
|
7
|
+
* { [K in keyof O]: K extends string ? [K, O[K]] : never }[keyof O],
|
|
8
|
+
* undefined
|
|
9
|
+
* >[]} TypedEntries
|
|
7
10
|
*/
|
|
8
11
|
export const typedEntries: TypedEntries;
|
|
9
12
|
/**
|
|
@@ -33,7 +36,7 @@ export function makeMeasureSeconds(currentTimeMillisec: () => number): <T>(fn: (
|
|
|
33
36
|
duration: number;
|
|
34
37
|
}>;
|
|
35
38
|
export function unprefixedProperties<P extends string, K extends string, V>(obj: Record<`${P}${K}`, V>, prefix: P): Record<K, V>;
|
|
36
|
-
export type TypedEntries = <O extends Record<string, unknown>>(obj: O) => { [K in keyof O]: K extends string ? [K, O[K]] : never; }[keyof O][];
|
|
39
|
+
export type TypedEntries = <O extends Record<string, unknown>>(obj: O) => Exclude<{ [K in keyof O]: K extends string ? [K, O[K]] : never; }[keyof O], undefined>[];
|
|
37
40
|
export type FromTypedEntries = <const Entries extends ReadonlyArray<readonly [PropertyKey, unknown]>>(entries: Entries) => { [Entry in Entries[number] as Entry[0]]: Entry[1]; };
|
|
38
41
|
export type TypedMap = <A extends unknown[], V>(arr: A, mapper: <K extends number>(el: A[K], idx: K, arr: A) => V) => V[];
|
|
39
42
|
export type LogLevel = (typeof logLevels)[keyof readonly ["debug", "log", "info", "warn", "error"] & number];
|
package/src/js-utils.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"js-utils.d.ts","sourceRoot":"","sources":["js-utils.js"],"names":[],"mappings":"AASA,yEAAyE;AACzE,mBAA0C,IAAI,CAAE;AAEhD
|
|
1
|
+
{"version":3,"file":"js-utils.d.ts","sourceRoot":"","sources":["js-utils.js"],"names":[],"mappings":"AASA,yEAAyE;AACzE,mBAA0C,IAAI,CAAE;AAEhD;;;;;;;GAOG;AACH,2BAAuC,YAAY,CAAsB;AAEzE;;;;;;GAMG;AACH,+BAA2C,gBAAgB,CAEzD;AAEF;;;;;GAKG;AACH,uBAAmC,QAAQ,CAEzC;AAEF,2EAMG;AAgBI,iCAJM,CAAC,SACH,CAAC,GACC,CAAC,CAE4D;AAsEnE,8BAVgC,CAAC,SAA1B,MAAM,CAAC,MAAM,EAAE,OAAO,CAAE,EACzB,CAAC,OACH,CAAC,UACD,CAAC,CAAC,SAAS,MAAM,CAAC,MAAM,EAAE,OAAO,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) => Exclude<
|
|
17
|
+
* { [K in keyof O]: K extends string ? [K, O[K]] : never }[keyof O],
|
|
18
|
+
* undefined
|
|
19
|
+
* >[]} TypedEntries
|
|
17
20
|
*/
|
|
18
21
|
export const typedEntries = /** @type {TypedEntries} */ (Object.entries);
|
|
19
22
|
|