@agoric/orchestration 0.1.1-dev-3915e4c.0 → 0.1.1-dev-24528f1.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 CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@agoric/orchestration",
3
- "version": "0.1.1-dev-3915e4c.0+3915e4c",
3
+ "version": "0.1.1-dev-24528f1.0+24528f1",
4
4
  "description": "Chain abstraction for Agoric's orchestration clients",
5
5
  "type": "module",
6
6
  "main": "index.js",
@@ -33,30 +33,33 @@
33
33
  },
34
34
  "homepage": "https://github.com/Agoric/agoric-sdk#readme",
35
35
  "dependencies": {
36
- "@agoric/async-flow": "0.1.1-dev-3915e4c.0+3915e4c",
37
- "@agoric/cosmic-proto": "0.4.1-dev-3915e4c.0+3915e4c",
38
- "@agoric/ertp": "0.16.3-dev-3915e4c.0+3915e4c",
39
- "@agoric/internal": "0.3.3-dev-3915e4c.0+3915e4c",
40
- "@agoric/network": "0.1.1-dev-3915e4c.0+3915e4c",
41
- "@agoric/notifier": "0.6.3-dev-3915e4c.0+3915e4c",
42
- "@agoric/store": "0.9.3-dev-3915e4c.0+3915e4c",
43
- "@agoric/time": "0.3.3-dev-3915e4c.0+3915e4c",
44
- "@agoric/vat-data": "0.5.3-dev-3915e4c.0+3915e4c",
45
- "@agoric/vats": "0.15.2-dev-3915e4c.0+3915e4c",
46
- "@agoric/vow": "0.1.1-dev-3915e4c.0+3915e4c",
47
- "@agoric/zoe": "0.26.3-dev-3915e4c.0+3915e4c",
48
- "@agoric/zone": "0.2.3-dev-3915e4c.0+3915e4c",
36
+ "@agoric/async-flow": "0.1.1-dev-24528f1.0+24528f1",
37
+ "@agoric/cosmic-proto": "0.4.1-dev-24528f1.0+24528f1",
38
+ "@agoric/ertp": "0.16.3-dev-24528f1.0+24528f1",
39
+ "@agoric/internal": "0.3.3-dev-24528f1.0+24528f1",
40
+ "@agoric/network": "0.1.1-dev-24528f1.0+24528f1",
41
+ "@agoric/notifier": "0.6.3-dev-24528f1.0+24528f1",
42
+ "@agoric/store": "0.9.3-dev-24528f1.0+24528f1",
43
+ "@agoric/time": "0.3.3-dev-24528f1.0+24528f1",
44
+ "@agoric/vat-data": "0.5.3-dev-24528f1.0+24528f1",
45
+ "@agoric/vats": "0.15.2-dev-24528f1.0+24528f1",
46
+ "@agoric/vow": "0.1.1-dev-24528f1.0+24528f1",
47
+ "@agoric/zoe": "0.26.3-dev-24528f1.0+24528f1",
48
+ "@agoric/zone": "0.2.3-dev-24528f1.0+24528f1",
49
49
  "@endo/base64": "^1.0.5",
50
50
  "@endo/errors": "^1.2.2",
51
51
  "@endo/far": "^1.1.2",
52
52
  "@endo/marshal": "^1.5.0",
53
- "@endo/patterns": "^1.4.0"
53
+ "@endo/patterns": "^1.4.0",
54
+ "@noble/hashes": "github:paulmillr/noble-hashes#ae060da"
54
55
  },
55
56
  "devDependencies": {
56
- "@agoric/swingset-liveslots": "0.10.3-dev-3915e4c.0+3915e4c",
57
+ "@agoric/swingset-liveslots": "0.10.3-dev-24528f1.0+24528f1",
57
58
  "@chain-registry/client": "^1.47.4",
58
59
  "@cosmjs/amino": "^0.32.3",
59
60
  "@cosmjs/proto-signing": "^0.32.3",
61
+ "@endo/bundle-source": "^3.2.3",
62
+ "@endo/import-bundle": "^1.1.2",
60
63
  "@endo/ses-ava": "^1.2.2",
61
64
  "ava": "^5.3.1",
62
65
  "c8": "^9.1.0",
@@ -91,5 +94,5 @@
91
94
  "typeCoverage": {
92
95
  "atLeast": 97.99
93
96
  },
94
- "gitHead": "3915e4cfaf6b3a86d0f5d5e69a57ca5166e2d721"
97
+ "gitHead": "24528f1e377f41e13e9fe47a6f04c0f4b0c33452"
95
98
  }
@@ -0,0 +1,7 @@
1
+ export function denomHash({ portId, channelId, path, denom, }: {
2
+ portId?: string | undefined;
3
+ channelId?: string | undefined;
4
+ path?: string | undefined;
5
+ denom: string;
6
+ }): string;
7
+ //# sourceMappingURL=denomHash.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"denomHash.d.ts","sourceRoot":"","sources":["denomHash.js"],"names":[],"mappings":"AAaO,+DALJ;IAAsB,MAAM;IACN,SAAS;IACT,IAAI;IACL,KAAK,EAAlB,MAAM;CAChB,UASA"}
@@ -0,0 +1,22 @@
1
+ // @ts-check
2
+ import { sha256 } from '@noble/hashes/sha256';
3
+ import { bytesToHex } from '@noble/hashes/utils';
4
+
5
+ /**
6
+ * cf. https://tutorials.cosmos.network/tutorials/6-ibc-dev/
7
+ *
8
+ * @param {object} opts
9
+ * @param {string} [opts.portId]
10
+ * @param {string} [opts.channelId] required unless `path` is supplied
11
+ * @param {string} [opts.path] alternative to portId, channelId
12
+ * @param {string} opts.denom base denom
13
+ */
14
+ export const denomHash = ({
15
+ portId = 'transfer',
16
+ channelId = /** @type {string | undefined} */ (undefined),
17
+ path = `${portId}/${channelId}`,
18
+ denom,
19
+ }) => {
20
+ const h = sha256.create().update(`${path}/${denom}`).digest();
21
+ return bytesToHex(h).toUpperCase();
22
+ };